icecast2 liquidsoap start-stop-daemon error

icecast2 liquidsoap start-stop-daemon error - Codes et scripts - Linux et OS Alternatifs

Marsh Posté le 31-05-2011 à 14:24:48    

Bonjour à tous!

 

Voila, je viens d'installer icecast2 et liquidsoap, j'ai creé les user et group "liquidsoap". icecast2 fonctionne parfaitement, liquidsoap fonctionne lui aussi très bien quand je le lance avec le user "liquidsoap".
Maintenant je cherche à le lancer en daemon dans /etc/init.d/liquidsoap.sh. Et d'ailleurs, je vous le liste plus loin.

 

Et je me prend une erreur :

 
Citation :


root@Balthazar /etc/init.d # ./liquidsoap.sh start
Starting channels: liquidsoap.liq start-stop-daemon: --start needs --exec or --startas
Try 'start-stop-daemon --help' for more information.
./liquidsoap.sh: 148: --chuid: not found
OK

 

liquidsoap.liq est un fichier de conf, un "liquidsoap --check /etc/liquidsoap/liquidsoap.liq" me confirme qu'il est bon.
Que faire..?

 
Code :
  1. #!/bin/sh
  2. ### BEGIN INIT INFO
  3. # Provides: liquidsoap
  4. # Required-Start: $remote_fs $network $time
  5. # Required-Stop: $remote_fs $network $time
  6. # Should-Start:
  7. # Should-Stop:
  8. # Default-Start: 2 3 4 5
  9. # Default-Stop: 0 1 6
  10. # Short-Description: Starts the liquidsoap daemon
  11. # Description:
  12. ### END INIT INFO
  13. user=liquidsoap
  14. group=liquidsoap
  15. prefix=/usr
  16. exec_prefix=${prefix}
  17. confdir=/etc/liquidsoap
  18. liquidsoap=${exec_prefix}/bin/liquidsoap
  19. rundir=/var/run/liquidsoap
  20. # Test if $rundir exists
  21. if [ ! -d $rundir ]; then
  22.   mkdir -p $rundir;
  23.   chown $user:$group $rundir
  24. fi
  25. case $# in
  26. 1)
  27. case "$1" in
  28.   stop)
  29.     echo -n "Stopping channels: "
  30.     cd $rundir
  31.     for liq in *.pid ; do
  32.       if test $liq != '*.pid' ; then
  33.         echo -n "$liq "
  34.         start-stop-daemon --stop --quiet --pidfile $liq --retry 4
  35.       fi
  36.     done
  37.     echo "OK"
  38.     ;;
  39.   start)
  40.     echo -n "Starting channels: "
  41.     cd $confdir
  42.     for liq in *.liq ; do
  43.       if test $liq != '*.liq' ; then
  44.         echo -n "$liq "
  45.         start-stop-daemon --start --quiet --pidfile $rundir/${liq%.liq}.pid \ --chuid $user:$group --exec $liquidsoap -- -d $confdir/$liq
  46.       fi
  47.     done
  48.     echo "OK"
  49.     ;;
  50.   list)
  51.     echo "Listing channels: "
  52.     cd $rundir
  53.     for liq in *.pid ; do
  54.       if test $liq != '*.pid' ; then
  55.         echo -n "$liq ID:"
  56. cat $liq
  57. ps -l -p $(cat $liq )
  58. echo ""
  59.       fi
  60.     done
  61.     echo "OK"
  62.     ;;
  63.   restart|force-reload)
  64.     $0 stop
  65.     $0 start
  66.     ;;
  67.   *)
  68.     echo "Usage: $0 {start|stop|restart|force-reload}[ $1 {channelname}]"
  69.     exit 1
  70.     ;;
  71. esac
  72. ;;



Message édité par Lycos5 le 31-05-2011 à 14:30:28

---------------
FlickR | Speed matters | gtag:Arkht
Reply

Marsh Posté le 31-05-2011 à 14:24:48   

Reply

Sujets relatifs:

Leave a Replay

Make sure you enter the(*)required information where indicate.HTML code is not allowed