PXE Booting with WDS for UEFI and BIOS Devices

UPDATE 2018-04-28: I’ve added the information in this post to a new one completely re-written for Windows Server 2016 here.

 

In a previous post (PXE Booting for Microsoft Deployment Toolkit) I mentioned that I would talk about how to set up PXE to deal with VLANs. To be honest I forgot all about it until someone on twitter reminded me – many thanks for the reminder!

A lot of what I’m going to go through in this post I learned from this YouTube video from BranchCache Bob, here’s the video. There are some differences, which I’ll point out below.

 

The Problem

You have multiple VLANs, and have a mixture of devices with BIOS and UEFI and need to boot them from the network using PXE from a WDS server.

 

Prerequisites

  • A Windows Deployment Server.
  • A Microsoft DHCP server (does not have to be running on the same server as WDS).
  • Have the DHCP server’s IP as a helper address on your network switch for each VLAN you want to boot.

 

Defining DHCP Vendor Classes

The first thing to do is to define the vendor classes for the BIOS PXE Client x84 and x64 and the UEFI PXEClient x86 and x64. To do this:

  1. Go to DHCP, right-click on IPv4.
  2. In the DHCP Vendor Classes window, click Add.
  3. For the Name enter PXEClient (UEFI x86).
  4. For the Description enter whatever you want.
  5. Under the ASCII text enter PXEClient:Arch:00006 (you will not be able to paste this text, and it’s also case-sensitive.
  6. Click OK to add it to the list.
  7. Now repeat steps 2 – 6 for PXEClient (UEFI x64) with PXEClient:Arch:00007 as the ASCII value.
  8. Finally, repeat steps 2 – 6 for PXEClient (BIOS x86 & x64) with PXEClient:Arch:00000 (five zero’s) as the ASCII value.

You should now have three additional vendor classes.

 

Creating the DHCP Policies

Now we’re going to create policies in DHCP so that the correct files are served to the correct clients. You will need to do this for each DHCP scope.

  1. Go to DHCP and expand the scope you wish to create a policy for.
  2. Right-click on Policies and choose New Policy.
  3. Enter PXEClient (UEFI x64) for the name.
  4. Enter a Description, or leave it blank. Click Next.
  5. On the Configure Conditions for the policy screen, click Add.
  6. In the Add/Edit Condition window, click the Value: drop down menu.
  7. Choose the PXEClient (UEFI x64) vendor class you created earlier.
  8. Tick the Append wildcard(*) check box and then click Add and finally Ok.
  9. Click Next on the Configure Conditions for the policy screen.
  10. On the Configure settings for the policy screen, click No for the Do you want to configure an IP address range for the policy. Click Next.
  11. Please Note: if DHCP is on the same server as WDS, you will need to set option 060, if WDS is on a different server, you do not need to set option 060.
  12. On the Configure settings for the policy screen, scroll down until you see options 060 (if applicable), 066 and 067.
  13. Tick option 060 and enter PXEClient if applicable.
  14. Tick option 066 and enter either the FQDN or the IP address of the WDS server.
  15. Tick option 067 and enter boot\x64\wdsmgfw.efi – this is the x64 UEFI boot file for WDS. Click Next.
  16. On the Summary screen, if all the details are correct, click Finish.
  17. Now repeat steps 2 – 14 for PXEClient (UEFI x86) with boot\x86\wdsmgfw.efi as option 067.
  18. Finally, repeat steps 2 – 14 once again for PXEClient (BIOS x86 & x64) with boot\x64\wdsnbp.com as option 067 and leave option 060 empty.

Don’t forget to repeat the above for each VLAN you wish to PXE boot from.

Now in DHCP, if you expand the Scope Options folder you should see the new options you just created and under policy name should be the names of the policies you just created. You should be able to boot both a UEFI and BIOS devices from the network.

Please note, if DHCP is installed on the same server as WDS, you will need to check both the Do not listen on DHCP ports and Configure DHCP options to indicate that this is also a PXE server options. I do not currently have DHCP and WDS on the same server, so I cannot reliably test this on a multi VLAN network.

 

My Experience

On my production network, I had previously added a helper address for the WDS server along with the DHCP server, so I have two helper addresses. I have not added policies for anything except PXEClient (UEFI x64) as my standard BIOS devices booted without issue, but my UEFI devices wouldn’t boot at all. I haven’t added PXEClient (UEFI x86) as all my devices boot x64 images and use x64 Task Sequences. So I have only one Policy in DHCP/IPv4/Scope x.x.x.x/Policies. My WDS server is running Windows Server 2016 and my DHCP server is Windows Server 2012 R2. An issue I currently have is that I cannot perform more than 2 or 3 PXE boots at a time, but no doubt it’s something to do with the “unique” configuration of my network. I guess your mileage may vary, but hopefully this post helps you out in some way.

I take great care to test my ideas and make sure my articles are accurate before posting, however mistakes do slip through sometimes. If you’d like to get in touch with me please use the comments, Twitter (you can tweet me and my DMs are open) or my contact form.

I hope this article helps you out, please consider supporting my work here. Thank you.

-Mike

22 thoughts on “PXE Booting with WDS for UEFI and BIOS Devices

Add yours

  1. Hey Mike,

    Wondering if I could ask your advice about WDS with MDT and PXE boot with UEFI

    We have three classrooms (Lab A, Lab B, Lab C)
    – identical Dell units in all three classrooms
    – all three classrooms are on the same subnet as the WDS and MDT
    – WDS and DHCP are on separate servers
    – the one class (Lab A) that I am having trouble with – if I change to legacy BIOS, I can PXE boot without problems.
    – Lab B & Lab C – no issues PXE booting using UEFI and successfully deployed OS with MDT

    Any idea of what it could be?

    Patrick

    Like

  2. Hey Mike,

    I am running into the same issue of only being able to PXE boot 2 or 3 machines at a time. I get Windows Deployment Services Encountered an Error: 0xc000001 when doing too many.

    Just curious if you ever figured out the issue on yours. Thanks!

    Like

    1. Hi Les,

      Unfortunately I didn’t find out exactly what was causing it. I don’t work at the place where I was having this issue any more, but where I am now, we don’t have this problem. The main difference is that I’ve moved from HP switches (old ones, not Aruba) to a Cisco based infrastructure. I suspect that it’s some configuration on the Cisco switches that wasn’t present on the HP ones, but I’m not well informed enough on Cisco to know what it is at the moment. Of course many other things are different at my new place so it could be something else.

      -Mike

      Like

  3. Great article, it worked really well for me. We did have an issue where sometimes PXE boot would still fail. Our problem was we had DHCP running on two servers with failover configured, but the Scope Policies aren’t replicated (whereas I had assumed they would be). Creating the same Scope Policies on the second DHCP server resolved the issue!

    Liked by 1 person

  4. Just in case anyone has issues with wdsmgfw.efi not being in their \\wdsserver\REMINST\Boot\x64 folder, you can find wdsmfgw.efi in C:\Windows\System32\RemInst\boot\x64\ and copy it over.

    Like

  5. Hello sir. I administer about 5 image servers, two of which have this configuration. However, one works but not the other despite identical configurations, the details of which I’ve gone through several times with a fine-toothed comb. The second server simply won’t pick up UEFI PXE clients, whereas it does fine over legacy PXE.

    I’m trying to figure out where to begin. WDS doesn’t log very much.

    Like

  6. I have a question regarding UEFI on new model PCs. My MDT and WDS server are all on one VLAN and only image from that same VLAN. I’m able to PXE boot the UEFI machines, start the task sequence, and the image gets laid down, but the error comes up that is can’t find a boot drive. I check the drive and it is getting formatted in GPT. Have you ever seen this issue? Only happens on UEFI machines and BIOS works fine. Could it be because the following, 067 and enter boot\x64\wdsmgfw.efi , isn’t added to DHCP? I’ve created a new task sequence and same issue.

    Like

    1. Hi William,

      This post (the one you’ve commented on) is a bit old and I’ve written a newer version of it with Windows Server 2016 in mind: https://gal.vin/2018/04/28/wds-pxe-booting-windows-server-2016-walkthrough/

      I also should mention that I’ve recently had to set this up recently with a Windows Server 2016 DHCP server and a WDS and MDT server also on 2016. I didn’t have to setup DHCP options or DHCP filters for UEFI and BIOS PXE boot images. The only thing I needed to do was configure IP helper addresses on the VLAN config on the switches – which were Cisco, if that helps.

      But to answer your question directly, it could be because the wdsmgfw.efi has been added. You might have luck in removing it and then testing both a BIOS and UEFI based device. PXE can be a bit flaky sometimes, I’ve had devices refuse to boot but then be fine 5 mins later. You might also try the DHCP policies and vendor classes in my posts and see if they help? They’ve helped me before on different networks.

      Hope this helps.

      -Mike

      Like

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Create a website or blog at WordPress.com

Up ↑

%d bloggers like this: