Displaying and maintaining DHCP snooping
Execute display commands in any view, and reset commands in user view.
Task
Display DHCP snooping entries.
Display Option 82 configuration information on
the DHCP snooping device.
Display DHCP packet statistics on the DHCP
snooping device (centralized devices in
standalone mode).
Display DHCP packet statistics on the DHCP
snooping device (distributed devices in
standalone mode/centralized devices in IRF
mode).
Display DHCP packet statistics on the DHCP
snooping device (distributed devices in IRF
mode).
Display information about trusted ports.
Display information about the file that stores
DHCP snooping entries.
Clear DHCP snooping entries.
Clear DHCP packet statistics on the DHCP
snooping device (centralized devices in
standalone mode).
Clear DHCP packet statistics on the DHCP
snooping device (distributed devices in
standalone mode/centralized devices in IRF
mode).
Clear DHCP packet statistics on the DHCP
snooping device (distributed devices in IRF
mode).
DHCP snooping configuration examples
Basic DHCP snooping configuration example
Network requirements
As shown in
•
Configure the port GigabitEthernet 2/0/1 connected to the DHCP server as a trusted port.
•
Configure other ports as untrusted ports.
•
Enable DHCP snooping to record clients' IP-to-MAC bindings by reading DHCP-ACK
messages received from the trusted port and DHCP-REQUEST messages.
Figure
37:
Command
display dhcp snooping binding [ ip ip-address [ vlan
vlan-id ] ]
display dhcp snooping information { all | interface
interface-type interface-number }
display dhcp snooping packet statistics
display dhcp snooping packet statistics [ slot
slot-number ]
display dhcp snooping packet statistics [ chassis
chassis-number slot slot-number ]
display dhcp snooping trust
display dhcp snooping binding database
reset dhcp snooping binding { all | ip ip-address [ vlan
vlan-id ] }
reset dhcp snooping packet statistics
reset dhcp snooping packet statistics [ slot
slot-number ]
reset dhcp snooping packet statistics [ chassis
chassis-number slot slot-number ]
90