Laptop wont boot, could not find /dev/root

My laptop crashed, so I moved my hardrive to another one while it was getting fixed. Got my laptop back, but when I place the hardrive back in, I get this error

Trying manual resume from /dev/disk/by-id/ata-Samsung_SSD_840_Series_S19HNEAD389689A-part3
resume device /dev/disk/by-id/ata-Samsung_SSD_840_Series_S19HNEAD389689A-part3 not found (ignoring)
Trying manual resume from /dev/disk/by-id/ata-Samsung_SSD_840_Series_S19HNEAD389689A-part3
resume device /dev/disk/by-id/ata-Samsung_SSD_840_Series_S19HNEAD389689A-part3 not found (ignoring)
Waiting for device /dev/root to appear: ......................Could not find /dev/root.
Want me to fall back to /dev/sda1? (Y/n)
 

I placed the hardrive on my desktop and this was the fstab config.

/dev/sda1            /                    ext4       acl,user_xattr        1 1
/dev/disk/by-id/ata-Samsung_SSD_840_Series_S19HNEAD389689A-part3 swap                 swap       defaults              0 0
/dev/disk/by-id/ata-Samsung_SSD_840_Series_S19HNEAD389689A-part2 /home                ext4       acl,user_xattr        1 2
proc                 /proc                proc       defaults              0 0
sysfs                /sys                 sysfs      noauto                0 0
debugfs              /sys/kernel/debug    debugfs    noauto                0 0
usbfs                /proc/bus/usb        usbfs      noauto                0 0
devpts               /dev/pts             devpts     mode=0620,gid=5       0 0


I thought the /dev/sda1 line was strange in that it didnt have a pointer to my hardrive, so I change that line to

/dev/sda1/ata-Samsung_SSD_840_Series_S19HNEAD389689A-part1 /                    ext4       acl,user_xattr        1 1

However I still got the same error.

I am using OpenSuse 12.3 with a 64 bit operating system.

Thanks

That line is invalid now. It should be “/dev/disk/by-id/ata-Samsung_SSD_840_Series_S19HNEAD389689A-part1”.
But since those partitions are not found using /dev/disk/by-id/ syntax as well, there seems to be a different problem.

Maybe you’re missing the hard disk controller driver in the initrd? Does booting a different kernel work? (“Advanced Options” in the boot menu)

I tried running the older kernel but that didn’t work either.

What does that mean?

Was the hard drive installed as an internal hard drive? If not, if it is somehow external, then your “initrd” is probably missing a kernel module needed to access that drive.

Sorry, I meant that I loaded it as an external drive on my desktop computer. It was able to load fine as a main drive on the other laptop I was using. I’ll try that one again in the morning to make sure it still works on that one.

Maybe you installed some updates on that laptop which recreated the initrd, and now it lacks needed modules for the first laptop?
Try to boot from a CD/DVD/USB and recreate the initrd. See here: https://forums.opensuse.org/content/146-using-livecd-take-over-repair-installed-system.html and run “mkinitrd” afterwards.

Or do an “update installation”, but only install the kernel. (click on “Package Selection” and unselect all packages except for the kernel, right-click on the package list and choose “All in this list->don’t install” for that)

Then that explains everything.

My desktop computer failed a few weeks ago. Mounting the hard drive in a different computer, I was able to boot it. But putting the hard drive in a disk enclosure and using as an external drive, I had errors similar to what you are seeing.

I went into rescue mode, and rebuilt the “initrd”. I could then boot it as an external drive. The reason: When I ran “mkinitrd” on that system with the drive external, the “mkinitrd” script knew which additional modules were needed in order for the kernel to be able to access the disk.

In your case: “grub2” can read the external disk and load the kernel, because grub2 is using BIOS services to read the drive. The kernel cannot read the external disk because it has not loaded the needed modules for reading an external drive, and it cannot load those modules because they are only on the drive that it cannot read.

The way that this is supposed to work, is that all modules needed during booting are in the “initrd”. The “initrd” is read by grub2, using BIOS services, and passed to the kernel. The kernel can then load modules from there, allowing it to access the disk.

Followed wolfi’s linked thread and ran mkinitrd, worked flawlessly. Thanks for the Help

Then that explains everything.

My desktop computer failed a few weeks ago. Mounting the hard drive in a different computer, I was able to boot it. But putting the hard drive in a disk enclosure and using as an external drive, I had errors similar to what you are seeing.

I went into rescue mode, and rebuilt the “initrd”. I could then boot it as an external drive. The reason: When I ran “mkinitrd” on that system with the drive external, the “mkinitrd” script knew which additional modules were needed in order for the kernel to be able to access the disk.

In your case: “grub2” can read the external disk and load the kernel, because grub2 is using BIOS services to read the drive. The kernel cannot read the external disk because it has not loaded the needed modules for reading an external drive, and it cannot load those modules because they are only on the drive that it cannot read.

The way that this is supposed to work, is that all modules needed during booting are in the “initrd”. The “initrd” is read by grub2, using BIOS services, and passed to the kernel. The kernel can then load modules from there, allowing it to access the disk.

That makes sense, however I’m curios to why it still worked on my other laptop. Did the bios services already have a good initrd that it could reference? I’m pretty sure I mounted it on my desktop before I placed it in my backup laptop.

Glad to hear that it worked! :slight_smile:

Did the bios services already have a good initrd that it could reference?

The BIOS doesn’t have/need any initrd or drivers. It just provides a low-level interface for reading sectors from the disk which is supported by all controllers. But that’s not efficient at all, it’s mainly there for compatibility. That’s why the kernel doesn’t use it and needs drivers for the hard disk controller therefore, either compiled in directly or available as module in the initrd (it can’t load the driver from the disk, since it already would need the driver to do that).
The BIOS itself reads the first sector of the disk (MBR) and runs the program found there (the bootloader).
The bootloader then loads the kernel and initrd, also by just using the BIOS’s legacy interface. Efficiency doesn’t really matter here, since it’s done only once at boot anyway.

Updated link (as requested)…
https://forums.opensuse.org/content.php/146-Using-a-LiveCD-to-take-over-repair-an-installed-system