LinuxQuestions.org
Go Job Hunting at the LQ Job Marketplace
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 11-19-2009, 01:49 AM   #1
von Stalhein
LQ Newbie
 
Registered: Jul 2008
Location: Thurgoona, Australia
Distribution: Ubuntu 11.10
Posts: 25

Rep: Reputation: 0
Can't get Karmic & XP to dual boot


Hello all,
This has had me vexed for 3 days :-(

I went from 9.04 to 9.10, and despite a few issues that I've now sorted, it's all good.

However, the rest of the family is yet to be convinced of the benefits of 'nix OS's, and therefore this system has always been a dual boot with XP.

Since GRUB 2 I can't get that to happen.

The machine has 3 HHDs, 1 with XP, 1 with Windows data & games, and one with Karmic.

fdisk -l output
Code:
Disk /dev/sda: 120.0 GB, 120034123776 bytes
255 heads, 63 sectors/track, 14593 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0xa3f79c20

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *           2       14593   117210240    f  W95 Ext'd (LBA)
/dev/sda5               2       14593   117210208+   7  HPFS/NTFS

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

   Device Boot      Start         End      Blocks   Id  System
/dev/sdb1   *           1       14593   117218241    7  HPFS/NTFS

Disk /dev/sdc: 160.0 GB, 160041885696 bytes
255 heads, 63 sectors/track, 19457 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0xf66fc667



   Device Boot      Start         End      Blocks   Id  System
/dev/sdc1   *           1        1309    10514511   83  Linux
/dev/sdc2            1310       18705   139733370   83  Linux
/dev/sdc3           18706       19457     6040440    5  Extended
/dev/sdc5           18706       19457     6040408+  82  Linux swap / Solaris
blkd output
Code:
/dev/sda5: UUID="A83CB1173CB0E18C" LABEL="Disk 2" TYPE="ntfs" 
/dev/sdb1: UUID="01C3D871F965AC80" LABEL="DSK1_VOL1" TYPE="ntfs" 
/dev/sdc1: UUID="ece48d4f-95ce-4c32-8ae6-20c3f3563597" TYPE="ext4" 
/dev/sdc2: UUID="b073ff20-47f8-440f-98fc-5bbc5fcbbd8d" TYPE="ext4" 
/dev/sdc5: UUID="27179ee5-e990-4dcb-9fc8-a5857a0f1b37" TYPE="swap"
Device map is: -
Code:
(hd0)	/dev/sdb
(hd1)	/dev/sda
(hd2)	/dev/sdc
and grub.cfg file output : -
Code:
#
# DO NOT EDIT THIS FILE
#
# It is automatically generated by /usr/sbin/grub-mkconfig using templates
# from /etc/grub.d and settings from /etc/default/grub
#

### BEGIN /etc/grub.d/00_header ###
if [ -s /boot/grub/grubenv ]; then
  have_grubenv=true
  load_env
fi
set default="0"
if [ ${prev_saved_entry} ]; then
  saved_entry=${prev_saved_entry}
  save_env saved_entry
  prev_saved_entry=
  save_env prev_saved_entry
fi
insmod ext2
set root=(hd2,1)
search --no-floppy --fs-uuid --set ece48d4f-95ce-4c32-8ae6-20c3f3563597
if loadfont /usr/share/grub/unicode.pf2 ; then
  set gfxmode=640x480
  insmod gfxterm
  insmod vbe
  if terminal_output gfxterm ; then true ; else
    # For backward compatibility with versions of terminal.mod that don't
    # understand terminal_output
    terminal gfxterm
  fi
fi
if [ ${recordfail} = 1 ]; then
  set timeout=-1
else
  set timeout=10
fi
### END /etc/grub.d/00_header ###

### BEGIN /etc/grub.d/05_debian_theme ###
set menu_color_normal=white/black
set menu_color_highlight=black/white
### END /etc/grub.d/05_debian_theme ###

### BEGIN /etc/grub.d/10_linux ###
menuentry "Ubuntu, Linux 2.6.31-14-generic" {
        recordfail=1
        if [ -n ${have_grubenv} ]; then save_env recordfail; fi
	set quiet=1
	insmod ext2
	set root=(hd2,1)
	search --no-floppy --fs-uuid --set ece48d4f-95ce-4c32-8ae6-20c3f3563597
	linux	/boot/vmlinuz-2.6.31-14-generic root=UUID=ece48d4f-95ce-4c32-8ae6-20c3f3563597 ro   quiet splash
	initrd	/boot/initrd.img-2.6.31-14-generic
}
menuentry "Ubuntu, Linux 2.6.31-14-generic (recovery mode)" {
        recordfail=1
        if [ -n ${have_grubenv} ]; then save_env recordfail; fi
	insmod ext2
	set root=(hd2,1)
	search --no-floppy --fs-uuid --set ece48d4f-95ce-4c32-8ae6-20c3f3563597
	linux	/boot/vmlinuz-2.6.31-14-generic root=UUID=ece48d4f-95ce-4c32-8ae6-20c3f3563597 ro single 
	initrd	/boot/initrd.img-2.6.31-14-generic
}
### END /etc/grub.d/10_linux ###

### BEGIN /etc/grub.d/20_memtest86+ ###
menuentry "Memory test (memtest86+)" {
	linux16	/boot/memtest86+.bin
}
menuentry "Memory test (memtest86+, serial console 115200)" {
	linux16	/boot/memtest86+.bin console=ttyS0,115200n8
}
### END /etc/grub.d/20_memtest86+ ###

### BEGIN /etc/grub.d/30_os-prober ###
menuentry "Microsoft Windows XP Home Edition (on /dev/sdb1)" {
	insmod ntfs
	set root=(hd0,1)
	search --no-floppy --fs-uuid --set 01c3d871f965ac80
	drivemap -s (hd0) ${root}
	chainloader +1
}
### END /etc/grub.d/30_os-prober ###

### BEGIN /etc/grub.d/40_custom ###
# This file provides an easy way to add custom menu entries.  Simply type the
# menu entries you want to add after this comment.  Be careful not to change
# the 'exec tail' line above.
### END /etc/grub.d/40_custom ###
Solutions gratefully accepted!!!
 
Old 11-19-2009, 05:09 AM   #2
ronlau9
Senior Member
 
Registered: Dec 2007
Location: In front of my LINUX OR MAC BOX
Distribution: Mandriva 2009 X86_64 suse 11.3 X86_64 Centos X86_64 Debian X86_64 Linux MInt 86_64 OS X
Posts: 2,369

Rep: Reputation: Disabled
On which drive is windows xp ?
Because on one hand it says windows on sdb1 that is (hd1,0)
But root is set for windows as (hd0,0) that is sda1
So on which drive and partition is windows xp
 
Old 11-19-2009, 06:16 AM   #3
tommcd
Senior Member
 
Registered: Jun 2006
Location: Philadelphia PA USA
Distribution: Lubuntu, Slackware
Posts: 2,230

Rep: Reputation: 287Reputation: 287Reputation: 287
Ubuntu Karmic 9.10 uses grub2. See this tutorial on grub2:
https://wiki.ubuntu.com/Grub2
First open a terminal and try running:
Code:
sudo update-grub
This should update your grb.cfg file and hopefully add Windows to the list so you can boot it.
Also, did you do a dist-upgrade from 9.04 to 9.10, or did you do a clean install of 9.10? If you did an upgrade then I would recommend fully upgrading to grub2 as per this part of the tutorial:
https://wiki.ubuntu.com/Grub2#Instal...untu%209.10%29
Then try running: "sudo update-grub" again. Then reboot.
If updating grub does not fix the problem, you can create a custom entry for XP in /etc/grub.d/ as per this part of the same tutorial:
https://wiki.ubuntu.com/Grub2#User-defined%20Entries
The entry for XP would look something like this:
Code:
echo "Adding WindowsXP" >&2
cat << EOF
menuentry "Microsoft Windows XP Home Edition (on /dev/sda1)" {
        set root=(hd0,1)
        chainloader +1
}
EOF
Be sure to change (hd0,1) to your XP partition. Remember, grub2 counts hard drives from 0 like grub-legacy, but counts partitions from 1, not 0.
Be sure to run: "sudo update-grub" after creating a custom entry.

Last edited by tommcd; 11-19-2009 at 06:32 AM.
 
Old 11-19-2009, 08:24 PM   #4
von Stalhein
LQ Newbie
 
Registered: Jul 2008
Location: Thurgoona, Australia
Distribution: Ubuntu 11.10
Posts: 25

Original Poster
Rep: Reputation: 0
Thanks guys - FYI those outputs were the result after running sudo update-grub.

The install is a clean one from the Alternate CD, as I couldn't get a GUI from either it or the desktop ISO (that's another story!!!)

