DHCP and the PXE Boot Process Explained

DHCP and the PXE Boot Process Explained

Recently I came across a scenario where we had to troubleshoot why a laptop wasn’t rebuilding via SCCM and I thought it would be good to write an article explaining the PXE boot process and how DHCP is linked to that.

Basic DHCP Process

The simplest of DHCP processes goes as follows:

  • The client connects to the network and sends out a DHCP broadcast
  • The DHCP server picks up the broadcast
  • The server then replies with a suggested IP address
  • The client then acknowledges the server and uses the provided address

PXE Boot Process

When the client initiates a PXE boot (by traditionally pressing F12) however the process is changed slightly:

  • The client sends out a DHCP broadcast and states that it needs to PXE boot
  • The DHCP server picks up this broadcast and replies with a suggested IP address to use.  If the server has the information on how to PXE boot, the it’s reply is included in it’s reply
  • The client then replies to the server and uses the provided address
  • Then the client contacts the PXE boot server (traditional a WDS server or SCCM server) and requests the bootfile that it received from the DHCP server
  • The file is then loaded and launched on the client

Typically Option 66 or Option 67 are set within your DHCP scope options or DHCP Helpers are configured within your router for the above process to work.   Option 66 specifics which server to contact and 67 is the name of the file to request.  I recently wrote an article on how to set the DHCP options within a Windows Server via Powershell cmdlets

Dynamic PXE Boot

Another method  of providing the boot information to a client is to have a service listen for the DHCP request.  Configuration Manager provides dynamic PXE boot using the Windows Deployment Service (WDS).

  • The client connects to the network and sends out a DHCP broadcast
  • The DHCP server picks up this broadcast and replies with a suggested IP address to use.
  • The WDS service also replies back to the client with the necessary information it needs to PXE boot
  • The client replies to the DHCP server and uses the suggested address
  • The client also contacts the PXE boot server and requests the bootfile specified in the boot information it was sent
  • The file is then loaded and launched on the client

Below is a diagram of what your network might look like in the above scenario:

Dynamic PXE Boot Network diagram with SCCM

DHCP Options vs IP Helpers

There’s long been a debate as to which method you should use to direct your clients to your PXE boot server.  Microsoft have long stated that they do not recommend or support the use of DHCP scope options as the method of redirection and prefer you update your router’s IP helper table with the necessary information.

Using the DHCP options limits your options as you can only specific one server and one Network Boot Program (NBP) file.   Only being able to specify one NBP file can cause issues in environments were both legacy and UEFI clients are being used.

Within a routed environment my personal preference is to use DHCP helper options configured at the router level as it provides much more flexibility and is the Microsoft supported method.

 

Conclusion

The above only covers simple environment solutions but hopefully it helps you understand the process and understand where you would need to look to troubleshoot any issues.

 

Please follow and like us:
0
Comments are closed.