[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: boot failure "mount: mounting /dev/sda1 on /root failed: no such device"



On Tuesday 07 July 2009 15:26:54 Kelly Clowers wrote:

> Is there a way to get a shell inside the initramfs, to
> look around?

  You can boot with "break=mount" as a kernel option, it 
will drop you into a busybox shell just before mounting
the root directory.  The initramfs environment doesn't
inherit environment variables from the boot scripts, but
you can browse the file system and run the scripts and
stuff.

  I've run into similar problems when the initramfs
didn't include the right driver module for the disk drive --
the result is that the BIOS can see the drive, and GRUB
can see it, but the kernel can't -- you get symptoms 
similar to what you describe, and it's also consistent
with the LiveCD working, as it presumably has a full 
kernel.  
  The solution in that case is to get the right module into
the initramfs, most simply by just listing it by name
in /etc/initramfs-tools/modules and rebuilding the 
initramfs.

  I haven't mentioned it because it doesn't make sense
in your case -- you're restoring an RMA'd drive on 
an old box, where presumably the motherboard SATA 
device hasn't changed, so the initramfs you restored
from back-up should work, plus you said you rebuilt the
initramfs several times.

  The other way to investigate the initramfs, incidentally,
is to just unpack it somehwere -- it's a cpio archive, you
can google for instructions.


				-- A.
-- 
Andrew Reid / reidac@bellatlantic.net


Reply to: