failed to execute /init

Bug #1236642 reported by Rob Frohne
16
This bug affects 3 people
Affects Status Importance Assigned to Milestone
grub2 (Ubuntu)
Expired
Undecided
Unassigned

Bug Description

I installed Ubuntu 13.10 _x64bit by this method last night (10/6/2013) and ended up with a kernel panic with the message "failed to execute /init" and here is how I installed it:

1) Using 13.04 on another partition of the same hard drive, made using unetbootin a flash drive with the latest daily Ubuntu _x64 image on it.
2) Booted on the USB drive, selected to do an "other partitioning" scheme, and set / to 60 Gigs of the remaining free space, and swap to 4 GB. Then went through the install with the download from the Internet selected. When it was done and said it was ready to reboot, I tried, but got the error, which I was able to read using the boot into recovery mode option.

I enclosed a photo of the kernel panic screen.

Revision history for this message
Rob Frohne (frohro) wrote :
Download full text (6.0 KiB)

The directories and files in the root partition look similar to my other working 13.04 partition with the exception of .old files. The /sbin/init is there.

Here is what the initrd.img has within it:

$ lsinitramfs initrd.img | grep init
initrd.img
bin/run-init
scripts/init-top
scripts/init-top/udev
scripts/init-top/all_generic_ide
scripts/init-top/blacklist
scripts/init-top/ORDER
scripts/init-bottom
scripts/init-bottom/udev
scripts/init-bottom/ORDER
init
lib/modules/3.11.0-11-generic/kernel/drivers/scsi/initio.ko
lib/firmware/ene-ub6250/sd_init2.bin
lib/firmware/ene-ub6250/sd_init1.bin
lib/firmware/ene-ub6250/ms_init.bin
conf/initramfs.conf

I followed the ideas for using the command line of grub at:

https://lists.ubuntu.com/archives/ubuntu-users/2013-August/271141.html

and set seemed all okay as did ls. Then I did:

linux /boot/vmlinuz-3.10.0.6-generic root=/dev/sda3 ro debug

and

initrd /boot/initrd.img-3.10.0.6-generic

and

boot

(Note: these versions are not mine. They came from the web page. I can't copy and paste if I can't boot. :-))

The same result ensued.

$ ldd sbin/init
 not a dynamic executable
I went looking for the libraries needed using

frohro@frohro-e6410:/media/frohro/5b901d56-389b-48b1-a911-08dab37d228d$ readelf -d sbin/init | grep NEEDED
 0x0000000000000001 (NEEDED) Shared library: [libnih.so.1]
 0x0000000000000001 (NEEDED) Shared library: [libnih-dbus.so.1]
 0x0000000000000001 (NEEDED) Shared library: [libdbus-1.so.3]
 0x0000000000000001 (NEEDED) Shared library: [libjson-c.so.2]
 0x0000000000000001 (NEEDED) Shared library: [librt.so.1]
 0x0000000000000001 (NEEDED) Shared library: [libc.so.6]

and found them all

ls lib/x86_64-linux-gnu/
ld-2.17.so libnsl-2.17.so
ld-linux-x86-64.so.2 libnsl.so.1
libacl.so.1 libnss_compat-2.17.so
libacl.so.1.1.0 libnss_compat.so.2
libanl-2.17.so libnss_dns-2.17.so
libanl.so.1 libnss_dns.so.2
libatasmart.so.4 libnss_files-2.17.so
libatasmart.so.4.0.5 libnss_files.so.2
libattr.so.1 libnss_hesiod-2.17.so
libattr.so.1.1.0 libnss_hesiod.so.2
libaudit.so.1 libnss_nis-2.17.so
libaudit.so.1.0.0 libnss_nisplus-2.17.so
libblkid.so.1 libnss_nisplus.so.2
libblkid.so.1.1.0 libnss_nis.so.2
libbrlapi.so.0.6 libntfs-3g.so.841
libbrlapi.so.0.6.0 libntfs-3g.so.841.0.0
libBrokenLocale-2.17.so libpamc.so.0
libBrokenLocale.so.1 libpamc.so.0.82.1
libbsd.so.0 libpam_misc.so.0
libbsd.so.0.6.0 libpam_misc.so.0.82.0
libbz2.so.1 libpam.so.0
libbz2.so.1.0 libpam.so.0.83.0
libbz2.so.1.0.4 libparted.so.0
libc-2.17.so libparted.so.0.0.1
libcap.so.2 libpci.so.3
libcap.so.2.22 libpci.so.3.1.9
libcidn-2.17.so libpcprofile.so
libcidn.so.1 libpcre.so.3
libcom_err.so.2 libpcre.so.3.13.1
libcom_err.so.2.1 libpcsclite.so.1...

Read more...

Revision history for this message
Rob Frohne (frohro) wrote :

This might help too:

frohro@frohro-e6410:/media/frohro/5b901d56-389b-48b1-a911-08dab37d228d$ sudo fdisk -l
[sudo] password for frohro:

Disk /dev/sda: 128.0 GB, 128035676160 bytes
255 heads, 63 sectors/track, 15566 cylinders, total 250069680 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x000ea3e1

   Device Boot Start End Blocks Id System
/dev/sda1 * 2046 134223871 67110913 5 Extended
/dev/sda2 134223872 250068991 57922560 83 Linux
/dev/sda5 7811072 134223871 63206400 83 Linux
/dev/sda6 2048 7811071 3904512 82 Linux swap / Solaris

Another thing: My other partition has Ubuntu 13.04 32 bit and the 13.10 is the 64 bit. My machine is a 64 bit one, a Dell E6410.

The error message says look at this document:

https://www.kernel.org/doc/Documentation/init.txt

I don't see anything that I can tag as a problem from that. I must be missing it.

Revision history for this message
Rob Frohne (frohro) wrote :

One thing I did note as I was in grub2, was that the drive partitions said something like this (hd0,msdos), and I didn't think there were any msdos partitions. The above note seems to corroborate that.

Revision history for this message
Rob Frohne (frohro) wrote :

