2-30
Cisco MDS 9000 Family NX-OS Interfaces Configuration Guide
OL-29284-01, Release 6.x
Chapter 2 Configuring Interfaces
Configuring Interfaces
Configuring Port Guard
Detailed Steps
To enable or disable the port guard for a port, follow these steps:
Examples
This example shows how to configure port guard to bring a port to down state if the link flaps 5 times
within 120 seconds based on multiple causes:
Switch# config t
Switch (config)# interface fc1/1
Switch (config-if)# errdisable detect cause link-down num-times 5 duration 120
Switch (config-if)# errdisable detect cause bit-errors num-times 5 duration 120
Switch (config-if)# errdisable detect cause credit-loss num-times 5 duration 120
The above example sets the configuration to the following status:
The port will be error-disabled due to bit errors if the port suffers link failure due to bit errors 5 times
in 120 seconds.
The port will be error-disabled due to credit loss if the port suffers link failure due to credit loss 5
times in 120 seconds.
The port will be error-disabled due to link down if the port suffers link failure due to bit errors 2
times and link-failure due to credit loss 3 times in 120 seconds.
This example shows the internal information about a port in down state because of TrustSec violation:
Command Purpose
Step 1 switch# config t Enters configuration mode.
Step 2 switch(config)# interface fc1/1 Selects the port interface.
Step 3 switch(config)# errdisable detect cause
link-down
Brings the port to down state if the link flaps
once.
switch(config)# errdisable detect cause
link-down [num-times
number
duration
seconds
]
Enables the port guard configuration for the
interface. Brings the port to down state if the link
flaps for the number of instances within the
specified seconds.
switch(config)# no errdisable detect cause
link-down
Removes (default) the port guard configuration
for the interface. The link resumes flapping and
sending error reports normally.
Step 4 switch(config)# errdisable detect cause
{trustsec-violation | bit-errors |
credit-loss | link-reset | signal-loss |
sync-loss}
Brings the port to down state if the specified error
occurs even once.
switch(config)# errdisable detect cause
{trustsec-violation | bit-errors |
credit-loss | link-reset | signal-loss |
sync-loss} [num-times
number
duration
seconds
]
Brings the port to down state if the specified error
occurs for the number of instances within the
specified seconds.
switch(config)# no errdisable detect cause
{trustsec-violation | bit-errors |
credit-loss | link-reset | signal-loss |
sync-loss}
Removes (default) the port guard configuration
for the interface. The link resumes flapping and
sending error reports normally.