Why would UEFI boot order change when restoring an image to a drive

PingSpike

Lifer
Feb 25, 2004
21,756
600
126
I have an HP PC at work. In it's boot options I set USB as the first option for the UEFI boot order. Then SATA Optical drive. Then m.2.
I boot off the USB with macrium reflect on it. Works fine.
I restore an image onto the m.2 drive. It is a Windows 10 image, using UEFI boot (converted from legacy bios if that matters)
Then I remove the macrium USB and boot Windows from the new image.
Finally I insert the reflect USB again. Since I didn't change anything in bios, I expect USB to be the first item.
It reboots into Windows instead of reflect. I hop in bios and find that the UEFI boot order is changed, m.2 Windows Boot Manager is now the first item.

I do not understand how Windows or macrium can change the boot order. In my mind neither should have any ability to change this. All I can think is once the USB is removed the boot order is reset but even the optical drive moved in the list.

I do not have this problem with legacy bios boot order.
 

crashtech

Lifer
Jan 4, 2013
10,680
2,274
146
I've seen this exact thing happen also. It's a "feature." It's not unusual these days for apps to have the ability to change UEFI settings. This is how overclocking software works, for example.
 

PingSpike

Lifer
Feb 25, 2004
21,756
600
126
Yeah, I've been doing some research and it seems this is possible. There were a lot of posts saying every time they ran windows update it broke their boot order, although usually had a complicated duel boot setup. I think I'm just seeing the same thing. I'm not sure why the new drive image resets it though, I remember after I noticed this happening I tried specifically setting the order prior to creating the image.

HP has a bios setting command line utility. I may script that to fix the issue automatically.

Honestly, it's pretty infuriating. I specifically set things up the way I want and then Windows swoops in and "fixes" it to be wrong.
 

crashtech

Lifer
Jan 4, 2013
10,680
2,274
146
I want to say that perhaps too many people are leaving the drive in when they needed to pull the stick out upon restart. Linux Mint setup simply and helpfully suggests you do so before restarting, but Windows and Linux users are not the same as a group.