Method and system for preventing, detecting and solving PFC deadlock on VPLS
By generating PAUSE' frames and PAUSE frames, combining MAC address judgment, dynamically adjusting the speed limit of upstream devices, solving the accurate detection and prevention of self-ring deadlocks in VPLS networks, and ensuring lossless network transmission.
Patent Information
- Application Number
- CN202510539225.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-27
- Publication Date
- 2025-07-18
AI Technical Summary
Self-ring deadlocks are prone to occur in VPLS networks and it is difficult to accurately determine whether self-ring deadlocks occur. The detection time of the prior art is uncertain and may be misjudged.
By generating PAUSE' frames and PAUSE frames, the PAUSE' frame frequency is negatively correlated with the service message transmission frequency. The upstream device adjusts the speed limit according to the PAUSE frame frequency until it detects the PAUSE frame sent by itself and the message traffic is 0 to determine the self-ring deadlock. The PAUSE frame contains the MAC address to avoid misjudgment.
Accurately prevent self-ring deadlocks, reduce misjudgments, and ensure lossless network transmission.
Smart Images

Figure CN120342907A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of QoS (Quality of Service), and particularly to a method and system for preventing, detecting, and resolving PFC deadlocks in VPLS (Virtual Private LAN Service). Background Art
[0002] With the development of communication technologies, applications such as high-performance computing, distributed storage, and driverless driving have emerged, leading to increasingly high network requirements. Therefore, the concept of a lossless network has been proposed, which requires low latency and high throughput. However, scenarios of network aggregation and excessive burst traffic often occur, easily resulting in port congestion. Subsequently, the technology evolved from FC (Flow Control) to PFC (Priority-based Flow Control). However, for PFC technology, packet congestion, deadlocks, and a throughput of 0 may also occur in special scenarios.
[0003] As Figure 1 shown, it is a schematic diagram of the principle of the port-based FC scheme. Among them, the service flow is sent from NE (Network Element, i.e., network device) 1 to NE2. When the traffic sent by NE1 is greater than the traffic received by NE2, congestion packet loss will occur when the port buffer of NE2 is insufficient. At this time, NE2 sends a backpressure PAUSE frame to NE1, and NE1 pauses the traffic transmission. The problem with this scheme is that when the port is blocked, all service traffic cannot be sent.
[0004] As Figure 2 shown, it is a schematic diagram of the principle of the PFC scheme based on port priorities. Among them, the service is sent from NE1 to NE2. According to the 8 priorities of the port, 8 virtual channels are created, allowing a PAUSE frame to be sent to a single channel when a certain priority channel at the receiving end is congested. After receiving the PAUSE frame at the sending port, only the sending of a single channel is blocked, thus not affecting the forwarding of services on other channels. The problem with this scheme is that self-loop deadlocks are likely to occur.
[0005] As Figure 3 shown, it is a schematic diagram of the principle of self-loop self-locking that occurs after adopting the PFC scheme. Among them, Figure 3The scenario is a common VPLS model. When routing reconvergence or split-horizon issues lead to abnormal loop formation and congestion occurs at point A of NE3, a PAUSE signal is sent to NE2. After receiving it, NE2 pauses sending traffic flows to NE3. However, it will also keep receiving packets from NE4, causing itself to become congested. Then it sends a PAUSE to NE4, and then the backpressure propagates step by step. Finally, NE3 will also receive the backpressure signal. When a loop occurs, each site sends a PAUSE signal to the upstream device to stop it from sending traffic downstream, making the throughput of the entire network or part of the network zero and resulting in deadlock. Some hardware only supports deadlock detection for 2 virtual channels. For scenarios with multiple priority service channels, corresponding supplements need to be made at the software level.
[0006] The prior art uses continuously receiving a PAUSE frame for a period of time, no packet forwarding, and zero throughput to determine self-loop deadlock. This solution has certain limitations: the first is that the detection time is an empirical value and is not easy to determine; the second is that it can only judge that there is no forwarded traffic after receiving the PAUSE frame. It is possible that only the downstream site is blocked, and it cannot judge whether it is caused by deadlock and self-loop. Summary of the Invention
[0007] This application provides a method and system for preventing, detecting, and resolving PFC deadlock on VPLS, which can solve the technical problems in the prior art that VPLS is prone to self-loop deadlock and it is difficult to accurately judge whether self-loop deadlock occurs.
[0008] In the first aspect, an embodiment of this application provides a method for preventing, detecting, and resolving PFC deadlock on VPLS. The method includes:
[0009] After receiving service packets, if a network device has a port congestion, it sequentially generates a PAUSE' frame and a PAUSE frame, and sends the PAUSE' frame and the PAUSE frame along the reverse transmission path of the service packets to each upstream network device.
[0010] Each upstream network device adjusts the rate of sending service packets to the downstream network device according to the frequency of receiving the PAUSE' frame by itself. The receiving frequency of the PAUSE' frame is negatively correlated with the sending frequency of the service packets.
[0011] When each upstream network device receives the PAUSE frame, it continues to send service packets to the downstream network device until the network device receives the PAUSE frame sent by itself and the packet traffic on the transmission path is zero, and then it determines that a self-loop deadlock has occurred on the transmission path.
[0012] In combination with the first aspect, in an implementation, the PAUSE frame contains the MAC address of the network device that generates the PAUSE frame.
[0013] The network device determines whether there is a self-loop deadlock in the transmission path by judging whether the MAC address in the PAUSE frame is the same as its own MAC address.
[0014] Combined with the first aspect, in an embodiment, when the PAUSE frame is sent to the source node, destination node of the transmission path, or the network device that generates the PAUSE frame, the sending is stopped.
[0015] Combined with the first aspect, in an embodiment, both the PAUSE' frame and the PAUSE frame adopt the PFC frame format. The PAUSE' frame identifier is written in the Pad field of the PFC frame, and the MAC address is written in the Source address field of the PFC frame.
[0016] Combined with the first aspect, in an embodiment, the traffic volume of 0 for the packet includes no packet forwarding and a throughput of 0.
[0017] Combined with the first aspect, in an embodiment, the network device determines the sending frequency of the PAUSE' frame by detecting the congestion degree of the queue cache in the virtual channel. The congestion degree of the queue cache is positively correlated with the sending frequency of the PAUSE' frame.
[0018] In a second aspect, an embodiment of the present application provides a system for preventing, detecting, and resolving PFC deadlocks on VPLS. The system includes:
[0019] A judgment module, which is set on the network device and is used to control the network device to sequentially generate a PAUSE' frame and a PAUSE frame when it is judged that there is a port blockage after the network device receives service packets, and send the PAUSE' frame and the PAUSE frame to each upstream network device along the reverse transmission path of the service packets;
[0020] A rate limiting module, which is set on the network device and is used to control each upstream network device to adjust the rate of sending service packets to the downstream network device according to the frequency of receiving the PAUSE' frame by itself. The receiving frequency of the PAUSE' frame is negatively correlated with the sending frequency of the service packets;
[0021] A detection module, which is set on the network device and is used to control each upstream network device to continue sending service packets to the downstream network device when receiving the PAUSE frame, until the network device receives the PAUSE frame sent by itself and the traffic volume of the packets on the transmission path is 0, and then judge that there is a self-loop deadlock in the transmission path.
[0022] Combined with the second aspect, in an embodiment, the PAUSE frame contains the MAC address of the network device that generates the PAUSE frame;
[0023] The detection module of the network device determines whether there is a self-loop deadlock in the transmission path by judging whether the MAC address in the PAUSE frame is the same as its own MAC address.
[0024] Combined with the second aspect, in one implementation, the detection module is further configured to control the network device to stop sending PAUSE frames continuously when it detects that the PAUSE frame is sent to the source node, the destination node, or the network device that generates the PAUSE frame in the transmission path.
[0025] Combined with the second aspect, in one implementation, the judgment module is further configured to detect the congestion degree of the queue cache in the virtual channel to judge the sending frequency of the PAUSE' frame, and the congestion degree of the queue cache is positively correlated with the sending frequency of the PAUSE' frame.
[0026] The beneficial effects brought by the technical solutions provided in the embodiments of the present application include:
[0027] By constructing a PAUSE' frame to limit the speed of each upstream network device of the blocked port, preventing self-loop deadlocks, and by constructing a PAUSE frame and controlling the network device that receives the PAUSE frame to continue sending service packets to the downstream network device until the network device receives the PAUSE frame sent by itself and the packet traffic is 0, accurately judge whether there is a self-loop deadlock. Brief Description of the Drawings
[0028] Figure 1 It is a schematic diagram of the principle of the port-based FC scheme in the prior art;
[0029] Figure 2 It is a schematic diagram of the principle of the PFC scheme based on port priority in the prior art;
[0030] Figure 3 It is a schematic diagram of the principle of self-loop self-locking that occurs after adopting the PFC scheme in the prior art;
[0031] Figure 4 It is a schematic diagram of the principle of an embodiment of the method for preventing, detecting, and solving PFC deadlocks on the VPLS of the present application;
[0032] Figure 5 It is a schematic diagram of the frame format of the PFC frame in the present application;
[0033] Figure 6 It is a schematic diagram of the relationship between the congestion degree of the queue cache and the sending frequency of the PAUSE' frame in the present application;
[0034] Figure 7 It is a schematic diagram of the functional modules of an embodiment of the system for preventing, detecting, and solving PFC deadlocks on the VPLS of the present application. Detailed Embodiments
[0035] To enable those skilled in the art to better understand the solution of this application, the technical solutions in the embodiments of this application will be clearly and completely described below in conjunction with the accompanying drawings in the embodiments of this application. Obviously, the described embodiments are only a part of the embodiments of this application, rather than all the embodiments. Based on the embodiments in this application, all other embodiments obtained by those of ordinary skill in the art without creative efforts shall fall within the scope of protection of this application.
[0036] To make the objectives, technical solutions, and advantages of this application more clear, the embodiments of this application will be further described in detail below in conjunction with the accompanying drawings.
[0037] In a first aspect, an embodiment of this application provides a method for preventing, detecting, and resolving PFC deadlocks on VPLS.
[0038] In one embodiment, the method for preventing, detecting, and resolving PFC deadlocks on VPLS includes:
[0039] After receiving a service message, if a port of a network device becomes blocked, a PAUSE' frame and a PAUSE frame are generated in sequence, and the PAUSE' frame and the PAUSE frame are sent to each upstream network device along the reverse transmission path of the service message.
[0040] Each upstream network device adjusts the rate of sending service messages to downstream network devices according to the frequency of receiving the PAUSE' frame by itself, and the receiving frequency of the PAUSE' frame is negatively correlated with the sending frequency of the service message.
[0041] When each upstream network device receives a PAUSE frame, it continues to send the received PAUSE frame to the upstream network device without terminating it. Until this network device receives the PAUSE frame sent by itself and the traffic of messages on the transmission path is 0, it is determined that a self-loop deadlock has occurred in the transmission path.
[0042] In this embodiment, by constructing a PAUSE' frame to limit the speed of each upstream network device of the blocked port, self-loop deadlocks are prevented. By constructing a PAUSE frame and controlling the network device that receives the PAUSE frame to continue sending service messages to downstream network devices, and reversely forwarding the constructed PAUSE frame to upstream network devices until this network device receives the PAUSE frame sent by itself and the message traffic is 0, it is accurately determined whether a self-loop deadlock occurs.
[0043] In a specific embodiment, refer to Figure 4 , Figure 4 is a schematic diagram of the principle of an embodiment of the method for preventing, detecting, and resolving PFC deadlocks on VPLS of this application. As Figure 4As shown in the figure, in this embodiment, when congestion occurs at port A of NE3 but no PAUSE frame has been generated yet, a PAUSE' frame with the same message format and MAC header as the PAUSE frame but a non-zero payload (e.g., 0x0901) is generated simultaneously. The PAUSE' frame is used to notify the upstream node that this device is about to become congested and will send a PAUSE frame, and the upstream node needs to limit the speed. After receiving the PAUSE' frame, the upstream node performs traffic shaping and speed limiting on the egress to ensure that the downstream node has time and resources to process the upcoming congested messages.
[0044] Specifically, the upstream device detects the received PAUSE' frame in the task and adjusts the speed limit value according to the frequency of the PAUSE'. The higher the frequency of the received PAUSE' frame, the smaller the speed limit value and the lower the rate sent to the downstream device. The lower the frequency, the larger the speed limit value and the higher the sent rate. For example, if only one PAUSE' frame is received within a task detection period, the traffic is sent with a 5% decrease. If three PAUSE' frames are received, the traffic is sent with a 10% decrease. This is used to dynamically adjust the sending rate to prevent congestion and trigger the generation of the backpressure mechanism. This solution limits the rate at which the upstream node sends service messages to the downstream node based on the frequency of the received PAUSE' frame, preventing congestion at the downstream node to the greatest extent, thereby preventing the downstream node from triggering the backpressure mechanism and preventing the occurrence of PFC deadlocks.
[0045] After the PAUSE' frame is generated, the PAUSE frame is generated. After the upstream node receives the PAUSE frame, it does not terminate the received PAUSE frame this time, but continues to reverse-forward the frame to the upstream node. When congestion occurs at the upstream node's own port, it also generates a PAUSE' frame and a PAUSE frame and continues to send the PAUSE' frame and the PAUSE frame to the up-upstream device until this network device receives the PAUSE frame it generated and sent itself and determines that the message traffic on the current transmission path is 0, then it determines that a self-loop deadlock has occurred on the current transmission path. This solution uses the most realistic scenario simulation to determine whether self-loop and deadlock problems caused by the PFC technology occur, and there is basically no misjudgment.
[0046] After the device software generates a self-loop deadlock due to some uncertain reasons, the software performs a reporting process. At the same time, the congested messages in the cache are discarded, and network operation and maintenance personnel access to determine whether it is a physical network-induced self-loop or a software configuration-induced self-loop based on the reported device, port, and topology to solve the network fault.
[0047] In summary, this solution proposes a method for preventing, checking, and resolving deadlocks from a different perspective from other manufacturers to ensure network losslessness with the greatest possibility.
[0048] Further, in one embodiment, the above PAUSE frame includes the MAC address of the network device that generates the PAUSE frame.
[0049] The network device determines whether there is a self-loop deadlock in the transmission path by judging whether the MAC address in the PAUSE frame is the same as its own MAC address.
[0050] In this embodiment, if the MAC address of the backpressure frame received by the current network device is its own address, it means that the frame is sent by itself, and it is considered that there is a loop. By adding the MAC address to the PAUSE frame, misjudgment can be avoided.
[0051] Further, in one embodiment, when the above PAUSE frame is sent to the source node, destination node, or the network device that generates the PAUSE frame of the transmission path, the transmission is stopped.
[0052] In this embodiment, when the PAUSE frame is sent to the source node and destination node of the transmission path, if the source node does not extract its own MAC address from the PAUSE frame, it means that there is no self-loop deadlock at present, and the PAUSE frame is not continued to be sent. When the MAC extracted from the PAUSE frame is the MAC of its own network device, it means that a self-loop deadlock has occurred, and the PAUSE frame is not continued to be sent either.
[0053] Further, in one embodiment, referring to Figure 5 , Figure 5 is a schematic diagram of the frame format of the PFC frame in this application. Both the above PAUSE' frame and PAUSE frame adopt the PFC frame format. The PAUSE' frame identifier is written in the Pad field of the PFC frame, and the above MAC address is written in the Source address field of the PFC frame.
[0054] In this embodiment, the Source address field is the port MAC address for sending the PAUSE frame to the upstream device. According to the self-loop detection scheme, if the MAC address of the backpressure frame received by the current network device is its own address, it means that the frame is sent by itself, and it is considered that there is a loop.
[0055] The Pad field uses the PAUSE' frame generated in the loop prevention scheme. This field is non-zero, such as 0X0901, to distinguish the normal PAUSE frame and notify the upstream device.
[0056] Further, in one embodiment, the above message traffic being 0 includes no message forwarding and a throughput of 0.
[0057] In this embodiment, no packet forwarding means that network devices (such as routers and switches) do not perform forwarding operations, which may be caused by configuration errors, service shutdowns, or policy interceptions (such as ACL rules), resulting in the device not processing or discarding data packets. Throughput being 0 means that the amount of data successfully transmitted per unit time is zero, which may be caused by link failures, congestion, device failures, or physical layer problems (such as disconnections), resulting in data not reaching the destination.
[0058] To troubleshoot no packet forwarding, it is necessary to check the device configuration, routing table, ACL policy, and service status. To troubleshoot throughput being 0, it is necessary to check the physical connection, link status, interface statistics (such as error packets and packet loss rate), and network congestion.
[0059] Further, in one embodiment, referring to Figure 6 , Figure 6 is a schematic diagram showing the relationship between the congestion degree of the queue cache in the present application and the transmission frequency of PAUSE' frames. The above network device determines the transmission frequency of PAUSE' frames by detecting the congestion degree of the queue cache in the virtual channel, and the congestion degree of the queue cache is positively correlated with the transmission frequency of PAUSE' frames.
[0060] In this embodiment, the algorithm of this solution uses the trend of congestion to dynamically determine the frequency of sending PAUSE' frames, and then adjusts the packet rate of the upstream device sending to the downstream device. The downstream device detects the congestion degree of the queue cache in the virtual channel in a task to send PAUSE' frames. The greater the transmission frequency of PAUSE' frames, the greater the congestion of the downstream device and the more urgent the transmission. The upstream device detects the received PAUSE' frames in the task and adjusts the speed limit value according to the frequency of PAUSE'. The higher the frequency of receiving PAUSE' frames, the smaller the speed limit value and the smaller the rate sent to the downstream device. The lower the frequency, the greater the speed limit value and the greater the transmission rate. For example, in a task detection period, only one PAUSE' frame is received and the traffic is sent after a 5% decrease. If three PAUSE' frames are received, the traffic is sent after a 10% decrease. In this way, the transmission rate is dynamically adjusted to prevent congestion and trigger the generation of the backpressure mechanism. This solution controls the rate of sending PAUSE' frames to the upstream node by detecting the congestion trend of the cache at the downstream node, preventing congestion at the downstream node to the greatest extent, thereby preventing the downstream node from triggering the backpressure mechanism and preventing the occurrence of PFC deadlocks.
[0061] In summary, different from the existing PFC mechanism's processing of PAUSE frames, the existing mechanism is to terminate and backpressure level by level. This solution does not have the situation of terminating at the transit station and then following the service forwarding. When the sending device receives the MAC address of its own sent frame, it judges self-loop and deadlock, improving the detection accuracy.
[0062] By constructing another PAUSE' frame with the same format but different Payloads, frames with different frequencies are sent according to the congestion level of the downstream device. The upstream device determines the congestion level of the downstream device based on the frequency and dynamically adjusts the transmission rate to minimize the congestion of the downstream device to the greatest extent.
[0063] In a second aspect, an embodiment of the present application further provides a system for preventing, detecting, and resolving PFC deadlocks on VPLS.
[0064] In one embodiment, referring to Figure 7 , Figure 7 is a schematic diagram of the functional modules of an embodiment of the system for preventing, detecting, and resolving PFC deadlocks on VPLS of the present application. As Figure 7 shown, the system for preventing, detecting, and resolving PFC deadlocks on VPLS includes:
[0065] The judgment module 1, which is set on the network device, is used to control the network device to sequentially generate PAUSE' frames and PAUSE frames when it judges that there is a port blockage after receiving service packets, and send the PAUSE' frames and PAUSE frames along the reverse transmission path of the service packets to each upstream network device.
[0066] The rate-limiting module 2, which is set on the network device, is used to control each upstream network device to adjust the rate of sending service packets to the downstream network device according to the frequency of receiving PAUSE' frames by itself, and the receiving frequency of PAUSE' frames is negatively correlated with the sending frequency of service packets.
[0067] The detection module 3, which is set on the network device, is used to control each upstream network device to continue sending the received PAUSE frames to the upstream network device without terminating when receiving a PAUSE frame, until this network device receives the PAUSE frame sent by itself and the traffic of packets on the transmission path is 0, and then judge that a self-loop deadlock occurs in the transmission path.
[0068] In this embodiment, by constructing PAUSE' frames to limit the speed of each upstream network device of the blocked port, self-loop deadlocks are prevented. By constructing PAUSE frames and controlling the network device that receives a PAUSE frame to continue sending the received PAUSE frame to the upstream network device without terminating, until this network device receives the PAUSE frame sent by itself and the packet traffic is 0, it is accurately judged whether a self-loop deadlock occurs.
[0069] Specifically, the upstream device detects the received PAUSE’ frame during the task and adjusts the speed limit value according to the frequency of the PAUSE’ frame. The higher the frequency of the received PAUSE’ frame, the smaller the speed limit value, and the smaller the rate sent to the downstream device. The lower the frequency, the larger the speed limit value, and the larger the sent rate. For example, if only one PAUSE’ frame is received within a task detection period, the traffic is sent with a 5% decrease. If three PAUSE’ frames are received, the traffic is sent with a 10% decrease. In this way, the sending rate is dynamically adjusted to prevent congestion and trigger the generation of the backpressure mechanism. This solution limits the rate at which the upstream node sends service packets to the downstream node based on the frequency of the PAUSE’ frame received by the upstream node, preventing downstream node congestion to the greatest extent, thereby preventing the downstream node from triggering the backpressure mechanism and preventing the occurrence of PFC deadlocks.
[0070] After the PAUSE’ frame is generated, the PAUSE frame is generated. After the upstream node receives the PAUSE frame, it does not terminate the received PAUSE frame but forwards this PAUSE frame upstream. When the port of the upstream node itself is blocked, it also generates the PAUSE’ frame and the PAUSE frame and continues to send the PAUSE’ frame and the PAUSE frame to the upstream device until the network device receives the PAUSE frame generated and sent by itself and determines that the packet traffic on the current transmission path is 0, then it determines that a self-loop deadlock has occurred on the current transmission path. This solution uses the most realistic scenario simulation to determine whether there are self-loop and deadlock problems caused by the PFC technology, and there is basically no misjudgment.
[0071] After the device software generates a self-loop deadlock due to some uncertain reasons, the software reports it for processing. At the same time, the congested packets in the cache are discarded. The network operation and maintenance personnel access and determine whether it is a physical network that introduces a self-loop or a software configuration that causes a self-loop based on the reported device, port, and topology, and then solve the network fault.
[0072] Furthermore, in one embodiment, the above PAUSE frame includes the MAC address of the network device that generates the PAUSE frame.
[0073] The detection module 3 of the network device determines whether a self-loop deadlock has occurred in the transmission path by judging whether the MAC address in the PAUSE frame is the same as its own MAC address.
[0074] In this embodiment, if the MAC address of the received backpressure frame by the current network device is its own address, it means that the frame is sent by itself, then it is considered that there is a loop. By adding the MAC address to the PAUSE frame, misjudgment can be avoided.
[0075] Further, in one embodiment, the above detection module 3 is further configured to control the network device to stop sending PAUSE frames when it detects that a PAUSE frame is sent to the source node, destination node, or the network device that generates the PAUSE frame of the transmission path.
[0076] In this embodiment, when the PAUSE frame is sent to the source node and destination node of the transmission path, if the source node does not extract its own MAC address from the PAUSE frame, it indicates that there is no self-loop deadlock currently; when the MAC extracted from the PAUSE frame is the same as the MAC of its own device port, it indicates that a self-loop deadlock has occurred, and the PAUSE frame is no longer sent.
[0077] Further, in one embodiment, both the above PAUSE' frame and PAUSE frame adopt the PFC frame format. The PAUSE' frame identifier is written in the Pad field of the PFC frame, and the above MAC address is written in the Source address field of the PFC frame.
[0078] In this embodiment, the Source address field is the MAC address of the port that sends the Pause frame to the upstream device. According to the self-loop detection scheme, if the current network device receives a MAC address of a backpressure frame that is its own address, it means that the frame is sent by itself, and then a loop is considered to exist.
[0079] The Pad field uses the PAUSE' frame generated in the loop prevention scheme. This field is non-zero, such as 0X0901, and is used to distinguish normal PAUSE frames and notify upstream devices.
[0080] Further, in one embodiment, the above message traffic being 0 includes no message forwarding and a throughput of 0.
[0081] In this embodiment, no message forwarding means that network devices (such as routers, switches) do not perform forwarding operations, which may be caused by configuration errors, service shutdown, or policy interception (such as ACL rules) resulting in the device not processing or discarding data packets. A throughput of 0 means that the amount of data successfully transmitted per unit time is zero, which may be caused by link failures, congestion, device failures, or physical layer problems (such as disconnection) resulting in data not reaching the destination.
[0082] To troubleshoot no message forwarding, it is necessary to check device configurations, routing tables, ACL policies, and service status. To troubleshoot a throughput of 0, it is necessary to check physical connections, link status, interface statistics (such as error packets, packet loss rate), and network congestion.
[0083] Further, in one embodiment, with reference to Figure 6 , Figure 6This is a schematic diagram showing the relationship between the congestion level of the queue buffer and the transmission frequency of the PAUSE' frame in this application. The above-mentioned determination module 1 is further configured to detect the congestion level of the queue buffer in the virtual channel to determine the transmission frequency of the PAUSE' frame, and there is a positive correlation between the congestion level of the queue buffer and the transmission frequency of the PAUSE' frame.
[0084] In this embodiment, the algorithm of this solution uses the congestion trend to dynamically determine the frequency of sending the PAUSE' frame, and then adjusts the message sending rate of the upstream device to the downstream device. The downstream device detects the congestion level of the queue buffer in the virtual channel in a task to send the PAUSE' frame. The greater the transmission frequency of the PAUSE' frame, the greater the congestion of the downstream device and the more urgent the transmission. The upstream device detects the received PAUSE' frame in the task and adjusts the speed limit value according to the frequency of the PAUSE'. The higher the frequency of receiving the PAUSE' frame, the smaller the speed limit value and the smaller the rate sent to the downstream device. The lower the frequency, the larger the speed limit value and the larger the transmission rate. For example, only one PAUSE' frame is received within a task detection period, and the traffic is sent with a 5% decrease. If three PAUSE' frames are received, the traffic is sent with a 10% decrease. In this way, the transmission rate is dynamically adjusted to prevent congestion and trigger the generation of the backpressure mechanism. This solution controls the rate of sending the PAUSE' frame to the upstream node by detecting the congestion trend of the buffer at the downstream node, preventing congestion at the downstream node to the greatest extent, thereby preventing the downstream node from triggering the backpressure mechanism and preventing the occurrence of PFC deadlocks.
[0085] Among them, the functional implementation of each module in the above-mentioned system for preventing, detecting, and resolving PFC deadlocks on VPLS corresponds to each step in the method embodiment for preventing, detecting, and resolving PFC deadlocks on VPLS, and its functions and implementation processes will not be elaborated here one by one.
[0086] In summary, compared with other solutions, other solutions use PFC messages to terminate the backpressure mechanism level by level, receive a specified number of PAUSE frames during the detection period, and then superimpose the throughput of 0 to determine deadlocks. This solution uses the most intuitive method: the message sent by itself, without terminating at the intermediate site, and then receiving the message after following the service forwarding to determine network self-loop deadlocks.
[0087] At the same time, a PAUSE' frame is constructed to notify the upstream device to adjust the transmission rate to the downstream device and prevent the downstream device from being congested as little as possible. When the device has an upcoming congestion trend, the PAUSE' frame controls the frame sending frequency according to the device congestion level. After receiving the PAUSE' frame, the upstream node performs speed limiting. The upstream node uses a dynamic algorithm to set the transmission rate for the downstream node according to the frequency of the received frame, reducing the probability of congestion at the downstream node.
[0088] It should be noted that the serial numbers of the embodiments of the present application above are only for description and do not represent the superiority or inferiority of the embodiments.
[0089] The terms "including" and "having" and any variations thereof in the description of the specification, claims and drawings of the present application are intended to cover non-exclusive inclusion. For example, a process, method, system, product or device that includes a series of steps or units is not limited to the listed steps or units, but optionally further includes steps or units not listed, or optionally further includes other steps or units inherent to these processes, methods, products or devices. The descriptions of terms such as "first", "second" and "third" are used to distinguish different objects, etc., and do not represent a sequence, nor do they limit that "first", "second" and "third" are different types.
[0090] In the description of the embodiments of the present application, words such as "exemplary", "for example" or "for illustration" are used to indicate examples, illustrations or explanations. Any embodiment or design solution described as "exemplary", "for example" or "for illustration" in the embodiments of the present application should not be construed as being more preferred or having more advantages than other embodiments or design solutions. Rather, the use of words such as "exemplary", "for example" or "for illustration" is intended to present relevant concepts in a specific manner.
[0091] In the description of the embodiments of the present application, unless otherwise specified, " / " means "or". For example, A / B can mean A or B; "and / or" in the text is only a description of the association relationship between associated objects, indicating that three relationships can exist. For example, A and / or B can mean: A exists alone, A and B exist simultaneously, and B exists alone. In addition, in the description of the embodiments of the present application, "a plurality of" means two or more than two.
[0092] In some processes described in the embodiments of the present application, a plurality of operations or steps appear in a specific order. However, it should be understood that these operations or steps may not be executed in the order in which they appear in the embodiments of the present application or may be executed in parallel. The serial numbers of the operations are only used to distinguish different operations, and the serial numbers themselves do not represent any execution order. In addition, these processes may include more or fewer operations, and these operations or steps may be executed in sequence or in parallel, and these operations or steps may be combined.
[0093] Through the description of the above embodiments, those skilled in the art can clearly understand that the above-described example methods can be implemented by means of software plus a necessary general hardware platform. Of course, they can also be implemented by hardware, but in many cases the former is a better implementation. Based on such an understanding, the technical solution of the present application, in essence, or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk) as described above and includes several instructions for causing a terminal device to execute the methods described in various embodiments of the present application.
[0094] The above are only the preferred embodiments of the present application, and do not limit the patent scope of the present application accordingly. Any equivalent structure or equivalent process transformation made by using the content of the specification and drawings of the present application, or directly or indirectly applied in other related technical fields, shall be equally included in the patent protection scope of the present application.
Claims
1. A method for preventing, detecting, and resolving PFC deadlocks on VPLS, characterized in that The method includes: After receiving a service packet, if a port of a network device becomes congested, the network device sequentially generates a PAUSE' frame and a PAUSE frame, and sends the PAUSE' frame and the PAUSE frame along the reverse transmission path of the service packet to each upstream network device; Each upstream network device adjusts the rate of sending service packets to downstream network devices according to the frequency of receiving the PAUSE' frame by itself, and the frequency of receiving the PAUSE' frame is negatively correlated with the frequency of sending service packets; When each upstream network device receives the PAUSE frame, it continues to send service packets to downstream network devices until the network device receives the PAUSE frame sent by itself and the packet traffic on the transmission path is 0, and then determines that a self-loop deadlock occurs in the transmission path.
2. The method for preventing, detecting, and resolving PFC deadlocks on VPLS as claimed in claim 1, wherein The PAUSE frame contains the MAC address of the network device that generates the PAUSE frame; The network device determines whether a self-loop deadlock occurs in the transmission path by judging whether the MAC address in the PAUSE frame is the same as its own MAC address.
3. The method for preventing, detecting, and resolving PFC deadlocks on VPLS according to claim 1, characterized in that, When the PAUSE frame is sent to the source node, destination node, or the network device that generates the PAUSE frame of the transmission path, the network device stops sending it continuously.
4. The method for preventing, detecting, and resolving PFC deadlocks on VPLS according to claim 2, wherein Both the PAUSE' frame and the PAUSE frame adopt the PFC frame format. The PAUSE' frame identifier is written in the Pad field of the PFC frame, and the MAC address is written in the Source address field of the PFC frame.
5. The method for preventing, detecting, and resolving PFC deadlocks on VPLS according to claim 1, wherein The packet traffic being 0 includes no packet forwarding and a throughput of 0.
6. The method for preventing, detecting and resolving PFC deadlocks on VPLS according to claim 1, characterized in that The network device determines the sending frequency of the PAUSE' frame by detecting the congestion degree of the queue cache in the virtual channel, and the congestion degree of the queue cache is positively correlated with the sending frequency of the PAUSE' frame.
7. A system for preventing, detecting, and resolving PFC deadlocks on VPLS, characterized in that, The system includes: A judgment module, which is set on the network device and is used to judge that when a port of the network device becomes congested after receiving a service packet, control the network device to sequentially generate a PAUSE' frame and a PAUSE frame, and send the PAUSE' frame and the PAUSE frame along the reverse transmission path of the service packet to each upstream network device; A rate-limiting module, which is set on the network device and is used to control each upstream network device to adjust the rate of sending service packets to downstream network devices according to the frequency of receiving the PAUSE' frame by itself, and the frequency of receiving the PAUSE' frame is negatively correlated with the frequency of sending service packets; A detection module, which is set on the network device and is used to control each upstream network device to continue to send service packets to downstream network devices when receiving the PAUSE frame, until the network device receives the PAUSE frame sent by itself and the packet traffic on the transmission path is 0, and then determines that a self-loop deadlock occurs in the transmission path.
8. The system for preventing, detecting and resolving PFC deadlocks on VPLS according to claim 7, wherein The PAUSE frame contains the MAC address of the network device that generates the PAUSE frame; The detection module of the network device determines whether a self-loop deadlock occurs in the transmission path by judging whether the MAC address in the PAUSE frame is the same as its own MAC address.
9. The system for preventing, detecting and resolving PFC deadlocks in VPLS according to claim 7, wherein, The detection module is further used to control the network device to stop sending the PAUSE frame continuously when detecting that the PAUSE frame is sent to the source node, destination node, or the network device that generates the PAUSE frame of the transmission path.
10. The system for preventing, detecting, and resolving PFC deadlocks in VPLS according to claim 7, wherein, The determination module is further configured to detect the congestion degree of the queue cache in the virtual channel to determine the transmission frequency of the PAUSE' frame, and the congestion degree of the queue cache is positively correlated with the transmission frequency of the PAUSE' frame.