[initscripts][PATCH] checkroot.sh: "Done checking root file system" is printed twice at boot

Bug #31535 reported by Michael Bienia
4
Affects Status Importance Assigned to Milestone
sysvinit (Ubuntu)
Confirmed
Medium
Unassigned

Bug Description

checkroot.sh (initscripts 2.86.ds1-6ubuntu9) prints "Done checking root file system" at boot twice. Once with a normal "*" and once with a red "*".
Looking at the script I assume there is a bug in the if-statement checking the return value from fsck.
The following patch fixed it for me:

--- checkroot.sh.orig 2006-02-14 17:01:56.020047191 +0100
+++ checkroot.sh 2006-02-15 18:42:37.759790884 +0100
@@ -250,8 +250,9 @@
                log_action_msg "Will now check root file system"
                fsck $spinner $force $fix -T -t $roottype $rootdev
                if [ "$?" = 0 ]
- log_success_msg "Done checking root file system"
                then
+ log_success_msg "Done checking root file system"
+ else
                        log_failure_msg "Done checking root file system"
                fi
                FSCKCODE=$?

Revision history for this message
Tormod Volden (tormodvolden) wrote : fixes the then/else mixup

Same patch as in previous comment.

Changed in sysvinit:
status: Unconfirmed → Confirmed
Revision history for this message
Tormod Volden (tormodvolden) wrote :

Forget this patch. The patch in bug #28067 fixes this, and more importantly, also the major bug that the actual return status from fsck gets lost by the log_failure_msg call.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.