Unable to start Windows - UEFI boot problems with Linux + Win8

-1

I have installed openSUSE (12.2) on a PC that has Win8 installed.

At the beginning there were problems and it didn't start, after some "fixes" Linux started but when going in the grub2-efi Windows 8 entry I get this error:

error: can't find command 'drivermap'
error: invalid EFI file path

First of all, I have checked and in my /boot/EFI/ there's no Windows .efi file, just the openSUSE one.

I have tried the command:

grub2-efi-probe --target=fs_uuid /boot/efi/EFI/Microsoft/Boot/bootmgfw.efi 

and I got:

grub2-efi-probe: error: failed to get canonical path of /boot/efi/EFI/Microsoft/Boot/bootmgfw.efi."

I tried also to modify /boot/grub2-efi/grub.cfg, adding:

menuentry "Windows 8 UEFI" {
  insmod part_gpt
  insmod fat
  insmod search_fs_uuid
  insmod chain
  set root='(hd0,gpt4)'
  search --fs-uuid --no-floppy --set=root 4f84-ee2e
  chainloader (${root})/efi/Microsoft/Boot/bootmgfw.efi
}

as suggested in some websites..

I also tried:

menuentry "Microsoft Windows Vista/7/8 x86_64 UEFI-GPT" {
  insmod part_gpt
  insmod fat
  insmod search_fs_uuid
  insmod chain
  search --fs-uuid --set=root $hints_string $uuid
  chainloader /EFI/Microsoft/Boot/bootmgfw.efi

}

but no luck.

My guess is that the Win EFI file has been deleted and I need that to make Win start? Am I right?

In this case, where can I find it? Is it possible to solve this problem without reinstalling Windows (I've got no DVD)?

Edit:

sudo ls -l $(find /boot/efi -iname "*.efi")
root's password:
-rwxrwxr-x 1 root root 665600 Jan  8  2013 /boot/efi/EFI/opensuse/grub.efi
-rwxrwxr-x 1 root root 120832 Mar 11  2013 /boot/efi/EFI/opensuse/grubx64.efi

testun

Posted 2013-10-09T10:57:48.500

Reputation: 1

Have you tried using Windows to repair the problem? Have you tried a different boot manager by chance? http://askubuntu.com/questions/263044/after-install-ubuntu-12-10-cannot-boot-to-windows-8-pre-installed I am going to guess your partition type is GPT instead of MBR? This thread explains how to use the Windows Recovery Console to solve this problem https://bbs.archlinux.org/viewtopic.php?id=164486

– Ramhound – 2013-10-09T15:22:09.107

What is the output of sudo /usr/bin/diff /boot/efi/EFI/Boot/bootx64.efi /boot/efi/EFI/Microsoft/Boot/bootmgfw.efi? You need to boot to the recovery mode in order to fix this, which might required media, so start working on that problem. – Ramhound – 2013-10-09T15:25:03.707

My previous comment was suppose to say "might need to" – Ramhound – 2013-10-09T15:39:22.163

Hi there, thank you for your suggestions. The output is: /usr/bin/diff: /boot/efi/EFI/Boot/bootx64.efi: No such file or directory /usr/bin/diff: /boot/efi/EFI/Microsoft/Boot/bootmgfw.efi: No such file or directory so it seems the file is not present.. Do you think it's possible to copy the EFI directory from another windows pc in that runs Win8 in my EFI partition and solve the problem in this way? I'd prefer to stay away from the win repair console – testun – 2013-10-10T07:12:17.273

Answers

1

The second of your two GRUB configuration entries is closer to being correct. The example I generally present looks like this:

menuentry "Windows" {
    insmod part_gpt
    insmod chain
    set root='(hd0,gpt1)'
    chainloader /EFI/Microsoft/Boot/bootmgfw.efi
}

Your example is missing the set root line, which you'll need to customize for your system. (It should point to your EFI System Partition (ESP).)

Alternatively, you could boot into Linux and install the RPM version of my rEFInd boot manager. rEFInd is much less finicky than GRUB, and it's easier to manage its configuration manually; but as it's not officially supported by OpenSUSE, you're more likely to have to manually configure it. (Of course, you're at a point where you're being forced to manually configure GRUB, so that may not really be a disadvantage of rEFInd!) One caveat about rEFInd: If you're booting with Secure Boot enabled, you may need to tweak the Secure Boot configuration. In particular, I've recently discovered that the Fedora and OpenSUSE versions of shim use different filenames, so you may need to play with those or disable Secure Boot in your firmware.

Rod Smith

Posted 2013-10-09T10:57:48.500

Reputation: 18 427

hi, thank you for your suggestions. I've tried what you wrote but I got the same error: bootmgfw.efi not found.. As I said I think that file isn't in the EFI partition anymore.. – testun – 2013-10-10T07:04:54.383

Please boot to Linux and type ls -l $(find /boot/efi -iname "*.efi"). This will show all the files on the ESP with names that end in .efi. Edit your original question to include the output. – Rod Smith – 2013-10-10T22:06:11.840

ok, I've done it – testun – 2013-10-11T07:09:07.440

Either something has deleted your Windows boot loader from the disk or it resides on another ESP. Use parted or some other tool to look for another FAT partition. If you've got another FAT partition, and if bootmgfw.efi is present on it, you should be able to edit GRUB's Windows entry to point to it, and that should fix the problem. Alternatively, switch to rEFInd (the second option in my original question); it scans all the filesystems that the EFI can read on every boot, so such problems are less likely when using it. – Rod Smith – 2013-10-11T16:23:18.663

thx. The only fat partition is the one where there's the linux efi file.. – testun – 2013-10-14T07:13:52.110

In that case, you need to restore the Windows EFI boot loader. If you've got a backup of the ESP, you can use that. Otherwise, use a Windows installation or emergency disc and use that. I'm not an expert on its use, though. – Rod Smith – 2013-10-14T19:36:40.473

uhm.. ok.. I've not any backup.. just a windows recovery disk.. let's see what I can do.. thank you mate – testun – 2013-10-15T12:17:17.607