<

PXEClient, dhcp options 60, 66 and 67, what are they for? Can I use PXE without it ?

Published on
97,200 Points
78,599 Views
1 Endorsement
Last Modified:
Ever wondered why you had to use DHCP options (dhcp opt 60, 66 or 67) in order to use PXE?
Well, you don't!
DHCP Option 60

You have to create dhcp option 60 only if:
- You have a PXE Service and that runs on the same host that also runs a dhcp service (bound on UDP 67)
- You need this PXE Service to provide the "network boot program" details to your PXE clients.
These details are actually: TFTP server IP address (DHCP option 66) and network boot program file name (DHCP option 67)

If you know these details, you can perfectly make the economy of a PXE Service. Just fill these dhcp options (66 and 67) with the needed data.

For instance, if your TFTP server runs on the host with IP address 192.168.1.10, and if your network boot program file name is pxelinux.0, just configure your dhcp server so that its option 66 is "192.168.1.10" and option 67 is "pxelinux.0".
No dhcp option 60, no "PXEClient".
Note that your DHCP server can also run on the same host (192.168.1.10 in this example)

Also, do not set this dhcp option 60 if you have a PXE Service running on an host that does not run any dhcp or bootp service.

The problem is that if you have both a DHCP and a PXE service on the same host, they can't use the same listening port (dhcps, which is udp 66). In that case, the PXE standard specifies that the PXE Service can use udp 4011 as its listening port. Of course, the PXEClient must send their DHCPDISCOVER packets to that port too. The DHCP option 60, when set to "PXEClient" is used only to instruct the PXE clients to try to use a PXE Service bound on UDP port 4011.


DHCP options 66 and 67

One side effect of having a PXE service (whether running on the same host as the DHCP service, thus requiring Dhcp Opt 60 to be set to PXEClient or on another host) is that you should NOT set DHCP opt 66 and 67.
When using a PXEService, dhcp options 66 and 67 are sent to the PXE clients by the PXE service itself, not by DHCP service.
If you do set DHCP options 66 and 67, ALL the PXEClient are instructed to download and boot the same network boot program (NBP) and you then cannot have different architecture support, for instance, you can't have clients booting an x86-bios boot program and some other booting an x64-bios nbp nor an x64-efi nbp.


DHCP and PXE on different subnets

Of course, if your clients and servers are not on the same subnets, you need to set some kind of dhcp-relay (aka ip-helper or dhcp-forwarder) so that the dhcp broadcasts sent by your PXE clients are forwarded to the dhcp server on another subnet.
If your PXE server is not your dhcp server and is not in the same subnet as the PXE clients, then, in addition not to have any dhcp option 60 set to "PXEClient", you also must add the IP address of the PXE server to the list of IP addresses that get the dhcp broadcasts. In the Cisco world, it means adding the address of the PXE server to  "ip-helper" addresses on your routers or (Layer 3) switches. In that case, you would have both the DHCP server and PXE server(s) in ip-helper list of addresses
 
1
Comment
Author:vivigatt
  • 2
2 Comments
LVL 17

Author Comment

by:vivigatt
One side effect of having a PXE service (whether running on the same host as the DHCP service, thus requiring Dhcp Opt 60 to be set to PXEClient or on another host) is that you should NOT set DHCP opt 66 and 67.
When using a PXEService, dhcp options 66 and 67 are sent to the PXE clients by the PXE service itself, not by DHCP service.
0
LVL 17

Author Comment

by:vivigatt
Of course, if your clients and servers are not on the same subnets, you need to set some kind of dhcp-relay (aka ip-helper or dhcp-forwarder) so that the dhcp broadcasts sent by your PXE clients are forwarded to the dhcp server on another subnet.
If your PXE server is not your dhcp server and is not in the same subnet as the PXE clients, then, in addition not to have any dhcp option 60 set to "PXEClient", you also must add the IP address of the PXE server to the list of IP addresses that get the dhcp broadcasts. In the Cisco world, it means adding the address of the PXE server to  "ip-helper" addresses on your routers or (Layer 3) switches. In that case, you would have both the DHCP server and PXE server(s) in ip-helper list of addresses
0

Featured Post

Cloud Class® Course: C++ 11 Fundamentals

This course will introduce you to C++ 11 and teach you about syntax fundamentals.

Join & Write a Comment

This video gives you a great overview about bandwidth monitoring with SNMP and WMI with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're looking for how to monitor bandwidth using netflow or packet s…
In this tutorial you'll learn about bandwidth monitoring with flows and packet sniffing with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're interested in additional methods for monitoring bandwidt…

Keep in touch with Experts Exchange

Tech news and trends delivered to your inbox every month