PDA

View Full Version : problems dual booting Win XP ... Please help!



mrgrieves
20th January 2008, 01:49 PM
Hi All,

I'm writing here because Fedora is the only usable OS installed right now in my system.

I have I Dell Dimension 5000 with 2 SATA drives. One of the drives has Windows XP installed and the other Fedora 8.

Everything was running fine (I was able to dual boot using grub selecting either Fedora or Windows in the splash window) until I had the not so brilliant idea of giving ubuntu a try by installing it on some free space available on the "Linux Drive".

It seems like ubuntu messed up with the MBR on the "Windows drive" because now, whenever I try to boot windows grub hangs. I'm saying that the MBR on the "Windows Drive" was modified is because not even disconnecting the "Linux Drive" and having the "Windows Drive" connected as the primary SATA windows XP is able to boot (the BIOS complains about not detecting the Drive and it tries to write a PBR).

Now and going back connecting the "Linux Drive" as the primary SATA and the "Windows Drive" as secondary I'm able at least to see the contents of windows XP.

What can I do to make windows bootable again having only fedora available?

Please find below some partitioning info so you can have a better idea of what I'm talking about:

[root@localhost ~]# fdisk -l

Disk /dev/sda: 150.0 GB, 150039945216 bytes
255 heads, 63 sectors/track, 18241 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x00042eda

Device Boot Start End Blocks Id System
/dev/sda1 * 1 25 200781 83 Linux
/dev/sda2 26 15323 122881185 8e Linux LVM

Disk /dev/sdb: 160.0 GB, 160000000000 bytes
255 heads, 63 sectors/track, 19452 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x41ab2316

Device Boot Start End Blocks Id System
/dev/sdb1 1 7 56196 de Dell Utility
/dev/sdb2 8 19093 153308295 7 HPFS/NTFS
/dev/sdb3 * 19094 19452 2883667+ db CP/M / CTOS / ...

Disk /dev/dm-0: 12.5 GB, 12582912000 bytes
255 heads, 63 sectors/track, 1529 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x00000000

Disk /dev/dm-0 doesn't contain a valid partition table

Disk /dev/dm-1: 104.8 GB, 104857600000 bytes
255 heads, 63 sectors/track, 12748 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x00000000

Disk /dev/dm-1 doesn't contain a valid partition table

Disk /dev/dm-2: 8355 MB, 8355053568 bytes
255 heads, 63 sectors/track, 1015 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x30307800

Disk /dev/dm-2 doesn't contain a valid partition table

sda="Linux Drive"
sdb="Windows Drive"

As you can see in the "Windows Drive" there are 3 partitions; the first is a diagnostic utility by dell which is not of much help, the second partition is windows and is the partition I'm interested to boot in ... the third partition is a backup copy of the windows OS as shipped from factory.

Here's a copy of my current grub.conf which I believe is irrelevant on this case but as always I might be wrong ... very wrong.

[root@localhost ~]# cat /boot/grub/grub.conf
# grub.conf generated by anaconda
#
# Note that you do not have to rerun grub after making changes to this file
# NOTICE: You have a /boot partition. This means that
# all kernel and initrd paths are relative to /boot/, eg.
# root (hd0,0)
# kernel /vmlinuz-version ro root=/dev/VolGroup00/LogVol00
# initrd /initrd-version.img
#boot=/dev/sda
default=0
timeout=5
splashimage=(hd0,0)/grub/splash.xpm.gz
hiddenmenu
title Fedora (2.6.23.9-85.fc8)
root (hd0,0)
kernel /vmlinuz-2.6.23.9-85.fc8 ro root=/dev/VolGroup00/LogVol00 rhgb quiet
initrd /initrd-2.6.23.9-85.fc8.img
title Fedora (2.6.23.1-42.fc8)
root (hd0,0)
kernel /vmlinuz-2.6.23.1-42.fc8 ro root=/dev/VolGroup00/LogVol00 rhgb quiet
initrd /initrd-2.6.23.1-42.fc8.img
title Windows XP Professional
map (hd0) (hd1)
map (hd1) (hd0)
rootnoverify (hd1,2)
makeactive
chainloader +1

I'll be honest here and the reason I'm really screaming for help is because there's only this PC at Home and my wife is not happy at all with what just happened, specially because she's the person who most uses the PC in this house (I have my work laptop).

Please any help is very much appreciatted.

Thanks in advance,

glennzo
20th January 2008, 02:20 PM
Hi MrGrieves, try this change

title Windows XP Professional
map (hd0) (hd1)
map (hd1) (hd0)
rootnoverify (hd1,1) <----
makeactive
chainloader +1
I can usually get things like this working for myself. The mapping thing throws me off. If that change doesn't work then try

title Windows XP Professional
map (hd0) (hd1)
map (hd1) (hd0)
rootnoverify (hd0,1) <---- Because it's mapped?
makeactive
chainloader +1

bob
20th January 2008, 02:22 PM
I'm not sure what "/dev/sdb3 * 19094 19452 2883667+ db CP/M / CTOS / ..." refers to. That's what you're trying to boot with (hd1,2). Have you tried setting Windows to "rootnoverify (hd1,1)" which refers to the "/dev/sdb2 8 19093 153308295 7 HPFS/NTFS" ?

Edit: Ah, Glennzo's got you covered too! The second option wouldn't work though, since Fedora's reading it's drive as (hd0) so Windows must be on (hd1).

glennzo
20th January 2008, 02:26 PM
Glad you popped in Bob. That mapping thing is something I just can't seem to get a grip on. Option 1 looks right?

bob
20th January 2008, 02:29 PM
Yes, that should do it, although we've had threads go on for 60 posts on what SHOULD have worked. :eek: To me, mapping is telling a computer "hey stupid, you've missed a whole drive - look over there! Oh, by the way, on that drive, there's an operating system. I'd like you to boot it". (That naturally is the technical jargon for mapping) :D

mrgrieves
20th January 2008, 04:06 PM
Hi Guys,

I'd swear I did try the (hd1,1) combination before starting this Thread ... In any case that certainly did the trick and I'm writing this reply from windows ... going back to linux in a minute :D

Thanks a lot for your help.

Daniel

About /dev/sdb3 I believe it's an image of windows XP that Dell uses in case the systems has to be rebuild with factory default settings.

glennzo
20th January 2008, 04:09 PM
I'll be honest here and the reason I'm really screaming for help is because there's only this PC at Home and my wife is not happy at all with what just happened, specially because she's the person who most uses the PC in this house (I have my work laptop).

Please any help is very much appreciatted.

Thanks in advance,
Looks like you still get to sleep in the big bed :p

mrgrieves
20th January 2008, 04:12 PM
believe me, it was going to be an ugly night if I didn't get working today ... certainly, I owe you guys!