Sunday 30 September 2018

grub2 - Windows 8 changes boot order


I installed Windows 8 and Ubuntu 12.10 on a 3TB GPT disk in UEFI mode.


Both can boot up OK.


Both operating systems created their ntries in the UEFI boot menu, there's an "ubuntu" and a "Windows 8" entry.


The boot order can be altered in the motherboard's UEFI setup.


I'd like to boot "ubuntu" first, because I set up GRUB 2 to be able to boot both systems.


But whenever I boot Windows 8, it changes the boot order so that it boots up first.


How can I prevent this?


Thanks a lot.


-- UPDATE --


I learned that bcdedit.exe can be used to manipulate the Boot Configuration Data in windows.


This is important because Windows synchronizes the BCD with the boot NVRAM, that stores the boot order.


Every time the {fwbootmgr} entry in the BCD is touched, the NVRAM is overwritten.


I modified this entry to load GRUB 2 first, and it did. However, after booting Windows 8, both the NVRAM and the {fwbootmgr} in the BCD reverted to the original order, that is, to boot Windows 8 first.


I'm really puzzled by this.


-- UPDATE 2 --


I managed to kinda fix the problem by creating a startup script at the group policy editor in Windows. The startup script issues a "bcdedit /set {fwbootmgr} DEFAULT {appropriate UUID}" command. This is BIG hack, and definitely NOT the soulution I want. I'd like Windows to feel OK at the second place after GRUB in the NVRAM.


So how can I do that?



Answer



A Microsoft representative answered my question on their official forum. They said that this is indeed the normal behaviour.


I solved the problem by running a .bat file at every system startup. The file does this:


bcdedit /set {fwbootmgr} DEFAULT {appropriate UUID}

Where "appropriate UUID" is the UUID in GRUB, and can be read from the list that "bcedit /enum firmware".


The bat files can be edited by opening the group policy editor (look it up in metro).


I wrote an article on the dual-boot issue at: http://tlfabian.blogspot.hu/2013/01/converting-dual-boot-mbr-partitioned.html


No comments:

Post a Comment

Where does Skype save my contact's avatars in Linux?

I'm using Skype on Linux. Where can I find images cached by skype of my contact's avatars? Answer I wanted to get those Skype avat...