LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - General (https://www.linuxquestions.org/questions/linux-general-1/)
-   -   grub dual boot, dual drives... (https://www.linuxquestions.org/questions/linux-general-1/grub-dual-boot-dual-drives-311832/)

scoob8000 04-10-2005 07:56 PM

grub dual boot, dual drives...
 
Trying to dual boot with two drives, bios is set to boot to scsi first, hence I'm using grub as my boot loader. Problem is when trying to boot windows, after chanloader +1, the system hangs..

/dev/hda = Windows
/dev/sda = CentOS 4



Code:

fdisk /dev/hda -l
Disk /dev/hda: 20.8 GB, 20847697920 bytes
255 heads, 63 sectors/track, 2534 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

  Device Boot      Start        End      Blocks  Id  System
/dev/hda1  *          1        892    7164958+  7  HPFS/NTFS
/dev/hda2            893        2534    13189365    7  HPFS/NTFS

fdisk /dev/sda -l

Disk /dev/sda: 4512 MB, 4512701440 bytes
255 heads, 63 sectors/track, 548 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

  Device Boot      Start        End      Blocks  Id  System
/dev/sda1  *          1          13      104391  83  Linux
/dev/sda2              14        548    4297387+  8e  Linux LVM

And here is my grub.conf

Code:

default=2
timeout=10
splashimage=(hd0,0)/grub/splash.xpm.gz
title CentOS 4.0 (2.6.9-5.0.3.EL)
        root (hd0,0)
        kernel /vmlinuz-2.6.9-5.0.3.EL ro root=/dev/VolGroup00/LogVol00
        initrd /initrd-2.6.9-5.0.3.EL.img
title Windows XP
        rootnoverify (hd1,0)
        chainloader +1


idontdowindough 04-10-2005 09:09 PM

Hi!
Problem is your "root" device is wrong. It probably should be sda0,0 That is supposed to be your Linux root device (your main linux file system, not your swap or home or?) where your menu.lst and devicemap are, not where your windoughs drive is. Hope this helps. I've made this mistake too in grub, so if that is the problem don't feel bad.

bigrigdriver 04-10-2005 11:06 PM

According to your grub.conf, windows is installed on the second hard drive ((hd1,0) = (hdb,1)).
But, elsewhere in your post, you indicate that windows in on /dev/hda.
If windows is in fact on /dev/hda, then edit grub.conf to correctly reflect that situation ((hd0,0) = (hda,1)).

scoob8000 04-11-2005 12:23 PM

((hd0,0) = (hda,1)).

I think thats my issue.. but if root (hd0,0) is wrong, why is it my linux boots okay.

I think I'm confused with grubs device naming convention..

(hd1,0) is not the same as (hda,1)?

harken 04-11-2005 12:47 PM

Quote:

(hd1,0) is not the same as (hda,1)?
No, it isn't. hd1 already means hdb actually. Take a look here: http://www.gnu.org/software/grub/man...g%20convention for Grub namings conventions.

scoob8000 04-11-2005 06:54 PM

Ah ha! Thanks for the link Harken!

Got it, heres what I had to do:

Code:

title Windows XP
        map (hd0) (hd1)
        map (hd1) (hd0)
        rootnoverify (hd1,0)
        chainloader +1

Works like a charm.

cp /etc/grub.conf grub.backup.and.dont.forget


All times are GMT -5. The time now is 08:20 PM.