FAQ  •  Register  •  Login

Problem after each reboot

<<

jo343

Serviio newbie

Posts: 17

Joined: Thu Aug 23, 2012 7:57 pm

Post Sun Sep 16, 2012 4:30 pm

Problem after each reboot

Hi,

After each reboot, I get a "The server is not accessible. Please try again later" error. I'm running Ubuntu Server 12.04, Serviio 1.0.1 and ffmpeg built from the source on the serviio download page.

I'm even running the serviio process using "root" to make sure it has all the required rights.

Here's the detail log:
  Code:
2012-09-16 11:59:47,040 DEBUG [WebServer] Incoming connection from /192.168.1.14:37496
2012-09-16 11:59:47,041 DEBUG [RendererDAOImpl] Reading a Renderer with ip address 192.168.1.14
2012-09-16 11:59:47,042 DEBUG [ServiceControlRequestHandler] ServiceControl request received for action '"urn:schemas-upnp-org:service:ContentDirectory:1#Browse"' from 192.168.1.14:
2012-09-16 11:59:47,042 DEBUG [RendererDAOImpl] Reading a Renderer with ip address 192.168.1.14
2012-09-16 11:59:47,045 DEBUG [ContentDirectory] Browse() called for renderer KDL-46EX700 (profile sony2010) with parameters: objectID = V_T^INI_65, browseFlag = BrowseDirectChildren, filter = dc:title,av:mediaClass,dc:date,@childCount,res,upnp:class,res@resolution,upnp:album,upnp:genre,upnp:albumArtURI,upnp:albumArtURI@dlna:profileID,dc:creator,res@size,res@duration,res@bitrate,res@protocolInfo, startIndex = 0, count = 10, sortCriteria =
2012-09-16 11:59:47,046 DEBUG [AccessGroupDAOImpl] Reading a AccessGroup (id = 1)
2012-09-16 11:59:47,046 DEBUG [LocalContentCacheDecorator] Found entry in the cache (local_default), returning it
2012-09-16 11:59:47,054 DEBUG [ServiceControlRequestHandler] Returning OK SOAP message
2012-09-16 11:59:49,958 DEBUG [FeedUpdaterThread] Checking for new and expired online resources
2012-09-16 11:59:49,958 DEBUG [OnlineRepositoryDAOImpl] Reading all OnlineRepositories
2012-09-16 11:59:51,692 DEBUG [WebServer] Incoming connection from /192.168.1.14:37497
2012-09-16 11:59:51,693 DEBUG [RendererDAOImpl] Reading a Renderer with ip address 192.168.1.14
2012-09-16 11:59:51,693 DEBUG [ResourceTransportRequestHandler] HEAD /resource/10/MEDIA_ITEM/AVC_TS_MP_HD_AC3_ISO-2/ORIGINAL HTTP/1.1, headers = [getcontentFeatures.dlna.org: 1,Pragma: getIfoFileURI.dlna.org,transferMode.dlna.org: Streaming,X-AV-Physical-Unit-Info: pa="BRAVIA KDL-46EX700";,X-AV-Client-Info: av=5.0; cn="Sony Corporation"; mn="BRAVIA KDL-46EX700"; mv="1.7";,Host: 192.168.1.99:8895]]
2012-09-16 11:59:51,694 DEBUG [RendererDAOImpl] Reading a Renderer with ip address 192.168.1.14
2012-09-16 11:59:51,694 DEBUG [ResourceDeliveryProcessor] Resource request accepted. Using client 'IPAddress=/192.168.1.14, Profile=Sony Bravia TV (2010)'
2012-09-16 11:59:51,694 DEBUG [ResourceDeliveryProcessor] Request for resource 10 and type 'MEDIA_ITEM' received
2012-09-16 11:59:51,694 DEBUG [MediaResourceRetrievalStrategy] Getting information about media item 10 (local)
2012-09-16 11:59:51,695 DEBUG [MediaItemDAOImpl] Reading a MediaItem (id = 10)
2012-09-16 11:59:51,696 DEBUG [VideoDAOImpl] Reading a Video (id = 10)
2012-09-16 11:59:51,697 DEBUG [VideoDeliveryEngine] Retrieving resource information for item 10, format AVC_TS_MP_HD_AC3_ISO and profile Sony Bravia TV (2010)
2012-09-16 11:59:51,697 DEBUG [AbstractTranscodingDeliveryEngine] Getting media info for transcoded version of file movie.mkv
2012-09-16 11:59:51,697 DEBUG [VideoDeliveryEngine] Found Format profile for transcoded file movie.mkv: AVC_TS_MP_HD_AC3_ISO
2012-09-16 11:59:51,697 DEBUG [ResourceDeliveryProcessor] Sending HEAD response back
2012-09-16 11:59:51,697 DEBUG [ResourceTransportRequestHandler] HTTP/1.1 200 OK, headers = [[Content-Type: video/mpeg,Date: Sun, 16 Sep 2012 15:59:51 GMT,Server: Linux, UPnP/1.0 DLNADOC/1.50, Serviio/1.0.1,Cache-control: no-cache,contentFeatures.dlna.org: DLNA.ORG_PN=AVC_TS_HD_60_AC3_ISO;DLNA.ORG_OP=10;DLNA.ORG_CI=1;DLNA.ORG_FLAGS=01500000000000000000000000000000,transferMode.dlna.org: Streaming]]
2012-09-16 11:59:51,707 DEBUG [WebServer] Incoming connection from /192.168.1.14:37498
2012-09-16 11:59:51,709 DEBUG [RendererDAOImpl] Reading a Renderer with ip address 192.168.1.14
2012-09-16 11:59:51,710 DEBUG [ResourceTransportRequestHandler] GET /resource/10/MEDIA_ITEM/AVC_TS_MP_HD_AC3_ISO-2/ORIGINAL HTTP/1.1, headers = [TimeSeekRange.dlna.org: npt=0.000-,getcontentFeatures.dlna.org: 1,Pragma: getIfoFileURI.dlna.org,transferMode.dlna.org: Streaming,X-AV-Physical-Unit-Info: pa="BRAVIA KDL-46EX700";,X-AV-Client-Info: av=5.0; cn="Sony Corporation"; mn="BRAVIA KDL-46EX700"; mv="1.7";,Host: 192.168.1.99:8895]]
2012-09-16 11:59:51,710 DEBUG [RendererDAOImpl] Reading a Renderer with ip address 192.168.1.14
2012-09-16 11:59:51,711 DEBUG [ResourceDeliveryProcessor] Resource request accepted. Using client 'IPAddress=/192.168.1.14, Profile=Sony Bravia TV (2010)'
2012-09-16 11:59:51,711 DEBUG [ResourceDeliveryProcessor] Request for resource 10 and type 'MEDIA_ITEM' received
2012-09-16 11:59:51,711 DEBUG [MediaResourceRetrievalStrategy] Getting information about media item 10 (local)
2012-09-16 11:59:51,711 DEBUG [MediaItemDAOImpl] Reading a MediaItem (id = 10)
2012-09-16 11:59:51,712 DEBUG [VideoDAOImpl] Reading a Video (id = 10)
2012-09-16 11:59:51,713 DEBUG [VideoDeliveryEngine] Delivering item '10' for client 'IPAddress=/192.168.1.14, Profile=Sony Bravia TV (2010)'
2012-09-16 11:59:51,713 DEBUG [VideoDeliveryEngine] Delivering file 'movie.mkv' using transcoding
2012-09-16 11:59:51,713 DEBUG [AbstractTranscodingDeliveryEngine] No other client uses transcoding job of file 'transcoding-temp-14-sony2010-ORIGINAL.stf', will stop the job
2012-09-16 11:59:51,713 DEBUG [AbstractTranscodingDeliveryEngine] Stopping previous transcoding job of file 'transcoding-temp-14-sony2010-ORIGINAL.stf'
2012-09-16 11:59:51,713 DEBUG [TranscodingJobListener] Deleted temp file '/tmp/Serviio/transcoding-temp-14-sony2010-ORIGINAL.stf': false
2012-09-16 11:59:51,713 DEBUG [AbstractTranscodingDeliveryEngine] No suitable transcoding job exists yet, start one for client 'IPAddress=/192.168.1.14, Profile=Sony Bravia TV (2010)'
2012-09-16 11:59:51,713 DEBUG [MediaItemDAOImpl] Getting file of media item 10
2012-09-16 11:59:51,714 DEBUG [FFMPEGWrapper] Invoking FFmpeg to transcode video file: /home/media/video/movie.mkv
2012-09-16 11:59:51,714 DEBUG [ProcessExecutor] Starting ffmpeg -fflags +genpts -i /home/media/video/movie.mkv -y -copyts -c:v copy -vbsf h264_mp4toannexb -c:a copy -map 0:0 -map 0:1 -sn -f mpegts /tmp/Serviio/transcoding-temp-10-sony2010-ORIGINAL.stf
2012-09-16 11:59:51,974 WARN  [ProcessExecutor] Process ffmpeg has a return code of 1! This is a possible error.
2012-09-16 11:59:51,975 DEBUG [TranscodingJobListener] Transcoding finished; successful: false
2012-09-16 11:59:59,217 ERROR [ResourceTransportRequestHandler] Error while processing resource, sending back 500 error. Message: Transcoded file '/tmp/Serviio/transcoding-temp-10-sony2010-ORIGINAL.stf' cannot be found, FFmpeg execution probably failed
java.io.IOException: Transcoded file '/tmp/Serviio/transcoding-temp-10-sony2010-ORIGINAL.stf' cannot be found, FFmpeg execution probably failed
   at org.serviio.delivery.resource.transcode.FileBasedTranscodingDeliveryStrategy.createInputStream(FileBasedTranscodingDeliveryStrategy.java:45)
   at org.serviio.delivery.resource.transcode.AbstractTranscodingDeliveryEngine.retrieveTranscodedResource(AbstractTranscodingDeliveryEngine.java:125)
   at org.serviio.delivery.resource.AbstractDeliveryEngine.deliver(AbstractDeliveryEngine.java:95)
   at org.serviio.delivery.MediaResourceRetrievalStrategy.retrieveResource(MediaResourceRetrievalStrategy.java:120)
   at org.serviio.delivery.ResourceDeliveryProcessor.deliverContent(ResourceDeliveryProcessor.java:84)
   at org.serviio.upnp.webserver.ResourceTransportRequestHandler.handleRequest(ResourceTransportRequestHandler.java:79)
   at org.serviio.upnp.webserver.AbstractRequestHandler.handle(AbstractRequestHandler.java:61)
   at org.apache.http.protocol.HttpService.doService(HttpService.java:293)
   at org.serviio.upnp.webserver.ServiioHttpService.doService(ServiioHttpService.java:58)
   at org.apache.http.protocol.HttpService.handleRequest(HttpService.java:212)
   at org.serviio.upnp.webserver.WebServer$WorkerThread.run(WebServer.java:191)


When I try the ffmpeg using a "regular" user, i'm getting this:
  Code:
server@h0m3s3rv3r:~$ ffmpeg -fflags +genpts -i /home/media/video/movie.mkv -y -copyts -c:v copy -vbsf h264_mp4toannexb -c:a copy -map 0:0 -map 0:1 -sn -f mpegts /tmp/Serviio/transcoding-temp-10-sony2010-ORIGINAL.stf
ffmpeg version N-42368-gbf53863 Copyright (c) 2000-2012 the FFmpeg developers
  built on Sep 12 2012 18:46:09 with gcc 4.6.3
  configuration: --enable-gpl --enable-libfaac --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libtheora --enable-libvorbis --enable-libx264 --enable-nonfree --enable-postproc --enable-version3 --enable-x11grab --enable-libvpx --enable-librtmp --enable-libxvid
  libavutil      51. 64.100 / 51. 64.100
  libavcodec     54. 33.100 / 54. 33.100
  libavformat    54. 15.102 / 54. 15.102
  libavdevice    54.  1.100 / 54.  1.100
  libavfilter     3.  1.100 /  3.  1.100
  libswscale      2.  1.100 /  2.  1.100
  libswresample   0. 15.100 /  0. 15.100
  libpostproc    52.  0.100 / 52.  0.100
Input #0, matroska,webm, from '/home/media/video/movie.mkv':
  Metadata:
    creation_time   : 2012-09-08 12:18:48
  Duration: 02:17:04.38, start: 0.000000, bitrate: 6556 kb/s
    Stream #0:0(fre): Video: h264 (High), yuv420p, 1280x720, SAR 1:1 DAR 16:9, 25 fps, 25 tbr, 1k tbn, 47.95 tbc (default)
    Stream #0:1(fre): Audio: ac3, 48000 Hz, 5.1(side), s16, 384 kb/s (default)
    Metadata:
      title           : French AC3 5.1 @384 Kbps
    Stream #0:2(fre): Subtitle: dvd_subtitle (default) (forced)
    Metadata:
      title           : Srt Forced
/tmp/Serviio/transcoding-temp-10-sony2010-ORIGINAL.stf: Permission denied


But when I run the command with sudo, all is good:
  Code:
server@h0m3s3rv3r:~$ sudo !!
sudo ffmpeg -fflags +genpts -i /home/media/video/movie.mkv -y -copyts -c:v copy -vbsf h264_mp4toannexb -c:a copy -map 0:0 -map 0:1 -sn -f mpegts /tmp/Serviio/transcoding-temp-10-sony2010-ORIGINAL.stf
[sudo] password for server:
ffmpeg version N-42368-gbf53863 Copyright (c) 2000-2012 the FFmpeg developers
  built on Sep 12 2012 18:46:09 with gcc 4.6.3
  configuration: --enable-gpl --enable-libfaac --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libtheora --enable-libvorbis --enable-libx264 --enable-nonfree --enable-postproc --enable-version3 --enable-x11grab --enable-libvpx --enable-librtmp --enable-libxvid
  libavutil      51. 64.100 / 51. 64.100
  libavcodec     54. 33.100 / 54. 33.100
  libavformat    54. 15.102 / 54. 15.102
  libavdevice    54.  1.100 / 54.  1.100
  libavfilter     3.  1.100 /  3.  1.100
  libswscale      2.  1.100 /  2.  1.100
  libswresample   0. 15.100 /  0. 15.100
  libpostproc    52.  0.100 / 52.  0.100
Input #0, matroska,webm, from '/home/media/video/movie.mkv':
  Metadata:
    creation_time   : 2012-09-08 12:18:48
  Duration: 02:17:04.38, start: 0.000000, bitrate: 6556 kb/s
    Stream #0:0(fre): Video: h264 (High), yuv420p, 1280x720, SAR 1:1 DAR 16:9, 25 fps, 25 tbr, 1k tbn, 47.95 tbc (default)
    Stream #0:1(fre): Audio: ac3, 48000 Hz, 5.1(side), s16, 384 kb/s (default)
    Metadata:
      title           : French AC3 5.1 @384 Kbps
    Stream #0:2(fre): Subtitle: dvd_subtitle (default) (forced)
    Metadata:
      title           : Srt Forced
[mpegts @ 0x25b8260] muxrate VBR, pcr every 2 pkts, sdt every 200, pat/pmt every 40 pkts
Output #0, mpegts, to '/tmp/Serviio/transcoding-temp-10-sony2010-ORIGINAL.stf':
  Metadata:
    encoder         : Lavf54.15.102
    Stream #0:0(fre): Video: h264, yuv420p, 1280x720 [SAR 1:1 DAR 16:9], q=2-31, 25 fps, 90k tbn, 23.98 tbc (default)
    Stream #0:1(fre): Audio: ac3, 48000 Hz, 5.1(side), 384 kb/s (default)
    Metadata:
      title           : French AC3 5.1 @384 Kbps
Stream mapping:
  Stream #0:0 -> #0:0 (copy)
  Stream #0:1 -> #0:1 (copy)
Press [q] to stop, [?] for help
frame=  607 fps=0.0 q=-1.0 size=   44246kB time=00:00:24.20 bitrate=14976.7kbitsframe= 2038 fps=2037 q=-1.0 size=   86036kB time=00:01:21.44 bitrate=8654.1kbitsframe= 3406 fps=2269 q=-1.0 size=  127402kB time=00:02:16.16 bitrate=7665.0kbitsframe= 4608 fps=2303 q=-1.0 size=  167518kB time=00:03:04.24 bitrate=7448.4kbitsframe= 5735 fps=2293 q=-1.0 size=  198958kB time=00:03:49.32 bitrate=7107.3kbitsframe= 6650 fps=2215 q=-1.0 size=  241547kB time=00:04:25.92 bitrate=7441.1kbitsframe= 7076 fps=2020 q=-1.0 size=  266825kB time=00:04:42.96 bitrate=7724.8kbitsframe= 7993 fps=1996 q=-1.0 size=  293802kB time=00:05:19.64 bitrate=7529.8kbitsframe= 8878 fps=1971 q=-1.0 size=  324964kB time=00:05:55.04 bitrate=7498.0kbitsframe=10188 fps=2036 q=-1.0 size=  357889kB time=00:06:47.44 bitrate=7195.7kbitsframe=10308 fps=2044 q=-1.0 Lsize=  361114kB time=00:06:52.24 bitrate=7176.0kbits/s   
video:312936kB audio:19336kB subtitle:0 global headers:0kB muxing overhead 8.680335%
<<

moltra

DLNA master

Posts: 1871

Joined: Thu Mar 24, 2011 11:00 pm

Location: Ohio USA

Post Sun Sep 16, 2012 5:31 pm

Re: Problem after each reboot

check the permissions of the folders and files. Make sure they are set correctly. Also set the permission of the /tmp/Serviio/ directory
Mark
Beta Tester Group
http://www.serviidb.com Online media resource repository

Netgear EVA2000 | Samsung BD-D5300 | XBOX 360 | Windows 7 | Mint Debian 12 | Raxz Maxx
HowTo: Provide supported formats of a device HowTo: Record a new ticket on Bitbucket
HowTo: Provide details of a video file that doesn't play HowTo: Turn on detailed logging
<<

jo343

Serviio newbie

Posts: 17

Joined: Thu Aug 23, 2012 7:57 pm

Post Sun Sep 16, 2012 6:16 pm

Re: Problem after each reboot

Here's the permissions:

The temp transcoding folder for serviio is /tmp/Serviio
The movie I'm trying to play is /home/media/video/movie.mkv


/tmp
  Code:
drwxrwxrwx   8 root root  4096 Sep 16 14:09 tmp


/tmp/Serviio
  Code:
drwxr-xr-x 2 root     root     4096 Sep 16 12:08 Serviio


/home/media
  Code:
drwxrwxrwx 5 root    root   4096 Aug 22 07:58 media


/home/media/video
  Code:
drwxrwxrwx 2 root root 4096 Sep 14 18:50 video


/home/media/video/movie.mkv
  Code:
-rwxrwxrwx 1 ftpuser   1002 6740520522 Sep  8 08:22 movie.mkv


Since the serviio service is autostarted when the server boots using "root" I though it would have all the autorities it needs... :?:
<<

npuser

DLNA master

Posts: 172

Joined: Mon Feb 06, 2012 3:44 am

Location: Michigan

Post Mon Sep 17, 2012 1:40 am

Re: Problem after each reboot

Try deleting 'serviio' folder inside /tmp [Default temp transcoding folder] and let the process auto created it using the proper permission. Or use -DdefaultTranscodeFolder=/home/somefolder/temp system variable to override the default tmp tc location.

NPuser
<<

jo343

Serviio newbie

Posts: 17

Joined: Thu Aug 23, 2012 7:57 pm

Post Mon Sep 17, 2012 9:58 pm

Re: Problem after each reboot

I've deleted the "Serviio" folder inside /tmp and rebooted. Tried streaming again to the TV and got the same server not accessible error...

