01-11-2021 01:46 PM
I am trying to clear a mac from a port. Here is what it looks like from the running config:
interface GigabitEthernet5/0/7
switchport mode access
switchport port-security mac-address sticky
switchport port-security
sh interfaces status err-disabled returns:
Gi5/0/7 err-disabled psecure-violation
If there is a violation, shouldn't there be a MAC address listed with the port in the running config? How do I resolve this so I can allow my client to connect?
01-12-2021 05:14 PM - edited 01-13-2021 06:05 PM
...
01-12-2021 05:04 PM - edited 01-13-2021 10:09 AM
.....
01-12-2021 08:43 AM
Hello,
I haven't followed the entire post, but try to default the interface:
Switch(config)#default interface GigabitEthernet5/0/7
01-12-2021 09:22 AM
Doing this allows me to pull an IP address.
01-12-2021 08:54 AM
Please go to port
#conf t
#int GigabitEthernet5/0/7
#Shut
#No Sh
04-18-2023 04:02 PM - edited 04-18-2023 04:06 PM
To clear the sticky mac address so the switch can learn a new address
conf t
int G5/0/7
no switchport port-security mac-address sticky xxxx.xxxx.xxxx
shut
no shut
Where xxxx.xxxx.xxxx is the old mac address that was learned by the sticky command. The port will then learn the new mac address that is connected to it. You can also just turn sticky off and back on to force it to learn, i.e.
conf t
int G5/0/7
no switchport port-security mac-address sticky
shut
no shut
switchport port-security mac-address sticky
08-29-2024 04:56 AM - edited 08-29-2024 04:59 AM
I know this an old post. Maybe it will assist someone else.
clear port-security all interface gi5/0/7
&
clear port-security all address H.H.H.H
This will clear the current violation and the interface will then learn the new mac dynamically.
Aug 29 13:31:41: %PORT_SECURITY-2-PSECURE_VIOLATION: Security violation occurred, caused by MAC address 9c93.4e9a.909b on port FastEthernet0/1.
JNBSA2924ACC0A-GFLR#
JNBSA2924ACC0A-GFLR#clear port-security all int fa0/1
JNBSA2924ACC0A-GFLR#clear port-security all add 9c93.4e9a.909b
JNBSA2924ACC0A-GFLR#wr
Building configuration...
[OK]
As per the output you can see the new mac of 9c93.4e9a.909b is assigned to the port.
JNBSA2924ACC0A-GFLR#sh run int fa0/1
Building configuration...
Current configuration : 483 bytes
!
interface FastEthernet0/1
description Xerox Printer
switchport access vlan 119
switchport mode access
switchport port-security violation restrict
switchport port-security mac-address sticky
switchport port-security mac-address sticky 9c93.4e9a.909b
switchport port-security
speed 100
duplex full
srr-queue bandwidth share 1 30 35 5
priority-queue out
mls qos trust dscp
auto qos trust dscp
no cdp enable
spanning-tree portfast
spanning-tree bpduguard enable
end
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide