LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 01-13-2004, 01:27 AM   #1
MrOuija
Member
 
Registered: Jan 2004
Location: California
Distribution: SuSE10.1, Ubuntu Edgy, Fedora 7
Posts: 30

Rep: Reputation: 15
NTLDR Dual Boot XP(RAID)/SuSE9.0


Been working on this one for several hours now. I know how to modify the boot.ini file for the Windows XP (NTLDR) boot loader. However, I have been unsuccessful as to this point at trying to fish the boot sector information off of the hard disk that Linux (SuSE 9) is installed on. I've used the "dd if=/blah/ of=/blah.lin etc." command to try and fish out the first 512 boot sector bytes from the Linux drive per many various FAQs and walkthroughs about configuring Linux to boot from NTLDR, with no success. None of these walkthroughs regarding Linux/XP dualboot seem to mention the HDD configuration. The jist of my question is: How do I point NTLDR to another hard disk that contains my SuSE installation. Also, what exactly should a boot record look like in text format? All I seem to be getting is a bunch of binary data, which, when I try to load it from NTLDR says that it can't turn over to the O/S because a suitable boot sector blah blah not found blah blah reboot.

Config:
Drive 0 = IBM 40.0gb Drive SiiG Hardware RAID 0 C: WinXP
Drive 1 = IBM 40.0gb Drive Siig Hardware RAID 0 C: WinXP
File system: NTFS
Single partition


Drive 2 = Western Digital 40.0gb Drive
File system: reiserfs
/dev/hdd1 10mb swap
/dev/hdd2 65mb /boot
/dev/hdd3 39.9gb /

Any help would be greatly appreciated!
Matt

Last edited by MrOuija; 01-13-2004 at 01:28 AM.
 
Old 01-13-2004, 01:59 AM   #2
Demonbane
LQ Guru
 
Registered: Aug 2003
Location: Sydney, Australia
Distribution: Gentoo
Posts: 1,796

Rep: Reputation: 47
Have you tried "dd if=/dev/hdd2 of=blah.bin bs=512 count=1"? Is Grub installed in /boot or mbr of drive 2?
The bootsector file is suppose to be binary
 
Old 01-13-2004, 02:16 AM   #3
MrOuija
Member
 
Registered: Jan 2004
Location: California
Distribution: SuSE10.1, Ubuntu Edgy, Fedora 7
Posts: 30

Original Poster
Rep: Reputation: 15
Methinks Im close

Okay, I've gotten it to the point where the loader will actually *attempt* to turn control of the system over to LILO. However, all I get when LILO attempts to load is LI 01 01 01 01 01 01 etc. How should I go about making a good boot file and knowing for sure it's correctly laid out and such? Should I edit lilo.conf to write the boot sector to /dev/fd0, run lilo, and then use dd to attempt to fish the file off of a diskette? It seems to me, that somewhere along the way, the loader data is becoming corrupted.
 
Old 01-13-2004, 02:32 AM   #4
Demonbane
LQ Guru
 
Registered: Aug 2003
Location: Sydney, Australia
Distribution: Gentoo
Posts: 1,796

Rep: Reputation: 47
LI 01 01 01 usually means that lilo cannot find the disk with your /boot partition, yeah try installing lilo onto a floppy disk(boot=/dev/fd0), and see if the the disk can boot your linux, if it does then extract the bootsector from the disk.
 
Old 01-13-2004, 02:40 AM   #5
MrOuija
Member
 
Registered: Jan 2004
Location: California
Distribution: SuSE10.1, Ubuntu Edgy, Fedora 7
Posts: 30

Original Poster
Rep: Reputation: 15
Same problem

I have the same message come up when I try to boot from the floppy as well? Does this mean the LILO data is somehow becoming corrupted while it's being written to the floppy disk? Is there something Im missing about putting LILO onto a disk? Don't you just point lilo.conf to /dev/fd0. save. and then run lilo at the prompt to execute the changes?
 
Old 01-13-2004, 03:06 AM   #6
Demonbane
LQ Guru
 
Registered: Aug 2003
Location: Sydney, Australia
Distribution: Gentoo
Posts: 1,796

Rep: Reputation: 47
That probably means lilo cannot properly determine the location of your drive, most likely has to do with your raid array which is set to the boot device. Right now I can only offer 2 suggestions, since im not overly familiar with Lilo:

1. Try GRUB, I've had it working in most dire situations, like having multiple operating systems on multiple drives on different controllers, each with grub in their boot partition extracted and loaded by NTLDR. Try making a grub bootdisk first and see if that works.

2. Try using bootpart http://www.winimage.com/bootpart.htm to extract the bootsector, from my experience it works better then using dd in linux, for extracting bootsectors for NTLDR. Though it works the best in dos u can still run it under XP.
 
Old 01-13-2004, 03:56 AM   #7
MrOuija
Member
 
Registered: Jan 2004
Location: California
Distribution: SuSE10.1, Ubuntu Edgy, Fedora 7
Posts: 30

Original Poster
Rep: Reputation: 15
Reinstall

Im thinking Im going to reinstall the SuSE distro sometime tomorrow- as it seems to have installed with some errors with it anyways (modprobe file not found?) and thus many other things fail, namely hotplugging and network devices. Ill try installing grub, as you suggested and see if I can get that to work. Now, when I install grub where should I put it? On the root partition or in the boot sector of the boot partition? Or in the boot sector of the root partition? Also, why would RAID prevent NTLDR from turning control of the system over to LILO. It seems like it would be a one way street- it's not like there's any data on the RAID array that LILO would need anyways right? Shouldn't it just get forwarded to boot of this other HD and that's the end of the story.... this really shouldn't be so complicated =P
 
Old 01-14-2004, 12:56 AM   #8
jschiwal
LQ Guru
 
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,733

Rep: Reputation: 671Reputation: 671Reputation: 671Reputation: 671Reputation: 671Reputation: 671
I have the same setup as you but I'm using Mandrake 9.2 and I'm using lilo. First I went into bios and disabled the RAID drive as a boot drive. Only linux would boot up then. ( Remember to edit lilo.conf and running lilo so the linux loader actually gets written to the drive that linux is on. ) Then I used the dd command to copy the linux loader to floppy. I went back into bios and changed it back, booting from the RAID drive into XP. I copied the file from floppy to the C: drive, and added the file to the boot.ini file. Then I was able to boot up windows, or select linux and the linux lilo menu would come up. Make sure to re-run lilo anytime you make a change, and recopy the file using the dd command.

I didn't have to indicate the linux drive location in boot.ini.

Using the BIOS setting, I was able to boot straight into the system I needed to work on.

On my system, the first non-raid drive is hda and not hdd. An ata-raid drive will show up as a scsi drive.

Last edited by jschiwal; 01-14-2004 at 01:12 AM.
 
Old 01-14-2004, 03:28 AM   #9
MrOuija
Member
 
Registered: Jan 2004
Location: California
Distribution: SuSE10.1, Ubuntu Edgy, Fedora 7
Posts: 30

Original Poster
Rep: Reputation: 15
Let me see if I follow

So on your system, you are indeed running Windows XP on a RAID array. It is the boot drive of the system, NTLDR is doing the booting, and it successfully boots to a non-RAID 3rd HD that Linux is on? Which means, NTLDR can turn the system over to LILO regardless of if there is a RAID array or not correct?

Let me make sure everything else is correct;
I installed Linux on /dev/hdd which is partitioned into /dev/hdd1 (100mb FAT32), /dev/hdd2 (swap), and /dev/hdd3 (reiserfs) and I installed the bootloader to the boot sector of /dev/hdd3.

You then extract the bootsector information from /dev/hdd3 via:
dd if=/dev/hdd3 of=/home/username/linux.lin

Then this is written to a floppy using
mount /media/floppy
cp /home/username/linux.lin /media/floppy

I then reboot and load Windows, copy the linux.lin file from the floppy disk to the root partition of Windows (which is on the RAID array) open up the boot.ini file and add in:
C:\linux.lin="SuSE Linux 9.0 Professional"
Save and reboot, and it *should* load, correct?
 
Old 01-14-2004, 07:40 AM   #10
Demonbane
LQ Guru
 
Registered: Aug 2003
Location: Sydney, Australia
Distribution: Gentoo
Posts: 1,796

Rep: Reputation: 47
yea, it should
 
Old 01-14-2004, 02:38 PM   #11
MrOuija
Member
 
Registered: Jan 2004
Location: California
Distribution: SuSE10.1, Ubuntu Edgy, Fedora 7
Posts: 30

Original Poster
Rep: Reputation: 15
BS or MBR

Can LILO/GRUB be fished out of the BS or does it need to be put on the MBR of the Linux installed HDD? Because if it has to be the MBR... I think I know the problem :-P
 
Old 01-14-2004, 02:57 PM   #12
Demonbane
LQ Guru
 
Registered: Aug 2003
Location: Sydney, Australia
Distribution: Gentoo
Posts: 1,796

Rep: Reputation: 47
No, you can either install it to the partition bootsector or the MBR. if its in the partition bootsector then you need some way of loading it, like using a bootloader such as ntldr. If you install it to the MBR of your linux disk it has to be set to the first bootable device to load, though I havent tried loading a mbr sector with ntldr, it might work, dunno.
Did grub work for you?
 
Old 01-14-2004, 03:08 PM   #13
MrOuija
Member
 
Registered: Jan 2004
Location: California
Distribution: SuSE10.1, Ubuntu Edgy, Fedora 7
Posts: 30

Original Poster
Rep: Reputation: 15
Nope, not yet

Im just not convinced Im getting the data out of the drive correctly- When you reinstall linux, it should write a new bootsector correct? And the bootsector should be at the beginning of the root drive right?
 
Old 01-17-2004, 01:37 PM   #14
jschiwal
LQ Guru
 
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,733

Rep: Reputation: 671Reputation: 671Reputation: 671Reputation: 671Reputation: 671Reputation: 671
The dd command should contain bs=512 count=1. Otherwise, you will be trying to copy the entire partition to floppy, when you just need the first 512 bytes.

My computer has the raid controller chip on the mother board, and so the raid drives and the normal ide drives are on different busses, so my linux is installed in hda.

When I was using a previous kernel, I was able to to use the promise drivers to access the raid drives, but I wasn't able to get linux to boot up when installed on a raid drive.

That's the part I do not understand, how does the initrd file, which contains the raid driver, get read in if it's on a raid drive?
 
Old 01-17-2004, 04:55 PM   #15
Demonbane
LQ Guru
 
Registered: Aug 2003
Location: Sydney, Australia
Distribution: Gentoo
Posts: 1,796

Rep: Reputation: 47
The initrd contains the raid driver for the linux kernel, keep in mind that GRUB does not need the linux kernel to operate.


Quote:
Im just not convinced Im getting the data out of the drive correctly- When you reinstall linux, it should write a new bootsector correct? And the bootsector should be at the beginning of the root drive right?
Yeah depends on where you select to install during installation, however a reinstall of lilo/grub would write a new bootsector. Take my advice, go make a grub bootdisk, get into the grub console and check if grub can see your linux drive.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
dual boot with suse9.2 and er...win xp topherman SUSE / openSUSE 4 07-16-2005 07:24 PM
XP dual boot with ONE OF FC2/SUSE9.1/MDK10 aus9 Linux - General 5 11-05-2004 09:53 PM
suse9.1 and ntldr, again... toddncl Linux - General 8 07-12-2004 08:05 PM
MBR and/or 1st Sector of HDA1 kaputt after attemting dual boot (win/suse9.1) w/ grub Nathanael Linux - General 2 05-29-2004 08:08 AM
Dual Boot Win XP and FC2 w/ NTLDR on Seperate Drives? manstretch Linux - Newbie 3 05-21-2004 05:31 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 06:27 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration