Getting PlexAMP to automatically start on Raspberry PI

Server Version#: 1.32.7.7621
Player Version#: Latest

I am having a bear of a time getting the PlexAMP on a headless Raspberry PI to automatically start.

I got it installed and it works when I manually start it in the CLI over an SSH session but it just the screen just hangs on the terminal and you can do everything you need to in the PlexAMP on the PI at https://[Raspberry PI IP Address}:32500

I followed these instructions including editing the service file with my username How to start Plexamp automatically when you power on your Raspberry Pi | How To Hi-Fi

And I rebooted it but the service still does not automatically start. I can manually start it all day.

It seems silly to me not to have this automatically start as you can control it over the web. I want to use this to play my Christmas playlist over an FM transmitter for my Christmas lights. It can run 24/7 for all I care. I just need to not have to manually start it up. I can use the web page over port 32500 to start, stop, or change playlists.

after rebooting, what do you see when you enter the following …

systemctl status plexamp.service

and what audio output are you using?

● plexamp.service - Plexamp
Loaded: loaded (/lib/systemd/system/plexamp.service; enabled; vendor preset: enabled)
Active: failed (Result: exit-code) since Thu 2023-11-30 17:39:35 CST; 2h 24min ago
Process: 595 ExecStart=/home/khilzinger/.nvm/versions/node/v16.20.2/bin/node /home/khilzinger/plexamp/js/index.js (code=exited, status=200/CHDIR)
Main PID: 595 (code=exited, status=200/CHDIR)
CPU: 7ms

Nov 30 17:39:34 KAH-OFFICEPI01 systemd[1]: plexamp.service: Scheduled restart job, restart counter is at 4.
Nov 30 17:39:34 KAH-OFFICEPI01 systemd[1]: Stopped Plexamp.
Nov 30 17:39:34 KAH-OFFICEPI01 systemd[1]: Started Plexamp.
Nov 30 17:39:34 KAH-OFFICEPI01 systemd[1]: plexamp.service: Main process exited, code=exited, status=200/CHDIR
Nov 30 17:39:34 KAH-OFFICEPI01 systemd[1]: plexamp.service: Failed with result ‘exit-code’.
Nov 30 17:39:35 KAH-OFFICEPI01 systemd[1]: plexamp.service: Scheduled restart job, restart counter is at 5.
Nov 30 17:39:35 KAH-OFFICEPI01 systemd[1]: Stopped Plexamp.
Nov 30 17:39:35 KAH-OFFICEPI01 systemd[1]: plexamp.service: Start request repeated too quickly.
Nov 30 17:39:35 KAH-OFFICEPI01 systemd[1]: plexamp.service: Failed with result ‘exit-code’.
Nov 30 17:39:35 KAH-OFFICEPI01 systemd[1]: Failed to start Plexamp.

thanks … can you also check the following …

which node

and

node -v

khilzinger@KAH-OFFICEPI01:/lib/systemd/system $ which node
/home/khilzinger/.nvm/versions/node/v16.20.2/bin/node

khilzinger@KAH-OFFICEPI01:/lib/systemd/system $ node -v
v16.20.2

thanks … not seeing anything obvious yet … sorry to keep asking for more info, what does this show?

cat /lib/systemd/system/plexamp.service

No, I 100% appreciate it. According to the documentation, I was supposed to replace “pi” with my username and I did verify the paths for “ExecStart”

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

[Service]
Type=simple
User=khilzinger
WorkingDirectory=/home/pi/plexamp
! ExecStart=/usr/bin/node /home/pi/plexamp/js/index.js
ExecStart=/home/khilzinger/.nvm/versions/node/v16.20.2/bin/node /home/khilzinger/plexamp/js/index.js
Restart=on-failure

[Install]
WantedBy=multi-user.target

ah, this might be it …
looks like you need to change to your user name in the WorkingDirectory line

1 Like

That was it. THANK YOU!!!

1 Like

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