You are not logged in.

#1 2018-09-18 18:29:07

shoelesshunter
Member
From: USA
Registered: 2014-05-18
Posts: 289

running emby-server as other user fails

I am using Emby and I'd like to run it as a different user. By default it runs like this:

[Unit]
Description=Emby brings together your videos, music, photos, and live television.

[Service]
EnvironmentFile=/etc/conf.d/emby-server
WorkingDirectory=/usr/lib/emby-server
ExecStart=/usr/bin/emby-server
RestartForceExitStatus=3
User=emby
Group=emby

[Unit]
After=network.target

[Install]
WantedBy=multi-user.target



I want to run it as jmgant:jmgant (that's my main user on the system).

I change the service file to look like this:

[Unit]
Description=Emby brings together your videos, music, photos, and live television.

[Service]
EnvironmentFile=/etc/conf.d/emby-server
WorkingDirectory=/usr/lib/emby-server
ExecStart=/usr/bin/emby-server
RestartForceExitStatus=3
User=jmgant
Group=jmgant

[Unit]
After=network.target

[Install]
WantedBy=multi-user.target

I issue systemctl daemon-reload
and
systemctl restart emby-server

and I get this error:

* emby-server.service - Emby brings together your videos, music, photos, and live telev>
   Loaded: loaded (/usr/lib/systemd/system/emby-server.service; enabled; vendor preset:>
   Active: failed (Result: core-dump) since Tue 2018-09-18 14:23:14 EDT; 3s ago
  Process: 11044 ExecStart=/usr/bin/emby-server (code=dumped, signal=ABRT)
Main PID: 11044 (code=dumped, signal=ABRT)

Sep 18 14:23:14 syd emby-server[11044]:    --- End of inner exception stack trace ---
Sep 18 14:23:14 syd emby-server[11044]:    at Interop.ThrowExceptionForIoErrno(ErrorInf>
Sep 18 14:23:14 syd emby-server[11044]:    at Microsoft.Win32.SafeHandles.SafeFileHandl>
Sep 18 14:23:14 syd emby-server[11044]:    at System.IO.FileStream..ctor(String path, F>
Sep 18 14:23:14 syd emby-server[11044]:    at Emby.Server.Implementations.Logging.FileL>
Sep 18 14:23:14 syd emby-server[11044]:    at Emby.Server.Implementations.Logging.Simpl>
Sep 18 14:23:14 syd emby-server[11044]:    at EmbyServer.Program.Main(String[] args)
Sep 18 14:23:14 syd emby-server[11044]:    at EmbyServer.Program.<Main>(String[] args)
Sep 18 14:23:14 syd systemd[1]: emby-server.service: Main process exited, code=dumped, >
Sep 18 14:23:14 syd systemd[1]: emby-server.service: Failed with result 'core-dump'.

I did this change fine on an Ubuntu system. Why won't it run as *another* user on my Arch system?

Last edited by shoelesshunter (2018-09-18 18:29:36)

Offline

#2 2018-10-01 02:00:57

tehgeek
Member
Registered: 2013-02-24
Posts: 12

Re: running emby-server as other user fails

Try also changing the permissions on the files in both /var/lib/emby and /usr/lib/emby-server and then restart emby.

Offline

#3 2018-10-01 02:09:12

jasonwryan
Anarchist
From: .nz
Registered: 2009-05-09
Posts: 30,424
Website

Re: running emby-server as other user fails

..and use code tags (I won't point you at the Code again): https://wiki.archlinux.org/index.php/Co … s_and_code


Arch + dwm   •   Mercurial repos  •   Surfraw

Registered Linux User #482438

Offline

Board footer

Powered by FluxBB