From: Werner Almesberger (almesber@nessie.cs.id.ethz.ch)
Date: 09/07/92


From: almesber@nessie.cs.id.ethz.ch (Werner Almesberger)
Subject: Re: MBR recommendation needed
Date: Mon, 7 Sep 1992 15:23:42 GMT

In article <1992Sep6.153433.22751@pool.info.sunyit.edu> ujlh@pool.info.sunyit.edu (James Henrickson) writes:
> I would like to boot DOS and Linux off the hard drive. I am currently
> using LILO and the MS-DOS MBR with the active partition set to Linux.

Easy, just tell LILO about it.

I'm assuming you have created an install script /etc/lilo/install and MS-DOS
is on your first partition. Your present /etc/lilo/install should look like
this (device names are probably different, you might use more options):

#!/bin/sh
/etc/lilo/lilo -c -i /etc/lilo/boot.b \
  /linux

Now, you change it to

#!/bin/sh
/etc/lilo/lilo -c -i /etc/lilo/boot.b \
  /linux \
  msdos=/etc/lilo/chain.b+/dev/hda1@/dev/hda

(Or, better, make the second line
$ROOT/etc/lilo/lilo -c -i /etc/lilo/boot.b $* \
^^^^^ ^^
and also add a second Linux boot image.)

Run it and reboot. Now, before LILO starts loading Linux, press [Shift],
[Ctrl] or [Alt] and hold that key down. LILO will display a boot: prompt
and you can enter msdos to boot MS-DOS.

If your system boots too quickly to press [Shift], etc. fast enough, you
can specify a delay with the -d option, e.g. -d 10 for one second.

Note: - you don't have to move LILO's boot sector. MS-DOS' MBR is okay as
        the MBR (unless you care about that fraction of a second it takes
        to load it).
      - this and may other things are described in the documentation that
        accompanies LILO.

- Werner

-- 
   _________________________________________________________________________
  / Werner Almesberger, ETH Zuerich, CH      almesber@nessie.cs.id.ethz.ch /
 / IFW A44  Tel. +41 1 254 7213                 almesberger@rzvax.ethz.ch /
/_BITNET:_ALMESBER@CZHETH5A__HEPNET/CHADNET:_[20579::]57414::ALMESBERGER_/