Bug#387894: [Pkg-sysvinit-devel] Bug#387894: tested with usplash + reviewed patch

Jean-Damien Durand Jean-Damien.Durand at tele2.fr
Sat Sep 23 14:42:20 UTC 2006


Dear Petter,

Petter Reinholdtsen wrote:
> [Jean-Damien Durand]
>> Tested with usplash - works for me.
> 
> Good to hear.
> 
>> Note that at shutdown usplash progress bar goes from left to right
>> while with splashutils it goes from right to left - but perhaps
>> usplash does 100-value if runlevel is 6, don't know its internals).
> 
> I believe usplash go from left to right when counting down.
> 
>> Here is a patch without unneeded space/tab changes.
> 
> I tested the patch with usplash enabled like this:
> 
>   debug=echo sh debian/sysv-rc/etc/init.d/rc 2
>   PREVLEVEL=2 debug=echo sh debian/sysv-rc/etc/init.d/rc 1
> 
> It does not seem to do what it should.  It fail to reach 100 when
> reaching kdm, and there is no progress info for the stop scripts.  Did
> I misunderstood what this patch is supposed to do?  I believe the
> correct behavoir is for the progress bar to reach 100 when kdm/xdm/gdm
> is starting, and to stay there.  The code in svn continue counting
> after 100, and that is a bug.
> 
> The code in the patch to count progress steps also seem to fail to
> take into account that some kill scripts will not be executed.
> 
> Friendly,

Here is how I reproduced your test. Worked for me?!

rm -rf /tmp/sysv-rc
mkdir -p /tmp/sysv-rc
cd /tmp/sysv-rc
apt-get -t unstable --reinstall -d install sysv-rc
dpkg -x /var/cache/apt/archives/sysv-rc_2.86.ds1-20_all.deb . 
cd etc/init.d
wget -Orc.patch 'http://bugs.debian.org/cgi-bin/bugreport.cgi/rc.patch?bug=387894;msg=20;att=1'
cat rc.patch|patch -p3
debug=echo sh ./rc 2
PREVLEVEL=2 debug=echo sh ./rc 1

One could think that usplash_write should not be called again if we already reached 0 or 100, but that
belongs to the logic already in rc - I did not dare to change that. Perhaps this should be. Don't know.

Verbose output below -;

% rm -rf /tmp/sysv-rc
% mkdir -p /tmp/sysv-rc
% cd /tmp/sysv-rc
% apt-get -t unstable --reinstall -d install sysv-rc
Reading package lists... Done
Building dependency tree... Done
0 upgraded, 0 newly installed, 1 reinstalled, 0 to remove and 1 not upgraded.
Need to get 53.6kB of archives.
After unpacking 0B of additional disk space will be used.
Do you want to continue [Y/n]?
Get: 1 http://ftp.fr.debian.org testing/main sysv-rc 2.86.ds1-20 [53.6kB]
Fetched 53.6kB in 0s (142kB/s)
Download complete and in download only mode
% dpkg -x /var/cache/apt/archives/sysv-rc_2.86.ds1-20_all.deb . 
% cd etc/init.d
% wget -Orc.patch 'http://bugs.debian.org/cgi-bin/bugreport.cgi/rc.patch?bug=387894;msg=20;att=1'
--16:32:03--  http://bugs.debian.org/cgi-bin/bugreport.cgi/rc.patch?bug=387894;msg=20;att=1
           => `rc.patch'
Resolving bugs.debian.org... 140.211.166.43
Connecting to bugs.debian.org|140.211.166.43|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: unspecified [text/plain]

    [ <=>                                                                                        ] 6,426         33.39K/s

16:32:04 (33.24 KB/s) - `rc.patch' saved [6426]

