Bug 274121 - 'sleep -1' does not sleep
'sleep -1' does not sleep
Status: CLOSED WONTFIX
Product: Fedora
Classification: Fedora
Component: mkinitrd (Show other bugs)
rawhide
All All
medium Severity low
: ---
: ---
Assigned To: Peter Jones
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2007-09-01 18:12 EDT by Felix Bellaby
Modified: 2007-11-30 17:12 EST (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2007-09-07 18:06:15 EDT
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 Felix Bellaby 2007-09-01 18:12:25 EDT
mkinitrd produces init nash scripts ending with the 3 lines:

switchroot
echo Booting has failed.
sleep -1

This is probably intended to leave the console in an infinite sleep should the
switchroot fail. However, nash does not sleep in response to 'sleep -1' and the
following returns immediately:

# echo 'nash-sleep -1' | nash --force

I suspect that nash interprets the '-1' as an invalid option. Replacing the
'sleep -1' with 'sleep 120' does produce the desired effect.
Comment 1 Peter Jones 2007-09-07 18:06:15 EDT
This should be fixed in current mkinitrd.
Comment 2 Felix Bellaby 2007-09-24 17:40:21 EDT
This has not been fixed as of mkinitrd-6.0.17-1.fc8.

mkinitrd continues to add 'sleep -1' onto the end of scripts
nash still does not sleep.

The failure of this sleep call allows the kernel to panic
immediately after the "Booting has failed" message. This can
prevent the user from reading any helpful information left
on the console following an initrd failure.

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