LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - General (https://www.linuxquestions.org/questions/linux-general-1/)
-   -   LILO config for Slack 10.0 and XP (https://www.linuxquestions.org/questions/linux-general-1/lilo-config-for-slack-10-0-and-xp-352989/)

Permaximus 08-13-2005 08:10 PM

LILO config for Slack 10.0 and XP
 
After searching, reading, and experimenting for a few hours this is my last hope. I have two hard drives, one with several partitions including an NTFS which has my XP install on it and another disk with my Slack install. My Linux drive is set to master and the other to slave. This is the output of fdisk -l:

Code:

bash-2.05b# fidks -l

Disk /dev/hdc: 10.1 GB, 10151286400 bytes
255 heads, 63 sectors/track, 233 cylinders
Units = cylinders of 16065 * 512 = 8225280 byes

  Device    Boot        Start                End          Blocks      Id    System
/dev/hdc1      *                1                  13        104391    83    Linux
/dev/hdc2                      14              1200      9534577+  83    Linux
/dev/hdc3                  1201            1232        257040    82    Linux Swap
 
Disk /dev/hdd: 160.0 GB, 160041885696 bytes
255 heads, 63 sectors/track, 19457 cylinders
Units = cylinders of 16065 * 512 = 8225280 byes

  Device    Boot        Start                End          Blocks      Id    System
/dev/hdd1      *                1            11473    92156841      7    HPFS/NTFS
/dev/hdd2                11486          104422+    104422+  83    Linux
/dev/hdd3                19392      63504945    63504945    83    Linux
/dev/hdd4                19393            19457      522112+    f    Linux
/dev/hdd5                19393            19457      522112+    82  Linux Swap

So I did this little guy:
Code:

bash-2.05b#su
bash-2.05b#gedit /etc/lilo.conf

This is what my lilo.conf looks like:

# LILO configuration file
# generated by 'liloconfig'
#
# Start LILO global section
boot = /dev/hdc
message = /boot/boot_message.txt
prompt
timeout = 1200
# Override dangerous defaults that rewrite the partition table:
change-rules
reset
# VESA framebuffer console @ 1024x768x256
vga = 773
# Normal VGA console
# vga = normal
# VESA framebuffer console @ 1024x768x64k
# vga=791
# VESA framebuffer console @ 1024x768x32k
# vga=790
# VESA framebuffer console @ 1024x768x256
# vga=773
# VESA framebuffer console @ 800x600x64k
# vga=788
# VESA framebuffer console @ 800x600x32k
# vga=787
# VESA framebuffer console @ 800x600x256
# vga=771
# VESA framebuffer console @ 640x480x64k
# vga=785
# VESA framebuffer console @ 640x480x32k
# vga=784
# VESA framebuffer console @ 640x480x256
# vga=769
# End LILO global section
# Linux bootable partition config begins
image = /boot/vmlinuz
root = /dev/hdc2
label = Linux
read-only
# Linux bootable partition config ends
#
#
## WinXP bootable partition config begins
other = /dev/hdd1
label = XP
table = /dev/hdd
# WinXP bootable partition config ends


Then I ran
Code:

bash-2.05b# /sbin/lilo
Added Linux *
Added XP

This is where I am stuck. When I select XP when lilo boots it won't do anything, it just hangs after it says, "booting XP" or whatever it says.

I greatly appreciate your help and am glad to provide anymore information if needed. Thanks again.

Charred 08-14-2005 01:33 AM

Quote:

Device Boot Start End Blocks Id System
/dev/hdd4 19393 19457 522112+ f Linux
/dev/hdd5 19393 19457 522112+ 82 Linux Swap
I find it interesting that hdd4 and hdd5 appear to occupy the same physical space.

fotoguy 08-14-2005 02:18 AM

Both /dev/hdc1 and /dev/hdd1 are set as boot partitions, i think that might be your problem, you canonly have one boot partition. Did you install windows first before installing linux?

Permaximus 08-14-2005 08:34 AM

Quote:

Originally posted by Charred
I find it interesting that hdd4 and hdd5 appear to occupy the same physical space.

What's interesting about that is that that isn't a typo, that is the actual print out from fdisk -l.

Quote:

Originally posted by fotoguy
Both /dev/hdc1 and /dev/hdd1 are set as boot partitions, i think that might be your problem, you canonly have one boot partition. Did you install windows first before installing linux?
They are on different hard drives, they dont have the same MBR. I wouldn't think that would matter. Doesn't LILO just select which disk to boot, then it would load up the NT loader?

Thanks for the quick replies.

rose_bud4201 08-14-2005 09:16 AM

No - he means that the boot partition is what the system looks at when it's looking for a bootloader. Set the boot partition to be the one that lilo -your bootloader- is on, and don't worry about having the windows partition be bootable. It doesn't need to be (as lilo tells windows "boot now plskthx!").

Permaximus 08-14-2005 01:25 PM

I guess I don't understand. It is booting LILO. LILO comes up fine, it will boot Slack fine, and it gives me the option to boot XP but won't do it. So all I need to do is erase whatever is on the boot partition of my windows drive?

Charred 08-14-2005 02:02 PM

Toggle the "Bootable" option of your Windoze partition to "OFF"

Permaximus 08-14-2005 02:12 PM

Quote:

Originally posted by Charred
Toggle the "Bootable" option of your Windoze partition to "OFF"
How?

fotoguy 08-14-2005 05:27 PM

Quote:

Originally posted by Permaximus
What's interesting about that is that that isn't a typo, that is the actual print out from fdisk -l.



They are on different hard drives, they dont have the same MBR. I wouldn't think that would matter. Doesn't LILO just select which disk to boot, then it would load up the NT loader?

Thanks for the quick replies.

Maybe it doesn't make a difference, I have only dual-booted a single drive never 2 drives so I'm problably wrong. It may just be a corrupted MBR on the windows drive, just repair the bootloader for windows.

Insert your windows cd, boot up to the screen it will ask if you would like to install windows or repair an installation, just press the 'r' key and then it will take you to a command prompt, you may also need to enter the administrators password. Theres 2 commands you can use:

fixboot
fixmbr

It has been a while since I have done these so I not sure which one will work, hope this will help.

aikidoist72 08-14-2005 06:04 PM

The boot option is irrelevant if you have a BIOS that you can change the boot options. If you set your BIOS to start from the Primary Master HD then that is the boot partition it will find. Conversely if you set the BIOS to Secondary Master, then that is the boot partition. I have had 4 HD's all with boot partitions running Xp, FreeBSD and various Linux distro's.

Although I use Slackware, and it's default boot loader is LILO, I admit I don't use it and never have. I use GRUB, and here is my setup

Code:

root@slacker:~# fdisk -l

Disk /dev/hda: 41.1 GB, 41110142976 bytes
16 heads, 63 sectors/track, 79656 cylinders
Units = cylinders of 1008 * 512 = 516096 bytes

  Device Boot      Start        End      Blocks  Id  System
/dev/hda1  *          1        194      97744+  83  Linux
/dev/hda2            195      23468    11730096    5  Extended
/dev/hda3          23469      42844    9765504  83  Linux
/dev/hda4          42845      79656    18553248  83  Linux
/dev/hda5            195        1186      499936+  83  Linux
/dev/hda6            1187        3124      976720+  83  Linux
/dev/hda7            3125        4116      499936+  83  Linux
/dev/hda8            4117      11866    3905968+  83  Linux
/dev/hda9          11867      23468    5847376+  83  Linux

Disk /dev/hdb: 40.0 GB, 40020664320 bytes
16 heads, 63 sectors/track, 77545 cylinders
Units = cylinders of 1008 * 512 = 516096 bytes

  Device Boot      Start        End      Blocks  Id  System
/dev/hdb1  *          1        192      96358+  83  Linux
/dev/hdb2            192      20544    10257502+  5  Extended
/dev/hdb3          20544      39924    9767520  83  Linux
/dev/hdb4          39924      77545    18961267+  a5  FreeBSD
/dev/hdb5            192        1164      489951  83  Linux
/dev/hdb6            1164        2136      489951  82  Linux swap
/dev/hdb7            2136        3108      489951  83  Linux
/dev/hdb8            3108        8925    2931831  83  Linux
/dev/hdb9            8926      20544    5855661  83  Linux

Disk /dev/hdd: 80.0 GB, 80026361856 bytes
16 heads, 63 sectors/track, 155061 cylinders
Units = cylinders of 1008 * 512 = 516096 bytes

  Device Boot      Start        End      Blocks  Id  System
/dev/hdd1  *          1      30218    15229588+  7  HPFS/NTFS
/dev/hdd2          30231      155061    62914824  83  Linux

In order to boot the Xp partition you need to map it. It kind of fools windows into believing it is installed on the first hard drive. I think Windows has some sort of complex about not being first. If it is not first then it is a loser.......... however I digress.


Here is my GRUB menu.1st entry
Code:

# (0) Slackware 10.1
title Slackware Current
root        (hd0,0)
kernel        (hd0,0)/vmlinuz vga=0x317 root=/dev/hda5 devfs=nomount ro splash=verbose
initrd        (hd0,0)/initrd-dolphin

# (1) Slackware 10.1
title Slackware Current old
root        (hd0,0)
kernel        (hd0,0)/vmlinuz-2.6.12-2-ev4 vga=0x317 root=/dev/hda5 devfs=nomount ro splash=verbose
initrd        (hd0,0)/initrd-dolphin

# (2) PC-BSD
title PCBSD 0.7.8 (BETA)
root (hd1,3,a)
kernel /boot/loader
boot

# (5) Vector Linux
title        Vector Linux
root        (hd1,0)
kernel        (hd1,0)/vmlinuz-2.6.12-2-ev1 root=/dev/hdb5 ro devfs=nomount vga=0x317 splash=silent
initrd        (hd1,0)/initrd


# (6) Microsoft Windows(TM)
title  Win XP
root (hd2,0)
map (hd0) (hd2)
map (hd2) (hd0)

makeactive
chainloader +1

This may somehow apply to LILO - Hope it helps! :)

lunarcloud_88 08-15-2005 10:35 AM

anyone know how to do this in lilo?

Permaximus 08-15-2005 09:38 PM

Quote:

Originally posted by fotoguy
Maybe it doesn't make a difference, I have only dual-booted a single drive never 2 drives so I'm problably wrong. It may just be a corrupted MBR on the windows drive, just repair the bootloader for windows.

Insert your windows cd, boot up to the screen it will ask if you would like to install windows or repair an installation, just press the 'r' key and then it will take you to a command prompt, you may also need to enter the administrators password. Theres 2 commands you can use:

fixboot
fixmbr

It has been a while since I have done these so I not sure which one will work, hope this will help.

Windows boots fine though, so I doubt that it is the Windows bootloader.

Thanks aikidoist72, I used to use Grub back in my Red Hatting days. I might just have to switch if I cannot get this figured out. Dang Windows, gives me trouble even when it is working perfectly.

aikidoist72 08-15-2005 10:03 PM

Hi Permaximus,

No problemo! Based on your fdisk -l output you will probably need to enter this
Code:

# (6) Microsoft Windows(TM)
title  Win XP
root (hd1,0)
map (hd0) (hd1)
map (hd1) (hd0)
makeactive
chainloader +1

Also, as it may have been a while
Code:

grub> root (hd0,1)
grub> setup (hd0)
grub> quit

And if your into a nice splash screen for grub - quit how-to

http://ruslug.rutgers.edu/~mcgrof/grub-images/

Cheers

Permaximus 08-19-2005 08:22 PM

I am not using grub

lunarcloud_88 08-20-2005 08:31 PM

nor am i.


All times are GMT -5. The time now is 01:13 AM.