In a dual-boot system, opensuse usually installs grub to the MBR, as a result, we can choose either winxp or opensuse to boot into. In case you don’t want to mess with the MBR, there’s another alternative - grub4dos.
This is just a guide to help you install grub4dos so that you can boot into opensuse using the windows boot loader ‘ntldr’ without rewriting the MBR. Please note, this is for a new opensuse 11 install, and not an upgrade. So, we assume there is enough unallocated space after your windows partitions.
An ideal partitioning scheme for dual-boot would be:
sda1-C:-winxp system-ntfs
sda2-D:-ntfs-for all your personal files
sda4-linux swap
sda5-linux boot
sda6-linux home
It is not advisable to create any FAT32 or NTFS partitions after sda6, to be on the safe side (when booting into windows).
Your linux partitions will not show up when you boot into windows, so you can’t read them natively.
For this purpose, there’s a utility called explore2fs.
You can get it from here:
chrysocome.net
Update: Just added a link for explore2fs
http://www.chrysocome.net/downloads/explore2fs-1.07.zip
Grub4dos is available from:
https://sourceforge.net/projects/grub4dos
Get grub4dos 0.4.3
SourceForge.net: Downloading …
-
When you’re in windows, download grub4dos and you’ll find a file call ‘grldr’ in the package. Copy that file to the root of C:. Then insert your opensuse 11 live cd and shutdown the system.
-
On switching it on, it should boot from the live cd and load the opensuse 11 desktop. If it doesn’t, try using the appropriate parameters or use the failsafe mode. (You may look that up on the opensuse website).
-
Launch the installer on your desktop to install opensuse 11.
-
Under the partitioning section, you will have to edit your partitions.
Grub4dos requires that the i-node size of the linux partitions be 128, whereas the default for opensuse 11 is 256.
So we’ll have to reformat the linux partitions. Click ‘Edit’ to edit the partitions. Select each linux partition (not swap) and change the i-node size to 128 in the ‘Options’. -
Once you’ve made the changes, go on to the grub boot loader section. Here you’ll have to make sure that grub is installed in the linux boot partition and not the MBR. So, select ‘Boot Partition’ and apply the changes.
-
Go over all the settings and continue installing opensuse 11.
-
When the installer asks you to reboot the system, just boot into winxp.
-
Next, use explore2fs to copy the ‘menu.lst’ file from sda5 to the root of C:. You’ll find it in the ‘boot’ folder. (You can also use a SLAX live cd to copy the menu.lst file, since SLAX boots faster!). Please note, grub4dos usually searches for the menu.lst file in C:\ first, since that is where ‘grldr’ is placed. If it does not find one in C:, it will search for it in other partitions. So, take care that you do not have any other menu.lst file on other windows partitions.
-
Rightclick your ‘My Computer’ icon, select ‘Properties’, under the ‘Advanced’ tab, select ‘Settings’ under the ‘Startup and Recovery’ section. Click the ‘Edit’ button under ‘System Startup’ to edit the boot.ini file. Add a new line at the end of the file and type the following:
C:\grldr=“Linux”
Save it and OK everything. -
Shutdown your system and then switch it on.
-
You should see a new line ‘Linux’ below the usual Windows XP selection. Select Linux and press ENTER.
-
Grub4dos should load and give you options for opensuse 11 and Windows too ! So, select opensuse 11 and press ENTER.
-
Opensuse 11 should boot for the first time and complete the hardware auto configuration.
-
Once you get into the desktop, navigate to your boot folder and see if the menu.lst file is identical to the one on your C:\ drive. Thankfully, you’ll be able to read/write to windows partitions from Linux natively.
-
There’s one more important thing for the future ! Whenever there’s a kernel update, the menu.lst file is also updated.
So, you’ll have to copy the new menu.lst file every time to C:. You can also do this from windows using explore2fs.
Grub4dos also has a command line. So, you can also boot into a linux system by loading the generic kernel/initrd in the command line. For further information on how to use grub4dos effectively, look up the grub4dos website and manual.
As you can see, the MBR is untouched, and uninstalling linux is easier. (Just delete grldr and the menu.lst from C:\ and delete your linux partitions from windows).
Hope this tutorial has been useful. If you have any problems, please post it as a separate thread with ‘grub4dos’ as the prefix.