LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   RedHat works great, WinXP won't boot (https://www.linuxquestions.org/questions/linux-newbie-8/redhat-works-great-winxp-wont-boot-111261/)

ShawnC 11-01-2003 07:25 PM

RedHat works great, WinXP won't boot
 
Ok, I'm about as newbie as they come, so be gentle.

I installed Redhat 9.0 on a partition of my hard drive. The other partition on my hard drive has WinXP. My computer only boots to Redhat.

I've tried to Google an answer but the pages I've come across that talk about GRUB and LILO in terms that are way beyond me and leave me fairly confused. Is there someone or somewhere that will walk a total newbie through this. As best I can tell, I need to figure out what partition WinXP is on, get this GRUB thingy to recognize it and agree to give me it as a boot choice?

Thanks.

Demonbane 11-01-2003 07:39 PM

Yeah you're on the right track, first find out where the winxp partition is by using
/sbin/fdisk -l

then add to /boot/grub/grub.conf

title WinXP
rootnoverify (hd0,X)
chainloader +1

X is the partition number, starting from 0, so if the xp partition is the 3rd partition in the first harddisk you would have (hd0,2)

lectraplayer 11-01-2003 08:30 PM

Use FAT32 for WinXP. If you're using NTFS, and you resize it, XP hates that, and you must reformat that partition and reinstall XP. Afterwards, you'll have to put Grub or LILO back (or reinstall RedHat). I found that the hard way. :mad: Fortuantely, it was already dead and I was using Linux to troubleshoot it. :)

I shoulda asked before now: Do you see the XP logo for a short time while it tries to boot, then you get an error message?

ShawnC 11-01-2003 10:01 PM

OK, here's where I'm at. This is my 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,2)
# kernel /vmlinuz-version ro root=/dev/hda5
# initrd /initrd-version.img
#boot=/dev/hda
default=2
timeout=10
splashimage=(hd0,2)/grub/splash.xpm.gz
title Red Hat Linux (2.4.20-8smp)
root (hd0,2)
kernel /vmlinuz-2.4.20-8smp ro root=LABEL=/ hdc=ide-scsi
initrd /initrd-2.4.20-8smp.img
title Red Hat Linux-up (2.4.20-8)
root (hd0,2)
kernel /vmlinuz-2.4.20-8 ro root=LABEL=/ hdc=ide-scsi
initrd /initrd-2.4.20-8.img
title DOS - HP Recovery
rootnoverify (hd0,1)
chainloader +1
title WinXP 2
rootnoverify (hd0,2)
chainloader +1
title WinXP 3
rootnoverify (hd0,3)
chainloader +1
title WinXP 4
rootnoverify (hd0,4)
chainloader +1
title WinXP 5
rootnoverify (hd0,5)
chainloader +1

DOS boots into HP Recovery which wants to wipe all my data and start anew.
WinXP options 2-5 either get me an "Error 13: Invalid or unsupported executable format", or it just goes nowhere.


Here is what I get when I type sbin/fdisk -l

Disk /dev/hda: 120.0 GB, 120034123776 bytes
255 heads, 63 sectors/track, 14593 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/hda1 593 10336 78268680 17 Hidden HPFS/NTFS
/dev/hda2 * 1 592 4755208+ b Win95 FAT32
/dev/hda3 10337 10349 104422+ 83 Linux
/dev/hda4 10350 14593 34089930 f Win95 Ext'd (LBA)
/dev/hda5 10350 14463 33045673+ 83 Linux
/dev/hda6 14464 14593 1044193+ 82 Linux swap

Partition table entries are not in disk order


And no, I don't see the windows XP logo, it goes straight to GRUB (I think). I tried reinstalling RedHat in hopes I could configure the boot launcher to find my WinXP partition but no luck (or I couldn't figure out the right way to do it).

Any direction is appreciated.

Demonbane 11-02-2003 05:45 AM

did you choose to install grub into the bootsector or the MBR?
and is your xp partition the ntfs or fat32 one?

ShawnC 11-02-2003 05:57 AM

I'm pretty sure the partition is NTFS. Whether GRUB is in the MBR or the boot sector, well, in my newbie-ness, I'm not sure.

I don't have anything on the Linux partition that I want to keep, I don't suppose I could just wipe it clean or somehow uninstall Linux and get back to XP, could I?

Demonbane 11-02-2003 08:06 AM

in that case maybe /dev/hda1 is your xp partition
try unhiding the first partition then use (use cfdisk and change the partition type to 7)

rootnoverify (hd0,0)
chainloader +1

lectraplayer 11-02-2003 04:23 PM

Try to go 'cd /mnt/windows'. Usually, that's where your Windows partition will be automounted (at least with Mandrake). Seriously, do find where it's at in the file system, or mount it in somewhere.

First, try to just type in 'mount' at a konsole (Ctrl-Alt-F1->F6). It should print out a thing telling about all your mounted partitions. Look for either FAT32 or NTFS listing. ...then try to CD to the folder that is listed there. (not the /dev/hda or whatever, but the other path that's listed, may be that /mnt/windows I mentioned a second ago).

ShawnC 11-02-2003 09:27 PM

Demonbane: I've unhidden hda1 but when I try a GRUB entry with
rootnoverify (hd0,0)
chainloader +1

It says "Booting command-list" and then it hangs and I have to manually shut the computer down. I'm not sure what partition type it is because I apparently have no cfdisk. It doesn't show up as a command and the helpfile has nothing about it.

lectraplayer: Here's what I see when I type mount:
/dev/hda5 on / type ext3 (rw)
none on /proc type proc (rw)
usbdevfs on /proc/bus/usb type usbdevfs (rw)
/dev/hda3 on /boot type ext3 (rw)
none on /dev/pts type devpts (rw,gid=5,mode=620)
none on /dev/shm type tmpfs (rw)

In /mnt all I have is two cdroms and a floppy.

ShawnC 11-03-2003 07:46 AM

FYI, I tried to reinstall redhat and change GRUB to boot from hda1, and I think it told me it couldn't detect a kernel.

Demonbane 11-03-2003 11:35 AM

Maybe boot with winxp CD then do fixmbr/fixmbr, if grub doesnt work well for you, try nt boot loader.

lectraplayer 11-03-2003 07:16 PM

It appears your Windows partition isn't listed. Try ls /dev/hd* and see what you get. What all do you have? Try mounting each one and seeing what's in it. You may recognize your Windows partition by the files in it. Also, look at your raid and SCSI drives, whatever they are in /dev.

ShawnC 11-04-2003 07:45 AM

Ok, I have a feeling that I've really messed up my windows partition through some attempts to find it. So I have a new strategy. I'd like to reinstall WinXP to a different partition so I can get back to an OS I am familiar with and then get a data recovery program to hunt through my partitions to try and get my files back.

So I need to figure out how to create a new partition that the WinXP will recognize, setup on, and boot from. I think I should have enough space on my linux partition that it can donate the space to the new partition.

I tried to setupWInXP before but it had booting issues.

By the way, thanks for your help so far, I'm sure you're thinking "what a schmuck this guy is." Well, that's what I'm thinking too (and my wife!).

.300WSM 11-04-2003 08:15 AM

i think u do this, from a terminal...

init 3

fdisk hda

p

then work from there ,ie delect your old XP partion and start again.
thats what i would do but i have no idea and am just a newbie too :)

and i think there is a telinit s command that unmounts drives, or puts u in single user mode

.300WSM 11-04-2003 08:21 AM

http://www.linuxquestions.org/questi...ticle&artid=41

that post expalins exactly what i was tryin to


All times are GMT -5. The time now is 10:39 AM.