BuildTheNet

Opening your workspace

Your learning content and tools are loading.

DHCP

show ip dhcp snooping

Shows whether DHCP snooping is on, for which VLANs, and which interfaces are trusted.

Written by a working field network engineer · CCNA, Security+, CySA+

DHCP snooping lets a switch drop DHCP server messages arriving on untrusted ports, which stops rogue DHCP servers. This shows the global state, the VLANs it protects, and which ports are trusted.

Example output

SW1#show ip dhcp snooping
Switch DHCP snooping is enabled
Switch DHCP gleaning is disabled
DHCP snooping is configured on following VLANs:
10
DHCP snooping is operational on following VLANs:
10
DHCP snooping is configured on the following L3 Interfaces:

Insertion of option 82 is enabled
   circuit-id default format: vlan-mod-port
   remote-id: 0050.7966.6800 (MAC)
Option 82 on untrusted port is not allowed
Verification of hwaddr field is enabled
Verification of giaddr field is enabled
DHCP snooping trust/rate is configured on the following Interfaces:

Interface                  Trusted    Allow option    Rate limit (pps)
-----------------------    -------    ------------    ----------------
GigabitEthernet0/1         yes        yes             unlimited
  Custom circuit-ids:

Reference output: hand-written in standard Cisco IOS format for this example network, not captured from a device.

Useful variants

What each column or field means

FieldMeaning
configured / operational on following VLANsVLANs listed with ip dhcp snooping vlan, and of those, the ones that exist and are active.
Insertion of option 82Whether the switch adds the relay agent information option to client requests.
TrustedTrusted ports may carry DHCP server replies. Every other port is untrusted, and server messages arriving there are dropped.
Rate limit (pps)DHCP packets per second allowed before the port is err-disabled, set with ip dhcp snooping limit rate.

When it doesn’t look right

No client gets an address after snooping is enabled.

The port toward the real DHCP server (or the uplink to it) is untrusted. Configure ip dhcp snooping trust on it.

Clients still fail, and the router is the DHCP server on the same VLAN.

The switch inserted option 82 with a zero giaddr and the IOS DHCP server drops it. Disable insertion with no ip dhcp snooping information option, or set ip dhcp relay information trust-all on the router.

Snooping is configured but not operational for a VLAN.

The VLAN does not exist or has no active ports. Global ip dhcp snooping must also be on.

Related commands

Try it yourself

Learn it in the CCNA path

Topic

DHCP — Run a DHCP server on a router, relay requests across subnets with ip helper-address, and protect the LAN with DHCP snooping.

All 57 commands