Before i am told just do it in bios
the issue is this, the computer is connected to a PXE server and when all the machines were legacy bios, i could just disable the disk and reimage the machine. Disable reboot. Machine will boot and install a fresh OS. So i don't want to be walking to these 1000s of machines pressing bios buttons and such. Needs to be automated. Hard disk is first, when disabled it boots to USB.
Question
When using a legacy bios,
You can run a command as an admin user to disable to disk from booting. hardware boot options as such:
- Disk
- Usb
- Network
Then when you can disable the disk with diskpart and mark it as inactive.
On UEFI bios this doesn't work
_________my understanding of the issue__________
This is because on a uefi machine windows is using a Bootmgr
This is because it is using a Windows Boot Manager
bcdedit /enum
Windows Boot Manager
--------------------
identifier {bootmgr}
device partition=\Device\HarddiskVolume1
description Windows Boot Manager
locale en-US
inherit {globalsettings}
default {current}
resumeobject {f665eab4-5d61-11e7-b384-e1075a4080e3}
displayorder {current}
toolsdisplayorder {memdiag}
timeout 30
I have had numerous attempts at disabling this. This is what I have tried.
bcdedit /deletevalue
This was to delete device partition=c I have tried it on osdevice
I have tried
bcdedit /delete {...}
this was to delete my current boot entry.
Any of these doesn't lead to the required results and just leads to either the OS not booting, or attempting to recover itself.
How do I disable the boot store, and have the computer boot from a USB