GRUB issue with partitions
Hello!
Well this is not a critical issue, but it is anoying anyway.
Every time a "grub-update" is performed to introduce new kernel images to grub menu.lst, the partitions numbers in every entry is wrong, but not the drive number.
Here is the list of partitions in my single drive:
/dev/sda1 is a fat16 partition containing Dell diagnose utilities (It's a Dell laptop).
/dev/sda2 is an ext3 partition containing Debian Lenny.
/dev/sda3 is an extended partition containing /dev/sda5 for linux-swap.
/dev/sda4 is an ntfs partition for winxp.
So an entry for a linux kernel in /dev/sda2 should looks like:
title Debian GNU/Linux, kernel 2.6.28.6
root (hd0,1)
kernel /boot/vmlinuz-2.6.28.6 root=/dev/sda2 ro
initrd /boot/initrd.img-2.6.28.6
However after doing grub-update (manually or automatically by a kernel image package install), this entry for the kernel looks like:
title Debian GNU/Linux, kernel 2.6.28.6
root (hd0,2)
kernel /boot/vmlinuz-2.6.28.6 root=/dev/hda3 ro
initrd /boot/initrd.img-2.6.28.6
As you can see, the partition number is one more than what should be, and it changes sda for hda in kernel's root parameter, though there is not any hd* device under /dev.
So after a grub-update, I have to change manually the partition number on root command and partition name on kernel's root parameter for every entry listed in menu.lst.
Also it doesn't make an entry for Dell utilities partition nor Winxp partition, so I have to introduce them both manually.
Just in case it could be useful.. device.map lists:
(hd0) /dev/sda
I tried adding entries here for each partition:
(hd0,0) /dev/sda1
(hd0,1) /dev/sda2
(hd0,3) /dev/sda4
but then grub-update complains about it.
I hope someone can help me to figure out why GRUB can't guess right partition numbers.
Thanks!