Plexamp Headless 4.11.2 not starting on Raspberry Pi

Using a Raspberry Pi 3B+ on Rasp OS lite 64bit

Followed the howtohifi guide but when I try to start Plexamp on the pi with “node plexamp/js/index.js” I get the following in the terminal window with no response:

Starting Plexamp 4.11.2
Settings: Parsing 23012 bytes into JSON for discovery:hubs.

Plexamp is started and I can navigate to the web portal but if I close the terminal window it stops. Any help would be appreciated.

there’s another guide that shows how to autostart Plexamp when the Pi turns on … sounds like you still might need to set up the service

starting manually while logged in is good for first run, but as you’ve observed, closing the terminal will also close Plexamp

I’ve been using odinb’s script to install/update plexamp headless for many, many versions without issue, but as of 4.11.2, I can see that plexamp.service is running, but I can’t access the webui unless I start Plexamp manually (and, obviously, it doesn’t persist if I close my SSH session). Any ideas why?

Hi!

Works on my setup! Have you changed user for the install when upgrading?
What does “systemctl status plexamp” and “cat /etc/systemd/system/plexamp.service” give?
For the service it should be running as the user it was installede for, and same thing for the service file, it should reflect the user it was installed for.

Worst case, you can try a clean install.

This is what the output and file should look like for the “piuser”:

piuser@PlexAmp4:~ $ systemctl status plexamp
● plexamp.service - Plexamp
     Loaded: loaded (/etc/systemd/system/plexamp.service; enabled; preset: enabled)
     Active: active (running) since Tue 2024-10-01 09:15:47 CDT; 1 day 6h ago
   Main PID: 725 (node)
      Tasks: 18 (limit: 1582)
        CPU: 1min 21.762s
     CGroup: /system.slice/plexamp.service
             └─725 /usr/bin/node /home/piuser/plexamp/js/index.js

Oct 01 09:15:47 PlexAmp4 systemd[1]: Started plexamp.service - Plexamp.
Oct 01 09:15:50 PlexAmp4 node[725]: Starting Plexamp 4.11.2
Oct 01 09:15:50 PlexAmp4 node[725]: Settings: Parsing 31570 bytes into JSON for discovery:hubs.
piuser@PlexAmp4:~ $ cat /etc/systemd/system/plexamp.service
[Unit]
Description=Plexamp
After=network-online.target
Requires=network-online.target

[Service]
Type=simple
User=piuser
WorkingDirectory=/home/piuser/plexamp
ExecStart=/usr/bin/node /home/piuser/plexamp/js/index.js
Restart=on-failure

[Install]
WantedBy=multi-user.target
piuser@PlexAmp4:~ $

Works on my setup!

Congrats.

Here’s the output of systemctl status:

● plexamp.service - Plexamp
Loaded: loaded (/etc/systemd/system/plexamp.service; enabled; preset: enabled)
Active: active (running) since Wed 2024-10-02 20:21:29 BST; 18h ago
Main PID: 525 (node)
Tasks: 16 (limit: 1069)
CPU: 7.710s
CGroup: /system.slice/plexamp.service
└─525 /usr/bin/node /home/dietpi/plexamp/js/index.js

Notice: journal has been rotated since unit was started, output may be incomplete.

So the service is running, but it doesn’t appear to have opened Plexamp…

Here’s my service file:

[Unit]
Description=Plexamp
After=network-online.target
Requires=network-online.target

[Service]
Type=simple
User=dietpi
WorkingDirectory=/dietpi/plexamp
ExecStart=/usr/bin/node /dietpi/plexamp/js/index.js
Restart=on-failure
Group=dietpi

[Install]
WantedBy=multi-user.target

(I’m running dietpi, obviously) The service is written exactly the same way as it was for version 4.11.1 and earlier, so I’m confused why there’s a problem now.

WorkingDirectory and ExecStart should both have /home before /dietpi … maybe it got removed unintentionally while updating, else i’m not sure how it would have worked before

Hmm, that was previously a quirk of DietPi (no /home directory), so maybe something in the OS has changed. That never would have worked before, but it seems to have fixed my problem for now. Thanks.

Funny enough, this doesn’t seem to work on another instance on an RPi Zero 2:

● plexamp.service - Plexamp
Loaded: loaded (/etc/systemd/system/plexamp.service; enabled; preset: enabled)
Active: active (running) since Thu 2024-10-03 10:51:09 EDT; 5h 23min ago
Main PID: 405 (node)
Tasks: 16 (limit: 478)
CPU: 9.177s
CGroup: /system.slice/plexamp.service
└─405 /usr/bin/node /home/dietpi/plexamp/js/index.js

Oct 03 10:51:09 DietPi systemd[1]: Started plexamp.service - Plexamp.
Oct 03 10:51:18 DietPi node[405]: Starting Plexamp 4.11.2

[Unit]
Description=Plexamp
After=network-online.target
Requires=network-online.target

[Service]
Type=simple
User=dietpi
WorkingDirectory=/home/dietpi/plexamp
ExecStart=/usr/bin/node /home/dietpi/plexamp/js/index.js
Restart=on-failure
Group=dietpi

[Install]
WantedBy=multi-user.target

What am I missing?

that looks like it should, appears to be running … are there Plexamp logs?

Nope, the logs only show entries from back in September. :man_shrugging:

Ah, you do not run RaspbianOS! That was not mentioned when you stated you used the script to install/upgrade!
Well, the script is not actively maintained for Dietpi, since I run RaspbianOS on my Pis. Let me see if I can get some time to re-verify it on Dietpi!
Dietpi is best effort for the script, and can therefor break at times, it is mentioned on the wiki of the page.
Feel free to open a ticket on the page on github, and I will respond/follow up there.

Just did a fresh install of DietPi v9.7.1 on one of my RPi4. Then ran the " install_Plexamp_pi.sh" script using sudo, and did a reboot.

After reboot, I ran the following 2 commands as instructed:
node /home/dietpi/plexamp/js/index.js
sudo systemctl enable plexamp.service && sudo systemctl start plexamp.service

Logged in via GUI, and authenticated, and were able to play music!

Did have to update the script to fix a minor error on the audio-card setup, so that should work now also (did for me). Latest revision is on github.

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.