25-14
Catalyst 3750 Switch Software Configuration Guide
OL-8550-02
Chapter 25 Configuring Port-Based Traffic Control
Configuring Port Security
To return the interface to the default condition as not a secure port, use the
no switchport port-security
interface configuration command. If you enter this command when sticky learning is enabled, the sticky
secure addresses remain part of the running configuration but are removed from the address table. All
addresses are now dynamically learned.
To return the interface to the default number of secure MAC addresses, use the
no
switchport
port-security maximum
value
interface configuration command. To return the violation mode to the
default condition (shutdown mode), use the
no
switchport port-security violation
{
protocol
|
restrict
}
interface configuration command.
To disable sticky learning on an interface, use the
no switchport port-security mac-address sticky
interface configuration command. The interface converts the sticky secure MAC addresses to dynamic
secure addresses. However, if you have previously saved the configuration with the sticky MAC
addresses, you should save the configuration again after entering the
no switchport port-security
mac-address sticky
command, or the sticky addresses will be restored if the switch reboots.
Use the
clear port-security
{
all
|
configured | dynamic | sticky
} privileged EXEC command to delete
from the MAC address table all secure addresses or all secure addresses of a specific type (configured,
dynamic, or sticky) on the switch or on an interface.
To delete a specific secure MAC address from the address table, use the
no switchport port-security
mac-address
mac-address
interface configuration command. To delete all dynamic secure addresses on
an interface from the address table, enter the
no switchport port-security
interface configuration
command followed by the
switchport port-security
command (to re-enable port security on the
interface). If you use the
no switchport port-security mac-address sticky
interface configuration
command to convert sticky secure MAC addresses to dynamic secure MAC addresses before entering
the
no switchport port-security
command, all secure addresses on the interface except those that were
manually configured are deleted.
Step 10
switchport port-security
mac-address sticky
[
mac-address
|
vlan
{
vlan-id
|
{
access
|
voice
}}]
(Optional) Enter a sticky secure MAC address, repeating the command as
many times as necessary. If you configure fewer secure MAC addresses than
the maximum, the remaining MAC addresses are dynamically learned, are
converted to sticky secure MAC addresses, and are added to the running
configuration.
Note
If you do not enable sticky learning before this command is entered,
an error message appears, and you cannot enter a sticky secure MAC
address.
(Optional)
vlan
—set a per-VLAN maximum value.
Enter one of these options after you enter the
vlan
keyword:
•
vlan-id
—On a trunk port, you can specify the VLAN ID and the MAC
address. If you do not specify a VLAN ID, the native VLAN is used.
•
access
—On an access port, specify the VLAN as an access VLAN.
•
voice
—On an access port, specify the VLAN as a voice VLAN.
Note
The
voice
keyword is available only if a voice VLAN is configured on
a port and if that port is not the access VLAN.
Step 11
end
Return to privileged EXEC mode.
Step 12
show port-security
Verify your entries.
Step 13
copy running-config
startup-config
(Optional) Save your entries in the configuration file.
Command
Purpose
Содержание 3750G - Catalyst Integrated Wireless LAN Controller
Страница 80: ...1 28 Catalyst 3750 Switch Software Configuration Guide OL 8550 02 Chapter 1 Overview Where to Go Next ...
Страница 606: ...27 8 Catalyst 3750 Switch Software Configuration Guide OL 8550 02 Chapter 27 Configuring UDLD Displaying UDLD Status ...
Страница 670: ...31 18 Catalyst 3750 Switch Software Configuration Guide OL 8550 02 Chapter 31 Configuring SNMP Displaying SNMP Status ...
Страница 1048: ...41 20 Catalyst 3750 Switch Software Configuration Guide OL 8550 02 Chapter 41 Configuring MSDP Monitoring and Maintaining MSDP ...
Страница 1086: ...43 26 Catalyst 3750 Switch Software Configuration Guide OL 8550 02 Chapter 43 Troubleshooting Using the crashinfo Files ...
Страница 1104: ...B 4 Catalyst 3750 Switch Software Configuration Guide OL 8550 02 Appendix B Supported MIBs Using FTP to Access the MIB Files ...