Quicky Setup - Linux and Windows XP/2000 dual bootLinux Pengiun Installing Dual boot Windows XP/2000 and Linux? & Chain-loading Windows XP/2000 and Li

  1. Use fdisk to partition your drive properly.
  2. Download an burn 3 Mandrake 8.2 CDs or your favorite distro
  3. Install Windows XP/2000 on the first partition, make sure you use fat 32 as your file system, not xp ntfs
  4. Start your Linux Installation and install the /root directory into the second partition.
    Install GRUB into the first sector of your boot partition (usually /boot) and not in the MBR. (Note there are reported problems with lilo)
  5. Make a boot disk during the Linux installation if possible so that you can boot into it.
  6. Now boot into Linux and copy the boot image from the boot sector. To do this run:
    dd if=/dev/hdan of=/bootsect.lnx bs=512 count=1
    , where /dev/hdan is the location of /boot and /bootsect.lnx is the Linux boot image.
  7. Copy this bootsect.lnx file to a safe location where you can reach it using Windows.
  8. Reboot into Windows XP/2000 and copy this bootsect.lnx file into the root directory (C:\).
  9. Edit c:\boot.ini and append the following line: c:\bootsect.lnx=”Linux”.
  10. Reboot your system and boot directly from the hard disk.
  11. The Windows XP/2000 boot loader should now give you the option of booting into either Windows XP/2000 or Linux.
  12. Try booting into both of them to see if you were successful.

    See linux docs for more info

    Troubleshooting

    What to do if if the actual boot code is *not* installed in /boot, but in the MBR?
    When the system gets ready to make the boot sector, it creates a file in /boot
    called boot.xxxx where xxxx is some number. (In his case, it was 0300 again IIRC.) This file is 512 bytes long to match the boot sector size. Copy this file into the bootsect.lnx
    and boot into Linux.

    Your Master Boot Record (MBR) is toast
    type: lilo -u /dev/hda in linux to remove lilo
    Boot to MS-DOS and type fdisk /mbr

    How to use Grub to Chainload XP Professional or Windows 2000

The trick is to preformat the drives . By preallocating all four primary partition slots, you ensure windows xp installs on a primary partition instead of a logical drive.

To do this you must first either use fdisk (dos boot disk) to format the drives or linux.

  1. One way of doing this is to first install linux. Boot Red Hat 7.2/Mandrake 8.2 install CD, use its partition management to wipe all existing partitions and set up the partition set,including a primary partition for WinXP (which you mark as type fat32 or EXT2).
  2. Boot Windows XP install CD. It will refuse to reformat the partition made in step 1, so it instead deletes and recreates that partition as an Win32 partition. Then finish the install normally.
  3. Again boot Mandrake/RH install CD; and tell it to install GRUB in the boot partition, not on the MBR; complete the install.
  4. This leaves you with a working system that will autoboot into Windows,
    since Windows had set the partition table to mark its own partition as
    active (bootable). Then use sfdisk to mark the boot partition as active
    (sfdisk -A1 /dev/hda) and you have a working dual-boot system.
  5. There is no evidence that the Windows installer mucks with the other
    partitions. It does, however, mark its install partition as active,
    so make sure you make a Linux boot floppy so you can get back into Linux
    to run sfdisk.

Again: GRUB can chain to WinXP’s boot code when WinXP is in a primary partition, but not when it’s in a logical partition. And you must make sure to reinstall grub after windows XP.

Komentar