I was confused as well by the XP drive being labelled by the GRUB menu as /dev/sdb1, I thought it was /dev/sda as well. Is that to do with the different way it now counts?

I'm sure Karmic is on /dev/sdc

blkid reports XP as on /dev/sdb1, whereas fdisk says it's /dev/sda1 - am I reading that right?

I'm not on that machine atm, but I will have a go at it later (about 7 or 8 hours local time) when I get home.


oh, btw, I've checked that the XP install is still OK by changing the boot order in BIOS and booting to it.
I will report back.

Last edited by von Stalhein; 11-19-2009 at 08:26 PM. Reason: more info
 
Old 11-20-2009, 04:00 AM   #5
von Stalhein
LQ Newbie
 
Registered: Jul 2008
Location: Thurgoona, Australia
Distribution: Ubuntu 11.10
Posts: 25

Original Poster
Rep: Reputation: 0
I tried the custom entry method without luck :-( Various combinations of drives/partitions. After changing options, I chmodded and updated GRUB, and then rebooted. Countlessly.

I also installed the GRUB 2 to the /dev/sda and lost the ability to boot XP when it was moved in the bIOS boot order. Even though I tried 3 times to restore the mbr with the XP disk it failed.

However, I had a Supergrub CD, and it did the job, thank the flying spaghetti monster!!!

It's weird,even though there are 3 HDDs in this box, the HDD access LED is only hooked up to the XP c: disk. When GRUB is directed to pick that menu choice (the default one from the install process - /dev/sdb1), the drive light goes on.

If I ctrl-alt-del before the blinking cursor disappears, the system will reboot.

Last edited by von Stalhein; 11-20-2009 at 04:01 AM.
 
Old 11-20-2009, 05:40 AM   #6
firewiz87
Member
 
Registered: Jan 2006
Distribution: OpenSUSE 11.2, OpenSUSE 11.3,Arch
Posts: 240

Rep: Reputation: 37
clarify the following please:

In which drive is grub installed to??
Where is your windows installation??
Have you explicitly set the device mappings??
 
Old 11-20-2009, 05:54 AM   #7
tommcd
Senior Member
 
Registered: Jun 2006
Location: Philadelphia PA USA
Distribution: Lubuntu, Slackware
Posts: 2,230

Rep: Reputation: 287Reputation: 287Reputation: 287
Quote:
Originally Posted by von Stalhein View Post

I was confused as well by the XP drive being labelled by the GRUB menu as /dev/sdb1, I thought it was /dev/sda as well. Is that to do with the different way it now counts?

I'm sure Karmic is on /dev/sdc

blkid reports XP as on /dev/sdb1, whereas fdisk says it's /dev/sda1 - am I reading that right?
You have 2 NTFS partitions according to fdisk and blkid: /dev/sda5 and /dev/sdb1. Do you know which one is XP?
Your grub.cfg says:
Code:
### BEGIN /etc/grub.d/30_os-prober ###
menuentry "Microsoft Windows XP Home Edition (on /dev/sdb1)" {
	insmod ntfs
	set root=(hd0,1)
	search --no-floppy --fs-uuid --set 01c3d871f965ac80
	drivemap -s (hd0) ${root}
	chainloader +1
}
But the set root= line in grub2 is (or at least was before you used Super Grub disc) pointing to /dev/sda1 (hd0,1). Remember, grub2 starts counting hard drives from 0, but partitions start from 1.
If XP is on /dev/sdb1, that would be (hd1,1) in grub2. So a custom entry in /etc/grub.d for XP would be something like:
Code:
echo "Adding WindowsXP" >&2
cat << EOF
menuentry "Microsoft Windows XP Home Edition (on /dev/sda1)" {
        insmod ntfs
        set root=(hd1,1)
        drivemap -s (hd1) ${root}
        chainloader +1
}
EOF
The lines I have put in bold may be optional. I'm not sure if you need them or not for Windows. I'm still trying to get up to speed with grub2 myself.

Last edited by tommcd; 11-20-2009 at 05:57 AM.
 
Old 11-20-2009, 06:19 PM   #8
von Stalhein
LQ Newbie
 
Registered: Jul 2008
Location: Thurgoona, Australia
Distribution: Ubuntu 11.10
Posts: 25

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by firewiz87 View Post
clarify the following please:

In which drive is grub installed to??
Where is your windows installation??
Have you explicitly set the device mappings??
Thanks again for your interest all:

GRUB is installed to dev/sdc - Karmic drive, in the / partition, according to
Code:
sudo file -s /dev/sdXX
The Karmic drive (dev/sdc) is partitioned to a / (about 10G), /home (about 140G)and /swap (about 6G)

XP is on dev/sdb1, media/DSK1_VOL1 (OS & the usual Win data, games etc)

The other disk is dev/sda5, media/Disk2 (Data, games, music etc.)

I have not changed the device mappings.

I checked grub.cfg after the SuperGrub rescue, and nothing's changed, other than since then I've had a kernel update to 2.6.31-15

sudo ls -l /dev/disk/by-uuid returns
Code:
total 0
lrwxrwxrwx 1 root root 10 2009-11-21 20:42 01C3D871F965AC80 -> ../../sdb1
lrwxrwxrwx 1 root root 10 2009-11-21 20:42 27179ee5-e990-4dcb-9fc8-a5857a0f1b37 -> ../../sdc5
lrwxrwxrwx 1 root root 10 2009-11-21 20:42 A83CB1173CB0E18C -> ../../sda5
lrwxrwxrwx 1 root root 10 2009-11-21 20:42 b073ff20-47f8-440f-98fc-5bbc5fcbbd8d -> ../../sdc2
lrwxrwxrwx 1 root root 10 2009-11-21 20:42 ece48d4f-95ce-4c32-8ae6-20c3f3563597 -> ../../sdc1
Thanks again for any help.

Last edited by von Stalhein; 11-20-2009 at 06:21 PM.
 
Old 11-21-2009, 09:49 AM   #9
firewiz87
Member
 
Registered: Jan 2006
Distribution: OpenSUSE 11.2, OpenSUSE 11.3,Arch
Posts: 240

Rep: Reputation: 37
Do the following:
1. Set the BIOS boot order such that the hard disk "sdc" (the third HDD) gets first priority.
2. Create (add) an entry as follows in grub.cfg:

Code:
menuentry "Microsoft Windows XP Home Edition (on /dev/sdb1)" {
	set root=(hd1,1)
	chainloader +1
}
Try booting to this entry n let me know what happens.

By the way if u didnt explicitly set the mappings how/from where did you list it in post #1??
 
Old 11-21-2009, 04:34 PM   #10
von Stalhein
LQ Newbie
 
Registered: Jul 2008
Location: Thurgoona, Australia
Distribution: Ubuntu 11.10
Posts: 25

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by firewiz87 View Post
Do the following:
1. Set the BIOS boot order such that the hard disk "sdc" (the third HDD) gets first priority.
2. Create (add) an entry as follows in grub.cfg:

Code:
menuentry "Microsoft Windows XP Home Edition (on /dev/sdb1)" {
    set root=(hd1,1)
    chainloader +1
}
Try booting to this entry n let me know what happens.

By the way if u didnt explicitly set the mappings how/from where did you list it in post #1??
1. The boot order has /dev/sdc as the first in order. The BIOS calls /dev/sdc SCSI-0, /dev/sdb Ch0-M, and /dev/sda Ch0-S

2. Created an entry as detailed above in etc/grub.d, called it "50_addxp" and chmodded it. When selected in the GRUB 2 menu it returns "error, no such partition.

I got the device map listings by looking in /boot/grub/device.map
 
Old 11-22-2009, 07:49 AM   #11
firewiz87
Member
 
Registered: Jan 2006
Distribution: OpenSUSE 11.2, OpenSUSE 11.3,Arch
Posts: 240

Rep: Reputation: 37
Is nt the grub.cfg file in /boot/grub??

try setting root=(hd0,1) in the above cose i mentioned and see....

By the way, wat is the output that you get whem u try the windowzz option that was created by default???

Last edited by firewiz87; 11-22-2009 at 07:50 AM.
 
Old 11-23-2009, 01:02 AM   #12
von Stalhein
LQ Newbie
 
Registered: Jul 2008
Location: Thurgoona, Australia
Distribution: Ubuntu 11.10
Posts: 25

Original Poster
Rep: Reputation: 0
No luck with the (hd0,1) change.

I tried to make it simpler for poor old GRUB by removing the disk without an OS on it. It still won't kick XP in to boot.

It might sound weird, but on selecting the XP menuentry the HDD light activates while the blinking cursor appears in the top LHS of the screen, and then it goes jet black and requires a hard reset to get back to the GRUB menu. I know it's that drive as it was the first one I installed when I built the machine, and the only one hooked up to a LED.

It's as if there's not enough of something to get it over the boot hump I've changed the boot order to check that XP boots OK, and it's fine. I wonder if there's some sort of parameter in GRUB that needs to be added or removed to let it start?

As before, in the BIOS the Karmic disk is first in order.

Grub.cfg is now:
Code:
#
# DO NOT EDIT THIS FILE
#
# It is automatically generated by /usr/sbin/grub-mkconfig using templates
# from /etc/grub.d and settings from /etc/default/grub
#

### BEGIN /etc/grub.d/00_header ###
if [ -s /boot/grub/grubenv ]; then
  have_grubenv=true
  load_env
fi
set default="0"
if [ ${prev_saved_entry} ]; then
  saved_entry=${prev_saved_entry}
  save_env saved_entry
  prev_saved_entry=
  save_env prev_saved_entry
fi
insmod ext2
set root=(hd1,1)
search --no-floppy --fs-uuid --set ece48d4f-95ce-4c32-8ae6-20c3f3563597
if loadfont /usr/share/grub/unicode.pf2 ; then
  set gfxmode=640x480
  insmod gfxterm
  insmod vbe
  if terminal_output gfxterm ; then true ; else
    # For backward compatibility with versions of terminal.mod that don't
    # understand terminal_output
    terminal gfxterm
  fi
fi
if [ ${recordfail} = 1 ]; then
  set timeout=-1
else
  set timeout=15
fi
### END /etc/grub.d/00_header ###

### BEGIN /etc/grub.d/05_debian_theme ###
set menu_color_normal=white/black
set menu_color_highlight=black/white
### END /etc/grub.d/05_debian_theme ###

### BEGIN /etc/grub.d/10_linux ###
menuentry "Ubuntu, Linux 2.6.31-15-generic" {
        recordfail=1
        if [ -n ${have_grubenv} ]; then save_env recordfail; fi
    set quiet=1
    insmod ext2
    set root=(hd1,1)
    search --no-floppy --fs-uuid --set ece48d4f-95ce-4c32-8ae6-20c3f3563597
    linux    /boot/vmlinuz-2.6.31-15-generic root=UUID=ece48d4f-95ce-4c32-8ae6-20c3f3563597 ro   quiet splash
    initrd    /boot/initrd.img-2.6.31-15-generic
}
menuentry "Ubuntu, Linux 2.6.31-15-generic (recovery mode)" {
        recordfail=1
        if [ -n ${have_grubenv} ]; then save_env recordfail; fi
    insmod ext2
    set root=(hd1,1)
    search --no-floppy --fs-uuid --set ece48d4f-95ce-4c32-8ae6-20c3f3563597
    linux    /boot/vmlinuz-2.6.31-15-generic root=UUID=ece48d4f-95ce-4c32-8ae6-20c3f3563597 ro single 
    initrd    /boot/initrd.img-2.6.31-15-generic
}
menuentry "Ubuntu, Linux 2.6.31-14-generic" {
        recordfail=1
        if [ -n ${have_grubenv} ]; then save_env recordfail; fi
    set quiet=1
    insmod ext2
    set root=(hd1,1)
    search --no-floppy --fs-uuid --set ece48d4f-95ce-4c32-8ae6-20c3f3563597
    linux    /boot/vmlinuz-2.6.31-14-generic root=UUID=ece48d4f-95ce-4c32-8ae6-20c3f3563597 ro   quiet splash
    initrd    /boot/initrd.img-2.6.31-14-generic
}
menuentry "Ubuntu, Linux 2.6.31-14-generic (recovery mode)" {
        recordfail=1
        if [ -n ${have_grubenv} ]; then save_env recordfail; fi
    insmod ext2
    set root=(hd1,1)
    search --no-floppy --fs-uuid --set ece48d4f-95ce-4c32-8ae6-20c3f3563597
    linux    /boot/vmlinuz-2.6.31-14-generic root=UUID=ece48d4f-95ce-4c32-8ae6-20c3f3563597 ro single 
    initrd    /boot/initrd.img-2.6.31-14-generic
}
### END /etc/grub.d/10_linux ###

### BEGIN /etc/grub.d/20_memtest86+ ###
menuentry "Memory test (memtest86+)" {
    linux16    /boot/memtest86+.bin
}
menuentry "Memory test (memtest86+, serial console 115200)" {
    linux16    /boot/memtest86+.bin console=ttyS0,115200n8
}
### END /etc/grub.d/20_memtest86+ ###

### BEGIN /etc/grub.d/30_os-prober ###
menuentry "Microsoft Windows XP Home Edition (on /dev/sda1)" {
    insmod ntfs
    set root=(hd0,1)
    search --no-floppy --fs-uuid --set 01c3d871f965ac80
    drivemap -s (hd0) ${root}
    chainloader +1
}
### END /etc/grub.d/30_os-prober ###

### BEGIN /etc/grub.d/40_custom ###
# This file provides an easy way to add custom menu entries.  Simply type the
# menu entries you want to add after this comment.  Be careful not to change
# the 'exec tail' line above.
### END /etc/grub.d/40_custom ###
blkid is now
Code:
/dev/sda1: UUID="01C3D871F965AC80" LABEL="DSK1_VOL1" TYPE="ntfs" 
/dev/sdb1: UUID="ece48d4f-95ce-4c32-8ae6-20c3f3563597" TYPE="ext4" 
/dev/sdb2: UUID="b073ff20-47f8-440f-98fc-5bbc5fcbbd8d" TYPE="ext4" 
/dev/sdb5: UUID="27179ee5-e990-4dcb-9fc8-a5857a0f1b37" TYPE="swap"
As you can see, XP is on /dev/sda1, and Karmic / is on /dev/sdb1

BTW, grub.cfg is in boot/grub/, but the config files that make it up are in etc/grub.d/

Last edited by von Stalhein; 11-23-2009 at 01:06 AM.
 
Old 11-23-2009, 02:18 AM   #13
firewiz87
Member
 
Registered: Jan 2006
Distribution: OpenSUSE 11.2, OpenSUSE 11.3,Arch
Posts: 240

Rep: Reputation: 37
ok.. I never needed to work in /etc/grub.d. Modifying /boot/grub.cfg always gave me the required output.

Grub will not work if you take off a HDD simply because doing so will change the device mappings.

Could you create a new grub.cfg file in /boot/grub (just rename the existing one) and just put in the following entries:

Code:
menuentry "Ubuntu, Linux 2.6.31-15-generic" {
    set root=(hd1,1)
    search --no-floppy --fs-uuid --set ece48d4f-95ce-4c32-8ae6-20c3f3563597
    linux    /boot/vmlinuz-2.6.31-15-generic root=UUID=ece48d4f-95ce-4c32-8ae6-20c3f3563597 ro   quiet splash
    initrd    /boot/initrd.img-2.6.31-15-generic
}

menuentry "Microsoft Windows XP Home Edition (on /dev/sda1)" {
    set root=(hd0,1)
    chainloader +1
}
And see what happens... I am assuming that you have grub installed to mbr of /dev/sdb which should have higher boot priiority
 
Old 11-24-2009, 02:40 AM   #14
von Stalhein
LQ Newbie
 
Registered: Jul 2008
Location: Thurgoona, Australia
Distribution: Ubuntu 11.10
Posts: 25

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by firewiz87 View Post
ok.. I never needed to work in /etc/grub.d. Modifying /boot/grub.cfg always gave me the required output.

Grub will not work if you take off a HDD simply because doing so will change the device mappings.

Could you create a new grub.cfg file in /boot/grub (just rename the existing one) and just put in the following entries:

Code:
menuentry "Ubuntu, Linux 2.6.31-15-generic" {
    set root=(hd1,1)
    search --no-floppy --fs-uuid --set ece48d4f-95ce-4c32-8ae6-20c3f3563597
    linux    /boot/vmlinuz-2.6.31-15-generic root=UUID=ece48d4f-95ce-4c32-8ae6-20c3f3563597 ro   quiet splash
    initrd    /boot/initrd.img-2.6.31-15-generic
}

menuentry "Microsoft Windows XP Home Edition (on /dev/sda1)" {
    set root=(hd0,1)
    chainloader +1
}
And see what happens... I am assuming that you have grub installed to mbr of /dev/sdb which should have higher boot priiority
Yes, /dev/sdb or as the BIOS calls it SCSI-0 is the first boot option.

Did what you suggested - made a grub.cfg file and then from gksudo nautilus pasted it into the /boot/grub/ dir.

The output when that menu item was selected was
Code:
GRUB_
and the bar was blinking - had to do a hard reset to get back t the GRUB menu.
 
Old 11-24-2009, 03:48 PM   #15
firewiz87
Member
 
Registered: Jan 2006
Distribution: OpenSUSE 11.2, OpenSUSE 11.3,Arch
Posts: 240

Rep: Reputation: 37
Ok... that was supposed to work... but it does nt thats strange....

You seem to get the grub menu which means grub installation should be fine and i suppose the linux menu entry worked...
And since booting the windows HDD worked.... chainloader should ve worked....

Can you post output to
Code:
fdisk -l /dev/sda
fdisk -l /dev/sdb
Am assuming you ve not inserted your 3rd HDD back, yet

Last edited by firewiz87; 11-24-2009 at 03:52 PM.
 
  


Reply

Tags
boot, dual, grub, ubuntu


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 display not available after karmic update oligodendrocyte Linux - Newbie 1 07-19-2009 01:33 AM
Dual boot Dual Drive Ubuntu Jaunty & XP - Advice on Best Way? Paul Langdon Linux - Newbie 4 05-28-2009 05:11 AM
how to remove ubuntu8.04 from a dual boot lappy as has 8.04 & 8.10 & windows Cooder Linux - Newbie 1 12-13-2008 04:54 AM
When I boot my comp. (dual boot sys-Suse 10.1 & Win XP) the first boot stalls. philip niedermeyer Linux - Desktop 5 11-13-2006 06:04 PM


All times are GMT -5. The time now is 03:58 AM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration