this is not a "cosmetic issue"
a whole LSB system init.d script insertion is falling apart and is useless
I wroted a script that stops rtorrent gracefully and want to instert it at INIT 0, 1 and 6 ( halt, silgme-user, reboot ) and configured it with LSB as this:
### BEGIN INIT INFO
# Provides: rtorrent-stop
# Required-Start:
# Required-Stop: $local_fs $remote_fs $syslog
# Default-Start:
# Default-Stop: 0 1 6
# Short-Description: Stop gracefully any rtorrent process durring shutdown/reboot
# Description: Run "kill -2 `pidof rtorrent'" which stops any rtorrent work,
# disconnect it from trackers and close files.
### END INIT INFO
so instead insterting scritp only where it is wanted it instert it into the default positions
here is quote from LSB wiki:
[..]
Default-Start: run_level_1 [run_level_2...],Default-Stop: run_level_1 [run_level_2...]
* defines the run levels where the script should be started (stopped) by default. For example, if a service should run in runlevels 3, 4, and 5 only, specify "Default-Start: 3 4 5" and "Default-Stop: 0 1 2 6".
[..]
So I configured my script as in this WIKI:
### BEGIN INIT INFO
# Provides: rtorrent-stop
# Required-Start:
# Required-Stop: $local_fs $remote_fs $syslog
# Default-Start: 3 4 5
# Default-Stop: 0 1 2 6
# Short-Description: Stop gracefully any rtorrent process durring shutdown/reboot
# Description: Run "kill -2 `pidof rtorrent'" which stops any rtorrent work,
# disconnect it from trackers and close files.
### END INIT INFO
and that what "update-rc.d" did:
update-rc.d: warning: rtorrent-stop start runlevel arguments (2 3 4 5) do not match LSB Default-Start values (3 4 5)
update-rc.d: warning: rtorrent-stop stop runlevel arguments (0 1 6) do not match LSB Default-Stop values (0 1 2 6)
Adding system startup for /etc/init.d/rtorrent-stop ...
/etc/rc0.d/K20rtorrent-stop -> ../init.d/rtorrent-stop
/etc/rc1.d/K20rtorrent-stop -> ../init.d/rtorrent-stop
/etc/rc6.d/K20rtorrent-stop -> ../init.d/rtorrent-stop
/etc/rc2.d/S20rtorrent-stop -> ../init.d/rtorrent-stop
/etc/rc3.d/S20rtorrent-stop -> ../init.d/rtorrent-stop
/etc/rc4.d/S20rtorrent-stop -> ../init.d/rtorrent-stop
/etc/rc5.d/S20rtorrent-stop -> ../init.d/rtorrent-stop
So... it's not working at all.
GARBAGE!!!
I need to do "sudo update-rc.d rtorrent-stop stop 99 0 1 6 ." manually.
Conclusion: "update-rc.d" in Ubuntu ( Karmic ) is working ONLY in legacy mode. And that is the real bug here.
this is not a "cosmetic issue"
a whole LSB system init.d script insertion is falling apart and is useless
I wroted a script that stops rtorrent gracefully and want to instert it at INIT 0, 1 and 6 ( halt, silgme-user, reboot ) and configured it with LSB as this:
### BEGIN INIT INFO
# Provides: rtorrent-stop
# Required-Start:
# Required-Stop: $local_fs $remote_fs $syslog
# Default-Start:
# Default-Stop: 0 1 6
# Short-Description: Stop gracefully any rtorrent process durring shutdown/reboot
# Description: Run "kill -2 `pidof rtorrent'" which stops any rtorrent work,
# disconnect it from trackers and close files.
### END INIT INFO
I've invoced "update-rc.d": d/rtorrent- stop ... rc0.d/K20rtorre nt-stop -> ../init. d/rtorrent- stop rc1.d/K20rtorre nt-stop -> ../init. d/rtorrent- stop rc6.d/K20rtorre nt-stop -> ../init. d/rtorrent- stop rc2.d/S20rtorre nt-stop -> ../init. d/rtorrent- stop rc3.d/S20rtorre nt-stop -> ../init. d/rtorrent- stop rc4.d/S20rtorre nt-stop -> ../init. d/rtorrent- stop rc5.d/S20rtorre nt-stop -> ../init. d/rtorrent- stop
sudo update-rc.d rtorrent-stop defults
update-rc.d: warning: rtorrent-stop start runlevel arguments (2 3 4 5) do not match LSB Default-Start values (none)
Adding system startup for /etc/init.
/etc/
/etc/
/etc/
/etc/
/etc/
/etc/
/etc/
so instead insterting scritp only where it is wanted it instert it into the default positions
here is quote from LSB wiki: 2...],Default- Stop: run_level_1 [run_level_2...]
[..]
Default-Start: run_level_1 [run_level_
* defines the run levels where the script should be started (stopped) by default. For example, if a service should run in runlevels 3, 4, and 5 only, specify "Default-Start: 3 4 5" and "Default-Stop: 0 1 2 6".
[..]
So I configured my script as in this WIKI:
### BEGIN INIT INFO
# Provides: rtorrent-stop
# Required-Start:
# Required-Stop: $local_fs $remote_fs $syslog
# Default-Start: 3 4 5
# Default-Stop: 0 1 2 6
# Short-Description: Stop gracefully any rtorrent process durring shutdown/reboot
# Description: Run "kill -2 `pidof rtorrent'" which stops any rtorrent work,
# disconnect it from trackers and close files.
### END INIT INFO
and that what "update-rc.d" did: d/rtorrent- stop ... rc0.d/K20rtorre nt-stop -> ../init. d/rtorrent- stop rc1.d/K20rtorre nt-stop -> ../init. d/rtorrent- stop rc6.d/K20rtorre nt-stop -> ../init. d/rtorrent- stop rc2.d/S20rtorre nt-stop -> ../init. d/rtorrent- stop rc3.d/S20rtorre nt-stop -> ../init. d/rtorrent- stop rc4.d/S20rtorre nt-stop -> ../init. d/rtorrent- stop rc5.d/S20rtorre nt-stop -> ../init. d/rtorrent- stop
update-rc.d: warning: rtorrent-stop start runlevel arguments (2 3 4 5) do not match LSB Default-Start values (3 4 5)
update-rc.d: warning: rtorrent-stop stop runlevel arguments (0 1 6) do not match LSB Default-Stop values (0 1 2 6)
Adding system startup for /etc/init.
/etc/
/etc/
/etc/
/etc/
/etc/
/etc/
/etc/
So... it's not working at all.
GARBAGE!!!
I need to do "sudo update-rc.d rtorrent-stop stop 99 0 1 6 ." manually.
Conclusion: "update-rc.d" in Ubuntu ( Karmic ) is working ONLY in legacy mode. And that is the real bug here.