No2: Correct way of running UMS as daemon?

For help and support with Universal Media Server
Forum rules
Please make sure you follow the Problem Reporting Guidelines before posting if you want a reply
Post Reply
hornetster
Posts: 4
Joined: Wed Oct 16, 2019 7:13 pm

No2: Correct way of running UMS as daemon?

Post by hornetster »

No2 - because it has been asked before, but a long time ago....

Have setup UMS, originally being run as me, on Ubuntu 18.04.3LTS x64 8GB, and run from the GUI, was able to set it up, it accessed the media, and all was good. But.....
The PC I am running it on, is basically headless(?), but does run a GUI, and I have access via Teamviewer, but generally connect using ssh, so I wish to configure UMS to run on startup, via systemd.
Have created a ums user, and set them as owner of the ums directory (setup under /opt/ums/)
Have created /etc/systemd/system/ums.service, containing:

Code: Select all

[Unit]
Description=Universal Media Server
After=syslog.target network.target rpcbind.service

[Service]
User=ums
Group=users
ExecStart=/opt/ums/UMS.sh

[Install]
WantedBy=multi-user.target
Seems to be running, but is limping... Webpage is accessible, but no data (when originally run as user, data was present and accessible.)
Would guess that it is either a config issue (Have added my media directory to UMS.conf), or a permissions issue?
atamariya
Posts: 146
Joined: Sun Aug 11, 2013 1:15 am

Re: No2: Correct way of running UMS as daemon?

Post by atamariya »

UMS.conf is usually created in $HOME/.config directory. When you're running it as a daemon, you should configure the one in Root's home directory.
hornetster
Posts: 4
Joined: Wed Oct 16, 2019 7:13 pm

Re: No2: Correct way of running UMS as daemon?

Post by hornetster »

Slight update on this... (Think I am correct....)
When starting as "ums" the user, the config is in /home/ums, and need to update any relevant info in this (shared folders and folders to scan, etc)
Believe I now have it working, using basically the above startup file etc.
Not real pretty and need to sort out other options, but so far, so good....
Post Reply