Otavio, I found other bugs in splashy-update-progress-steps. This patch fixes those bugs as well. Please disregard the patch I sent before for that file (see Bug # 400598 on DBTS).
To avoid possible confusions, I added the full file as well. This is assume to be used with Splashy 0.2.1. The idea is that simply listing the files in /etc/rcS.d and /etc/rc2.d/[KS]* gives you symlinks that are not actually pointing to files and scripts that do not all log_end_msg at all. This new patch only cares about files calling log_end_msg for our progressbar. The bug is triggered when you have scripts at the end of the resulting step file that do not call log_end_msg. Leaving the progressbar in, say, 94% and never completing to 100%, therefore, Splashy just sits there waiting until it times out! -- ----)(----- Luis Mondesi *NIX Guru "Feliz el hombre que ha hallado sabiduria y el hombre que consigue discernimiento, porque el tenerla como ganancia es mejor que tener la plata como ganancia; y el tenerla como producto, [mejor] que el oro mismo" (Prov 3:13-14).
--- ../../tags/0.2.1/scripts/splashy-update-progress-steps 2006-10-26 10:54:58.555800300 -0400 +++ /tmp/splashy-update-progress-steps 2006-12-02 01:02:48.000000000 -0500 @@ -56,12 +56,20 @@ # Depend on lsb-base (>= 3.0-6) to ensure that this file is present. . /lib/lsb/init-functions -set -e +# we cannot use sed -e here because when we have hanging symlinks +# grep -l will return an error +#set -e + +# Bug #400598 +if [ -z "$RUNLEVEL" ]; then + # we need only the current level + RUNLEVEL=`runlevel | sed 's/^. //'` +fi case "$1" in # Sounds a bit weird, but called as start will stop splashy;) start) - if [ "x$RUNLEVEL" = "xS" ]; then + if [ "x$RUNLEVEL" = "xN S" -o "x$RUNLEVEL" = "xS" ]; then log_daemon_msg "Starting $DESC" $NAME pidof splashy > /dev/null || /sbin/splashy boot log_end_msg $? @@ -88,6 +96,7 @@ fi ;; stop) + # note that these steps are done with a fully mounted /usr log_daemon_msg "(Re)generating splash steps for " RLVL=`sed -n 's/id:\([2345]\):initdefault:/\1/ p' /etc/inittab` @@ -100,10 +109,15 @@ fi # While booting rcS will also be executed - ls /etc/rcS.d/S* > $TMP + #ls /etc/rcS.d/S* > $TMP + # we only care about the scripts that actually call log_end_msg + # if not we end up never completing our progressbar! + grep -l log_end_msg /etc/rcS.d/S* > $TMP 2> /dev/null for I in ${RLVL:=2} 0 6; do - ls /etc/rc$I.d/[KS]* >> $TMP + #ls /etc/rc$I.d/[KS]* >> $TMP + # in debian rc.local runs log_end_msg conditionally. we simply skip that + grep -l log_end_msg /etc/rc$I.d/[KS]* 2> /dev/null | grep -v rc.local >> $TMP NR=`wc -l $TMP` awk '{print $1, int(FNR/'${NR%%[[:space:]]*}'*100)}' $TMP > "$DIR/$I-progress"
splashy-update-progress-steps
Description: Binary data