Brain Dump

A place to store my random thoughts and anything else I might find useful.

Dual boot UEFI Windows 7 and Ubuntu 12.04 (adapted from

Posted by mzanfardino on November 20, 2012

In an effort to ensure that I do not forget how to perform the following tasks, I am re-posting them here. This is a near-verbatim copy of the instructions provided at

Find where the windows bootloader resides by mounting the efi partition, and searching for bootmgfw.efi. My configuration has Windows installed on four (4) separate devices: sda1, sda2, sda3, and sda4. The GRUB scripts find windows installed on sda3, but this does not boot as it’s not the correct EFI entry. In my case, I found bootmgfw.efi on sda1.

$ mount /dev/sda1 ~/tmp/sda1
$ grub-probe --target=fs_uuid ~/tmp/sda1/EFI/Microsoft/Boot/bootmgfw.efi

Edit grub custom script to add an entry for UEFI boot for Windows 7:

$ vim /etc/grub.d/40_custom
menuentry "Windows x86_64 UEFI-GPT" {
search --fs-uuid --no-floppy --set=root 2431-71DE
chainloader (${root})/efi/Microsoft/Boot/bootmgfw.efi

NOTE: replace the UUID follow ‘–set=root’ with the value returned from grub-probe. Then run update-grub:

$ sudo update-grub

This worked in my case.

The PC I configured for DualBoot is an HP Pavilion pre-installed with Windows 7 Home Premium. I used gparted to resize sda3 to make space before I installed ubuntu. I installed ubuntu from the alternate install CD (64-bit).


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: