I have a similar proplem.
I started because I deleted sda2 and resized sda1 to the free space. Thus sda3 which was the extended partition is now sda2. The boot loade was installed to sda3 which now does not exist anymore.
However installing grub fails. I can boot with the DVD into the installed system and can reinstall grub using yast2 without any warning or error - however there is no grub comming on reboot. It still boots into the Windows system!
Here the output of what I then tried from commandline. Any help is appreciated.
fdisk -l
Disk /dev/sda: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x000bdc6e
Device Boot Start End Blocks Id System
/dev/sda1 * 1 26110 209728543 7 HPFS/NTFS
/dev/sda2 26111 60799 278639392+ 5 Extended
/dev/sda5 26111 26372 2104483+ 82 Linux swap / Solaris
/dev/sda6 26373 34205 62918541 83 Linux
/dev/sda7 34206 42038 62918541 83 Linux
/dev/sda8 42039 60799 150697701 83 Linux
Disk /dev/sdb: 400.1 GB, 400088457216 bytes
255 heads, 63 sectors/track, 48641 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x0fdf0fde
Device Boot Start End Blocks Id System
/dev/sdb1 * 1 10198 81915403+ 7 HPFS/NTFS
/dev/sdb2 10199 48641 308793397+ f W95 Ext’d (LBA)
/dev/sdb5 10199 10721 4200966 82 Linux swap / Solaris
/dev/sdb6 10722 14638 31463271 83 Linux
/dev/sdb7 14639 18555 31463271 83 Linux
/dev/sdb8 18556 26388 62918541 83 Linux
/dev/sdb9 26389 48641 178747191 83 Linux
grub-install /dev/sda
WARNING! You are trying to invoke the unsupported grub-install script
with a parameter. To really do this, call grub-install.unsupported.
You should rather call “yast2 bootloader” or create configuration files
appropriate for the intended target.
“yast2 bootloader” comes with this error message
Because of the paritioning the boot loader can not be installed properly
grub-install
GNU GRUB version 0.97 (640K lower / 3072K upper memory)
Minimal BASH-like line editing is supported. For the first word, TAB
lists possible command completions. Anywhere else TAB lists the possible
completions of a device/filename. ]
grub> setup --stage2=/boot/grub/stage2 --force-lba (hd0,2) (hd0,5)
Checking if “/boot/grub/stage1” exists… yes
Checking if “/boot/grub/stage2” exists… yes
Checking if “/boot/grub/e2fs_stage1_5” exists… yes
Running “embed /boot/grub/e2fs_stage1_5 (hd0,2)”… failed (this is not fatal)
Running “embed /boot/grub/e2fs_stage1_5 (hd0,5)”… failed (this is not fatal)
Running "install --force-lba --stage2=/boot/grub/stage2 /boot/grub/stage1 (hd0,2) /boot/grub/stage2 p /boot/grub/menu.lst "… failed
Error 22: No such partition
grub> setup --stage2=/boot/grub/stage2 --force-lba (hd0,1) (hd0,5)
Checking if “/boot/grub/stage1” exists… yes
Checking if “/boot/grub/stage2” exists… yes
Checking if “/boot/grub/e2fs_stage1_5” exists… yes
Running “embed /boot/grub/e2fs_stage1_5 (hd0,1)”… failed (this is not fatal)
Running “embed /boot/grub/e2fs_stage1_5 (hd0,5)”… failed (this is not fatal)
Running "install --force-lba --stage2=/boot/grub/stage2 /boot/grub/stage1 (hd0,1) /boot/grub/stage2 p /boot/grub/menu.lst "… succeeded
Done.
grub> quit
Here the device.map
linux:/boot/grub # cat device.map
(hd0) /dev/disk/by-id/ata-SAMSUNG_HD502HI_S1VZJ9AS904755
(hd2) /dev/disk/by-id/ata-SAMSUNG_HD103SI_S1VSJ90SB05729
(hd1) /dev/disk/by-id/ata-SAMSUNG_HD401LJ_S0HVJ1GP403880
note that hd2 is currently not installed
menu.lst
linux:/boot/grub # cat menu.lst
Modified by YaST2. Last modification on So Feb 21 09:56:51 CET 2010
THIS FILE WILL BE PARTIALLY OVERWRITTEN by perl-Bootloader
Configure custom boot parameters for updated kernels in /etc/sysconfig/bootloader
default 0
timeout 8
##YaST - generic_mbr
gfxmenu (hd0,5)/boot/message
##YaST - activate
###Don’t change this comment - YaST2 identifier: Original name: other###
title Windows 7
rootnoverify (hd0,0)
chainloader +1
###Don’t change this comment - YaST2 identifier: Original name: linux###
title SUSE LINUX
root (hd0,5)
kernel /boot/vmlinuz root=/dev/disk/by-id/ata-SAMSUNG_HD502HI_S1VZJ9AS904755-part6 noresume splash=silent quiet showopts vga=0x31b
initrd /boot/initrd
###Don’t change this comment - YaST2 identifier: Original name: failsafe###
title Failsafe – SUSE LINUX
root (hd0,5)
kernel /boot/vmlinuz root=/dev/disk/by-id/ata-SAMSUNG_HD502HI_S1VZJ9AS904755-part6 showopts apm=off noresume edd=off powersaved=off nohz=off highres=off processor.max_cstate=1 x11failsafe
initrd /boot/initrd
###Don’t change this comment - YaST2 identifier: Original name: other###
title Windows XP
rootnoverify (hd1,0)
chainloader +1