I am attempting to dual-boot Windows Vista and Arch linux that was newly installed.

The problem:
After installing Arch-linux and GRUB2 (unsuccessfully), I was presented with the Windows Boot Manager. However, Arch wasn't listed in the bootup menu. I tried a Windows utility called EasyBCD to edit the windows boot config file to show Arch OS. It did show the Arch. However when I chose to boot Arch, I was greeted with the notorious GRUB2 CLI.
I was unable to perform a manual boot (via linux vm* /dev/sdb3; initrd init*; boot). I then tried to overwrite the MBR with just GRUB2, but I lost the Windows bootloader entry (as expected) and I was still presented with GRUB2 CLI.
I tried to reinstall GRUB2 again, but this time editing /etc/grub.d/40_custom to show Windows Vista. At bootup, I was presented with the familiar GRUB2 screen, however only the Windows OS was listed. On selecting the Windows OS, I was presented with the windows boot manager that lists both Windows Vista and Arch linux. Booting into Windows was successful. Booting into Arch was not. In fact, booting into Arch takes me back to the GRUB2 screen, which would chainload Windows Vista boot loader again upon selection, and an infinite loop occurs.

My Analysis
I believe I am having problems with booting because, my boot partition is at /dev/sdb3 and not /dev/sdb1. Since the grub2 configuration files are at /dev/sdb3, the GRUB2 code at MBR is unable to locate them, hence fubar'ing the boot-up sequence (prolly in stage 2).
Another reason why I think I'm having problems is because for some reason, the kernel image and the ram disk aren't at the default locations, i.e. /boot. Instead they're at root.
According to http://www.dedoimedo.com/computers/grub.html:

Quote:

By default, MBR code looks for the partition marked as active and once such a partition is found, it loads its boot sector into memory and passes control to it.

Does that mean that I should mark my Windows partition as inactive so that the MBR code would locate GRUB2 at sdb3?

I cannot think of any ideas, so I'm hoping someone here would provide me with a solution.

Thanks.

syg00

03-18-2013 03:16 AM

Quote:

Originally Posted by Inphi
(Post 4913553)

I believe I am having problems with booting because, my boot partition is at /dev/sdb3 and not /dev/sdb1. Since the grub2 configuration files are at /dev/sdb3, the GRUB2 code at MBR is unable to locate them, hence fubar'ing the boot-up sequence (prolly in stage 2).

Nope. Grub (of any vintage) is well able to find it's code - I regularly (normally even) boot from a logical partition for example.

Quote:

Another reason why I think I'm having problems is because for some reason, the kernel image and the ram disk aren't at the default locations, i.e. /boot. Instead they're at root.

Yep, that's more of an issue, but will rear it's head later in the boot cycle.

M$oft propaganda repeated endlessly on the web. Not relevant to Linux boot-loaders that ignore the boot flag entirely. Windoze will get more confused - remove the boot flag from the Linux partition to keep it (Windoze) happy.

So we can get a real picture of your current boot structure, go here, do as it says and post the RESULTS.txt

--------------------------------------------------------------------------------
#
# DO NOT EDIT THIS FILE
#
# It is automatically generated by grub-mkconfig using templates
# from /etc/grub.d and settings from /etc/default/grub
#

### 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 ###

--------------------------------------------------------------------------------
#
# DO NOT EDIT THIS FILE
#
# It is automatically generated by grub-mkconfig using templates
# from /etc/grub.d and settings from /etc/default/grub
#

--------------------------------------------------------------------------------
#
# DO NOT EDIT THIS FILE
#
# It is automatically generated by grub-mkconfig using templates
# from /etc/grub.d and settings from /etc/default/grub
#

### 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 ###

No volume groups found
mdadm: No arrays found in config file or automatically

amani

03-18-2013 12:02 PM

You can boot from grub2 cli like so

configfile (hd2,3)/grub.cfg

Inphi

03-18-2013 12:12 PM

yeah. I know that would boot it.
But, I want to know how to boot my OS without the GRUB2 CLI like it's supposed to do/

amani

03-20-2013 10:01 AM

Quote:

Originally Posted by Inphi
(Post 4913948)

yeah. I know that would boot it.
But, I want to know how to boot my OS without the GRUB2 CLI like it's supposed to do/

The install log of grub2 will help

what happens if you update grub?

check driver modules loaded in grub2, boot order

Inphi

03-20-2013 12:20 PM

So after much strain, I was able to edit the grub.cfg files to include Arch OS in the boot menu and load the appropriate kernel and modules for that entry. It worked!
Thing is, I did this without the use of custom scripts. In fact /boot/grub/grub.cfg had only the Windows Vista menuentry with the 10_linux script entry empty(I really don't know why I didn't see that earlier), and /grub/grub.cfg had only the Arch linux menuentry. This is kinda confusing since I thought grub-update or grub-install should have picked up both scripts when grub.cfg was generated.