DHCP snooping configuration example
Network requirements
As shown in
The port connected to the DHCP server can forward responses from the server, but the other ports
•
cannot forward responses from any DHCP server.
•
Configure Router B to record clients' IP-MAC bindings by reading DHCP-REQUEST messages and
DHCP-ACK messages received from the trusted port.
Figure 29 Network diagram
Configuration procedure
# Enable DHCP snooping.
<SwitchB> system-view
[SwitchB] dhcp-snooping
# Specify GigabitEthernet 1/0/1 as trusted.
[SwitchB] interface gigabitethernet 1/0/1
[SwitchB-GigabitEthernet1/0/1] dhcp-snooping trust
[SwitchB-GigabitEthernet1/0/1] quit
DHCP snooping Option 82 support configuration
example
Network requirements
As shown in
DHCP server (Switch A).
The circuit ID sub-option is company001.
•
The remote ID sub-option is device001.
•
•
On GigabitEthernet 1/0/3, configure the padding format as verbose, access node identifier as
sysname, and code type as ascii for Option 82.
Figure
29, perform configurations on Switch B to achieve the following purposes:
Figure
29, Switch B replaces Option 82 in DHCP requests before forwarding them to the
60