Click to See Complete Forum and Search --> : Having problems with Grub and Windows


thug_poet22
04-03-2003, 02:12 AM
Im having trouble with grub the bootloader. I cant seem to get my windows partition to boot, i can use red hat but my windows partition seems out of reach. I was wondering what would i have to do to get my windows partition to boot. How would or should i configure grub.

serz
04-03-2003, 02:32 AM
Look at your grub.conf file and see how your linux partition is configured there and try to add your Windows partition.

thug_poet22
04-03-2003, 02:50 AM
Please if u dont mind tell me how i would go about doing that. Im really a newbie, If you dont want to explain to me, please give me a link. Thanks a lot.

bosox79
04-03-2003, 03:36 AM
Originally posted by thug_poet22
Please if u dont mind tell me how i would go about doing that. Im really a newbie, If you dont want to explain to me, please give me a link. Thanks a lot.

can you please post your grub.conf file?

to do that open a terminial window & then
type su (press enter) at the password prompt type your root password

then at the root prompt type vi /etc/grub.conf

then copy & past the text from the file into your reply

& to edit grub during process when grub shows up on your screen press e then this will bring you to a screen with all of your grub entries.

you can find a sample grub.conf file here http://www.ibiblio.org/pub/Linux/docs/HOWTO/mini/other-formats/html_single/Multiboot-with-GRUB.html
under section 2.3. After you post your current grub.conf it will be eaiser to tell you what line to add to boot windows :)

bosox79

serz
04-03-2003, 03:41 AM
Well, I don't know much about Grub, but I hope this helps you.

http://www.tldp.org/HOWTO/mini/Multiboot-with-GRUB-1.html

There are some examples in that howto, that will help you.

DMR
04-03-2003, 02:12 PM
thug_poet22,

A couple of things to keep in mind when you post:

1. Don't post multiple threads on a single problem; double-posting/cross-posting is a "no-no" here. I've deleted your other post on this topic.

2. When you do start a thread, give it a title that at least somewhat describes your problem. I've renamed this thread so that it does just that.

Read the "Community Help Posting Guidelines" message posted at the top of the forum for more.

For your grub problem:

- As bosox79 suggested, post the contents of your grub.conf file. bosox79 got the location wrong, though- it isn't in /etc/grub.conf, it's either /boot/grub/grub.conf (in Redhat) or /boot/grub/menu.lst (in some other distros).

- You'll also need to tell us which partition of the drive Windows is installed on (hda1, hda2, etc.).

Give us that and we can tell you how to configure grub.conf to boot Windows.

:)

thug_poet22
04-03-2003, 06:30 PM
here is my grub.config file

# grub.conf generated by anaconda
#
# Note that you do not have to rerun grub after making changes to this file
# NOTICE: You do not have a /boot partition. This means that
# all kernel and initrd paths are relative to /, eg.
# root (hd0,2)
# kernel /boot/vmlinuz-version ro root=/dev/hda3
# initrd /boot/initrd-version.img
#boot=/dev/hda
default=0
timeout=10
splashimage=(hd0,2)/boot/grub/splash.xpm.gz
title Red Hat Linux (2.4.18-14)
root (hd0,2)
kernel /boot/vmlinuz-2.4.18-14 ro root=LABEL=/ hdd=ide-scsi
initrd /boot/initrd-2.4.18-14.img
title DOS
rootnoverify (hd0,4)
chainloader +1
~
~
~
~
"/etc/grub.conf" 19L, 632C

and i will post which hda has my windows partition, the only way i can get to my windows files is by using knoppix.

DMR
04-03-2003, 06:49 PM
Originally posted by thug_poet22
title DOS
rootnoverify (hd0,4)
chainloader +1From your grub.conf, it looks like grub thinks your Windows OS is loaded on what Linux would call hda5, which I doubt is true since hda5, if it really exists, is a logical partition.

Is it possible that you have another Windows partition on the drive (for data/music storage or something like that)? Grub might have seen that and chosen it accidently instead of the partiton that Windows is really loaded on.

Also- what version of Windows do you have, and is the Win partition formatted as FAT32 or NTFS?

bosox79
04-04-2003, 12:13 AM
Originally posted by DMR
thug_poet22,

A couple of things to keep in mind when you post:

1. Don't post multiple threads on a single problem; double-posting/cross-posting is a "no-no" here. I've deleted your other post on this topic.

2. When you do start a thread, give it a title that at least somewhat describes your problem. I've renamed this thread so that it does just that.

Read the "Community Help Posting Guidelines" message posted at the top of the forum for more.

For your grub problem:

- As bosox79 suggested, post the contents of your grub.conf file. bosox79 got the location wrong, though- it isn't in /etc/grub.conf, it's either /boot/grub/grub.conf (in Redhat) or /boot/grub/menu.lst (in some other distros).

- You'll also need to tell us which partition of the drive Windows is installed on (hda1, hda2, etc.).

Give us that and we can tell you how to configure grub.conf to boot Windows.

:)

sorry my bad I was really tired when I wrote that post;)

fanren
04-04-2003, 12:40 AM
Have you tried (hd0,0).
Windows is on first harddisk first partition for most cases.

DMR
04-04-2003, 02:16 AM
Originally posted by bosox79
sorry my bad I was really tired when I wrote that post;) Hey, at least you weren't really drunk like I usually am when I'm posting.

:D

bosox79
04-04-2003, 10:28 PM
Originally posted by DMR
Hey, at least you weren't really drunk like I usually am when I'm posting.

:D

Thanks, But I have been there before too:D

thug_poet22
04-05-2003, 12:38 AM
Thanks for all the help. When i get back to my computer will try. By the way im using windows 98se and it is fat 32. And yes i do have more then one partition in windows. I have a C: and a D: drive that both contain storage.

DMR
04-05-2003, 01:30 AM
Originally posted by thug_poet22
By the way im using windows 98se and it is fat 32.That's good- Linux fully supports reading and writing to FAT32 partitions, so you'll be able to access all of your Win data from within Linux if you need to.

Originally posted by thug_poet22
And yes i do have more then one partition in windows. I have a C: and a D: drive that both contain storage. Cool, I thought so. Because DOS/Windows can only create one primary partition on a drive (Linux can create the maximum of four), your D: drive is a logical partition in an extended partition, which jives with grub's (hd0,4) naming; grub just picked the wrong Windows partition.

Try changing the "rootnoverify (hd0,4) " in grub.conf to "rootnoverify (hd0,0)". The hd0,0 would be the correct location (C:) of your actual Windows installation.

thug_poet22
04-07-2003, 10:41 AM
You were right, hd0,0 goes to my windows partition but i still get stoped. It asked me to type in the name of the command interperter. Im really not sure what this is. This is the example that they gave me. C>\WINDOWS\COMMAND.COM

Someone please tell me what a command interperter is, thanks.

DMR
04-07-2003, 05:13 PM
Well, that's a DOS/Windows error message, so at least at that point grub has done its job and started the Win bootloader.

The command interpreter is the layer which accepts the user's commands and translates ("interprets") them into the lower-level instruction codes used by the OS's kernel. The command interpreter can be command-line based like DOS's command.com or a UNIX shell, or it can be a GUI.

In Win 98, command.com lives in two places: C:\command.com and C:\windows\command.com. I don't know why the bootloader is having trouble finding the interpreter, but if you type in one of the above paths when prompted that should do it.

thug_poet22
04-07-2003, 05:58 PM
it seems that more is needed because when i changed my grub config from hd0,4 to hd0,0 and when prompted to enter a command interpreter i put in C:\WINDOWS\COMMAND.COM and that did not work and then i restarted the computer and put in C:COMMAND.COM. Both times i was just promted to type in the command interpreter, nothing booted, just a new line apeared over and over. I hope this can be fixed.

DMR
04-07-2003, 06:58 PM
Hmm, that's weird. Two things:

1. Can you get into Windows by using a rescue/boot floppy? If so, look in C:\ and C:\windows to make sure that COMMAND.COM really exists. It probably does, but it's worth a check.

2. Run fdisk on the drive and post the partition information it reports. That way we'll know exactly what the partition layout of the drive is:

-In Linux, open a terminal window and type "fdisk /dev/hda" (omit the quotes).

-At the "Command (m for help):" prompt, type "p" and hit Enter.

- Post the resulting information here.

thug_poet22
04-07-2003, 07:48 PM
i tried doing what you said but this is what i got


[thugpoet@localhost thugpoet]$ fdisk/dev/hda
bash: fdisk/dev/hda: No such file or directory

And it seems that the only way i can get to my windows partition is by using Knoppix, I dont think i have a rescue boot floppy

thug_poet22
04-07-2003, 08:07 PM
man i hope i will be able to figure this thing out.

DMR
04-07-2003, 10:47 PM
Originally posted by thug_poet22
i tried doing what you said but this is what i got


[thugpoet@localhost thugpoet]$ fdisk/dev/hda
bash: fdisk/dev/hda: No such file or directory You have no space between "fdisk" and "/dev/hda"; type the command exactly like this:

fdisk /dev/hda

thug_poet22
04-07-2003, 11:02 PM
[thugpoet@localhost thugpoet]$ fdisk /dev/hda
bash: fdisk: command not found

There must be something wrong with my red hat distro. Although i was not able to use the fdisk promt, i still was able to obtain the same information.


Here are the partitions

1 Linux Swap
2 Hidden Fat 32 (windows) (hidden)
3 Linux ext2 (active)
4 Extended
5 Fat 32 (backup)

I hope this helps

DMR
04-09-2003, 02:50 PM
Originally posted by thug_poet22
[thugpoet@localhost thugpoet]$ fdisk /dev/hda
bash: fdisk: command not found Odd. Were you logged in as root when you tried to execute fdisk?
You can find out if/where fdisk is installed by running one of the following commands:

locate fdisk
which fdisk
whereis fdisk

Originally posted by thug_poet22
Here are the partitions

1 Linux Swap
2 Hidden Fat 32 (windows) (hidden)
3 Linux ext2 (active)
4 Extended
5 Fat 32 (backup)

I hope this helps Woops, that's not what I expected!

a) Your Windows install is on the second primary partition (I expected it to be on the first; that's where people usually put it), so your grub.conf entry should be:

title DOS
rootnoverify (hd0,1)
chainloader +1

b) Why is the Windows partition hidden? I've never found that to be necessary when dual-booting Win98 and Linux; you might have to alter grub.conf a little further:

title DOS
unhide (hd0,1)
rootnoverify (hd0,1)
chainloader +1

thug_poet22
04-09-2003, 05:19 PM
i'm having a little trouble altering my grub.config. i tried putting it in but it doesn't seem to work, i must be doing something wrong. What i did was when the computer boots up i picked dos to boot up but i pressed (e) and when i got in there the two things that were listed was rootnoverify (hd0,4) and chainloader +1 i pressed (o) and created a new line to add the unhide (hd0,1) that you told me to put in but nothing seems to happen.

DMR
04-09-2003, 05:56 PM
Originally posted by thug_poet22
when i got in there the two things that were listed was rootnoverify (hd0,4) and chainloader +1 i pressed (o) and created a new line to add the unhide (hd0,1) that you told me to put in but nothing seems to happen. Yes, but did you also change the "rootnoverify (hd0,4)" to "rootnoverify (hd0,1)" so that grub looks for your Win install on the second partition?

redcape
04-10-2003, 08:28 AM
Originally posted by thug_poet22
[thugpoet@localhost thugpoet]$ fdisk /dev/hda
bash: fdisk: command not found

There must be something wrong with my red hat distro.

Redhat does not include superuser commands in the default path. You must type:
/sbin/fdisk /dev/hda

To get the info quickly you could also use:
/sbin/fdisk -l