(MX) How Does DHCP Relay Packets Forward With DHCP-only

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 2

2023/12/21 上午11:14 [MX] How does DHCP relay packets forward with DHCP-only?

[MX] How does DHCP relay packets forward with DHCP-only?

Article ID KB37320 Created 2021-07-14 Last Updated 2021-08-15

Description
This article explains why the DHCP relay cannot complete DORA when DHCP-only is enabled.

Symptoms
With the following configuration when forward-only is enabled, there will be a sub-option 9 under dhcp option
82 which is be added automatically. The sub-option will indicate which interface is going to be the OIF for this
dhcp relay foward-only. Since the dhcp reply forward-only does not generate the dhcp stateful info, we have to
depend on this sub-option 9 to find out the OIF. If the returned dhcp offer does not contain this sub-option, the
dhcp will not forward this offer to client.

set forwarding-options dhcp-relay server-group 1 172.16.100.10


set forwarding-options dhcp-relay group 1 active-server-group 1
set forwarding-options dhcp-relay group 1 overrides trust-option-82
set forwarding-options dhcp-relay group 1 overrides send-release-on-delete
set forwarding-options dhcp-relay group 1 forward-only
set forwarding-options dhcp-relay group 1 interface xe-1/3/0.0

On a server-facing interface, there are 2 option-82's. On the 2nd option-82, there is a sub-option 9 with the
physical interface where it received the dhcp discover from the client. But for some reason, the dhcp offer did
not carry this sub-option. So the MX discarded the dhcp packet.
Monitor traffic interface ge-1/1/9 detail layer2-headers no-resolve
Address resolution is OFF.
Listening on ge-1/1/9, capture size 1514 bytes

12:07:32.507745 Out 94:f7:ad:5a:a9:e5 > f0:00:02:b0:a7:8d, ethertype IPv4 (0x0800), length 496: (tos 0x0, ttl 64, id 38498, offs
Gateway-IP 172.16.10.1
Client-Ethernet-Address f0:00:01:b0:a7:8d
Vendor-rfc1048 Extensions
Magic Cookie 0x63825363
DHCP-Message Option 53, length 1: Discover
MSZ Option 57, length 2: 576
Client-ID Option 61, length 7: ether f0:00:01:b0:a7:8d
Lease-Time Option 51, length 4: 60
Hostname Option 12, length 52: "client_Port //2/10 [F4:A7:39:CD:4E:00/xe-0/0/21]-0-0"
Parameter-Request Option 55, length 5:
Subnet-Mask, Domain-Name-Server, Domain-Name, Static-Route
Netbios-Name-Server
Agent-Information Option 82, length 53:
Circuit-ID SubOption 1, length 51: circuitId_Port //2/10 [F4:A7:39:CD:4E:00/xe-0/0/21]
Agent-Information Option 82, length 72:
Circuit-ID SubOption 1, length 51: circuitId_Port //2/10 [F4:A7:39:CD:4E:00/xe-0/0/21]
Unknown SubOption 9, length 17:
0x0000: 0000 0a4c 0c04 0a78 652d 312f 332f 302e
0x000f: 30
12:07:32.508827 In PFE proto 2 (ipv4): (tos 0xc0, ttl 64, id 39486, offset 0, flags [none], proto: UDP (17), length: 408) 172.1
Your-IP 172.16.10.1
Server-IP 172.16.100.10
Gateway-IP 172.16.10.1
Client-Ethernet-Address f0:00:01:b0:a7:8d
Vendor-rfc1048 Extensions
Magic Cookie 0x63825363
DHCP-Message Option 53, length 1: Offer
Lease-Time Option 51, length 4: 3600
Server-ID Option 54, length 4: 172.16.100.10
Subnet-Mask Option 1, length 4: 255.255.255.0
Hostname Option 12, length 52: "server_Port //11/4 [F4:A7:39:CD:4E:00/xe-0/0/22]-2-0"
Default-Gateway Option 3, length 4: 172.16.10.1
Agent-Information Option 82, length 53:
Circuit-ID SubOption 1, length 51: circuitId_Port //2/10 [F4:A7:39:CD:4E:00/xe-0/0/21]

https://supportportal.juniper.net/s/article/MX-How-does-DHCP-relay-packets-forward-with-DHCP-only?language=en_US&t=1703128422359 1/2
2023/12/21 上午11:14 [MX] How does DHCP relay packets forward with DHCP-only?

Solution
Since the sub-option 9 will be added automatically, the DHCP server must have this sub-option in offer/ack.
Otherwise, the DORA cannot be finished.

AFFECTED PRODUCT SERIES / FEATURES

https://supportportal.juniper.net/s/article/MX-How-does-DHCP-relay-packets-forward-with-DHCP-only?language=en_US&t=1703128422359 2/2

You might also like