I have a dual SATA drive setup for a file storage/general purpose box, which is arranged thus:

/dev/sda1 + /dev/sda1 = /dev/md0 RAID1 --> /boot

/dev/sda2 + /dev/sdb2 = /dev/md1 RAID1 --> LVM with VGs and LVs for /, /usr, /var, etc. partitions.

I chose this setup during Ubuntu install and it worked quite fine, until some latest updates that apparently included kernel update or something like that, which required GRUB to modify something.

After that I now have kernel panic and unable to mount FS on boot.

I booted from Live CD and after getting mdadm and lvm2, checked that filesystems are fine, I can assemble MD arrays and LVM scans produce the correct VG/LV listings.

I would appreciate if you could tell me (or point to good resource about) how to now recover the boot from hard disk in middle of Ubuntu update. I have been doing recoveries mostly for LILO bootloader, which is, as I understand, almost extinct, and I have practically no GRUB experience (and it looks way more complicated than LILO).

Edit: I tried the https://help.ubuntu.com/community/Grub2#ChRoot procedure, which seems to work for some, that is, chroot into the existing server config from live cd, then try to update-grub, grub-install /dev/sdXX, but it doesn't work.

Specifically, I tried to do "grub-install /dev/sda", but after reboot I encountered same error as before.


as per cstamas' answer, you can use the Chroot procedure with unmounting & remounting dev services as described in the ubuntu community link, then once inside chroot, update-initramfs (for -k specify kernel version name that matches one in your /lib/modules/) and update-grub2, no need for grub-install.

1 Answer 1


Personally I prefer grml.org's rescue cds.

First of all the most important is to get a cd that matches your $arch like i386/amd64.

  • You boot the cd and assemble the raid/lvms.
  • mount only the root fs
  • chroot into the root fs
  • outside the rootfs stop udevd
  • inside the rootfs start udevd
  • assemble/scan/mount the missing filesystems inside the chroot (the most important is the usr and boot)
  • rebuild the initramfs
    • on debian (i think it is the same on ubuntu) run:
    • update-initramfs -uv -k $yourkernelversion
    • update-grub or update-grub2

If something else is wrong like lvm2 uninstalled by accident or something like that you can reinstall it in the chroot. If you give the exact error message we try to take a look.

  • Thanks: I chrooted into the rootfs, but I had to mount some of the filesystems from outside chroot (/boot, /var, /usr) else I got errors inside chroot.
    – Gnudiff
    Jun 19, 2011 at 17:06

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .