Most switches will have a self-diagnosis function. When the switch or switch port fails for some reason, the indicator is used to inform the administrator of the error. However, there are times when the switch can be diagnosed incorrectly. If the switch's port work led clearly indicates normal, but the user reflects the network is not. If it's just a regular user, it's not a big problem. But if the port happens to be used for backup, the situation is worse. In order to avoid this situation, in the actual work many network administrators like to adopt the switch UDLD mode to eliminate this kind of mistake diagnosis of the switch.
, under what circumstances will there be a false diagnosis?
The
error diagnosis is mainly because the interface still fails to deliver data traffic normally, even when the port light on the link or switch is normal (that is, the state of the port is up). This error is often referred to as a one-way link. In general, this error occurs when an interface failure, software failure, hardware failure, or other unusual cause occurs. With today's technology, switches are not fundamentally immune to this error. To do so, only other ways to strengthen the detection of switch ports to detect this error as early as possible. In Cisco series switches, the UDLD mode is used to solve the error diagnosis in this case.
UDLD Theoretically, it is an agreement to work on the second floor. However, from the actual point of view, it often has a deep relationship with the content of the first layer. In other words, UDLD mode is not only in the second level of operation, it will be with the first layer of the relevant mechanisms to work together to complete. The main idea is that the UDLD protocol runs between the first to second layer and finally determines the actual working state of the link. When it is found that "link up state is normal, but no traffic", the UDLD agreement will immediately call the police. Specifically, in the first layer through the automatic negotiation function to observe the relevant parameters such as physical signaling operation. The UDLD protocol will accomplish tasks that the automated negotiation mechanism is not able to perform. When automatic negotiation discovers that the physical signaling is abnormal, it does not automatically convert the port from the up state to another state, causing the one-way link to fail. The UDLD protocol is able to accept parameters from the automated negotiation mechanism, and then when the failure is detected, the switch port is turned off in a timely manner. It can be seen that the UDLD model is not only a protocol, but the result of interaction between UDLD protocol and automatic negotiation mechanism. If the network administrator wants to start the UDLD mode, then must enable the UDLD protocol and the automatic negotiation mechanism simultaneously, in the first level and the second layer through their division responsibility, the coordinated work, prevents the physical or the logical one-way connection, thus fundamentally eliminates the switch the mistake diagnosis.
network administrators need to understand that UDLD is not a replacement for the original diagnosis system of the switch, but an independent diagnostic method. That is, it makes a self-diagnosis of the running state of the switch's ports from another angle. There is basically no conflict or overlap between the two. In practical work, the traditional diagnosis method and UDLD mode are often used at the same time.
two, reasonable allocation of various parameters in UDLD mode
if both the UDLD protocol and the automatic negotiation mechanism are enabled, the UDLD mode is started, in which case an interface of the switch periodically sends the UDLD protocol datagram to the neighboring port. Under normal circumstances, this interface of the switch receives a response packet before the scheduled timer expires. If before this timer expires, the switch sends the UDLD packet to the interface has not received the response information, then the UDLD protocol will think that there is a failure, that is, the one-way link failure (in fact, more precisely, it should be automated negotiations to find this fault and informed the UDLD Agreement). When Udld knows this, it immediately shuts down the problematic switch interface.
In the UDLD configuration, the first thing to consider is this timer. In other words, it's good to set this time to how much. If the time set is relatively short, not only will cause unnecessary data traffic, but also because of data latency and other reasons can not be within a reasonable time to receive a response packet. If you set the timer to a long time, you may not be able to find the problem in a short time. You know, maybe a minute for the user, not much feeling. But for the data network transmission, this time is very long. By default, this timer is 15 seconds. In actual work, the network administrator may need to set this parameter reasonably according to different circumstances. If you need to be based on the complexity of the enterprise network, wiring length to consider. According to the previous situation, the enterprise may often encounter network congestion and so on, and this congestion is temporary, then the appropriate extension of the timer and so on. The author's suggestion is that at the beginning of the time you can set the timer a bit longer, and then slowly shorten. Finally, a reasonable numerical value is obtained.
third, improve the applicability of the port
in the case of a normal interface, the interface closes when an interface is not receiving a UDLD response message. This also has a flaw. If the enterprise may have network congestion, such as due to temporary backup, etc. cause congestion and so on. At this point, the sender may not be able to receive the response information before the timer expires. In this case, if the switch port is set to shut down, it will obviously cause no more trouble. The network administrator wants to be able to "change the wrong" opportunity for the network. Therefore, on the basis of the original UDLD mode, Cisco switches put forward the concept of active UDLD mode. The difference between the two modes is mainly that the latter gives the network a chance to correct the error.
in active UDLD mode, when the switch interface finds that the UDLD response information is not received correctly, the port is not immediately set to shutdown, and the UDLD packet will continue to be sent. Typically, UDLD packets are sent eight times. If you still cannot receive the UDLD packet after sending eight times, the UDLD protocol will change the port status to Err-disable state. If the sending port receives any response information during this interrupted time, it is considered normal. Obviously, if the active UDLD mode is adopted, it may be effective to avoid the problem of misjudgment caused by network congestion.
Another reason to adopt a positive UDLD model is to route a black hole. What is called a routing black hole? This definition is not very much to say, I give an example. If the 3rd layer or the routing interface is experiencing a one-way link, the interface sinks in the up state, so the switch will continue to convert traffic to this interface. But the end result is that the packet will never reach the remote device's corresponding interface. This is a simple example of routing a black hole. If the traditional UDLD mode is adopted, it is not good enough to avoid this situation. Conversely, if active UDLD mode is adopted, it can effectively avoid the network fault caused by routing black hole.
Active UDLD mode is more special than the number of messages sent, there are two special places. One is when the link side of the port to send congestion, the active mode of the UDLD protocol will also set the port to the error state, and display the relevant measures information. The traditional UDLD model has no reaction to this situation. The second is when one of the ports in the link is up and the other side is down, and if the active UDLD mode is used, the error message is displayed and the port is set to the wrong state. If the traditional UDLD mode is adopted, there will be no response. This is also the author mentioned above through the positive UDLD model to solve the problem of the black hole on the road.
Quad, reboot switch interface after recovery
whether the traditional UDLD mode or the active UDLD mode, there is a common point, that is, as long as the port is set to error-disable state, even if the fault is resolved, the switch can not automatically restore the interface. In other words, when this happens, the network administrator needs to manually recover the interface. As a general practice, the port is shutdown off with the command, and then enabled using the command no shutdown.
in short, as long as the switch support, you can enable UDLD mode, or even enable active UDLD mode, you can effectively avoid one-way link misdiagnosis. In particular, the use of active mode of UDLD, then routed black hole This network problem can also be solved