2-38
Catalyst4500 Series SwitchCiscoIOS Command Reference—Release 12.2(18)EW
78-16201-01
Chapter2 Cisco IOS Commands for the Catalyst 4500 Series Switches
clear port-security
clear port-security
To delete from the MAC address table all secure addresses, all configured secure addresses, or a specific
dynamic or sticky secure address on an interface, use the clear port-security command.
clear port-security {all | dynamic} [address mac-addr [vlan vlan-id]] | [interface interface-id]
Syntax Description
Defaults This command has no default settings.
Command Modes Privileged EXEC
Usage Guidelines If you enter the clear port-security all command, the switch removes all secure MAC addresses from
the MAC address table.
If you enter the clear port-security dynamic interface interface-id command, the switch removes all
dynamic secure MAC addresses on an interface from the MAC address table.
Command History
Examples This example shows how to remove all secure addresses from the MAC address table:
Switch# clear port-security all
This example shows how to remove a dynamic secure address from the MAC address table:
Switch# clear port-security dynamic address 0008.0070.0007
This example shows how to remove all the dynamic secure addresses learned on a specific interface:
Switch# clear port-security dynamic interface gigabitethernet0/1
You can verify that the information was deleted by entering the show port-security command.
Related Commands show port-security
switchport port-security
all Deletes all secure MAC addresses.
dynamic Deletes all dynamic secure MAC addresses.
address mac-addr (Optional) Deletes the specified secure MAC address.
vlan vlan-id (Optional) Deletes the specified secure MAC address from the specified
VLAN.
interface interface-id (Optional) Deletes secure MAC addresses on the specified physical port or
port channel.
Release Modification
12.2(18)EW This command was first introduced on the Catalyst 4500 series switch.