GRUB Problem after Windows Install?

My current boot process is managed by GRUB. I have a multi-boot setup in which I can boot Windows or one of multiple openSUSE 11.2 instances. I have cascading GRUB menus set up exactly as I want them. It is necessary for me to reinstall Windows 7 in its (SDA1) partition. Afterwards, I intend to restore the boot configuration to its current state.

My question is: is there anything in the MBR (related to GRUB or essential to the current boot configuration) that was put there when openSUSE was installed that will have to be restored after the Windows installation? Or will it only be necessary to flip the boot partition flag back to it current setting (to SDA5, where it was set after the installation of the last 11.2 instance)?

Thanks in advance for any assistance.

After reinstalling windows GRUB will not load.

there are good solutions here GRUB Boot Multiboot openSUSE Windows (2000, XP, Vista) using the Grub bootloader.

I believe they also work with win7, but I won’t buy it, so I can’t test it.

sda5 will I guess be an extended partition.
@swerdna’s guide will work

Flipping the boot flag back will not work, you need to re-install grub. My method is here: Re-Install Grub Quickly with Parted Magic - openSUSE Forums

Make a backup of /boot/grub/menu.lst

Install WIN 7 and update it (see you next week)

Re-install grub

If you’ve got it setup to look for the flag (i.e. if there’s generic code in the MBR that seeks the flag), and if the flag is on sda5 now, and if the installation of win7 flushes the mbr and reinstalls generic code and writes the flag back to sda1, then I feel that it’s only necessary to flip the flag to get Suse’s loader back into play.

But if something goes wrong it’s not a big drama.

@swerdna
In my tests, every time I try the switch of the boot flag, it doesn’t work.
But, as you say. Whatever happens it’s no problem.

sda5 has to be a logical partition, can having the boot flag there work, or would it have to be on the extended?

You have a point there. Good to know someone has their brain in gear. I think I have seen the * on a logical before, but it does sound odd. I’m fairly sure Fedora did that recently for me, but it’s hard to recall. I have done so many more since then.

I guess we should really see fdisk -l to be completely sure of things.

Thank you for your replies. Windows had been installed first; openSUSE in an extended partition was the last install. So the menu.lst file is located in that extended partition (SDA5). Does that indicate that the GRUB code is also installed in SDA5, and that, as Swerdna suggests as a possibility, the MBR just says “go look at the boot partition and execute what’s there?” The tutorials have not quite made that clear.

I was wanting to get a handle on what to expect before I pulled the rip cord. It does appear, though, that if flipping the boot partition flag doesn’t solve the impending problem, the fix will be no big deal, thanks to the guides you’ve offered.

I’ll be blowing this thing up sometime this weekend, and I’ll report back with the results.

Thanks again for the help.

Thank you for your replies. Windows had been installed first; openSUSE in an extended partition was the last install. So the menu.lst file is located in that extended partition (SDA5). Does that indicate that the GRUB code is also installed in SDA5, and that, as Swerdna suggests as a possibility, the MBR just says “go look at the boot partition and execute what’s there?” The tutorials have not quite made that clear.

To answer the questions here we would need to see the output caf 4926 suggested.

in a root terminal,

fdisk -l

and post the output.

Back to this job; about to launch Win7 reinstall. Here’s the fdisk output:

linux-jra1:~ # fdisk -l

Disk /dev/sda: 320.1 GB, 320072933376 bytes
255 heads, 63 sectors/track, 38913 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0xd9fbd9fb

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1               1        8159    65537136    7  HPFS/NTFS
/dev/sda2            8160       16318    65537167+   7  HPFS/NTFS
/dev/sda3   *       16319       38913   181494337+   f  W95 Ext'd (LBA)
/dev/sda5           16319       16840     4192933+  82  Linux swap / Solaris
/dev/sda6           16841       25195    67111506   83  Linux
/dev/sda7           25196       28328    25165791   83  Linux
/dev/sda8           28329       31461    25165791   83  Linux
/dev/sda9           31462       33550    16779861   83  Linux
/dev/sda10          33551       35639    16779861   83  Linux
/dev/sda11          35640       37728    16779861   83  Linux
/dev/sda12          37729       38913     9518481   83  Linux

Win7 is in sda1; sda2 is data; sda3 is an extended partition, openSUSE 11.2 is installed in sda6, 7, and 8 (production and testing implementations); the rest are data.

I’ll post an update after the installation is completed.

Thanks.