Bug 156666 - exec of init (/sbin/init) failed on reboot following crash
exec of init (/sbin/init) failed on reboot following crash
Product: Fedora
Classification: Fedora
Component: sysvinit (Show other bugs)
All Linux
medium Severity medium
: ---
: ---
Assigned To: Jakub Jelinek
Brian Brock
Depends On:
  Show dependency treegraph
Reported: 2005-05-02 20:55 EDT by Kevin R. Page
Modified: 2007-11-30 17:11 EST (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2005-05-02 20:58:55 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Kevin R. Page 2005-05-02 20:55:45 EDT
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.7) Gecko/20050416 Fedora/1.0.3-1.3.1 Firefox/1.0.3

Description of problem:
Not a bug per se; but I didn't find any clues to solve this, only false leads (corrupt filesystem, selinux etc.), so hopefully this might help someone else in the right direction. I found it fairly non-obvious to start with!

My machine crashed (I suspect a hardware fault). On reboot, the kernel was uncompressed and started to boot until:

Switching to new root
exec of init (/sbin/init) failed!!!: 2
umount /inited/dev failed: 2
kernel panic - not syncing: Attemped to kill init!

Suspecting a bad initrd, I tried all the kernels I had installed, but all failed with the same error.

Booting to rescue disk, I verifed the filesystems - ok.

chroot /mnt/sysimage (where FC rescue mounts the filesystem) also failed with:
chroot: cannot execute /bin/sh: No such file or directory

but /mnt/sysimage/bin/sh existed, and could be run.

The solution was to rebuild ld.so.cache, e.g.
chroot /mnt/sysimage /sbin/ldconfig

Following this I could successfully chroot, and init wouldn't fail on boot.

Yeah, it hadn't occured to me that the "no such file" was probably refering to a shared library, not the executable itself; or indeed that init wouldn't be statically linked. 

I guess ld.so.cache was midway through rebuild when the machine went down?

Version-Release number of selected component (if applicable):

How reproducible:
Didn't try

Additional info:
Comment 1 David Lawrence 2007-06-21 22:18:23 EDT
Package name is now sysvinit in latest Fedora.

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