when issuing /etc/init.d/mpd restart I get this: # /etc/init.d/mpd restart * Stopping service mpd * Stopped service mpd * Starting service mpd /usr/bin/mpd already running. [ !! ] * FAILED to start service mpd! That's with parallel startup on, with it off I still get the same error. Reproducible: Always Steps to Reproduce:
Which version of mpd? mpd-0.11.5 works fine with baselayout-1.12.0_pre5
I am using the mpd-svn-20050731. Diff'ing the init script from mpd to mpd-svn turns up two major differences: - start-stop-daemon --start --quiet --exec /usr/bin/mpd -- --no-create-db /etc/mpd.conf + start-stop-daemon --start --exec /usr/bin/mpd -- --no-create-db /etc/mpd.conf and - start-stop-daemon --stop --quiet --exec /usr/bin/mpd --oknodo + start-stop-daemon --stop --pidfile ${pidfile} Changing the init script to that of the one from regular mpd seems to fix the problem.
I'm having a similar problem with the webmin init script and baselayout-1.12.0_pre5... It seems that the bug is in start-stop-daemon because executing the process manually (as described below) works... start-stop-daemon --start --quiet -exec /usr/libexec/webmin/miniserv.pl /etc/webmin/miniserv.conf to /usr/libexec/webmin/miniserv.pl /etc/webmin/miniserv.conf in the init script
replacing /lib/rcscripts/sh/rc-daemon.sh with the 1.11.3 version makes the problem go away...
And this might pose a clue... or just another unrelated bug... $ /etc/init.d/authdaemond start * Starting authdaemond.plain ... pidof: invalid options on command line! [ !! ] This bit of debugging: --- rc-daemon.sh.1.12.0_pre5 2005-08-16 23:24:28.000000000 -0700 +++ rc-daemon.sh 2005-08-16 23:32:14.000000000 -0700 @@ -182,12 +182,15 @@ rc_kill_pid() { # This is to handle the rpc.nfsd program which acts weird pidof() { local arg args - + + > /tmp/a for arg in "$@"; do [[ ${arg##*/} == "rpc.nfsd" ]] && arg="${arg%/*}/nfsd" + echo "${arg}" >> /tmp/a args="${args} '"${arg}"'" done + echo "eval /bin/pidof -x ${args}" >> /tmp/a eval /bin/pidof -x ${args} } produced this: $ cat /tmp/a '-' '/usr/lib/courier-imap/courierlogger' '-pid=/var/run/authdaemon.pid' '-start' '/usr/lib/courier-imap/authlib/authdaemond.plain' eval /bin/pidof -x ''-'' ''/usr/lib/courier-imap/courierlogger'' ''-pid=/var/run/authdaemon.pid'' ''-start'' ''/usr/lib/courier-imap/authlib/authdaemond.plain'' this call is coming from is_daemon_running from rc_start_daemon
(In reply to comment #5) > And this might pose a clue... or just another unrelated bug... > > $ /etc/init.d/authdaemond start > * Starting authdaemond.plain ... > pidof: invalid options on command line! Bug #98745 has fixed scripts for courier-imap and related stuff Bug #102826 has a patch for the webmin script to call start-stop-daemon correctly The rc-daemon.sh prior to baselayout-1.12 didn't actually do anything btw, so we either ship this and fix init scripts (which are the issue 90% of the time) or leave things as is. Marking as invalid as the reporter has a working mpd init script now.