1
title CentOS (2.6.32.9)
        root (hd0,0)
        kernel /vmlinuz-2.6.32.9 ro root=/dev/VolGroup00/LogVol00 rhgb quiet
        initrd /initrd-2.6.32.9.img

I'm now upgrading the kernel,but failed several times...

seems the system can't find /dev/VolGroup00/LogVol00 when booting...

How can I verify the configuration manually?

grub
  • 23
  • 1
  • 4

1 Answers1

0

It sounds like when mkinitrd was run to generate the initrd for your new kernel, it built a kernel without the required device mapper module (dm_mod). First of all, can you still boot the system using your old kernel? If so, do that, then try building a new initrd along these lines:

mv /boot/initrd-$(uname -r).img /boot/initrd-$(uname -r).img.bak
mkinitrd -v /boot/initrd-$(uname -r).img $(uname -r)

pay attention to the messages and see if lvm support is being included.

After your initrd is built, you can always mount it manually and inspect it. The script inside the initrd is pretty simple and you should be able to quickly tell if you are loading the correct modules.

Another thing to verify is that you are loading the linux software raid modules (if you are running lvm on top of software raid). If those aren't loaded in your initrd, the kernel will also fail to find the lvm volume to boot from.

Here's some instructions I wrote up about raid and lvm that might be generally useful.

Phil Hollenback
  • 14,647
  • 4
  • 34
  • 51
  • `mkinitrd` builds `initrd-2.6.32.9.img` from `vmlinux`,right? What's the difference between `initrd-2.6.32.9.img` and `vmlinux`,only `gzip`? – grub Mar 25 '11 at 03:41
  • mkinitrd actually creates a miniature bootable system that includes an init script that loads various modules such as lvm, as well as the actual kernel image. – Phil Hollenback Mar 25 '11 at 04:58
  • `mkinitrd ` needs something as **input**,right?What's its **input**? – grub Mar 25 '11 at 08:14
  • what's already on the system, for example it gets the boot-time loadable modules for the proper kernel in /lib/modules. – Phil Hollenback Mar 25 '11 at 08:25