Following my previous post, this is an quick example on how to use my Powershell script to convert from BIOS to UEFI in a bare metal scenario. (Again, only Lenovo laptops is working with this script)
Most of the magic lies within the Task Sequence itself, so I will break it down in pieces:
- Create a group in your Task Sequence called “Prepare Computer (BIOS)” with the condition _SMSTSBootUEFI not equals true (This will make sure the content of the group only runs if UEFI is not enabled already)
- Next step, format the disk with following settings (Step: Format and Partition Disk (BIOS))
- Disk type: Standard (MBR)
- Partition type: Primary
- 100% remaining disk
- File system: NTFS
- Next step, create a new group called Config Lenovo BIOS with following condition: SELECT * FROM Win32_BIOS WHERE Manufacturer = “Lenovo” (This will make sure the step only runs on a Lenovo computer)
- Next step, run my Powershell script directly from a package like shown below. The parameter -EnableSecureBoot will also enforce UEFI to be enabled.
- Next step, format the disk with following settings (Step: Format and Partition Disk (BIOS to UEFI))
- Disk type: GPT
- Partition type: Primary
- Size: 600Mb
- File System: FAT32
- Variable: TSUEFIDrive
- Add another partition:
- Partition type: Primary
- Size: 100% of remaining space
- File system: NTFS
- Variable: None
- Next step, one final reboot to the boot image currently assigned to this task sequence. When the task sequence returns from the reboot, the Lenovo BIOS will be set to SecureBoot AND UEFI and Windows will continue installing.
Ultimately, you can have 2 steps to take care of when the computer is coming with either BIOS setting or UEFI, and act accordingly. Se below snippet for inspiration.
Enjoy! 🙂
Hello,
I’m really so proud of you, could you please tell me more info about the screen shot that shows Join domain to specific OU
Where is the script man ?
Looks like TechNet Gallery is down, so I will have to upload to github asap.
You upload it already?
Im sorry, not yet. Tomorrow – I promise. 100 things going with work, family etc. You know the drill.
Hey man .
Any news with the upload?
You upload the script ?