The "Serviio" folder has been automaticaly recreated though:
  Code:
drwxr-xr-x 2 root     root     4096 Sep 17 17:53 Serviio


What else can I try?
<<

jo343

Serviio newbie

Posts: 17

Joined: Thu Aug 23, 2012 7:57 pm

Post Wed Sep 19, 2012 12:08 pm

Re: Problem after each reboot

I tried a couple of things and I found out that when I do

sudo service serviio stop
sudo service serviio start

Everything works! But when I reboot I get the same error again. So it seems that after a reboot, the serviio service is started automatically (without me doing a sudo start) but it's missing rights.

Here's the complete steps I took to install serviio:

cd /opt
sudo wget http://download.serviio.org/releases/se ... nux.tar.gz
sudo tar -zxvf serviio-1.0.1-linux.tar.gz
sudo mv serviio-1.0.1 serviio
sudo rm -f serviio-1.0.1-linux.tar.gz

sudo ln -s /opt/serviio/bin/serviio.sh /usr/bin/serviio

sudo useradd -d /opt/serviio -r serviio
sudo usermod -a -G root serviio
sudo chown -R serviio:serviio /opt/serviio

sudo nano /etc/default/serviio

  Code:
#########################################################
#- Daemon Script Configuration for Serviio Media Server
#- By Ian Laird
#- /etc/default/serviiod
#########################################################

NAME="Serviio Media Server"
DAEMON="/opt/serviio/bin/serviio.sh" ## Update this to point at pc5dczc_root/bin/serviio.sh
SERVICE_ACCOUNT="serviio" ## DON'T RUN UNDER ROOT!


sudo nano /etc/init.d/serviio
  Code:
#!/bin/bash
#
#########################################################
#- Daemon script for Serviio media server
#- By Ian Laird; converted for Debian by Jacob Lundbergand edited by Jopie
#- /etc/init.d/serviio
#########################################################
#
### BEGIN INIT INFO
# Provides: serviio
# Required-Start: $local_fs $remote_fs $network $syslog
# Required-Stop: $local_fs $remote_fs $network $syslog
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# X-Interactive: true
# Short-Description: Start/stop serviio media server
# Description: The Serviio media server makes your media available to
# all kinds of networked devices.
### END INIT INFO

. /lib/lsb/init-functions

if [ -f /etc/default/rcS ]; then
. /etc/default/rcS
fi

DAEMON_STOP=" -stop"
NAME="$(basename $0)"
PIDFILE="/var/run/serviiod.pid"
TIMEOUT=10

if [ -f /etc/default/serviio ]; then
. /etc/default/serviio
fi

[ -x "$DAEMON" ] || exit 0

running() {
if [ "x$1" == "x" ]; then
echo 0
return 1
fi

PS=$(ps h -p $(echo $1 | sed -r 's/[\t \n]+/ -p /') | wc -l)
echo $PS

if [ $PS -gt 0 ]; then
return 0
else
return 1
fi
}

start() {
log_daemon_msg "Starting Serviio media server daemon" "$NAME"
start-stop-daemon --start -q -b -p "$PIDFILE" -m -c "${SERVICE_ACCOUNT}" -x "${DAEMON}"
log_end_msg $?
}

stop() {
log_daemon_msg "Stopping Serviio media server daemon" "$NAME"
if [ -r "$PIDFILE" ]; then
PIDS=$(pstree -p $(<"$PIDFILE") | awk -F'[\(\)]' '/^[A-Za-z0-9]/ { print $2" "$4; }')
if running "$PIDS" > /dev/null; then
"${DAEMON}" "${DAEMON_STOP}"
for PID in $PIDS; do
if running $PID > /dev/null; then
kill -TERM $PID
fi
done
fi
COUNTDOWN=$TIMEOUT
while let COUNTDOWN--; do
if ! running "$PIDS" > /dev/null; then
break
fi
if [ $COUNTDOWN -eq 0 ]; then
for PID in $PIDS; do
if running $PID > /dev/null; then
kill -KILL $PID
fi
done
else
echo -n .
sleep 1
fi
done
fi

if running "$PIDS" > /dev/null; then
log_end_msg 1
else
rm -f "$PIDFILE"
log_end_msg $?
fi
}

