LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - General (https://www.linuxquestions.org/questions/linux-general-1/)
-   -   Trouble with setting up a Dual Boot system (https://www.linuxquestions.org/questions/linux-general-1/trouble-with-setting-up-a-dual-boot-system-36063/)

tarballed 11-21-2002 09:24 AM

Trouble with setting up a Dual Boot system
 
Well, just as the subject states, i'm having some problems getting a dual boot system up and running. Let me give some specs and what i've done so far. Maybe someone can see where I messed up:

PIII 1gig CPU
512 RAM
26 gig IBM Drive

I installed Win2K first. I set it up on a 13 gig partition.
I then installed RH 7.3. I setup my partitions on the remaining hard disk space; made a /, home, /usr and /var partition.

Now, when I went through the setup process, I specified to boot the boot loader (The screen to where you can specify whether to use LILO or GRUB) on the / partition, not the MBR.

I was assuming that was all I needed to do. But, after the RH install and a reboot, I was not prompted for a boot manager and Win2K booted right up.

Obviously, I missed something.

I think im close, im just not sure what I missed.

Anyone have any ideas on what I left out? I did not make a boot disk and am wondering if I need to make that disk, then boot to it first. Once im there, make some type of configuration change?

Anyone have ideas?

Thanks everyone.

Tarballed

Bert 11-21-2002 09:29 AM

Making a boot disk is always a good idea. If all else fails, you have a bootable kernel image safely tucked away on a floppy.

If you can get into linux post the ouput of

/sbin/fdisk -l /dev/hda

and the output of

more /etc/lilo.conf

if you use lilo or if you use grub:

/boot/grub/menu.lst

(The files may not be in those exact locations - have a look around). Then we can help you.

Bert

tarballed 11-21-2002 09:52 AM

Just out of curiosity, i'm starting to wonder why the LILO boot loader did not start up. I guess I was expecting it to load up right away when the computer would start up. But, it was not so I missed something.

Is there something I missed most likely during the setup procedure where I specified where to place the boot loader? Either the MBR or the / partition?

I'm thinking i really missed something here.

Unfortunately, im not at the computer that this is setup on. :( At work right now.

Anyway, I installed Win2K on /dev/hda1.

My Linux partitions are installed on /dev/hda2-5

I have not edited lilo.conf yet. Was plain after the install.

Thoughts?

Tarballed

tarballed 11-21-2002 10:17 AM

I've been doing some research and came across a couple of things that prompted me to come back and ask a few questions:

I found the Linux+NT Loader at www.tldp.org

What striked me as very peculiar is that you had to do some editing to the boot.ini file for Windows 2K.

My question is, is this absolutely necessary thing to do to be able to get a successful dual boot between Windows and Linux?

Or is there something else that can be done to not have to do this step?

Here is the output I was referring to:

You have to boot from diskettes until the NT-part is fixed.


Now you have to peel the bootsector from your Linux-root-Partition. With /dev/hda2 as your linux-partition, the dd-command is:


# dd if=/dev/hda2 of=/bootsect.lnx bs=512 count=1

There is something wrong if your bootsect.lnx has more than 512 bytes.

Now copy the file bootsect.lnx to a DOS-formated floppy if this is your way to transfer files to the NTFS-Windows-partition.

You can copy it with


# mcopy /bootsect.lnx a:

or with


# mount -t msdos /dev/fd0 /mnt
# copy /bootsect.lnx /mnt
# umount /mnt


Copy the file from the diskette to C:\\bootsect.lnx. I don't tell you how to do that.

What lilo.conf is for linux is c:\\boot.ini for Windows NT. Remove the, system- and the read-only-attribute before you can modify it with:


C:\attrib -s -r c:\boot.ini

Now change the file boot.ini with an editor, notepad for example, as follows:


[boot loader]
timeout=30
default=multi(0)disk(0)rdisk(0)partition(1)\WINNT
[operating systems]
multi(0)disk(0)rdisk(0)partition(1)\WINNT="Windows NT Workstation ...
multi(0)disk(0)rdisk(0)partition(1)\WINNT="Windows NT Workstation ...
C:\BOOTSECT.LNX="Linux"

Only the last line has been added in this example. Restore the attributes after you have saved boot.ini with:


C:\attrib +s +r c:\boot.ini

After a shutdown of your Windows NT and a restart your should see the following:


OS Loader V4.00

Please select the operating system to start:

Windows NT Workstation Version 4.0
Windows NT Workstation Version 4.0 [VGA mode]
Linux

Select Linux and see

LILO loading zImage ....


Thoughts?

jglen490 11-21-2002 10:45 AM

Quote:

Is there something I missed most likely during the setup procedure where I specified where to place the boot loader? Either the MBR or the / partition?
Yep, but it's a common ailment ;) .

First some background. When a PC boots, the BIOS and the bootstrap loader program look for boot code on the MBR of the first bootable device (i.e., primary hard drive). Let's say that it finds some boot code on your primary gard drive's MBR. That code then either chain loads some code in a specified boot sector or is passed off to a boot manager.

In your case, since you put Grub on your Linux partition, the existing MBR code was not altered -- so, Windoze comes up and nothing else.

There are a couple of ways that you can fix this: one is simple, the other is a little more complex, but neither is terribly difficult.

1) Use your RedHat install CD to go into "Rescue" mode (hit F1, select or enter "Rescue". From there you will get a menu which includes the means to fix.reinstall your boot manager and put it on the MBR.

2) Follow the instructions on the Linux Doc Project. Copy your Linux boot sector to a file (i.e., bootsct.bin), copy that file to your "C:\" drive, and add a C:\bootsct.bin="Linux" menu entry to your boot.ini file.

tarballed 11-21-2002 11:29 AM

I appreciate your guys input.

Just a few quick questions:

When you are installing Linux, would it be wise to install the bootloader on the MBR? Reason I ask is that I read a few articles and they specifically say not to install on the MBR; instead to install it on the / partition.

Basically, in a nutshell:

Is it possible, do install Win2K first, then install RH 7.3, use LILO for the boot loader and some how configure the boot loader during initial setup to work on the next reboot?
Or does it require some tweaking?

Just trying to find a easy, simple way to get a dual boot up. Both for learning purposes and in a working enviroment.

Thanks guys.

Tarballed

tarballed 11-21-2002 12:24 PM

Ok guys. As I sit here and think about this, I keep thinking that this install, the dual boot should be much easier that what it has been.

A couple things occured to me:

During the initial Linux install after the Win2K install, can't I install LILO on the MBR? Then, when the system reboots, it should detect LILO and bring up the boot menu, correct?

Or am I wrong? I keep thinking this should be much easier than it is.

ANy thoughts or help is very appreciated.

Tarballed

Thymox 11-21-2002 12:29 PM

You can indeed. It works a treat for most people, but for some reason, when NT or 2k or XP are involved, it is suggested that you use the NT bootloader - I haven't a clue why!

If you install Lilo to the MBR then you should only need to have an entry for Win2k pointing to the correct partition...

(I've never had an NT based Win, so I can't be sure)

tarballed 11-21-2002 12:34 PM

You can indeed. It works a treat for most people, but for some reason, when NT or 2k or XP are involved, it is suggested that you use the NT bootloader - I haven't a clue why

I tell you, that is what was confusing me. Why not just make it so I can use LILO for the bootloader. I will give it a shot tonight when I get home. I will tryloading LILO on the MBR.

ANy other suggestions when installing the bootloader during install?

Thanks

Tarballed

Thymox 11-21-2002 12:39 PM

I don't know if RH 7.3 has a rescue mode on the CD, but if so, you won't need to re-install, just boot from the CD into rescue mode (could involve pressing F1 initially and then typing 'rescue' at the prompt) and put the bootloader in the mbr.

Another if: if the RH rescue mode doesn't have an option to do this for you, then you'll need to mount the appropriate filesystem(s), chroot to them, edit your lilo.conf file and change the boot= line (should be the first line) to /dev/hda rather than /dev/hdaX, and then run /sbin/lilo to put the changes into effect.

Good luck.

deadbug 11-21-2002 12:43 PM

Oh, any thoughts? Okay, use jglen490's first idea--put the boot loader in the MBR and get on with life. I'm not sure where you got the advice to not put is there, but I think at worst, you will find the community split on the best way to do it. The explanation I was given was to put it in the MBR, unless you want to have a system that boots from a floppy or are using another boot loader (such as System Commander). In other words, the MBR is the default location unless you have a compelling reason to not do so.

I have one computer that has Windows 2000 and Red Hat 8.0. The boot loader is Grub and it is in the MBR. I did not have to alter any Windows .ini files. Grub handles everything just fine.

So, my thoughts are that it is a lot simpler than you're making it!

Cheers

Paul7526 12-05-2002 06:09 PM

deadbug, Help please.....
 
deadbug,

I have the same setup, Win2K and RH 8. Two different HD, Win2K on one and RH 8 on the other. Problem, after install of RH no boot at all. Had to use Win2K CD to fix MBR. Worked with LILO after reading post here and now get "LI" that's it. Prior to working with LILO & after fixing the MBR I was able to boot to Win2K.

So, now that I'm close (?) getting "LI" what now? Am I failing to save the LILO to the MBR and if so how do I do that?

Here is my LILO as seen from the KDE Control Center / System / Boot Manager (LILO);


boot="/dev/hdb"
prompt
timeout="50"
message=/boot/message
root=/dev/hda2
linear
vga="791"

image="/boot/vmlinuz-2.4.18-14"
label="2.4.18-14"
root="/dev/hda2"
read-only
initrd="/boot/initrd-2.4.18-14.img"

image="/usr/src/linux/arch/i386/boot/bzImage"
label="Linux_Compiled"
root="/dev/hda2"
read-only
optional

other=/dev/hdb1
label="Win2K"

image="/dev/hdb1"
root="/dev/hda2"


Any help?


Paul

JoC 12-06-2002 12:23 AM

Tarballed-

i just finished getting XP and Redhat 7.2 to dual boot on my box. my problem ended up being that i did not create a boot label for my windows partition ( or drive in my case ). as soon as i put a boot label in everything was fine!

the boot label is asked whe you are asked what loader to use. or just once you get into your loader instal.

here is a link that may help you

http://www.redhat.com/docs/manuals/l...-bootload.html

DavidPhillips 12-06-2002 01:04 AM

paul it really looks like you failed to run lilo

or maybe boot= is wrong

DavidPhillips 12-06-2002 02:02 AM

you have boot=/dev/hdb

this will install lilo to hdb

it needs to be installed on hda


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