Potential Problems with and Limitations of Dual-Boot Systems


It is possible to have a dual-boot system in which you have two (or even more) operating systems on the hard disk, and you can select which one you want at each system boot. This is a very useful configuration in many circumstances; if you only have one computer, and you want to use FreeBSD for programming and Windows for gaming, dual-booting is an ideal solution. Working with dual-boot systems can present some problems, however, if you don't take steps to avoid and/or deal with them.

First, be aware that all the information necessary to boot FreeBSD must be located within the first 1,024 cylinders of the hard disk. This is necessary for the FreeBSD boot manager to work; it means that when you partition the disk for FreeBSD using FIPS, either the root partition must be completely located within the first 1,024 cylinders, or you can use a separate boot partition that is completely located in the first 1,024 cylinders. (The crux of the matter is that the BIOS is only equipped to look for a bootable partitionone that contains /bootin that first segment of the disk.) Use the "Start" and "End" cylinder readouts in FIPS to determine where your partitions start and end. If you choose the latter option (a bootable partition other than the root partition), the root partition does not have to be completely located in the first 1,024 cylinders. Note that "completely located" means that the partition has to both start and end below the 1,024th cylinder. Simply starting below the 1,024th cylinder is not good enough.

If you need more space for Windows or DOS than is available below 1,024 cylinders, you can use FIPS again to split the Windows or DOS partition into two partitions, giving you a C: drive and a D: drive in Windows or DOS. In between these C: and D: drives, you need to install a small partition for FreeBSD to boot from. This partition will be used as /boot later on during the install (30MB should be more than enough for this partition).

Second, when you reinstall programs after partitioning, be certain to install DOS or Windows before you install FreeBSD. DOS and Windows assume that they are the only operating system on the hard drive and will overwrite the master boot record without asking. If you install FreeBSD first, installing DOS or Windows later will "clobber" FreeBSD's boot manager, and you will no longer be able to boot into FreeBSD. This problem is easily fixed, but save yourself the headaches and just install DOS or Windows first.

Dual-Booting with DOS, Windows 95, Windows 98, Windows Me, or Windows XP

FreeBSD comes with a boot manager that allows you to dual-boot with various operating systems. Simply select the "Install the FreeBSD Boot Manager" option during installation. Subsequently, each time you boot your system, you'll be given a menu allowing you to choose between FreeBSD and your previously installed version of MS-DOS or Windows, by pressing the appropriate F-key.

Tip

GAG is an alternative, third-party boot manager that's graphical and even more flexible than FreeBSD's. Visit its website at http://gag.sourceforge.net/.


Dual-Booting with Linux

If you want to dual-boot with Linux and load Linux from the FreeBSD boot manager, install LILO or GRUB (Linux boot managers) at the beginning of your Linux boot partition rather than in the master boot record (MBR). See the LILO or GRUB documentation for instructions on how to do this. After you have installed the Linux boot manager, you can boot Linux from the FreeBSD boot manager.

If you want to boot FreeBSD from LILO or GRUB, the following subsections explain how.

Booting FreeBSD from LILO

If you're running Linux and want to boot FreeBSD from Linux's LILO loader, it is fairly easy to do so. In Linux, edit the file /etc/lilo.conf and add the following lines:

other=/dev/hda2     table=/dev/hda     label=FreeBSD


Change the line beginning with other= to reflect whatever device name Linux uses to identify your FreeBSD drive. (Remember, Linux's device names, including hard drive names, are significantly different from FreeBSD's naming convention.)

After you have changed the configuration file, reinstall LILO by typing lilo as the root user.

Booting FreeBSD from GRUB

To dual-boot Linux and FreeBSD using the GRUB boot manager, edit /boot/grub/grub.conf and add the following lines:

title FreeBSD 6.1 #1         root (hd0,0,a)         kernel /boot/loader


The arguments in front of the root statement indicate where FreeBSD's root partition is located; in the examples shown previously, that has been in BSD partition a of slice 0 on the primary hard disk, thus (hd0, 0, a). If your FreeBSD installation uses different disks and slices, adjust these numbers accordingly.

Refer to http://geodsoft.com/howto/dualboot/grub.htm#freebsd for more information on using GRUB along with Linux and FreeBSD.




FreeBSD 6 Unleashed
FreeBSD 6 Unleashed
ISBN: 0672328755
EAN: 2147483647
Year: 2006
Pages: 355
Authors: Brian Tiemann

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net