status() {
echo -n "$NAME should be"
if [ -r "$PIDFILE" ]; then
echo -n " up with primary PID $(<"$PIDFILE")"
PIDS=$(pstree -p $(<"$PIDFILE") | awk -F'[\(\)]' '/^[A-Za-z0-9]/ { print $2" "$4; }')
RUNNING=$(running "$PIDS")
if [[ $RUNNING && $RUNNING -gt 0 ]]; then
echo -n " and $RUNNING processes are running."
else
echo -n " but it is not running."
fi
else
echo -n " stopped."
fi
echo
}

case "${1:-}" in
start)
start
;;
stop)
stop
;;
restart)
stop
start
;;
status)
status
;;
*)
log_success_msg "Usage: /etc/init.d/$NAME {start|stop|restart|status}"
exit 1
;;
esac

exit 0

sudo chmod 755 /etc/init.d/serviio
sudo update-rc.d serviio defaults



What is wrong with this setup that makes the automatically started service after a reboot missing rights?
(As I said, I even tried running the service as root in the deamon script configuration with the same results.)

Thanks.
<<

jo343

Serviio newbie

Posts: 17

Joined: Thu Aug 23, 2012 7:57 pm

Post Sun Sep 23, 2012 2:30 pm

Re: Problem after each reboot

Anyone got an idea why I can't autostart the service correctly (with "serviio" or "root" user).

I always have to do
sudo service serviio stop
sudo service serviio start

for serviio to work
<<

Spadge

Serviio lover

Posts: 58

Joined: Sun Sep 23, 2012 5:22 pm

Post Sun Sep 23, 2012 5:57 pm

Re: Problem after each reboot

I had the same problem with Ubuntu 12.04, but have fixed it.

NB "service start ..." and "service stop ..." are *so* ubuntu < 12.x

I suspect that's where the problem lies, specifically with the upstart script. When the system starts it will start services in the newer "start ..." upstart manner, and this doesn't work for Serviio with the script I had previously.

I just rewrote my upstart script, and the start/stop commands now work. Serviio now starts up with the system perfectly.

  Code:
root@Tobermory:~# cat /etc/init/serviio.conf
# Serviio - media server
#
# Serviio is a free media server. It allows you to stream your media files
# (music, video or images) to renderer devices (e.g. a TV set, Bluray player,
# games console or mobile phone) on your connected home network.

start on        started networking

script
        exec /usr/local/bin/serviio/bin/serviio.sh
end script



Thanks
<<

jo343

Serviio newbie

Posts: 17

Joined: Thu Aug 23, 2012 7:57 pm

Post Sun Sep 23, 2012 10:43 pm

Re: Problem after each reboot

Yes, that did it! Thanks a lot.

This method starts the deamon as root, is it ok to do that?
Is there a way to start it using the "serviio" user?
<<

Spadge

Serviio lover

Posts: 58

Joined: Sun Sep 23, 2012 5:22 pm

Post Mon Sep 24, 2012 5:55 am

Re: Problem after each reboot

Depending on how open your system is to the outside world or people who are not you.

I will look at changing user later. I know it can be done.
<<

Spadge

Serviio lover

Posts: 58

Joined: Sun Sep 23, 2012 5:22 pm

Post Mon Sep 24, 2012 7:14 pm

Re: Problem after each reboot

Try this:

  Code:
# Serviio - media server
#
# Serviio is a free media server. It allows you to stream your media files
# (music, video or images) to renderer devices (e.g. a TV set, Bluray player,
# games console or mobile phone) on your connected home network.

start on        started networking

setuid <user>
setgid <group>

script
        exec /usr/local/bin/serviio/bin/serviio.sh
end script


change <user> and <group> to the name and group you desire.

That should do it.

Return to Serviio Support & Help

Who is online

Users browsing this forum: No registered users and 39 guests

Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Designed by ST Software for PTF.