Switch User Manual

Client Security Commands
22-10
22
Related Commands
ip dhcp snooping (22-7)
ip dhcp snooping trust (22-12)
ip dhcp snooping binding (22-10)
ip dhcp snooping binding
This command adds a static address to the DHCP snooping binding table. Use the
no form to remove an entry from the binding table.
Syntax
ip dhcp binding mac-address vlan vlan-id ip-address
interface ethernet unit/port lease-time
no ip dhcp binding mac-address vlan vlan-id
mac-address - A valid unicast MAC address.
vlan-id - ID of a configured VLAN (Range: 1-4093)
ip-address - A valid unicast IP address, including classful types A, B or C.
unit - Stack unit. (Range: 1)
port - Port number. (Range: 1-28)
lease-time - The time after which an entry is removed from the table.
(Range: 0-4294967295, where 0 indicates a permanent entry)
Default Setting
None
Command Mode
Global Configuration
Command Usage
If DHCP snooping is enabled globally, and also enabled on the VLAN where
the DHCP packet is received on a trusted port, a dynamic DHCP snooping
entry is added to the binding table. An entry is added or removed dynamically
whenever a client has gotten or released an IP address from a DHCP server.
Table entries can also be statically configured using the ip dhcp binding
command. Table entries includes a MAC address, IP address, lease time,
entry type (Dynamic-DHCP-Binding, Static-DHCP-Binding), VLAN identifier,
and port identifier.
If the DHCP snooping is disabled globally, all dynamic bindings are removed
from the binding table; all static bindings are retained in the binding table but
will have no effect until DHCP snooping is globally re-enabled.
If DHCP snooping is enabled globally, and then disabled on a VLAN, all
dynamic bindings learned for this VLAN are removed from the binding table;
all static bindings configured for this VLAN are retained in the binding table but
will have no effect until snooping is re-enabled on the VLAN.
A static DHCP snooping entry can be added in the binding table under any of
the following conditions:
- If there is no binding with same VLAN ID and MAC address.