Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

I bought two SSD disks and as usual I though that installing Windows on a completely separate disk would be the easiest solution, but I can't find any tutorials for dual booting with grub2 (efi). All tutorials assume one EFI boot partition.

Using just:

menuentry "Windows 7" {
        set root=(hd1,1)
        chainloader +1
}

Gives me invalid EFI path.

What is the correct configuration?

share|improve this question
    
I dual-booted Windows7 from one GUID partitioned SSD, with one (1) EFI boot partition on the "first" disk (the SSD). The issues I had: * The Windows install DVD need to be booted in UEFI mode * The Ubuntu version of GRUB"2" didn't display any text/graphics, so I had just a pink screen until Ubuntu had booted, which led me to revert back to BIOS and oldschool partitioning. –  MattBianco Aug 15 '12 at 8:22
add comment

3 Answers

Do you have Windows installed on a GPT partition? If I understand you correctly, you are trying something like what I did yesterday

I had the same error, it comes up, because with EFI you do not give chainloader a number of sectors to read but the path to the Windows boot file.

chainloader /efi/Microsoft/Boot/bootmgfw.efi

Your root should be set to the EFI system partition created by Windows. You can also set the root by GUID instead of (hdX,Y) using search --fs-uuid --set=root. The additional parameters for specifying the GUID can be found with

grub-probe --target=hints_string /boot/efi/EFI/Microsoft/Boot/bootmgfw.efi

(Assuming your EFI partition is mounted to /boot, change the path accordingly if you mount it somewhere else.)

share|improve this answer
add comment

This comes from superuser:

menuentry "Other Disk" {
    insmod part_msdos
    set root='(hd1)'
    drivemap -s hd0 hd1
    chainloader (hd1)+1
}

This particular example is for slingshotting to another disk to boot the MBR which holds GRUB1. So it needs a bit of rewriting for your particular example. But throwing GRUB2 to boot the other disk seems to be the way to go. Your set root=(hd1,1) hopes to find a bootloader at the first partition of the second disk.

share|improve this answer
add comment

as far as I remember

  1. Windows now has 2 installation modes: MBR and GPT and UEFI can only be used with the second, so you have to make sure the HD is formatted in GPT; this partition structure is likely the "UEFI mode" you mentioned
  2. OS-Prober from the Grub2 package must be able to locate Windows (not Win8 yet) and include it into the boot menu on its own

maybe you didn't install Windows properly so it's natural that Grub can't find it

share|improve this answer
    
Oh wow, that is sooo helpful :-D Yes, of course the disk is partitioned using GPT with the FAT EFI boot partition. Both of the disks are. And no, grub obviously doesn't detect the Windows installation, otherwise I wouldn't be asking the question. –  Let_Me_Be Sep 17 '12 at 13:27
1  
Did you "ls" from the Grub console? If it shows both disks, the problem may lay in the mysterious renaming of disks sometimes done by Grub ((hd0) can become (hd1)). Then the answer is in searching partition by uuid ("search" Grub command). If "ls" doesn't list both disks, the problem resembles my current one (unix.stackexchange.com/q/48347/23465). –  alexey Sep 17 '12 at 13:44
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.