Hello, I've tried more 'times to install Serviio on NSA325 V2 but I get always this error:
root@Venom:/ffp/start# sh /ffp/start/serviiod.sh start
: command not found.sh: line 1:
: command not found.sh: line 6:
: numeric argument requirede 7: exit: 0
I tried to start Serviio sirettamente sh serviio.sh but despite with servidroid I can put the first settings, path, password and registration key; Now, after 15 minutes I was not more 'accessible even with servidroid and I have not even available in the' web interface. It 'possible that something is missing? Have I missed a step (here I answer myself alone since I checked more 'and more' times) what is missing and why these errors in the line 1 and 6?
this is the content of the file serviiod.sh.
I tried to remove the line 1 and 6 were blanks but still get the error: numeric argument requirede 7: exit: 0 I do not know how to solve.
- Code:
#!/ffp/bin/sh
# FFP Startup script for Serviio
EXEC=/ffp/opt/serviio/bin/serviio.sh
PIDFILE=/var/run/serviiod.pid
JAVA_HOME=/ffp/opt/java/
OPTS=
test -x $EXEC || exit 0
case "$1" in
start)
echo "Starting Serviio"
# set required JAVA home environment variable
export JAVA_HOME
# Use the normal serviio.sh script to ensure correct environment is set up
if start-stop-daemon --start --quiet --oknodo --make-pidfile --background --pidfile $PIDFILE --exec $EXEC -- $OPTS; then
echo "OK"
else
echo "Failed"
fi
;;
stop)
echo "Stopping Serviio"
# Kill both serviio.sh script and Java process
serv_kill=`ps aux | grep serviio.sh | grep -v grep | awk '{print $2}'`
java_kill=`ps aux | grep org.serviio.MediaServer | grep -v grep | awk '{print $2}'`
if [ "$serv_kill" = "" ]; then
echo "Serviio shell is not running"
RETVAL=1
else
kill $serv_kill
RETVAL=0
fi
if [ "$java_kill" = "" ]; then
echo "Serviio Java is not running"
RETVAL=1
else
kill -9 $java_kill
RETVAL=0
fi
echo "OK"
;;
status)
serv_pid=`ps aux | grep serviio.sh | grep -v grep | awk '{print $2}'`
java_pid=`ps aux | grep java | grep -v grep | awk '{print $2}'`
if [ "$serv_pid" != "" ]; then
echo "Serviio shell (pid $serv_pid) is running"
RETVAL=0
else
echo "Serviio shell is stopped"
RETVAL=1
fi
if [ "$java_pid" != "" ]; then
echo "Serviio Java (pid $java_pid) is running"
RETVAL=0
else
echo "Serviio Java is stopped"
RETVAL=1
fi
esac
exit 0
The java are working it seems.
root@Venom:/ffp/start# java -version
java version "1.7.0_60"
Java(TM) SE Embedded Runtime Environment (build 1.7.0_60-b19, headless)
Java HotSpot(TM) Embedded Client VM (build 24.60-b09, mixed mode)
root@Venom:/ffp/start#
Thanks in advance any help that can solve my problem Thank you.