Bug 132346 - rc.sysinit drops to shell even if fsck succeeds reparing file system
Summary: rc.sysinit drops to shell even if fsck succeeds reparing file system
Keywords:
Status: CLOSED DUPLICATE of bug 117641
Alias: None
Product: Fedora
Classification: Fedora
Component: initscripts
Version: rawhide
Hardware: i386
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Bill Nottingham
QA Contact: Brock Organ
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2004-09-11 04:15 UTC by Steinar Hauan
Modified: 2014-03-17 02:48 UTC (History)
2 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2006-02-21 19:05:34 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Steinar Hauan 2004-09-11 04:15:27 UTC
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 04:19:14 UTC
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 04:25:14 UTC

*** This bug has been marked as a duplicate of 117641 ***

Comment 3 Red Hat Bugzilla 2006-02-21 19:05:34 UTC
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.