% cat rc.patch|patch -p3
patching file rc
% debug=echo sh ./rc 2
/etc/rc2.d/S10sysklogd start
usplash_write PROGRESS 67
/etc/rc2.d/S11klogd start
usplash_write PROGRESS 68
/etc/rc2.d/S19hplip start
usplash_write PROGRESS 70
/etc/rc2.d/S19mysql start
usplash_write PROGRESS 71
/etc/rc2.d/S19mysql-ndb-mgm start
usplash_write PROGRESS 73
/etc/rc2.d/S20cupsys start
usplash_write PROGRESS 74
/etc/rc2.d/S20dbus start
usplash_write PROGRESS 76
/etc/rc2.d/S20dirmngr start
usplash_write PROGRESS 77
/etc/rc2.d/S20gpm start
usplash_write PROGRESS 79
/etc/rc2.d/S20lisa start
usplash_write PROGRESS 80
/etc/rc2.d/S20makedev start
usplash_write PROGRESS 82
/etc/rc2.d/S20mysql-ndb start
usplash_write PROGRESS 83
/etc/rc2.d/S20nvidia-glx start
usplash_write PROGRESS 85
/etc/rc2.d/S20nvidia-kernel start
usplash_write PROGRESS 86
/etc/rc2.d/S20openbsd-inetd start
usplash_write PROGRESS 88
/etc/rc2.d/S20samba start
usplash_write PROGRESS 89
/etc/rc2.d/S20smartmontools start
usplash_write PROGRESS 91
/etc/rc2.d/S20xfs start
usplash_write PROGRESS 92
/etc/rc2.d/S89anacron start
usplash_write PROGRESS 94
/etc/rc2.d/S89atd start
usplash_write PROGRESS 95
/etc/rc2.d/S89cron start
usplash_write PROGRESS 97
/etc/rc2.d/S90binfmt-support start
usplash_write PROGRESS 98
/etc/rc2.d/S99kdm start
usplash_write PROGRESS 100
/etc/rc2.d/S99rc.local start
usplash_write PROGRESS 100
/etc/rc2.d/S99rmnologin start
usplash_write PROGRESS 100
/etc/rc2.d/S99stop-bootlogd start
usplash_write PROGRESS 100
% PREVLEVEL=2 debug=echo sh ./rc 1
/etc/rc1.d/K01kdm stop
usplash_write PROGRESS 67
/etc/rc1.d/K11anacron stop
usplash_write PROGRESS 68
/etc/rc1.d/K11cron stop
usplash_write PROGRESS 70
/etc/rc1.d/K19hplip stop
usplash_write PROGRESS 71
/etc/rc1.d/K19samba stop
usplash_write PROGRESS 73
/etc/rc1.d/K20cupsys stop
usplash_write PROGRESS 74
/etc/rc1.d/K20dbus stop
usplash_write PROGRESS 75
/etc/rc1.d/K20dirmngr stop
usplash_write PROGRESS 77
/etc/rc1.d/K20gpm stop
usplash_write PROGRESS 78
/etc/rc1.d/K20lisa stop
usplash_write PROGRESS 80
/etc/rc1.d/K20makedev stop
usplash_write PROGRESS 81
/etc/rc1.d/K20mysql-ndb stop
usplash_write PROGRESS 83
/etc/rc1.d/K20nvidia-glx stop
usplash_write PROGRESS 84
/etc/rc1.d/K20nvidia-kernel stop
usplash_write PROGRESS 85
/etc/rc1.d/K20openbsd-inetd stop
usplash_write PROGRESS 87
/etc/rc1.d/K20smartmontools stop
usplash_write PROGRESS 88
/etc/rc1.d/K20xfs stop
usplash_write PROGRESS 90
/etc/rc1.d/K21mysql stop
usplash_write PROGRESS 91
/etc/rc1.d/K21mysql-ndb-mgm stop
usplash_write PROGRESS 92
/etc/rc1.d/K89atd stop
usplash_write PROGRESS 94
/etc/rc1.d/K89klogd stop
usplash_write PROGRESS 95
/etc/rc1.d/K90sysklogd stop
usplash_write PROGRESS 97
/etc/rc1.d/S30killprocs start
usplash_write PROGRESS 98
/etc/rc1.d/S90single start
usplash_write PROGRESS 100

Cheers, JD.




More information about the Pkg-sysvinit-devel mailing list