FS#6129 - mpd script should use mpd --kill
Attached to Project:
Arch Linux
Opened by Scott H (stonecrest) - Monday, 01 January 2007, 20:22 GMT
Last edited by Roman Kyrylych (Romashka) - Saturday, 14 April 2007, 09:35 GMT
Opened by Scott H (stonecrest) - Monday, 01 January 2007, 20:22 GMT
Last edited by Roman Kyrylych (Romashka) - Saturday, 14 April 2007, 09:35 GMT
|
Details
Currently the /etc/rc.d/mpd script uses:
[ ! -z "$PID" ] && kill $PID &> /dev/null However, this doesn't properly shutdown mpd (for example, mpd won't update the mpdstate file on exit!). This should really be changed to: [ ! -z "$PID" ] && /usr/bin/mpd --kill &> /dev/null The only side effect of doing this is that the pid_file variable needs to be uncommented for mpd --kill to work, so you'll probably want to grep+sed it. |
This task depends upon
"mpd --kill"
do in such a case?
killing daemons should be pID specific - i agree that oen should use the "proper" shutdown way of mpd
This makes me realize though that what we probably want is, in fact:
[ ! -z "$PID" ] && /usr/bin/mpd --kill /etc/mpd.conf &> /dev/null
so that the MPD that starts from the script is the one that is killed.