Method for interrupting session connection and related equipment

By calculating the processing priority in the BGP session connection and interrupting the target peer, the problem of over-limit failure caused by a large number of routes due to reception abnormalities is solved, ensuring the normal operation of the network.

CN119155237APending Publication Date: 2024-12-17BEIJING HUAWEI DIGITAL TECH
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202310715754.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-06-15
Publication Date
2024-12-17

AI Technical Summary

Technical Problem

When routers in existing networks receive abnormal large number of routes, they may lead to memory and CPU resource processing limits, resulting in over-limit failures, and thus cause large-scale network failures and service interruptions.

Method used

By obtaining the fuse condition factor values ​​of each peer in a BGP session connection, compute the processing priority, and interrupt the target peer that is most likely to cause an overlimit failure to prevent the failure from spreading and keep the network running normally.

Benefits of technology

It effectively prevents the spread of over-limit failures caused by abnormal large number of routes, maintains normal operation between network devices, and avoids large-scale failures and business interruptions.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119155237A_ABST
    Figure CN119155237A_ABST
Patent Text Reader

Abstract

The embodiment of the invention discloses a method for interrupting session connection and related equipment, which are used for interrupting a target peer which is most likely to cause an over-limit fault. In the application, a first network device firstly obtains values of N fusing condition factors of each of M peers, determines processing priorities of each of the M peers based on the values of the N fusing condition factors of each of the M peers to obtain M processing priorities, and determines target peers needing to be fused in the M peers based on the M processing priorities, the target peer is used for representing BGP session connection between the first network device and the second network device, and when the use condition of memory resources and / or computing resources of the first network device exceeds a corresponding preset proportion, the first network device can interrupt the target peer. Therefore, the diffusion of an over-limit fault caused by an abnormal large number of routes can be prevented at a relatively high probability, and the normal operation between the first network equipment and other network equipment except the second network equipment is kept.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of communications, and in particular to a method for interrupting a session connection and related equipment. Background Art

[0002] Border Gateway Protocol (BGP) is a dynamic routing protocol used between autonomous systems (AS). BGP is mainly used to select the best route between different ASs and control the propagation of routes.

[0003] Among them, the router that publishes BGP messages (carrying routes) is called a BGP speaker. The BGP speaker receives or generates new routes and publishes them to other BGP speakers. When a BGP speaker receives a new route sent by another router, if the new route is better than the currently known route or there is no known route at present, the new route will be published to all other BGP speakers.

[0004] In existing networks, if a router receives an abnormally large number of routes, it may reach the processing limit of resources such as memory and central processing unit (CPU), that is, an over-limit failure, which may cause the router to be unable to forward business traffic. In addition, the router will publish an abnormally large number of routes, thereby impacting all routers on the network and causing secondary network disasters such as large-scale failures. The route transmission and processing of a large number of routers may fail, and even all services on the network may be interrupted. Summary of the invention

[0005] The embodiment of the present application provides a method and related device for interrupting a session connection, which is used to interrupt a target peer that is most likely to cause an over-limit failure.

[0006] A first aspect of the present application provides a method for interrupting a session connection, in which a first network device first obtains the value of N fuse condition factors of each peer among M peers, where peer is used to represent a Border Gateway Protocol BGP session connection between the first network device and another network device, and determines the processing priority of each peer among the M peers based on the value of the N fuse condition factors of each peer among the M peers, obtains M processing priorities, and determines a target peer among the M peers that needs to be fused based on the M processing priorities, where the target peer is used to represent the BGP session connection between the first network device and the second network device. Then, when the usage of memory resources and / or computing resources of the first network device exceeds a corresponding preset ratio, the first network device can interrupt the target peer, thereby preventing the spread of over-limit faults caused by an abnormally large number of routes with a high probability, and maintaining normal operation between the first network device and other network devices other than the second network device.

[0007] In some possible implementations, the N fuse condition factors include one or more of the proportion of non-preferred routes of the corresponding peer, the last route update time, the route update speed, the establishment time, the upward count, the total number of published routes, and the security attack risk, so that the first network device can determine the target peer that is most likely to cause an over-limit failure based on the N fuse condition factors.

[0008] In some possible implementations, the first network device sorts the values ​​of each fuse condition factor in the N fuse conditions of the M peers to obtain Ranking CF nm, where n = 1, 2, 3, ..., N, and m = 1, 2, 3, ..., M, where Ranking CF nm represents the ranking of the values ​​of the mth fuse condition factor in the N fuse conditions of the M peers, and the higher the ranking, the more priority processing is required. Then, the first network device can calculate the processing priority X(m) of each peer in the M peers by the following formula:

[0009] X(m)=(RankingCF1-m*Weight1)+(RankingCF2-m*Weight2)+(RankingCF3-m*Weight3)+(RankingCF4-m*Weight4)+…+(RankingCF Nm*Weight N)

[0010] Among them, Weight n represents the preset weight corresponding to the nth fuse condition factor among the N fuse condition factors, and the processing priority with a smaller value among the M processing priorities has a higher priority, so that the first network device implements the step of determining the target peer that is most likely to cause an over-limit failure based on the N fuse condition factors.

[0011] In some possible implementations, before the first network device interrupts the target peer, the first network device may stop learning the routes published by the second network device and / or stop publishing routes to the second network device, thereby causing the target peer to enter an elastic fuse holding state.

[0012] In some possible implementations, the first network device may send a first notification message to the second network device, wherein the first notification message is used to indicate that the target peer is in an elastic fuse holding state, and the elastic fuse holding state is used to indicate that the first network device stops learning routes published by the second network device, and / or the first network device stops publishing routes to the second network device, so that the second network device saves bandwidth resources and computing resources.

[0013] In some possible implementations, the first network device sends a second notification message to the second network device, and the second notification message is used to indicate a first preset duration that the target peer is in the elastic fuse holding state, so that the second network device can determine the duration that the first network device is in the elastic fuse holding state.

[0014] In some possible implementations, after the first network device interrupts the target peer, the first network device may send a third notification message to the second network device, wherein the third notification message is used to indicate that the target peer is in a blown state, and the blown state is used to indicate that the first network device has interrupted the target peer, so that the second network device can determine that the first network device is in a blown state.

[0015] In some possible implementations, the first network device sends a fourth notification message to the second network device, and the fourth notification message is used to indicate a second preset duration that the target peer is in the blown state, so that the second network device can determine the duration that the first network device is in the blown state.

[0016] In some possible implementations, after the first network device interrupts the target peer for the second preset time period, the first network device restarts the target peer, so that the target peer can be repaired and restarted within the second preset time period.

[0017] In some possible implementations, the first network device sends a fifth notification message to the second network device, where the fifth notification message is used to indicate that the target peer has been restarted.

[0018] A second aspect of the present application provides a network device, used as a first network device, and configured to execute the method executed by the first network device in any one of the aforementioned first aspects.

[0019] A third aspect of the present application provides a computer-readable storage medium, wherein the computer-readable storage medium stores instructions, which, when executed on a computer, enable the computer to execute any of the methods in the first, second, or third aspects above.

[0020] A fourth aspect of the present application provides a computer program product, which includes computer execution instructions, which are stored in a computer-readable storage medium; at least one processor of a device can read the computer execution instructions from the computer-readable storage medium, and at least one processor executes the computer execution instructions so that the device implements the method provided by the above-mentioned first aspect or any possible implementation of the first aspect.

[0021] In a fifth aspect, the present application provides a communication device, which may include at least one processor, a memory, and a communication interface. At least one processor is coupled to the memory and the communication interface. The memory is used to store instructions, at least one processor is used to execute the instructions, and the communication interface is used to communicate with other communication devices under the control of at least one processor. When the instructions are executed by at least one processor, the at least one processor executes the method in the first aspect or any possible implementation of the first aspect.

[0022] A sixth aspect of the present application provides a chip system, which includes a processor for supporting the implementation of the functions involved in the above-mentioned first aspect or any possible implementation method of the first aspect.

[0023] In a possible design, the chip system may also include a memory, which is used to store necessary program instructions and data. The chip system may be composed of a chip, or may include a chip and other discrete devices.

[0024] Among them, the technical effects brought about by the second to sixth aspects or any possible implementation methods thereof can refer to the technical effects brought about by the first aspect or different possible implementation methods of the first aspect, and will not be repeated here. BRIEF DESCRIPTION OF THE DRAWINGS

[0025] Figure 1 A schematic diagram of the structure of a communication system provided in an embodiment of the present application;

[0026] Figure 2-1 A flowchart of a method for interrupting a session connection provided in an embodiment of the present application;

[0027] Figure 2-2 A schematic diagram of determining a target peer in a communication system provided by an embodiment of the present application;

[0028] Figure 2-3 This is a schematic diagram of the composition of a notification type message in this application;

[0029] Figure 3 A schematic diagram of the structure of a network device provided in an embodiment of the present application;

[0030] Figure 4 A schematic diagram of the structure of a communication device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0031] The embodiments of the present application provide a method and related devices for interrupting a session connection, which are used to interrupt a peer that is most likely to publish an abnormally large number of routes.

[0032] The embodiments of the present application are described below in conjunction with the accompanying drawings.

[0033] The terms "first", "second", etc. in the specification and claims of the present application and the above-mentioned drawings are used to distinguish similar objects, and need not be used to describe a specific order or sequential order. It should be understood that the terms used in this way can be interchangeable under appropriate circumstances, which is only to describe the distinction mode adopted by the objects of the same attributes when describing in the embodiments of the present application. In addition, the terms "including" and "having" and any of their variations are intended to cover non-exclusive inclusions, so that the process, method, system, product or equipment comprising a series of units need not be limited to those units, but may include other units that are not clearly listed or inherent to these processes, methods, products or equipment.

[0034] An embodiment of the present application provides a communication system, which includes multiple ASs, each AS includes multiple network devices, and the network devices may be routers or route reflectors.

[0035] For example, see Figure 1As shown, a communication system 100 provided in an embodiment of the present application is provided, and the communication system 100 includes AS1, AS2, AS3 and AS100, wherein AS1 includes R1 and R2, AS2 includes R3 and R4, AS3 includes R5, and AS100 includes R11, R12, R13, R14, R15, R16, RR1, and RR2. Among them, R1, R2, R3, R4, R5, R11, R12, R13, R14, R15, and R16 are all routers, and RR1 and RR2 are all route reflectors.

[0036] Among them, a router is a hardware device that connects two or more user devices and acts as a gateway between user devices. A router is a dedicated intelligent network device that can read the destination address in a message and decide how to transmit the message according to the destination address. A router can understand different protocols, such as the Ethernet protocol used in a local area network, the transmission control protocol / internet protocol (TCP / IP) protocol used in the Internet, etc. In this way, a router can analyze the destination addresses of messages from various types of networks, convert non-TCP / IP addresses into TCP / IP addresses, or vice versa; and then transmit each message to the destination address along the best transmission path according to the routing algorithm, so a router can connect a non-TCP / IP network to the Internet.

[0037] In the Internet, an AS is a network unit that has the right to autonomously decide which routing protocols should be used in the system. An AS can be a simple network or include one or more network groups, such as a university, an enterprise, or an individual company. An AS includes one or more routers. All routers in an AS must be interconnected, run the same routing protocol, and be assigned the same autonomous system number. The connection between ASs requires the use of external routing protocols, such as the Border Gateway Protocol (BGP).

[0038] BGP is a dynamic routing protocol used between ASes. BGP is mainly used to select the best route between different ASes and control the propagation of routes. Among them, the router that publishes BGP messages (carrying routes) is called a BGP speaker. The BGP speaker receives or generates new routes and publishes them to other BGP speakers. When a BGP speaker receives a new route sent from another router, if the new route is better than the currently known route or there is no known route at present, the new route will be published to all other BGP speakers. Among them, BGP speakers that exchange BGP messages with each other are called peers, and two BGP speakers that are peers are called a peer.

[0039] BGP is the main routing protocol for current network communications. Routes between different provinces and countries mostly rely on BGP, so BGP carries the propagation and control of millions of routes. In the existing network, BGP is deployed in important locations of the network, such as the bearer network, backbone core, international gateways and other core network nodes. If BGP fails when propagating or controlling routes, it will have a serious impact on the existing network.

[0040] To ensure connectivity between peers, a fully connected relationship needs to be established between peers. For example, if there are n routers in an AS, the number of connections that should be established is n(n-1) / 2. When there are many peers, the consumption of network resources and CPU is very large. Therefore, a route reflector can be used to solve this problem. In an AS, one of the routers is used as a route reflector (RR), and other routers are used as clients to establish connections with the route reflector. The route reflector transmits (reflects) routing information between clients, and there is no need to establish direct connections between clients.

[0041] In the existing network, if a router receives an abnormally large number of routes, it may reach the processing limit of resources such as memory and central processing unit (CPU), which may cause the router to be unable to forward business traffic. In addition, the router will publish an abnormally large number of routes, thereby impacting all routers on the network and causing secondary network disasters such as large-scale failures. The route transmission and processing of a large number of routers will fail, and even all services on the network will be interrupted.

[0042] In the present application, the first network device first obtains the value of N fuse condition factors of each peer among M peers, where peer is used to represent a Border Gateway Protocol BGP session connection between the first network device and another network device, and determines the processing priority of each peer among the M peers based on the value of the N fuse condition factors of each peer among the M peers, obtains M processing priorities, and determines the target peer among the M peers that needs to be fused based on the M processing priorities, where the target peer is used to represent the BGP session connection between the first network device and the second network device. Then, when the usage of memory resources and / or computing resources of the first network device exceeds the corresponding preset ratio, the first network device can interrupt the target peer, thereby preventing the spread of over-limit faults caused by an abnormally large number of routes, and maintaining normal operation between the first network device and other network devices other than the second network device.

[0043] The above embodiment introduces the communication system provided by the present application. Next, a method for interrupting a session connection based on the communication system is introduced. Figure 2-1 As shown, a method for interrupting a session connection provided in an embodiment of the present application mainly includes the following steps:

[0044] 201. A first network device receives multiple routes.

[0045] For example, Figure 1 As shown, R11 in AS100 can receive one or more routes sent from R1 and R2 in AS1, one or more routes sent from R3 and R4 in AS2, and one or more routes sent from R5 in AS3. Figure 1 As shown, R12 in AS100 can receive one or more routes sent from R1 and R2 in AS1, one or more routes sent from R3 and R4 in AS2, and one or more routes sent from R5 in AS3. Figure 1 As shown, R1 or R2 in AS1, R3 or R4 in AS2, and R5 in AS3 may also receive one or more routes sent by R11 and R12 in AS100. In the embodiment of the present application, R11 is taken as the first network device for example.

[0046] It should be noted that after the first network device receives multiple routes, the multiple routes can be written into the routing table. The routing table is a spreadsheet or database-like stored in the router. The routing table stores the path to a specific network address. The routing table contains the topology information around the network. The main purpose of establishing the routing table is to implement routing protocols and static route selection.

[0047] 202. The first network device determines, based on multiple routes, that the first network device is in an over-limit state.

[0048] In some possible implementations, if the first network device receives an abnormally large number of routes, the processing limit of the memory, CPU and other resources of the first network device may be reached, that is, the first network device will be in an over-limit state. Exemplarily, the first network device will monitor the usage status of its own memory and CPU in real time, and the usage status can be presented in the form of percentage. For example, the memory usage status is 50%, and the CPU usage status is 60%. In some possible implementations, when the memory usage status exceeds the first preset ratio, and / or the CPU usage status exceeds the second preset ratio, the first network device is determined to be in an over-limit state. For example, the first preset ratio is 80% and the second preset ratio is 90%. Then when the memory usage status exceeds 80%, and / or the CPU usage status exceeds 90%, it is determined that the first network device is in an over-limit state.

[0049] 203. The first network device calculates the processing priority of each peer among the M peers to obtain M processing priorities.

[0050] In the embodiment of the present application, two network devices that are peers to each other are referred to as a peer. Figure 1 As shown, R1 and R11 are peers to each other, and the connection between R1 and R11 is called a peer. In the embodiment of the present application, the first network device can be associated with multiple peers of the first network device. For example, the multiple peers that R11 can determine include: R1-R11, R2-R11, R3-R11, R4-R11, R5-R11, RR1-R11, RR2-R11.

[0051] In an embodiment of the present application, when the first network device is in an over-limit state, the first network device may process at least one of the M peers, wherein a peer with a higher processing priority is processed first, where M is a positive integer. For example, the M peers include peer1 and peer2, wherein the processing priority of peer1 is X1, and the processing priority of peer2 is X2, and X1 is higher than X2, then the first network device preferentially processes peer1 corresponding to X1.

[0052] In some possible implementations, for the processing priority of a peer, the first network device can obtain the values ​​of N elastic fuse condition factors of the peer, and calculate based on N preset weights to obtain the processing priority of the peer, where N is a positive integer and the N weights correspond one-to-one to the N elastic fuse condition factors.

[0053] In some possible implementations, the N elastic fuse condition factors may be as shown in Table 1:

[0054] Table 1

[0055]

[0056] In some possible implementations, the first network device may obtain the value of N fuse condition factors of each of the M peers, and then sort the values ​​of the fuse condition factors of the M peers.

[0057] For example, after obtaining the value of the proportion of the number of non-preferred routes (CF1) of each peer among M peers, CF1-1, CF1-2, CF1-3, ..., CF1-M are obtained, and then CF1-1, CF1-2, CF1-3, ..., CF1-M are sorted to obtain RankingCF1-1, Ranking CF1-2, Ranking CF1-3, ..., Ranking CF1-M, wherein Ranking CF1-1 represents the sorting of CF1-1 in CF1-1, CF1-2, CF1-3, ..., CF1-M from large to small, Ranking CF1-2 represents the sorting of CF1-2 in CF1-1, CF1-2, CF1-3, ..., CF1-M from large to small, ..., Ranking CF1-M represents the sorting of CF1-2 in CF1-1, CF1-2, CF1-3, ..., CF1-M from large to small.

[0058] Similarly, after obtaining the value of the last routing update time (CF2) of each of the M peers, CF2-1, CF2-2, CF2-3, ..., CF2-M are obtained, and then CF2-1, CF2-2, CF2-3, ..., CF2-M are sorted to obtain RankingCF2-1, Ranking CF2-2, Ranking CF2-3, ..., Ranking CF2-M, where Ranking CF2-1 represents the ordering of CF2-1 in CF2-1, CF2-2, CF2-3, ..., CF2-M from large to small, Ranking CF2-2 represents the ordering of CF2-2 in CF2-1, CF2-2, CF2-3, ..., CF2-M from large to small, ..., Ranking CF2-M represents the ordering of CF2-2 in CF2-1, CF2-2, CF2-3, ..., CF2-M from large to small.

[0059] …

[0060] Similarly, after obtaining the value of the last routing update time (CF N) of each of the M peers, CF N-1, CF N-2, CF N-3, ..., CF NM are obtained, and then CF N-1, CF N-2, CF N-3, ..., CF NM are sorted to obtain Ranking CF N-1, Ranking CF N-2, Ranking CF N-3, ..., Ranking CF NM, where RankingCF N-1 represents the ordering of CF N-1 in CF N-1, CF N-2, CF N-3, ..., CF NM from large to small, Ranking CFN-2 represents the ordering of CF N-2 in CF N-1, CF N-2, CF N-3, ..., CF NM from large to small, ..., Ranking CFN-M represents the ordering of CF N-2 in CF N-1, CF N-2, CF N-3, ..., CF NM from large to small.

[0061] Next, the first network device can calculate the processing priority X(m) of the mth peer by the following formula: X(m) = (Ranking CF1-m*Weight 1) + (Ranking CF2-m*Weight 2) + (Ranking CF3-m*Weight

[0062] 3)+(Ranking CF4-m*Weight 4)+…+(Ranking CF Nm*Weight N)

[0063] Among them, Weight 1, Weight 2, ..., Weight N represent the weights corresponding to CF 1-m, CF 2-m, ..., CF Nm, respectively, where m = 1, 2, ..., M. It should be noted that Weight 1, Weight 2, ..., Weight N can be preset. In some possible implementations, the values ​​of Weight 1, Weight 2, ..., Weight N are decimals between 0 and 1. In some possible implementations, Weight 1+Weight 2+Weight 3+ ...+Weight N=1. No limitation is made here.

[0064] Exemplarily, as shown in Table 2, the ranking method and corresponding weights of various fuse condition factors are shown.

[0065] Table 2

[0066]

[0067] Exemplarily, if the M peers include peer1, peer2 and peer3, the first network device determines that the values ​​of the N fuse condition factors of peer1 are: CF1-1, CF2-1, CF3-1, ..., CF N-1, respectively; the first network device determines that the values ​​of the N fuse condition factors of peer2 are: CF1-2, CF2-2, CF3-2, ..., CF N-2, respectively; the first network device determines that the values ​​of the N fuse condition factors of peer3 are: CF1-3, CF2-3, CF3-3, ..., CFN-3, respectively.

[0068] Then, the first network device can sort CF1-1, CF1-2, and CF1-3 to obtain Ranking CF1-1, Ranking CF1-2, and Ranking CF1-3; the first network device can sort CF2-1, CF2-2, and CF2-3 to obtain Ranking CF2-1, Ranking CF2-2, and Ranking CF2-3; the first network device can sort CF3-1, CF3-2, and CF3-3 to obtain Ranking CF3-1, Ranking CF3-2, and Ranking CF3-3.

[0069] For example, if CF1-1>CF1-2>CF1-3, then Ranking CF1-1=1, Ranking CF1-2=2, and Ranking CF1-3=3.

[0070] If CF2-3>CF2-2>CF2-1, then Ranking CF2-1=3, Ranking CF2-2=2, Ranking CF2-3=1.

[0071] If CF3-2>CF3-1>CF3-3, then Ranking CF3-1=2, Ranking CF3-2=1, Ranking CF3-3=3.

[0072] In an embodiment of the present application, the first network device can obtain the processing priority of each peer among the M peers through the above calculation, and obtain M processing priorities. The M processing priorities can be expressed as X(1), X(2), X(3),..., where the smaller the value of the processing priority, the higher the processing priority of the corresponding peer.

[0073] 204. The first network device determines a target peer that needs to be fuse-broken based on the M processing priorities, where the target peer represents a connection between the first network device and the second network device.

[0074] Exemplarily, the M peers include peer1, peer2, and peer3. Among them, X(1) represents the processing priority of peer1, X(2) represents the processing priority of peer2, and X(3) represents the processing priority of peer3. For example, if X(1) < X(2) < X(3), then the processing priority of peer1 is the highest, the processing priority of peer2 is the second highest, and the processing priority of peer3 is the lowest. Among peer1, peer2, and peer3, peer1 should be processed first, then peer2, and finally peer3.

[0075] In some possible implementation manners, the first network device may determine one peer with the highest priority based on the M processing priorities as the target peer. Exemplarily, if X(1) < X(2) < X(3), then peer1 is determined as the target peer.

[0076] In some possible implementation manners, the first network device may determine several peers with the highest priorities based on the M processing priorities as the target peers. Exemplarily, if X(1) < X(2) < X(3), then peer1 and peer2 are determined as the target peers.

[0077] In some possible implementation manners, the first network device may determine one peer with a priority higher than a preset value (that is, the value of the processing priority is lower than the preset value) based on the M processing priorities as the target peer. Exemplarily, if X(1) < X(2) < X(3), and the values of X(1) and X(2) are both less than the preset value, and the value of X(3) is greater than the preset value, then peer1 and peer2 are determined as the target peers.

[0078] Exemplarily, as Figure 2-2 shown, when R11 receives an abnormally large number of routes from R1 and R2, it will forward the abnormally large number of routes to RR1 and RR2. Then RR1 forwards the abnormally large number of routes from R11 to R3 - R5, R12 - R16, and RR1 forwards the abnormally large number of routes from R12 to R3 - R5, R11, R13 - R16. RR2 forwards the abnormally large number of routes from R11 to R3 - R5, R12 - R16, and RR2 forwards the abnormally large number of routes from R12 to R3 - R5, R11, R13 - R16, thus impacting all routers on AS2, AS3, and AS100, generating a secondary disaster of a large-scale network failure. The route transmission and processing of a large number of routers will fail, and even all services on the network will be interrupted.

[0079] Then, R11 can determine through the above steps 201-204 that the target peer that needs to be fuse-broken is the peer between R1 and RR1, or the peer between R2 and R11; R12 can determine through the above steps 201-204 that the target peer that needs to be fuse-broken is the peer between R1 and R12, or the peer between R2 and R12. This prevents R11 from transferring an abnormally large number of routes to R3-R5, RR1, RR2, R12-R16, and also prevents R11 from transferring an abnormally large number of routes to R3-R5, RR1, RR2, R11, R13-R16.

[0080] 205. The first network device stops learning the routes published by the second network device.

[0081] In an embodiment of the present application, after the first network device determines the target peer to be processed preferentially, the first network device can set the target peer to an elastic fuse hold state. After the first network device sets the target peer to an elastic fuse hold state, the first network device stops learning routes from the second network device, but the first network device does not interrupt the target peer, that is, the first network device and the second network device continue to transmit data packets. In some possible implementations, after setting the target peer to an elastic fuse hold state, the first network device can also stop publishing new routes to the second network device. This is not limited here.

[0082] In some possible implementations, the first network device may place the target peer in a resilience hold state within a first preset time period, where the first preset time period may also be referred to as a resilience hold-time.

[0083] In some possible implementations, after the first network device enters the elastic fuse holding state, within a first preset time period, if the over-limit state of the first network device is released, the first network device can release the elastic fuse holding state, that is, the first network device resumes learning the routes published by the second network device, or the first network device resumes learning the routes published by the second network device and the first network device resumes publishing new routes to the second network device.

[0084] In some possible implementations, after the first network device enters the elastic fuse holding state, at the end of the first preset time period, if the over-limit state of the first network device is still not resolved, the first network device may execute step 208 .

[0085] In some possible implementations, the first preset duration may be obtained through configuration.

[0086] 206. The first network device sends a first notification message to the second network device, where the first notification message is used to indicate that the target peer is in an elastic fuse hold state.

[0087] In some possible implementations, after the first network device sets the target peer to the elastic fuse holding state, or before the first network device is ready to set the target peer to the elastic fuse holding state, the first network device may send a first notification message to the second network device, and the first notification message is used to indicate that the target peer is in the elastic fuse holding state.

[0088] In some possible implementations, the first notification message may be a message of the notification type (NOTIFICATION) indexed in RFC4271 of the BGP protocol. Figure 2-3 As shown, the first notification message may include data (variable), error code and error subcode. The value of the data is represented by 16 bits (2 bytes), the value of the error code is represented by 8 bits (1 byte), and the value of the error subcode is represented by 8 bits (1 byte).

[0089] As shown in Table 3, when the to be defined (TBD) value of the error code is 8 (ie, 00001000), the symbolic name represented is elastic fuse, that is, the first notification message indicates the elastic fuse state of the target peer.

[0090] Table 3

[0091] Error Code Symbolic Name TBD=8 Flexible fuse

[0092] As shown in Table 4, the error subcode can take values ​​of 1 / 2 / 3 / 4 / 5 (i.e., 00000001, 00000010, 00000011, 00000100, 00000101, respectively), which are used to indicate the different states of the target peer. When the error subcode is 1, the symbol name represented is resilience hold state, indicating that the first notification message is used to indicate that the target peer is in resilience hold state. In some possible implementations, when the error subcode is 1, the data in the first notification message can be true (TRUE) or false (FALSE), wherein TRUE indicates that the first notification message is used to indicate that the target peer is in resilience hold state, and FALSE indicates that the first notification message is used to indicate that the resilience hold state of the target peer has ended.

[0093] Table 4

[0094]

[0095] 207. The first network device sends a second notification message to the second network device, where the second notification message includes a resilience hold timer for indicating the target peer.

[0096] In some possible implementations, after the first network device sends the first notification message to the second network device, the first network device may continue to send a second notification message to the second network device, and the second notification message includes a resilience hold timer (resilience hold timer) for indicating the target peer, and the resilience hold timer (resilience hold timer) is used to indicate the fuse hold time (resilience hold-time) of the target peer, that is, the first preset duration.

[0097] In some possible implementations, the second notification message may be a message of the notification type (NOTIFICATION) indexed in RFC4271 of the BGP protocol. Figure 2-3 As shown, the second notification message may include data (variable), error code and error subcode. The value of the data is represented by 16 bits (2 bytes), the value of the error code is represented by 8 bits (1 byte), and the value of the error subcode is represented by 8 bits (1 byte).

[0098] As shown in Table 3, when the to be defined (TBD) value of the error code is 8 (ie, 00001000), the symbolic name represented is elastic fuse, that is, the second notification message indicates the elastic fuse state of the target peer.

[0099] As shown in Table 4, the error subcode can take values ​​of 1 / 2 / 3 / 4 / 5 (i.e., 00000001, 00000010, 00000011, 00000100, 00000101, respectively), which are used to indicate the different states of the target peer, wherein, when the error subcode is 2, the symbolic name represented is resilience hold timer, indicating that the second notification message is used to indicate that the target peer maintains a resilience fuse hold state. In some possible implementations, the data in the second notification message may be a time in seconds, which is used to indicate a first preset time, i.e., to indicate to the second network device that the target peer will be in a resilience fuse hold state within the first preset time.

[0100] 208. The second network device stops publishing routes to the first network device.

[0101] In an embodiment of the present application, after the second network device receives the first notification message, the second network device can obtain the value of the error code and the value of the error subcode in the first notification message to determine that the first notification message indicates that the first network device is in an elastic fuse holding state.

[0102] In some possible implementations, after determining that the first network device is in an elastic fuse holding state, the second network device may stop publishing routes to the first network device. In some possible implementations, after determining that the first network device is in an elastic fuse holding state, the second network device may also stop learning routes published by the second network device. This is not limited here.

[0103] In some possible implementations, after receiving the second notification message, the second network device can determine the resilience hold-time indicating the target peer based on the second notification message, and the resilience hold-time is the first preset time length. The second network device then stops publishing routes to the first network device within the first preset time length, and continues publishing routes to the first network device after the first preset time length expires.

[0104] In some possible implementations, after receiving the second notification message, the second network device can determine the resilience hold-time indicating the target peer based on the second notification message, and the resilience hold-time is the first preset time length. The second network device then stops learning the routes published by the first network device within the first preset time length, and learns the routes published by the first network device after the first preset time length expires.

[0105] 209. The first network device interrupts the target peer.

[0106] In some possible implementations, after the first network device determines a target peer to be processed with priority, the first network device may set the target peer to a blown state.

[0107] In some possible implementations, after the first network device enters the elastic fuse holding state, at the end of the first preset time period, if the over-limit state of the first network device is still not resolved, the first network device can set the target peer to the fuse state.

[0108] In some possible implementations, after the first network device enters the elastic fuse holding state, at the end of the first preset time, if the over-limit state of the first network device has not been resolved and is currently within the disconnection time range (disconnection-time-range), the first network device can set the target peer to the fuse state. In some possible implementations, the disconnection time range (disconnection-time-range) can be obtained by configuration. For example, the preset time period can be a network idle period, such as 00:00-6:00 late at night.

[0109] In an embodiment of the present application, after the first network device sets the target peer to the blown state, the first network device interrupts the target peer, that is, the first network device does not transmit data packets to the second network device, nor does it receive data packets transmitted from the second network device, that is, the first network device disconnects the BGP link between the first network device and the second network device.

[0110] 210. The first network device sends a third notification message to the second network device, where the third notification message is used to indicate that the target peer is in a blown state.

[0111] In some possible implementations, after the first network device sets the target peer to a blown state, or before the first network device is ready to set the target peer to a blown state, the first network device may send a third notification message to the second network device, where the third notification message is used to indicate that the target peer is in a blown state.

[0112] In some possible implementations, the third notification message may be a message of the notification type (NOTIFICATION) indexed in RFC4271 of the BGP protocol. Figure 2-3As shown, the third notification message may include data (variable), error code and error subcode. The value of the data is represented by 16 bits (2 bytes), the value of the error code is represented by 8 bits (1 byte), and the value of the error subcode is represented by 8 bits (1 byte).

[0113] As shown in Table 3, when the to be defined (TBD) value of the error code is 8 (ie, 00001000), the symbolic name represented is elastic fuse, that is, the third notification message is used to indicate the elastic fuse state of the target peer.

[0114] As shown in Table 4, the error subcode can take values ​​1 / 2 / 3 / 4 / 5 (i.e., 00000001, 00000010, 00000011, 00000100, 00000101, respectively), which are used to indicate the different states of the target peer. Among them, when the error subcode is 3, the symbol name represented is resilience breaker, indicating that the third notification message indicates that the target peer is in a breaker state.

[0115] In some possible implementations, the data (data) in the third notification message may be true (TRUE) or false (FALSE), wherein TRUE indicates that the third notification message is used to indicate that the target peer is in a blown state, and FALSE indicates that the third notification message is used to indicate that the blown state of the target peer has ended.

[0116] 211. The first network device sends a fourth notification message to the second network device, where the fourth notification message is used to indicate a breaker hold-time of the target peer.

[0117] In some possible implementations, after the first network device sends the first notification message to the second network device, the first network device may continue to send a fourth notification message to the second network device, where the fourth notification message is used to indicate a breaker hold-time of the target peer.

[0118] In some possible implementations, the fourth notification message may be a message of the notification type (NOTIFICATION) indexed in RFC4271 of the BGP protocol. Figure 2-3As shown, the fourth notification message may include data (which is a variable), an error code, and an error subcode. The value of the data is represented by 16 bits (2 bytes), the value of the error code is represented by 8 bits (1 byte), and the value of the error subcode is represented by 8 bits (1 byte).

[0119] As shown in Table 3, when the to be defined (TBD) value of the error code is 8 (ie, 00001000), the symbolic name represented is elastic fuse, that is, the fourth notification message is used to indicate the elastic fuse state of the target peer.

[0120] As shown in Table 4, the error subcode can take values ​​1 / 2 / 3 / 4 / 5 (i.e., 00000001, 00000010, 00000011, 00000100, 00000101, respectively), which is used to indicate the different states of the target peer. Among them, when the error subcode is 2, the symbol name represented is resilience breaker timer, indicating that the fourth notification message is used to instruct the target peer to maintain the resilience breaker state.

[0121] In some possible implementations, the data in the fourth notification message may be a time in seconds, which is used to indicate a second preset time, and is used to indicate to the second network device that the target peer will be in an elastically blown state within the second preset time.

[0122] 212. The second network disconnects the target peer.

[0123] In an embodiment of the present application, after the second network device receives the third notification message, the second network device can obtain the value of the error code and the value of the error subcode in the third notification message to determine that the third notification message indicates that the first network device is in a blown state.

[0124] In some possible implementations, after determining that the target peer is in a blown state, the second network device may interrupt the target peer, that is, stop sending data packets to the first network device and stop receiving data packets sent by the first network device.

[0125] In some possible implementations, after the second network device receives the third notification message sent by the first network device, the second network device may execute the steps executed by the first network device in steps 201-210. If the network devices of the entire network all execute the steps executed by the first network device in steps 201-210 when receiving the third notification message, the behavior of the first network device executing steps 201-210 may be transmitted to the second network device, and the second network device may subsequently transmit the behavior of executing steps 201-210 to other network devices until the source of the problem that causes the first network device to be in an over-limit state is found and the fault is repaired.

[0126] In some possible implementations, after receiving the fourth notification message, the second network device can determine the resilience breaker timer (resilience breaker timer) indicating the target peer based on the fourth notification message, and the resilience breaker timer (resilience breaker timer) is the second preset time length. The second network device stops sending data packets to the first network device within the second preset time length, and continues to publish routes to the first network device after the second preset time length expires.

[0127] In some possible implementations, after receiving the fourth notification message, the second network device can determine the resilience breaker timer indicating the target peer based on the fourth notification message, and the breaker maintenance time is the second preset time length. The second network device then stops learning the routes published by the first network device within the second preset time length, and learns the routes published by the first network device after the first preset time length expires.

[0128] 213. The first network device restarts the target peer.

[0129] In some possible implementations, after the first network device enters the blown state, the first network device re-establishes the BGP link with the second network device after a second preset time period.

[0130] In some possible implementations, after interrupting the target peer, the first network device may cause the target peer to enter an elastic fuse suppression state within a third preset time period, wherein the third preset time period is greater than the second preset time period. Within the third preset time period, when the second preset time period ends and the first network device re-establishes the BGP link with the second network device, if the over-limit state of the first network device has not been resolved, the first network device re-interrupts the target peer, even if the target peer is in a fuse state. In some possible implementations, within the third preset time period, the second time period for the target peer to enter the fuse state increases sequentially.

[0131] In some possible implementations, at the end of the third preset time period, if the over-limit state of the first network device has not been resolved, the first network device ends the elastic fuse suppression state and no longer attempts to re-establish the BGP link with the second network device, but waits for manual restart of the BGP peer session; before the end of the third preset time period, if the first network device re-establishes the BGP link with the second network device and the over-limit state of the first network device has been resolved, the first network device ends the elastic fuse suppression state.

[0132] In the embodiment of the present application, after the target peer is restarted, the first network device and the second network device can continue to publish and receive routes, and transmit and receive data packets to each other.

[0133] 214. The first network device sends a fifth notification message to the second network device, where the fifth notification message is used to indicate that the target peer has been restarted.

[0134] In some possible implementations, after the first network device restarts the target peer, or before the first network device is ready to restart the target peer, the first network device may send a fifth notification message to the second network device, where the fifth notification message is used to indicate that the target peer has been restarted.

[0135] In some possible implementations, the fifth notification message may be a message of the notification type (NOTIFICATION) indexed in RFC4271 of the BGP protocol. Figure 2-3 As shown, the fifth notification message may include data (variable), error code and error subcode. The value of the data is represented by 16 bits (2 bytes), the value of the error code is represented by 8 bits (1 byte), and the value of the error subcode is represented by 8 bits (1 byte).

[0136] As shown in Table 1, when the error code's to be defined value (TBD) is 8 (i.e., 00001000), the symbolic name represented is resilience breaker, i.e., the fifth notification message is used to indicate the resilience breaker state of the target peer. As shown in Table 2, the error subcode can take values ​​of 1 / 2 / 3 / 4 / 5 (i.e., 00000001, 00000010, 00000011, 00000100, 00000101, respectively), which are used to indicate the different resilience breaker states of the target peer, wherein, when the error subcode is 5, the symbolic name represented is resilience breaker recovery, indicating that the fifth notification message is used to indicate that the target peer has been restarted.

[0137] In some possible implementations, the data in the fifth notification message may be true (TRUE) or false (FALSE), wherein TRUE indicates that the fifth notification message is used to indicate that the target peer has been restarted, and FALSE indicates that the fifth notification message is used to indicate that the target peer has failed to restart.

[0138] In the present application, the first network device first obtains the value of N fuse condition factors of each peer among M peers, where peer is used to represent a Border Gateway Protocol BGP session connection between the first network device and another network device, and determines the processing priority of each peer among the M peers based on the value of the N fuse condition factors of each peer among the M peers, obtains M processing priorities, and determines the target peer among the M peers that needs to be fused based on the M processing priorities, where the target peer is used to represent the BGP session connection between the first network device and the second network device. Then, when the usage of memory resources and / or computing resources of the first network device exceeds the corresponding preset ratio, the first network device can interrupt the target peer, thereby preventing the spread of over-limit faults caused by an abnormally large number of routes, and maintaining normal operation between the first network device and other network devices other than the second network device.

[0139] It should be noted that, for the aforementioned method embodiments, for the sake of simplicity, they are all expressed as a series of action combinations, but those skilled in the art should be aware that the present application is not limited by the described order of actions, because according to the present application, certain steps can be performed in other orders or simultaneously. Secondly, those skilled in the art should also be aware that the embodiments described in the specification are all preferred embodiments, and the actions and modules involved are not necessarily required by the present application.

[0140] In order to better implement the above-mentioned solution of the embodiment of the present application, relevant devices for implementing the above-mentioned solution are also provided below.

[0141] See also Figure 3 As shown, a network device 300 provided in an embodiment of the present application is used as a first network device, and the network device 300 may include:

[0142] An acquisition module 301 is used to obtain the value of N fuse condition factors of each of M peers, where the peer is used to represent a Border Gateway Protocol BGP session connection between the first network device and another network device, and M and N are both positive integers;

[0143] A processing module 302 is used to determine the processing priority of each of the M peers based on the value of N fuse condition factors of each of the M peers to obtain M processing priorities, wherein the fuse condition factor is a specified parameter of the corresponding peer;

[0144] The processing module 302 is further used to determine a target peer among the M peers that needs to be fuse-broken based on the M processing priorities, where the target peer is used to represent a BGP session connection between the first network device and the second network device;

[0145] The processing module 302 is further configured to interrupt the target peer when usage of the memory resources and / or computing resources of the first network device exceeds a corresponding preset ratio.

[0146] In some possible implementations, the processing module 302 is specifically configured to:

[0147] Ranking the values ​​of each of the N fuse conditions of the M peers to obtain Ranking CF nm, where n=1, 2, 3, ..., N, and m=1, 2, 3, ..., M, wherein Ranking CF nm represents the ranking of the value of the mth fuse condition factor in the N fuse conditions of the M peers, and a higher ranking indicates a higher need for priority processing;

[0148] The processing priority X(m) of each peer among the M peers is calculated by the following formula:

[0149] X(m)=(RankingCF1-m*Weight1)+(RankingCF2-m*Weight2)+(RankingCF3-m*Weight3)+(RankingCF4-m*Weight4)+…+(RankingCF Nm*Weight N)

[0150] Among them, Weight n represents the preset weight corresponding to the nth fuse condition factor among the N fuse condition factors, and the processing priority with a smaller value among the M processing priorities has a higher priority.

[0151] In some possible implementations, the processing module 302 is further configured to: stop learning the routes published by the second network device; and / or stop publishing the routes to the second network device.

[0152] In some possible implementations, the network device also includes: a transceiver module 303, used to send a first notification message to the second network device, the first notification message is used to indicate that the target peer is in an elastic fuse holding state, the elastic fuse holding state is used to indicate that the first network device stops learning the routes published by the second network device, and / or the first network device stops publishing routes to the second network device.

[0153] In some possible implementations, the transceiver module 303 is further used to send a second notification message to the second network device, where the second notification message is used to indicate that the target peer is in the elastic fuse holding state for a first preset time period.

[0154] In some possible implementations, the transceiver module 303 is further used to send a third notification message to the second network device, where the third notification message is used to indicate that the target peer is in a blown fuse state, and the blown fuse state is used to indicate that the first network device has interrupted the target peer.

[0155] In some possible implementations, the transceiver module 303 is further used to send a fourth notification message to the second network device, where the fourth notification message is used to indicate a second preset time duration that the target peer is in the blown state.

[0156] In some possible implementations, the processing module 302 is further configured to: restart the target peer after interrupting the target peer for the second preset time period.

[0157] In some possible implementations, the transceiver module 303 is further used to: send a fifth notification message to the second network device, where the fifth notification message is used to indicate that the target peer has been restarted.

[0158] It should be noted that the information interaction, execution process, etc. between the modules / units of the above-mentioned device are based on the same concept as the method embodiment of the present application, and the technical effects they bring are the same as those of the method embodiment of the present application. For specific contents, please refer to the description in the method embodiment shown above in the present application, and will not be repeated here.

[0159] An embodiment of the present application also provides a computer storage medium, wherein the computer storage medium stores a program, and the program executes some or all of the steps recorded in the above method embodiment.

[0160] Next, another communication device provided by the embodiment of the present application is introduced. Figure 4 As shown, the communication device 400 includes:

[0161] Receiver 401, transmitter 402, processor 403 and memory 404. In some embodiments of the present application, receiver 401, transmitter 402, processor 403 and memory 404 may be connected via a bus or other means, wherein: Figure 4 The example of connecting through bus is taken in the following.

[0162] The memory 404 may include a read-only memory and a random access memory, and provides instructions and data to the processor 403. A portion of the memory 404 may also include a non-volatile random access memory (NVRAM). The memory 404 stores an operating system and operating instructions, executable modules or data structures, or a subset thereof, or an extended set thereof, wherein the operating instructions may include various operating instructions for implementing various operations. The operating system may include various system programs for implementing various basic services and processing hardware-based tasks.

[0163] The processor 403 controls the operation of the communication device 400, and the processor 403 may also be referred to as a central processing unit (CPU). In a specific application, the various components of the communication device 400 are coupled together through a bus system, wherein the bus system may include a power bus, a control bus, and a status signal bus in addition to a data bus. However, for the sake of clarity, various buses are referred to as bus systems in the figure.

[0164] The method disclosed in the above embodiment of the present application can be applied to the processor 403, or implemented by the processor 403. The processor 403 can be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the above method can be completed by the hardware integrated logic circuit or software instructions in the processor 403. The above processor 403 can be a general processor, a digital signal processor (digital signal processing, DSP), an application specific integrated circuit (application specific integrated circuit, ASIC), a field programmable gate array (field-programmable gate array, FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components. The methods, steps and logic block diagrams disclosed in the embodiments of the present application can be implemented or executed. The general processor can be a microprocessor or the processor can also be any conventional processor, etc. The steps of the method disclosed in the embodiment of the present application can be directly embodied as a hardware decoding processor to execute, or the hardware and software modules in the decoding processor can be executed. The software module can be located in a mature storage medium in the field such as a random access memory, a flash memory, a read-only memory, a programmable read-only memory or an electrically erasable programmable memory, a register, etc. The storage medium is located in the memory 404, and the processor 403 reads the information in the memory 404 and completes the steps of the above method in combination with its hardware.

[0165] The receiver 401 may be used to receive input digital or character information and generate signal input related to relevant settings and function control. The transmitter 402 may include a display device such as a display screen. The transmitter 402 may be used to output digital or character information through an external interface.

[0166] In the embodiment of the present application, the processor 403 is used to execute the aforementioned method for interrupting the session connection.

[0167] In another possible design, when the network device 300 or the communication device 400 is a chip, it includes: a processing unit and a communication unit, the processing unit may be, for example, a processor, and the communication unit may be, for example, an input / output interface, a pin or a circuit, etc. The processing unit may execute the computer execution instructions stored in the storage unit, so that the chip in the terminal executes the method for sending wireless report information of any one of the above-mentioned first aspects. Optionally, the storage unit is a storage unit in the chip, such as a register, a cache, etc., and the storage unit may also be a storage unit in the terminal located outside the chip, such as a read-only memory (ROM) or other types of static storage devices that can store static information and instructions, a random access memory (RAM), etc.

[0168] The processor mentioned in any of the above places may be a general-purpose central processing unit, a microprocessor, an ASIC, or one or more integrated circuits for controlling the execution of the program of the above method.

[0169] It should also be noted that the device embodiments described above are merely schematic, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed over multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of this embodiment. In addition, in the drawings of the device embodiments provided by the present application, the connection relationship between the modules indicates that there is a communication connection between them, which may be specifically implemented as one or more communication buses or signal lines.

[0170] Through the description of the above implementation mode, the technicians in the field can clearly understand that the present application can be implemented by means of software plus necessary general hardware, and of course, it can also be implemented by special hardware including application-specific integrated circuits, special CPUs, special memories, special components, etc. In general, all functions completed by computer programs can be easily implemented with corresponding hardware, and the specific hardware structure used to implement the same function can also be various, such as analog circuits, digital circuits or special circuits. However, for the present application, software program implementation is a better implementation mode in more cases. Based on such an understanding, the technical solution of the present application is essentially or the part that contributes to the prior art can be embodied in the form of a software product, which is stored in a readable storage medium, such as a computer floppy disk, a U disk, a mobile hard disk, a ROM, a RAM, a magnetic disk or an optical disk, etc., including a number of instructions to enable a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment of the present application.

[0171] In the above embodiments, all or part of the embodiments may be implemented by software, hardware, firmware or any combination thereof. When implemented by software, all or part of the embodiments may be implemented in the form of a computer program product.

[0172] The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the process or function described in the embodiment of the present application is generated in whole or in part. The computer may be a general-purpose computer, a special-purpose computer, a computer network, or other programmable devices. The computer instructions may be stored in a computer-readable storage medium, or transmitted from one computer-readable storage medium to another computer-readable storage medium, for example, the computer instructions may be transmitted from a website site, a computer, a server, or a data center by wired (e.g., coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) mode to another website site, computer, server, or data center. The computer-readable storage medium may be any available medium that a computer can store or a data storage device such as a server or a data center that includes one or more available media integrations. The available medium may be a magnetic medium, (e.g., a floppy disk, a hard disk, a tape), an optical medium (e.g., a DVD), or a semiconductor medium (e.g., a solid-state drive (SSD)), etc.

Claims

1. A method for interrupting a session connection, characterized in that: include: The first network device obtains the value of N fuse condition factors of each of M peers, where the peer is used to represent a Border Gateway Protocol BGP session connection between the first network device and another network device, and M and N are both positive integers; The first network device determines the processing priority of each of the M peers based on the value of N fuse condition factors of each of the M peers to obtain M processing priorities, wherein the fuse condition factor is a specified parameter of the corresponding peer; The first network device determines a target peer among the M peers that needs to be fuse-broken based on the M processing priorities, where the target peer is used to represent a BGP session connection between the first network device and the second network device; When the usage of the memory resources and / or computing resources of the first network device exceeds a corresponding preset ratio, the first network device interrupts the target peer.

2. The method according to claim 1, characterized in that: The N fuse condition factors include one or more of the proportion of non-preferred routes of the corresponding peer, the last route update time, the route update speed, the establishment time, the upward count, the total number of published routes, and the security attack risk.

3. The method according to claim 1 or 2, characterized in that: The first network device determines the processing priority of each of the M peers based on the value of the N fuse condition factors of each of the M peers, and further includes: The first network device sorts the values ​​of each fuse condition factor in the N fuse conditions of the M peers to obtain Ranking CF nm, where n=1, 2, 3, ..., N, and m=1, 2, 3, ..., M, where Ranking CF nm represents the ranking of the value of the mth fuse condition factor in the N fuse conditions of the M peers, and the higher the ranking, the more priority processing is required; The first network device calculates the processing priority X(m) of each peer in the M peers by the following formula: X(m)=(RankingCF1-m*Weight1)+(RankingCF2-m*Weight2)+(RankingCF3-m*Weight3)+(RankingCF4-m*Weight4)+…+(RankingCF Nm*Weight N); Among them, Weight n represents the preset weight corresponding to the nth fuse condition factor among the N fuse condition factors, and the processing priority with a smaller value among the M processing priorities has a higher priority.

4. The method according to any one of claims 1 to 3, characterized in that: Before the first network device interrupts the target peer, the method further includes: The first network device stops learning the routes published by the second network device; and / or, The first network device stops publishing routes to the second network device.

5. The method according to claim 4, characterized in that: The method further comprises: The first network device sends a first notification message to the second network device, and the first notification message is used to indicate that the target peer is in an elastic fuse holding state, and the elastic fuse holding state is used to indicate that the first network device stops learning the routes published by the second network device, and / or the first network device stops publishing routes to the second network device.

6. The method according to claim 5, characterized in that: The method further comprises: The first network device sends a second notification message to the second network device, where the second notification message is used to indicate that the target peer is in the elastic fuse holding state for a first preset time period.

7. The method according to any one of claims 1 to 6, characterized in that: After the first network device interrupts the target peer, the method further includes: The first network device sends a third notification message to the second network device, where the third notification message is used to indicate that the target peer is in a blown fuse state, and the blown fuse state is used to indicate that the first network device has interrupted the target peer.

8. The method according to claim 7, characterized in that: The first network device sends a fourth notification message to the second network device, where the fourth notification message is used to indicate a second preset time duration that the target peer is in the blown state.

9. The method according to claim 8, characterized in that: The method further comprises: After the first network device interrupts the target peer for the second preset time period, the first network device restarts the target peer.

10. The method according to claim 9, characterized in that: The method further comprises: The first network device sends a fifth notification message to the second network device, where the fifth notification message is used to indicate that the target peer has been restarted.

11. A network device, characterized in that: Used as the first network device, including: An acquisition module, used to obtain the value of N fuse condition factors of each peer among M peers, where the peer is used to represent a Border Gateway Protocol BGP session connection between the first network device and another network device, and M and N are both positive integers; a processing module, configured to determine a processing priority of each of the M peers based on a value of N fuse condition factors of each of the M peers, to obtain M processing priorities, wherein the fuse condition factor is a specified parameter of the corresponding peer; The processing module is further used to determine a target peer among the M peers that needs to be fuse-broken based on the M processing priorities, where the target peer is used to represent a BGP session connection between the first network device and the second network device; The processing module is further configured to interrupt the target peer when usage of memory resources and / or computing resources of the first network device exceeds a corresponding preset ratio.

12. The network device according to claim 11, characterized in that: The processing module is specifically used for: The values ​​of each of the N fuse conditions of the M peers are sorted to obtain RankingCF nm, where n=1, 2, 3, ..., N, and m=1, 2, 3, ..., M, wherein Ranking CF nm represents the ranking of the value of the mth fuse condition factor among the N fuse conditions of the M peers, and a higher ranking indicates a higher need for priority processing; The processing priority X(m) of each peer among the M peers is calculated by the following formula: X(m)=(RankingCF1-m*Weight1)+(RankingCF2-m*Weight2)+(RankingCF3-m*Weight3)+(RankingCF4-m*Weight4)+…+(RankingCF Nm*Weight N); Among them, Weight n represents the preset weight corresponding to the nth fuse condition factor among the N fuse condition factors, and the processing priority with a smaller value among the M processing priorities has a higher priority.

13. The network device according to claim 11 or 12, characterized in that: The processing module is further used for: Stop learning the routes published by the second network device; and / or, Stop publishing the route to the second network device.

14. The network device according to claim 13, characterized in that: The network device also includes: A transceiver module is used to send a first notification message to the second network device, wherein the first notification message is used to indicate that the target peer is in an elastic fuse holding state, and the elastic fuse holding state is used to indicate that the first network device stops learning the routes published by the second network device, and / or the first network device stops publishing routes to the second network device.

15. The network device according to claim 14, characterized in that: The transceiver module is further used to send a second notification message to the second network device, where the second notification message is used to indicate that the target peer is in the elastic fuse holding state for a first preset time length.

16. The network device according to any one of claims 11 to 15, characterized in that: The transceiver module is further used to send a third notification message to the second network device, where the third notification message is used to indicate that the target peer is in a blown fuse state, and the blown fuse state is used to indicate that the first network device has interrupted the target peer.

17. The network device according to claim 16, characterized in that: The transceiver module is further used to send a fourth notification message to the second network device, where the fourth notification message is used to indicate a second preset time duration that the target peer is in the blown state.

18. The network device according to claim 17, characterized in that: The processing module is also used for: After interrupting the target peer for the second preset time period, restarting the target peer.

19. The network device according to claim 18, characterized in that: The transceiver module is also used for: A fifth notification message is sent to the second network device, where the fifth notification message is used to indicate that the target peer has been restarted.

20. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a program, and the program causes a computer device to execute the method according to any one of claims 1 to 10.

21. A computer program product, characterized in that The computer program product includes computer-executable instructions, which are stored in a computer-readable storage medium; at least one processor of a device reads the computer-executable instructions from the computer-readable storage medium, and the at least one processor executes the computer-executable instructions so that the device performs the method as described in any one of claims 1-10.

22. A communication device, characterized in that: The communication device includes at least one processor, a memory and a communication interface; The at least one processor is coupled to the memory and the communication interface; The memory is used to store instructions, the processor is used to execute the instructions, and the communication interface is used to communicate with other communication devices under the control of the at least one processor; When the instructions are executed by the at least one processor, the at least one processor is caused to perform the method according to any one of claims 1 to 10.

23. A chip system, characterized in that: The chip system includes a processor and a memory, the memory and the processor are interconnected via a line, instructions are stored in the memory, and the processor is used to execute the method as described in any one of claims 1-10.