1

I am considering a setup with a primary DHCP server providing "IP data" (IP address, subnet mask, DNS, …), and a proxyDHCP server providing only PXE boot options. As it happens, my proxyDHCP server does not only provide the PXE options, but also the IP data (hence it's not really a proxyDHCP).

Using Wireshark, I now observe:

  1. The client (PXE-ROM) sends an "extended" DHCPDISCOVER (asking for IP data and PXE options)
  2. The primary DHCP server sends a DHCPOFFER (with only IP data)
  3. The client does not accept the DHCPOFFER (because it’s missing the PXE options?)
  4. (Much later) The proxyDHCP server sends a DHCPOFFER (with IP data and PXE options)
  5. The client accepts the second DHCPOFFER (and PXE-boots successfully)

Now I am wondering:

  • Why does the client not accept the first DHCPOFFER? That would be mandatory for the intended primary-proxy setup to work – how else would the client get its IP data?
  • If it’s all a matter of requested and provided DHCP options: Which specific missing options make the client ignore the offer? Why does the server even bother sending a DHCPOFFER, when it knows that it cannot provide all options and that the client would not accept the DHCPOFFER anyway?

Client Request:

Ethernet II, Src: cc:cc:cc:cc:cc:cc (cc:cc:cc:cc:cc:cc), Dst: Broadcast (ff:ff:ff:ff:ff:ff)
Internet Protocol Version 4, Src: 0.0.0.0, Dst: 255.255.255.255
User Datagram Protocol, Src Port: 68, Dst Port: 67
Dynamic Host Configuration Protocol (Discover)
    Message type: Boot Request (1)
    Hardware type: Ethernet (0x01)
    Hardware address length: 6
    Hops: 0
    Transaction ID: 0xcf952d8d
    Seconds elapsed: 0
    Bootp flags: 0x8000, Broadcast flag (Broadcast)
    Client IP address: 0.0.0.0
    Your (client) IP address: 0.0.0.0
    Next server IP address: 0.0.0.0
    Relay agent IP address: 0.0.0.0
    Client MAC address: cc:cc:cc:cc:cc:cc (cc:cc:cc:cc:cc:cc)
    Client hardware address padding: 00000000000000000000
    Server host name not given
    Boot file name not given
    Magic cookie: DHCP
    Option: (53) DHCP Message Type (Discover)
    Option: (57) Maximum DHCP Message Size
    Option: (55) Parameter Request List
        Length: 35
        Parameter Request List Item: (1) Subnet Mask
        Parameter Request List Item: (2) Time Offset
        Parameter Request List Item: (3) Router
        Parameter Request List Item: (4) Time Server
        Parameter Request List Item: (5) Name Server
        Parameter Request List Item: (6) Domain Name Server
        Parameter Request List Item: (12) Host Name
        Parameter Request List Item: (13) Boot File Size
        Parameter Request List Item: (15) Domain Name
        Parameter Request List Item: (17) Root Path
        Parameter Request List Item: (18) Extensions Path
        Parameter Request List Item: (22) Maximum Datagram Reassembly Size
        Parameter Request List Item: (23) Default IP Time-to-Live
        Parameter Request List Item: (28) Broadcast Address
        Parameter Request List Item: (40) Network Information Service Domain
        Parameter Request List Item: (41) Network Information Service Servers
        Parameter Request List Item: (42) Network Time Protocol Servers
        Parameter Request List Item: (43) Vendor-Specific Information
        Parameter Request List Item: (50) Requested IP Address
        Parameter Request List Item: (51) IP Address Lease Time
        Parameter Request List Item: (54) DHCP Server Identifier
        Parameter Request List Item: (58) Renewal Time Value
        Parameter Request List Item: (59) Rebinding Time Value
        Parameter Request List Item: (60) Vendor class identifier
        Parameter Request List Item: (66) TFTP Server Name
        Parameter Request List Item: (67) Bootfile name
        Parameter Request List Item: (97) UUID/GUID-based Client Identifier
        Parameter Request List Item: (128) DOCSIS full security server IP [TODO]
        Parameter Request List Item: (129) PXE - undefined (vendor specific)
        Parameter Request List Item: (130) PXE - undefined (vendor specific)
        Parameter Request List Item: (131) PXE - undefined (vendor specific)
        Parameter Request List Item: (132) PXE - undefined (vendor specific)
        Parameter Request List Item: (133) PXE - undefined (vendor specific)
        Parameter Request List Item: (134) PXE - undefined (vendor specific)
        Parameter Request List Item: (135) PXE - undefined (vendor specific)
    Option: (97) UUID/GUID-based Client Identifier
    Option: (94) Client Network Device Interface
        Length: 3
        Major Version: 3
        Minor Version: 16
    Option: (93) Client System Architecture
        Length: 2
        Client System Architecture: EFI x64 (7)
    Option: (60) Vendor class identifier
        Length: 32
        Vendor class identifier: PXEClient:Arch:00007:UNDI:003016
    Option: (255) End

(Ignored) Response from primary DHCP server (172.17.34.30 / aa:aa:aa:aa:aa:aa):

Ethernet II, Src: aa:aa:aa:aa:aa:aa (aa:aa:aa:aa:aa:aa), Dst: Broadcast (ff:ff:ff:ff:ff:ff)
Internet Protocol Version 4, Src: 172.17.34.30, Dst: 255.255.255.255
User Datagram Protocol, Src Port: 67, Dst Port: 68
Dynamic Host Configuration Protocol (Offer)
    Message type: Boot Reply (2)
    Hardware type: Ethernet (0x01)
    Hardware address length: 6
    Hops: 0
    Transaction ID: 0xcf952d8d
    Seconds elapsed: 0
    Bootp flags: 0x8000, Broadcast flag (Broadcast)
    Client IP address: 0.0.0.0
    Your (client) IP address: 172.17.34.1
    Next server IP address: 172.17.34.30
    Relay agent IP address: 0.0.0.0
    Client MAC address: cc:cc:cc:cc:cc:cc (cc:cc:cc:cc:cc:cc)
    Client hardware address padding: 00000000000000000000
    Server host name not given
    Boot file name not given
    Magic cookie: DHCP
    Option: (53) DHCP Message Type (Offer)
    Option: (54) DHCP Server Identifier (172.17.34.30)
    Option: (51) IP Address Lease Time
        Length: 4
        IP Address Lease Time: (900s) 15 minutes
    Option: (58) Renewal Time Value
        Length: 4
        Renewal Time Value: (450s) 7 minutes, 30 seconds
    Option: (59) Rebinding Time Value
        Length: 4
        Rebinding Time Value: (787s) 13 minutes, 7 seconds
    Option: (28) Broadcast Address (172.17.63.255)
    Option: (1) Subnet Mask (255.255.224.0)
    Option: (255) End

(Accepted) Response from proxyDHCP server (172.17.61.1 / bb:bb:bb:bb:bb:bb):

Ethernet II, Src: bb:bb:bb:bb:bb:bb (bb:bb:bb:bb:bb:bb), Dst: Broadcast (ff:ff:ff:ff:ff:ff)
Internet Protocol Version 4, Src: 172.17.61.1, Dst: 255.255.255.255
User Datagram Protocol, Src Port: 67, Dst Port: 68
Dynamic Host Configuration Protocol (Offer)
    Message type: Boot Reply (2)
    Hardware type: Ethernet (0x01)
    Hardware address length: 6
    Hops: 0
    Transaction ID: 0xcf952d8d
    Seconds elapsed: 0
    Bootp flags: 0x8000, Broadcast flag (Broadcast)
    Client IP address: 0.0.0.0
    Your (client) IP address: 172.17.61.61
    Next server IP address: 172.17.61.1
    Relay agent IP address: 0.0.0.0
    Client MAC address: cc:cc:cc:cc:cc:cc (cc:cc:cc:cc:cc:cc)
    Client hardware address padding: 00000000000000000000
    Server host name not given
    Boot file name not given
    Magic cookie: DHCP
    Option: (53) DHCP Message Type (Offer)
    Option: (54) DHCP Server Identifier (172.17.61.1)
    Option: (51) IP Address Lease Time
        Length: 4
        IP Address Lease Time: (600s) 10 minutes
    Option: (67) Bootfile name
        Length: 13
        Bootfile name: syslinux.efi
    Option: (58) Renewal Time Value
        Length: 4
        Renewal Time Value: (300s) 5 minutes
    Option: (59) Rebinding Time Value
        Length: 4
        Rebinding Time Value: (525s) 8 minutes, 45 seconds
    Option: (1) Subnet Mask (255.255.224.0)
    Option: (28) Broadcast Address (172.17.63.255)
    Option: (3) Router
        Length: 4
        Router: 172.17.61.1
    Option: (6) Domain Name Server
        Length: 4
        Domain Name Server: 172.17.61.1
    Option: (255) End

(MACs disguised)

1
  • While not a direct answer I suggest looking at "Preboot Execution Environment (PXE) Specification" - it should answer your question, see chapter 2 "PXE Client / Server Protocol". It is hard to find these days but there is a copy here: pix.net/software/pxeboot/archive/pxespec.pdf
    – Tomek
    Commented Jan 5, 2023 at 19:48

2 Answers 2

2

The ignored offer provides:

Your (client) IP address: 172.17.34.1        << offered IP address
Next server IP address: 172.17.34.30         << TFTP Server IP
Boot file name **not given**                 << NBP name

which is an incomplete PXE offer (Boot filename is missing when "next server" was provided) this is erroneous and could lead the client to totally ignore the offer.

The accepted offer provides:

Your (client) IP address: 172.17.61.61       << offered IP address
Next server IP address: 172.17.61.1          << TFTP Server IP
Option: (67) Bootfile name -> syslinux.efi   << NBP name

This is a complete PXE offer but also not quite right.

In both cases the offers were sent by a DHCP server there was not proxyDHCP here. In a DHCP Server - proxyDHCP scenario the DHCP server only provides IP info and related options and the proxyDHCP only PXE info

The PXE info (in the DHCP server or the proxyDHCP server) is either provided by "next server" and "file" fields of the DHCP offer (preferred method) "or" by DHCP options 66 and 67, but never by a combination of this 2 alternatives. Now you can see why the accepted offer is also not totally correct even when taken by the client.

0

You should disable the dhcp configuration in proxy DHCP server and try if the pxe client is getting the IP from primary DHCP and boot from the proxy dhcp. When a pxe client boots, it will send a dhcp discovery with option 60. In your case the proxy server is providing the option 60. That's y you second dhcp is accepted by pxe client.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .