The objective of this article is to show how to diagnose and troubleshoot link flapping issues on a switch using SG350X as an example.
Applicable Devices | Software Version
A port flap, also referred to as a link flap, is a situation in which a physical interface on the switch continually goes up and down, three or more times a second for duration of at least ten seconds. The common cause is usually related to bad, unsupported, or non-standard cable or Small Form-Factor Pluggable (SFP) or related to other link synchronization issues. The cause for link flapping can be intermittent or permanent.
Since link flapping tends to be a physical interference, this document will explain the steps and procedures that can be taken to diagnose and prevent it. In addition, the article will also cover the settings that can be configured on the switch to prevent or solve a link flapping issue.
Table of Contents
Identifying Link Flapping
Link flapping is easy to identify in a network. Connectivity of certain devices will be intermittent. Link flapping can be seen and identified in the device’s syslog; syslog messages provide information about the events, errors or any serious problems which can happen within the switch. When reviewing your syslogs, look for “Up” and “Down” entries that seem to be back-to-back in a short span of time. Those entries will also describe exactly which port is causing the issue, and you can proceed to troubleshoot that specific port.
Checking the physical and hardware of the device including cables
The common cause for link flapping is usually related to bad, unsupported, or non-standard cable or Small Form-Factor Pluggable (SFP) or related to other link synchronization issues. Test the ethernet cables and cables being used on the ports giving issues. Be sure your device is on the latest firmware.
Try changing cables and monitor. If the issue persists, proceed to Step 2.
Go to Status and Statistics > Diagnostics > Copper Test.
Select the Port from the drop-down menu. In this example, GE16 is selected. Click on Copper Test.
A warning will appear. Be aware that the port will be shut down for a short period of time. Choose OK.
The Test Results will be displayed. If it says OK, it is most likely not the cable. If the results are not OK, change the cable and repeat the copper test to confirm that it is not the cable.
Analyzing your Topology
To confirm it is a physical problem and not a configuration issue on the switch, you need to analyze the devices connected to your switch. Check the following:
- What devices are connected to the switch?
- Analyze each device connected to the switch. Have you experienced any issues with those devices?
- Which ports are causing the problem and which devices are connected to those ports?
- Test the ports by connecting other devices and verifying if the problem continues.
- See if the device is causing issues on another port.
- Is it the port or the device?
- Determining whether it is the port, or the device determines how to continue the troubleshooting process.
- If it is the device, you may have to contact support management for that device.
- If you have determined it is the port, it is time to check whether the issue is related to configuration or a physical one.
How to Configure Link Flap Prevention
Link flap prevention minimizes the disruption to the switch and network operations. It stabilizes the network topology by automatically setting the ports that experience excessive link flap events to err-disable state ports. This mechanism also provides time to debug and locate root cause for flapping. A syslog message or Simple Network Management Protocol (SNMP) trap is sent to alert regarding link flap and port shutdown. The interface will become active again only if specifically enabled by the system administrator. For CLI-based instructions, check out the article Configure Link Flap Prevention Settings on a Switch through the CLI.
Log in to the graphical user interface (GUI) of the switch.
Choose Advanced Display Mode.
Go to Port Management > Port Settings.
On the Port Settings page, enable Link Flap Prevention by checking the Enable box. Click Apply.
Disabling Energy Efficient Ethernet (EEE)
Are you are still experiencing link flapping after checking your topology, devices, and enabling Link flap prevention? Try disabling Energy Efficient Ethernet (EEE). The purpose of EEE is that ethernet links have idle time and the opportunity to save energy. However, not all devices are compatible with EEE 802.3AZ and disabling it may be the best course of action.
Log in to the switch GUI.
Choose Advanced Display Mode.
Go to Port Management > Green Ethernet > Properties.
Disable 802.3 Energy Efficient Ethernet (EEE) by unchecking the Enable box. Click Apply.
The Smartport feature applies a pre-configured setup to the switch port based on the type of device that is trying to connect. Auto Smartport lets the switch apply these configurations to interfaces automatically when it detects the device. At times, Smartport may detect the device incorrectly, which can cause that specific port to “flap”. To prevent this, you can disable Smartport.
Choose Smartport > Properties.
Select Disable next to Administrative Auto Smartport to disable the Smartport globally on the switch. Click Apply.
This will disable the Smartport on all interfaces but will not affect manual VLAN configurations.
Having Smartport issues? Learn how to identify, troubleshoot, and disable the Smartport feature if it is causing problems with your switch.
Link flapping can be debilitating in a network. But now with all this information that you have learned, you can diagnose, prevent, and solve link flapping issues with ease.