Bug 132346 - rc.sysinit drops to shell even if fsck succeeds reparing file system
rc.sysinit drops to shell even if fsck succeeds reparing file system
Status: CLOSED DUPLICATE of bug 117641
Product: Fedora
Classification: Fedora
Component: initscripts (Show other bugs)
rawhide
i386 Linux
medium Severity medium
: ---
: ---
Assigned To: Bill Nottingham
Brock Organ
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2004-09-11 00:15 EDT by Steinar Hauan
Modified: 2014-03-16 22:48 EDT (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2006-02-21 14:05:34 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Steinar Hauan 2004-09-11 00:15:27 EDT
Description of problem:

in /etc/rc.d/rc.sysinit (line 320 in v7.66), the return code of fsck
is checked; if > 1, the system drops the machine to an interactive
shell for manual fsck on a partition.

this is incorrect and should only happen if fsck _fails_ to repair the
problem; if fsck succeeds, the return code is 3 (1+2) and the system
should reboot automatically since no manual fsck (code 4) is needed.

Version-Release number of selected component (if applicable): all
(have tested up to 7.77)


How reproducible: every time
  
i've used the patch to be attached for > 1 year now and it works.
(patch will be attached on the next page)
Comment 1 Steinar Hauan 2004-09-11 00:19:14 EDT
this behavior is very annoying for clusters where the machines are
usually not connected to displays; if fsck succeeds in repairing the
file system, we really should just reboot automatically?



from /etc/rc.d/rc.sysinit around line 320
        # A return of 2 or higher means there were serious problems.
        if [ $rc -gt 1 ]; then
                if [ -x /usr/bin/rhgb-client ] && /usr/bin/rhgb-client
--ping ; then
                    chvt 1
                fi
                #
                # SHa, Aug 2004 (for seLinux; initscript 7.66)
                # drop to interactive shell only if 
                # fsck errors were not fixed ($rc > 3)
                #
                if [ $rc -lt 4 ]; then
                    echo
                    echo "(Info) root file system fixed -- rebooting"
                    echo
                    sleep 1
                    umount -av
                    sleep 1
                    reboot -f
                fi
                # --- SHa: end of changes ---

                failure "$STRING"

      [keep everything below here; the sleeps are technically not
needed above, but i like to see it on the console]
Comment 2 Bill Nottingham 2004-09-11 00:25:14 EDT

*** This bug has been marked as a duplicate of 117641 ***
Comment 3 Red Hat Bugzilla 2006-02-21 14:05:34 EST
Changed to 'CLOSED' state since 'RESOLVED' has been deprecated.

Note You need to log in before you can comment on or make changes to this bug.