I guess the msdos is the partition type. (I used logical, in gparted or the installer; I can't recall which anymore.)

Revision history for this message
Phillip Susi (psusi) wrote :

/init is the script in the initramfs, not /sbin/init in your root fs, so it sounds like your initramfs is broken. Try regenerating it with update-initramfs, and attach your /boot/grub/grub.cfg.

Changed in grub2 (Ubuntu):
status: New → Incomplete
Revision history for this message
Rob Frohne (frohro) wrote :

Here is my grub.cfg.

I'm still trying to figure out how to run update-initramfs when booted from Ubuntu 13.04.

It seems to be the chicken and egg problem. From 13.04 when connected into the / directory of the 13.10 partition, I get:

sudo update-initramfs -c -k 3.11.0-11-generic
[sudo] password for frohro:
update-initramfs: Generating /boot/initrd.img-3.11.0-11-generic
grep: /boot/config-3.11.0-11-generic: No such file or directory
WARNING: missing /lib/modules/3.11.0-11-generic
Device driver support needs thus be built-in linux image!
ERROR: could not open directory /lib/modules/3.11.0-11-generic: No such file or directory
FATAL: could not search modules: No such file or directory
WARNING: could not open /tmp/mkinitramfs_Uhii5Q/lib/modules/3.11.0-11-generic/modules.order: No such file or directory
WARNING: could not open /tmp/mkinitramfs_Uhii5Q/lib/modules/3.11.0-11-generic/modules.builtin: No such file or directory

and when I use the -b ./boot option I get the same thing.

Revision history for this message
Phillip Susi (psusi) wrote :

I'm not sure what you mean by "when connected into the / directory of the 13.10 partition". Did you mount it and chroot into it?

Revision history for this message
Rob Frohne (frohro) wrote :

Thanks Philip,

I hadn't figured out about the chroot. I was just connected to it from
13.04. Then I tried chroot, but you can't chroot from a 32 bit system to
a 64 bit root, so I am now booted from the USB Live 64 bit install and
have chrooted there okay, but it won't update. Here is what I get:

root@ubuntu:/# sudo update-initramfs -c -k 3.11.0-11-generic
sudo: unable to resolve host ubuntu
update-initramfs: Generating /boot/initrd.img-3.11.0-11-generic
/usr/sbin/mkinitramfs: 137: /usr/sbin/mkinitramfs: cannot create
/dev/null: Permission denied
/usr/sbin/mkinitramfs: 142: /usr/sbin/mkinitramfs: cannot create
/dev/null: Permission denied
/usr/sbin/mkinitramfs: 142: /usr/sbin/mkinitramfs: cannot create
/dev/null: Permission denied
/usr/sbin/mkinitramfs: 279: /usr/sbin/mkinitramfs: cannot create
/dev/null: Permission denied
WARNING: no ldd around - install libc-bin
update-initramfs: failed for /boot/initrd.img-3.11.0-11-generic with 1.
root@ubuntu:/# which ldd
/usr/bin/ldd

I noticed from reading the thread quoted above than someone in August had
this issue, and tried the next daily build and it solved the problem for
him. Maybe I should do that, but then I'll always wonder what was the
problem with this one.

Any ideas?

Thanks,

Rob

Revision history for this message
Rob Frohne (frohro) wrote :

I went and tried the daily build from today, and the first reboot I did recovery mode so I could see what was happening. I noticed the kernel panic was different than the ones I get subsequently. I thought I took a photo of it, but the camera button didn't get pushed properly, and I missed it. Even though I formatted the partition, I now notice that there is an initrd.img.old in the / directory.

Revision history for this message
Rob Frohne (frohro) wrote :

I decided to try installing 13.04, 64 bit, to see what would happen and the results are identical. So this is not an OS issue, or it is there in 13.04 as well.

Revision history for this message
Phillip Susi (psusi) wrote :

Bind mount /dev, /proc, and /sys before chrooting:

sudo mount --bind /dev /mnt/dev, etc

You might also want to check the drive's SMART status in the disk utility to make sure it isn't failing.

Revision history for this message
Rob Frohne (frohro) wrote :

Thanks Phillip,

I discovered something interesting. The problem seems to go away if I install a 32 bit OS instead of 64 bit. Right now I'm installed with Ubuntu 13.10 32 bit on that same partition, and everything is hunky doory. I do want to change over to 64 bit, so I'm going to go back and install Ubuntu 13.10 64 bit and try your suggestions above to create a new initramfs.

The results of SMART testing (short test) completed without error.

Rob

Revision history for this message
Rob Frohne (frohro) wrote :

Phillip,

You suggestion about bind mounting allowed update-intiramfs to work, but the no /init error persists.

I think the key lies in the fact that 32 bit installs work, but not 64 bit ones, but I'm not quite sure where to go from here.

Thanks for the assistance.

Rob

Revision history for this message
Rob Frohne (frohro) wrote :

Further information:

This bug might be better filed against unetbootin, because when I install from a DVD, it works flawlessly!

I am going to proceed on with my install, but I may have a chance to test things after I determine that I can ditch my 13.04 partition.

Thanks for all the help!

Rob

Revision history for this message
Rob Frohne (frohro) wrote :
Revision history for this message
Launchpad Janitor (janitor) wrote :

[Expired for grub2 (Ubuntu) because there has been no activity for 60 days.]

Changed in grub2 (Ubuntu):
status: Incomplete → Expired
Revision history for this message
aleandro (aleandrodasilva) wrote :

Same bug after some updates in ubuntu 13.10. I had to reistall after having tried all methods of all gurus around. Reinstall over same OS failed with same error. No idea why. It seems that someone in the web solved this error putting back the link in the /lib/lib64 folder.

ln -s /lib/x86_64-linux-gnu/ld-2.17.so ld-linux-x86-64.so.2

This seems a common problem in ubuntu 13.04 and 13.10. Everything is intact in the filesystem with exception of that small file.

I would reopen this thread due to the frequency of this bug. Looking around in the web many users had this problem after regular updates of the OS.

Revision history for this message
cuby (cuby) wrote :

This is far from expired.
My desktop has an 3 disks. one is an SSD (for the / filesystem). I was unable to install Ubuntu 64 bits on it because of this problem. Tried 12.04 and 13.10 both as a CD install and USB. always the same message. It seems there is no /init script in the initramfs.

Grub 2 config seems ok. References are pointing to the right places and the destination files seem to be there. There is no way to boot the machine normally.

Tried Ubuntu 32Bits worked immediately.

Revision history for this message
Rob Frohne (frohro) wrote :

For me the problem originated from using unetbootin to install. When I went to using a CD, all was well.

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

Other bug subscribers

Bug attachments

Remote bug watches

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