Jump to content

Ubuntu


Luke

Recommended Posts

hurricanehrndz

Yes. And ensure that /usr/bin/emby-server exist and is executable and replace it with the one I linked earlier as well. It might be different, I have been working on it all night long for other distros and projects.

Link to post
Share on other sites
nicheplayer

OK. Uploaded the new emby-server and then ran 

/etc/init.d/emby-server start

Got

/etc/init.d/emby-server start
[....] Starting emby-server daemon:/usr/bin/emby-server: 30: [: 1: unexpected operator
. ok 

But the server is running!

Link to post
Share on other sites
hurricanehrndz

Okay, did you run it as nicheplayer007

 

OK. Uploaded the new emby-server and then ran 

/etc/init.d/emby-server start

Got

/etc/init.d/emby-server start
[....] Starting emby-server daemon:/usr/bin/emby-server: 30: [: 1: unexpected operator
. ok 

But the server is running!

Link to post
Share on other sites

I'm having a similar issue too - can no longer start after the update ...

 

This is the output of systemctl status emby-server

● emby-server.service - Emby Media Server
   Loaded: loaded (/lib/systemd/system/emby-server.service; disabled; vendor preset: enabled)
   Active: failed (Result: exit-code) since Sat 2015-12-12 22:15:43 AEDT; 7min ago
  Process: 14187 ExecStopPost=/usr/bin/emby-server clear (code=exited, status=0/SUCCESS)
  Process: 14178 ExecStart=/usr/bin/emby-server start (code=exited, status=1/FAILURE)
 Main PID: 14178 (code=exited, status=1/FAILURE)

Dec 12 22:15:43 machine emby-server[14178]: /usr/bin/emby-server: 82: /usr/bin/emby-server: cannot create : Directory nonexistent
Dec 12 22:15:43 machine su[14178]: No passwd entry for user 'env'
Dec 12 22:15:43 machine su[14178]: FAILED su for env by root
Dec 12 22:15:43 machine systemd[1]: emby-server.service: main process exited, code=exited, status=1/FAILURE
Dec 12 22:15:43 machine emby-server[14187]: dirname: missing operand
Dec 12 22:15:43 machine emby-server[14187]: Try 'dirname --help' for more information.
Dec 12 22:15:43 machine emby-server[14187]: chown: missing operand after ‘.’
Dec 12 22:15:43 machine emby-server[14187]: Try 'chown --help' for more information.
Dec 12 22:15:43 machine systemd[1]: Unit emby-server.service entered failed state.
Dec 12 22:15:43 machine systemd[1]: emby-server.service failed.

... and sudoers.d/emby

#Allow emby to start, stop and restart itself
emby ALL=(ALL) NOPASSWD: /bin/systemctl restart emby-server.service
emby ALL=(ALL) NOPASSWD: /etc/init.d/emby-server *
emby ALL=(ALL) NOPASSWD: /usr/sbin/service emby-server *
emby ALL=(ALL) NOPASSWD: /usr/sbin/invoke-rc.d emby-server *
#Allow the server to mount iso images
emby ALL=(ALL) NOPASSWD: /bin/mount
emby ALL=(ALL) NOPASSWD: /bin/umount

Defaults:emby !requiretty
Link to post
Share on other sites
nicheplayer

Script has been updated. 

 

I downloaded it again from the link you posted earlier this morning. Shut down emby server and then SCPed the script to the server and checked permissions.

root@machine:/usr/bin# ls -la /usr/lib/emby-server/
total 32
drwxr-xr-x  3 root root  4096 Dec  6 12:24 .
drwxr-xr-x 66 root root 12288 Dec  6 13:04 ..
drwxr-xr-x  5 root root 12288 Dec  6 12:24 bin
-rwxr-xr-x  1 root root   778 Dec 12 10:37 restart.sh

Started emby with /etc/init.d/emby-server start

[....] Starting emby-server daemon:/usr/bin/emby-server: 30: [: 1: unexpected operator
. ok 

Went to the web dashboard and hit restart. Shutdown button went gray. Refreshed the page, and no connection. Here's the server log from the event, FWIW.

Link to post
Share on other sites
hurricanehrndz

Why do you keep trying the button, there is no sense if you can't not get your user nicheplayer007 to sudo without a password. Line 30 of the start script should have been fixed. I will double check it.

 

Sent from my D6603 using Tapatalk

Link to post
Share on other sites
hurricanehrndz

what happens when you run:

 

su nicheplayer007

sudo /etc/init.d/emby-server restart <--- this needs to work without a password before you can even hit the button

Link to post
Share on other sites
nicheplayer

what happens when you run:

 

su nicheplayer007

sudo /etc/init.d/emby-server restart <--- this needs to work without a password before you can even hit the button

$ sudo /etc/init.d/emby-server restart
[sudo] password for nicheplayer007: 
Link to post
Share on other sites
hurricanehrndz

well, i don't know what to tell you. I have done this hundreds of time and it works. Here are some things to check:

 

1. permission of /etc/sudoers.d/emby should 0640

2. ensure nicheplayer007 is part of group emby

3. ensure /etc/sudoers permissions is 0640

4. ensure your file /etc/sudoers.d/emby looks as follows: https://github.com/hurricanehrndz/Emby.Build/blob/ft_docker/builders/emby-server/debfiles/emby

 

Once you can get sudo /etc/init.demby-server restart working as nicheplayer007 we can move on. 

Edited by hurricanehrndz
  • Like 1
Link to post
Share on other sites
nicheplayer

You know, I was just looking at /etc/sudoers.d/ . There are two emby files in there:

 

root@machine:/etc/sudoers.d# ls -la

total 16

drwxr-xr-x   2 root root 4096 Dec 12 03:22 .

drwxr-xr-x 105 root root 4096 Dec 12 02:26 ..

-r--r-----   1 root root    0 Dec 12 02:11 emby

-rw-r-----   1 root root 1541 Dec 12 03:22 emby.txt

-r--r-----   1 root root  958 Mar  1  2013 README

 

emby is empty. emby.txt looks like the github file you linked above. So not sure how that happened. So anyway, I removed emby, moved emby.txt to emby, did su nicheplayer007 and then sudo /etc/init.d/emby-server restart and got:

$ sudo /etc/init.d/emby-server restart
[ ok ] Stopping emby-server daemon:[....] apparently already stopped.
. ok 
[....] Starting emby-server daemon:/usr/bin/emby-server: 30: [: 1: unexpected operator
. ok 

!!  :D

  • Like 1
Link to post
Share on other sites
nicheplayer

ps aux | grep emby:

root@machine:/# ps aux | grep emby
root     25641  0.0  0.0  37072  1088 pts/0    S    12:37   0:00 su -s /bin/sh -c exec "$0" "$@" nicheplayer007 -- env MONO_THREADS_PER_CPU=500 MONO_GC_PARAMS=nursery-size=128m LD_LIBRARY_PATH= /usr/bin/mono-sgen --optimize=all /usr/lib/emby-server/bin/MediaBrowser.Server.Mono.exe -programdata /var/lib/emby-server -ffmpeg /usr/bin/ffmpeg -ffprobe /usr/bin/ffprobe -restartpath /usr/lib/emby-server/restart.sh
1000     25657  3.5 13.1 781552 275312 ?       Ssl  12:37   0:36 /usr/bin/mono-sgen --optimize=all /usr/lib/emby-server/bin/MediaBrowser.Server.Mono.exe -programdata /var/lib/emby-server -ffmpeg /usr/bin/ffmpeg -ffprobe /usr/bin/ffprobe -restartpath /usr/lib/emby-server/restart.sh
root     25978  0.0  0.0   7724   944 pts/0    S+   12:54   0:00 grep emby

sudo /usr/lib/emby-server/restart.sh :

root@machine:/# su nicheplayer007
$ sudo /usr/lib/emby-server/restart.sh
[sudo] password for nicheplayer007: 
Sorry, user nicheplayer007 is not allowed to execute '/usr/lib/emby-server/restart.sh' as root on machine.

ps aux | grep emby :

root@machine:/# ps aux | grep emby
root     25641  0.0  0.0  37072  1088 pts/0    S    12:37   0:00 su -s /bin/sh -c exec "$0" "$@" nicheplayer007 -- env MONO_THREADS_PER_CPU=500 MONO_GC_PARAMS=nursery-size=128m LD_LIBRARY_PATH= /usr/bin/mono-sgen --optimize=all /usr/lib/emby-server/bin/MediaBrowser.Server.Mono.exe -programdata /var/lib/emby-server -ffmpeg /usr/bin/ffmpeg -ffprobe /usr/bin/ffprobe -restartpath /usr/lib/emby-server/restart.sh
1000     25657  3.3 11.9 781552 250884 ?       Ssl  12:37   0:41 /usr/bin/mono-sgen --optimize=all /usr/lib/emby-server/bin/MediaBrowser.Server.Mono.exe -programdata /var/lib/emby-server -ffmpeg /usr/bin/ffmpeg -ffprobe /usr/bin/ffprobe -restartpath /usr/lib/emby-server/restart.sh
root     26040  0.0  0.0   7724   944 pts/0    S+   12:58   0:00 grep emby
Edited by nicheplayer
Link to post
Share on other sites
nicheplayer

ps aux | grep emby

root     25641  0.0  0.0  37072  1088 pts/0    S    12:37   0:00 su -s /bin/sh -c exec "$0" "$@" nicheplayer007 -- env MONO_THREADS_PER_CPU=500 MONO_GC_PARAMS=nursery-size=128m LD_LIBRARY_PATH= /usr/bin/mono-sgen --optimize=all /usr/lib/emby-server/bin/MediaBrowser.Server.Mono.exe -programdata /var/lib/emby-server -ffmpeg /usr/bin/ffmpeg -ffprobe /usr/bin/ffprobe -restartpath /usr/lib/emby-server/restart.sh
1000     25657  2.9 14.8 807708 310996 ?       Ssl  12:37   1:04 /usr/bin/mono-sgen --optimize=all /usr/lib/emby-server/bin/MediaBrowser.Server.Mono.exe -programdata /var/lib/emby-server -ffmpeg /usr/bin/ffmpeg -ffprobe /usr/bin/ffprobe -restartpath /usr/lib/emby-server/restart.sh
root     26300  0.0  0.0   7724   940 pts/0    S+   13:13   0:00 grep emby

then, after running the su and /usr/lib/emby-server/restart.sh , I'm prompted for nicheplayer007's password. I enter it, and there's no feedback, just a return to the $ prompt. Exiting out of that and running ps aux | grep emby gets

root     25641  0.0  0.0  37072  1088 pts/0    S    12:37   0:00 su -s /bin/sh -c exec "$0" "$@" nicheplayer007 -- env MONO_THREADS_PER_CPU=500 MONO_GC_PARAMS=nursery-size=128m LD_LIBRARY_PATH= /usr/bin/mono-sgen --optimize=all /usr/lib/emby-server/bin/MediaBrowser.Server.Mono.exe -programdata /var/lib/emby-server -ffmpeg /usr/bin/ffmpeg -ffprobe /usr/bin/ffprobe -restartpath /usr/lib/emby-server/restart.sh
1000     25657  2.9 14.1 808732 297584 ?       Ssl  12:37   1:10 /usr/bin/mono-sgen --optimize=all /usr/lib/emby-server/bin/MediaBrowser.Server.Mono.exe -programdata /var/lib/emby-server -ffmpeg /usr/bin/ffmpeg -ffprobe /usr/bin/ffprobe -restartpath /usr/lib/emby-server/restart.sh
root     26370  0.0  0.0   7724   944 pts/0    S+   13:18   0:00 grep emby
Link to post
Share on other sites
hurricanehrndz

okay

Dude, you might really have to start troubleshooting this yourself. I have a ton to do, and this thread is getting super long. Go to chat.
 
ps aux | grep emby
su nicheplayer007
sudo /etc/init.d/emby-server restart
ps aux | grep emby
  • Like 1
Link to post
Share on other sites
nicheplayer

 

okay

Dude, you might really have to start troubleshooting this yourself. I have a ton to do, and this thread is getting super long. 

 

Totally understand. I really do appreciate the assistance. I'll look into wiping my current install and just starting from scratch.

Link to post
Share on other sites
hurricanehrndz

I'm in the chat. And I wouldn't do a reinstall just yet, there is a ton of fixes going into the next update. Thanks for the bugs you found.

Link to post
Share on other sites
maiky jonathan gomes

My friends , since I moved to my access and even put to Emby access so that it still does not recognize the second hd , you guys have any help for me

Link to post
Share on other sites

Totally different issue. Remove /etc/default/emby-sever and reinstall

 

Sent from my D6603 using Tapatalk

 

This worked : dpkg --force-confmiss -i /var/cache/apt/archives/emby-server_3.0.5781.5_all.deb




			
				


	Edited  by lordvader
	
	

			
		
Link to post
Share on other sites

I installed Ubuntu 15.10 on the day it was released. Upon realizing that Emby-server was not ready for 15.10 I felt like a fool. My system is primarily games and Emby-server. I followed the instructions and installed the mono tools from the 15.04 repo alongside the deb posted to the forums. This worked but as soon as I finished the install I started getting this error when starting Emby-server.

 

"Error: No space left on device"

 

I have plenty of space on all my hard drive partitions, so I have no idea where this is coming from. I believe it is linked to what was installed by the 15.04 repo but I do not know for certain. I don't really know what was installed so I don't know how to revert and fix this. I have switched to th 15.10 repository and installed emby-server. It works fine, but I get that error message on launch.

 

Any idea what would cause this or where this is coming from?

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...