shame on me

Shaun shaun at dog-berry.net
Tue Aug 20 21:00:43 PDT 2002


On Tue, 2002-08-20 at 08:33, none wrote:
> On Tue, Aug 20, 2002, Shaun wrote:
> > 
> > This should help lilo boot win9x from a drive other than hda:
> > 
> > (tried and tested with lilo-22.2)
> > 
> > # /etc/lilo.conf
> > 
> > lba32
> > boot=/dev/hda
> > 
> > disk=/dev/hda bios=0x80
> > disk=/dev/hdb bios=0x81
> > disk=/dev/hdc bios=0x82
> > disk=/dev/hdc bios=0x83
> > 
> > ( all your lilo.conf here )
> > 
> > other=/dev/hdc1
> > 	label="Win98"
> > 	map-drive = 0x80
> > 	       to = 0x82
> > 	map-drive = 0x82
> > 	       to = 0x80
> > 
> > # end lilo.conf
> > 
> > 
> > As for installing Win98 onto hdc, the easiest way must be to physically
> > swap the disks, get 98 installed, and swap them back.
> > 
> > This results in win98 being installed into hdc1, 98's MBR being
> > installed into hdc, thus lilo and linux left intact.
> > 
> > HTH, Shaun.
> > 
> > -- 
> > Unsubscribe: send email to listar at linuxfromscratch.org
> > and put 'unsubscribe blfs-support' in the subject header of the message
> > 
> 
> hi,
> think i have not enought knows about hardware:-)
> 
> ok i see http://btmgr.sourceforge.net.
> and it's look for me not apropriate because i don't need a big soft for managing my system.
> and it's seems a little big and not easy to use,i can intersted may be later but i think i have some important think to do before.
> Thanks grep for ur help
> Shaun, i think ure solution is good for me but.
> sorry i'm french and some word for me seems to have multiple way,
> swap=turn off hd. power (maybe in bios but i don't know enought bios) or physicaly
> because it's what i was doing.and i think like u say my win98 mbr is in hdc and my lfs mbr don't move.
> i think it's a good beginning.
> 
> can me explain if 0x80...
> this adress his the same for me?
> i think i have a big hole in my knowledges about adress etc.
> 
> ps:i'm imprested about all you're help,
> fast, goods ideas, effecients,
> nice phylosophie,
> lfs is a good project in all point of view.
> congratulation, people
> 
> -- 
> ----------------------------------------------------
> none
> mail:none at ingenierie.org
> Quel est la difference entre une chauve souris et...
> merde m'en rappele plus, tantpis.
> ----------------------------------------------------

OK, after a little google to refresh my memory ..

As the bios sees your (physical) drives, 

0x00 = Primary floppy   ( /dev/fd0 or A: )
0x01 = Secondary floppy ( /dev/fd1 or B: )

0x80 = Primary IDE, Master disk   ( /dev/hda )
0x81 = Primary IDE, Slave disk    ( /dev/hdb )
0x82 = Secondary IDE, Master disk ( /dev/hdc )
0x83 = Secondary IDE, Slave disk  ( /dev/hdd )

As far as I can find, these addresses work for all bios .. by keeping
them standard, the OS always knows where to find your drives.



Drive-mapping, as provided by many boot-managers, gives you the ability
to redefine these addresses.

In your case:

0x80 = Primary IDE, Master disk (/dev/hda) = Linux
0x82 = Secondary IDE, Master disk (/dev/hdc) = Windows (hopefully)

for windows to install with minimum fuss, it wants to be the first
partition, on the first disk ( 0x80 ).

The lines:

map-drive = 0x80
       to = 0x82

map-drive = 0x82
       to = 0x80

Would redefine the addresses, so that:

0x80 = Secondary IDE, Master disk = Windows (hopefully)
0x82 = Primary IDE, Master disk = Linux

Windows is now on what it sees as the first disk (0x80), just as it
wants, and should install smoothly.

I'll stress that these changes are not permenant - when the machine is
rebooted, the bios starts fresh, having no memory of what lilo
instructed it previously.

These topics are described in the "lilo mini-HOWTO", although not as
specific to this scenario :

http://www.tldp.org/HOWTO/mini/LILO-4.html
http://www.tldp.org/HOWTO/mini/LILO-6.html#ss6.2

or in french .. 

http://www.freenix.fr/unix/linux/HOWTO/mini/LILO-4.html
http://www.freenix.fr/unix/linux/HOWTO/mini/LILO-6.html

Hopefully they'll explain better where I've failed.



The issue of swaping, is simply the easiest method I can see of getting
windows onto hdc to start with. If you boot with either a boot-floppy,
or a CD-ROM, all lilo's careful preperations will be skipped.

Using this method,

physically remove the drive containing linux (primary IDE, master disk)

physically move the drive that will contain windows, to where the linux
drive came from (primary IDE, master disk).

Install windows as usual.

At this stage, windows was installed into the partition it wants to be,
and the windows MBR is installed onto the beginning of that disc.
Neither linux nor lilo have been touched.

physically move the windows drive, to it's original position (Secondary
IDE, master disk)

physically replace the linux to it's original position (Primary IDE,
master disk).

At this stage, lilo and linux are as they were originally, and windows
is now on your /dev/hdc. All that remains is to setup the lilo trickery,
so windows will always see itself as still being on that first drive.

Physically swapping the drives like this isn't as daunting as it sounds
.. you're just swapping which cable goes to which drive, for the
duration of the windows install.



Hopefully this is a better explanation that last night's :o)

HTH, Shaun



Due to the wonder of backups, here's my lilo.conf from when I used this,
as an example. The same situation, except I used /dev/hdb rather than
hdc.  Win98 was put on a spare disk, as /dev/hdb, to satisfy my Red
Alert addiction:

### /etc/lilo.conf

lba32
boot=/dev/hda

### BIOS Disks

disk=/dev/hda   bios=0x80
disk=/dev/hdb   bios=0x81
disk=/dev/hdc   bios=0x82
disk=/dev/hdd	bios=0x83

### Lilo BMP Loader

install=/boot/boot-bmp.b
bitmap=/boot/lilo-bmp/boot.bmp
bmp-colors=15,7,0,15,0,0
bmp-table=54,6,1,18,
bmp-timer=75,30,15,0,0

### Boot Options

map=/boot/map
prompt
delay=100
timeout=100
default="Debian Linux"

### Images

image=/boot/vmlinuz-2.4.18
	label="Debian Linux"
	vga=0x318
	append=" hdc=ide-scsi"
	root=/dev/hda8
	read-only

image=/mnt/lfs/boot/vmlinuz-2.4.18
	label="LFS"
	vga=0x318
	append=" hdc=ide-scsi"
	root=/dev/hda7
	read-only

### Other OS

other=/dev/hda1
	label="Windows 2000"

other=/dev/hda2
	label="FreeBSD 4.4"

other=/dev/hdb1
	label="Windows 98"
	map-drive=0x80 to=0x81
	map-drive=0x81 to=0x80

### end /etc/lilo.conf



-- 
Unsubscribe: send email to listar at linuxfromscratch.org
and put 'unsubscribe blfs-support' in the subject header of the message



More information about the blfs-support mailing list