CN106549866B - Method, network device and system for processing message - Google Patents

Method, network device and system for processing message Download PDF

Info

Publication number
CN106549866B
CN106549866B CN201510609202.0A CN201510609202A CN106549866B CN 106549866 B CN106549866 B CN 106549866B CN 201510609202 A CN201510609202 A CN 201510609202A CN 106549866 B CN106549866 B CN 106549866B
Authority
CN
China
Prior art keywords
network device
message
packet
time
link
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201510609202.0A
Other languages
Chinese (zh)
Other versions
CN106549866A (en
Inventor
张旭东
胡志波
夏冬冬
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Huawei Technologies Co Ltd
Original Assignee
Huawei Technologies Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Huawei Technologies Co Ltd filed Critical Huawei Technologies Co Ltd
Priority to CN201510609202.0A priority Critical patent/CN106549866B/en
Priority to CN202010323415.8A priority patent/CN111683006B/en
Publication of CN106549866A publication Critical patent/CN106549866A/en
Application granted granted Critical
Publication of CN106549866B publication Critical patent/CN106549866B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/28Routing or path finding of packets in data switching networks using route fault recovery

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The embodiment of the invention provides a method for updating a route and network equipment thereof, wherein the method comprises the following steps: a first network device receives a first message sent by a second network device, wherein the first message carries state information of a first link, and the aging time carried by the first message reaches the maximum aging time; if the second network device is in an abnormal state, the first network device starts a first timer at the initial moment of receiving a first message, the timing duration of the first timer is a first duration, and after the first timer is overtime, the first message participates in route calculation. The embodiment of the invention can reduce the influence on the routing processing caused by the message which is generated by equipment failure and carries the link state information deletion instruction, and reduce the routing oscillation and the flow loss.

Description

Method, network device and system for processing message
Technical Field
The present invention relates to the field of communications, and in particular, to a method for processing a packet and a network device thereof.
Background
The Open Shortest Path First Protocol (Open Shortest Path First, abbreviated as OSPF) and the Intermediate System to System Protocol (IS) belong to the Interior Gateway Protocol (IGP), which IS a Link State Protocol that establishes adjacency relations hop by sending Hello messages between devices to form a network topology, where each adjacency relation IS bidirectional and has a metric value, and then sends the local Link topology and routing information to each device at the remote end by sending Link State Advertisement (LSA) or (Link State Protocol Data Unit, abbreviated as LSP), OSPF or IS-IS calculates the routing information using the Shortest Path First algorithm (Open Shortest Path First, abbreviated as SPF), and calculating the shortest path reaching each route in the network so as to guide message forwarding.
The LSA of OSPF has a mechanism for timed refresh and aging, and there is an age field in the LSA that grows with the passage of time in seconds. The generator of LSA will refresh LSA once every 1800 seconds (i.e. LSA message refresh period in OSPF protocol), the age field starts from zero again, and the whole network floods the refreshed LSA, other devices receive the refreshed LSA, the time starts from the age size of the received LSA. For the device of the non-LSA generator, if the LSA age reaches the maximum aging time MaxAge (3600 seconds in OSPF), it is deleted from the database, and the network-wide notification deletes the LSA with MaxAge. For the device of the LSA generator, if the LSA needs to be deleted, it is only necessary to set the age of the LSA to MaxAge (3600 seconds in OSPF), and the LSA with MaxAge is flooded in the whole network, so that the LSA can be deleted in the whole network. Similarly, the ISIS protocol has a similar mechanism.
However, in actual network communication, there are situations where LSAs or LSPs may be deleted erroneously, for example, a failure of a device time-to-live timer results in an overly fast aging of an LSA or LSP, and for example, an error exists on a device program, resulting in a full-network flooding to delete an LSA or LSP.
In the prior art, when an LSA or LSP is deleted by mistake, a device that receives notification of deleting the LSA or LSP immediately deletes the LSA or LSP and recalculates a route until the deleted LSA or LSP is regenerated, the route is recovered, and if a failed device periodically deletes the LSA or LSP by mistake, a route shock is caused, resulting in loss of traffic flow.
Disclosure of Invention
The embodiment of the invention provides a method for updating a route, which can reduce route oscillation caused by faults.
In a first aspect, a method for processing a packet includes: the method comprises the steps that first network equipment receives a first message sent by second network equipment, wherein the first message carries state information of a first link, and the survival time carried by the first message reaches the maximum aging time; if the second network device is in an abnormal state, the first network device starts a first timer at the initial moment of receiving a first message, the timing duration of the first timer is a first duration, and after the first timer is overtime, the first message participates in route calculation.
With reference to the first aspect, in a first possible implementation manner of the first aspect, before the first network device receives the first packet, the method further includes: the first network equipment receives a second message sent by the second network equipment, the second message carries topology state information of a second link, and the time-to-live carried by the second message reaches the maximum aging time; and determining that the second network equipment is in an abnormal state according to the second message.
With reference to the first possible implementation manner of the first aspect, in a second possible implementation manner of the first aspect, the second packet is a zero-fragmentation link state packet of an intermediate system to intermediate system protocol or an open shortest path first protocol routing link state issue.
With reference to the first or second possible implementation manner of the first aspect, in a third possible implementation manner of the first aspect, the determining that the second network device is in an abnormal state according to the second packet includes: and the first network equipment determines that the second network equipment is in an abnormal state within a second time length, wherein the second time length takes the time when the first network equipment receives the second message as an initial time, and the second time length is a time interval for the second network equipment to generate link state information.
With reference to the first aspect or the first to third possible implementation manners of the first aspect, in a fourth possible implementation manner of the first aspect, the method further includes: and when the first network equipment receives a third message when the first timer is not overtime, canceling the first timer, and performing routing calculation by adopting the third message, wherein the third message carries the state information of the first link, and the survival time carried by the third message does not reach the maximum aging time.
In a second aspect, a first network device is provided, which includes: a receiving unit, configured to receive a first packet sent by a second network device, where the first packet carries state information of a first link, and a lifetime carried by the first packet reaches a maximum aging time; and the processing unit is used for determining that the first network equipment starts a first timer at the initial moment of receiving the first message if the second network equipment is in an abnormal state, wherein the timing duration of the first timer is a first duration, and the first message participates in route calculation after the first timer is overtime.
With reference to the second aspect, in a first possible implementation manner of the second aspect, the receiving unit is further configured to receive a second packet sent by the second network device, where the second packet carries topology state information of a second link, and a lifetime carried by the second packet has reached a maximum aging time; the processing unit is further to: and determining that the second network equipment is in an abnormal state according to the second message.
With reference to the second aspect or the first possible implementation manner of the second aspect, in a second possible implementation manner of the second aspect, the second packet is a zero-fragmentation link state packet of an intermediate system to intermediate system protocol or an open shortest path first protocol routing link state issue.
With reference to the first or second possible implementation manner of the second aspect, in three possible implementation manners of the second aspect, the processing unit is further configured to determine that the second network device is in an abnormal state within a second duration, where the second duration takes a time when the first network device receives the second packet as a starting time, and the second duration is a time interval when the second network device generates link state information.
With reference to the second aspect or the first to third possible implementation manners of the second aspect, in a fourth possible implementation manner of the second aspect, the processing unit is further configured to cancel the first timer and perform routing calculation by using the third packet when the first network device receives the third packet when the first timer is not overtime, where the third packet carries state information of the first link, and a lifetime carried by the third packet does not reach the maximum aging time.
In a third aspect, a system for processing a packet is provided, which includes the foregoing first network device and second network device.
The method and the network device thereof provided by the embodiment of the invention can determine whether to immediately adopt the message for route calculation by judging whether the survival time carried in the received message reaches the maximum aging time, when the network device sending the message is in an abnormal state and the survival time carried in the message reaches the maximum aging time, the state information of the link is temporarily deleted, and when the message is determined not to be deleted wrongly, the message is deleted, otherwise, the route calculation is carried out according to the state information of the local current existing link. Therefore, the route oscillation caused by the message deleted by mistake can be reduced, and the possibility of causing the loss of the service flow is reduced.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings needed to be used in the embodiments of the present invention will be briefly described below, and it is obvious that the drawings described below are only some embodiments of the present invention, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without creative efforts.
Fig. 1 is a schematic flow chart of a method for processing a packet according to an embodiment of the present invention.
Fig. 2 is a schematic flow chart of a method for processing a message according to another embodiment of the present invention.
Fig. 3 is a schematic flow chart of a method for processing a message according to another embodiment of the present invention.
Fig. 4 is a schematic flow chart of a method for processing a message according to another embodiment of the present invention.
Fig. 5 is a schematic block diagram of a network device of an embodiment of the present invention.
Fig. 6 is a schematic block diagram of an apparatus of a network device of an embodiment of the present invention.
Fig. 7 is a schematic block diagram of a system for processing a message according to an embodiment of the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are some, not all, embodiments of the present invention. All other embodiments, which can be obtained by a person skilled in the art without any inventive step based on the embodiments of the present invention, shall fall within the scope of protection of the present invention.
Fig. 1 is a schematic flowchart of a method for processing a packet according to an embodiment of the present invention, where an execution subject of the method may be a first network device, as shown in fig. 1, and the method 100 includes:
110, the first network device receives a first message sent by the second network device, where the first message carries state information of the first link, and the lifetime carried by the first message has reached the maximum aging time.
And 120, if the second network device is in an abnormal state, the first network device starts a first timer at the initial moment of receiving the first message, the timing duration of the first timer is the first duration, and the first message participates in the route calculation after the first timer is overtime.
Specifically, taking the OSPF system as an example, in the OSPF system, an LSA message (that is, an LSA belonging to the second network device) generated by the network device may carry topology relationship information or routing information of a corresponding link of the network device, that is, state information of one or more links generated by the network device, where the LSA carries an age field for indicating a lifetime of the LSA, where the lifetime may also be referred to as a generation time, and when the lifetime of the age field reaches a maximum lifetime MaxAge (3600 s in the OSPF system), the LSA message is deleted in a local database. Similarly, in the IS-IS system, the LSP generated by the network device also carries an age field to identify the lifetime of the LSP, the default maximum lifetime of the age field in the LSP IS 1200s, and when the lifetime of the age field in the LSP reaches MaxAge, the lifetime of the age field in the LSP IS also deleted in the local database. Therefore, when a network device receives an LSA or LSP of MaxAge, the LSA or LSP in the local database is deleted.
In step 110, the first network device and the second network device are any two different network devices, the state information of the first link is generated by the second network device, the content of the state information of the first link is link topology relationship information or routing information of the second network device, and the state information of the first link, which carries the maximum aging time, of the first packet means that the lifetime indicated by the age field in the first packet has reached the maximum aging time, for example, the age field in an LSA has reached 3600s or the age field in an LSP has reached 1200 s.
Specifically, in step 120, if the second network device that generates the first packet is in an abnormal state, the first network determines that the first link state with the maximum aging time in the first time period does not immediately participate in the route calculation, that is, the first link state is maintained for a period of time without being deleted, specifically: the first network equipment is provided with a first timer, the timing duration of the first timer is a first duration, the first message does not participate in the routing calculation within the first duration, and after the first timer is overtime, the first message participates in the routing calculation.
For example, if the age field of the LSA received by the first network device is MaxAge, the first network device will maintain the first duration to not delete the LSA, and will not perform routing computation on the LSA with MaxAge in the first duration, and after the first timer expires, the LSA with MaxAge will participate in the routing computation.
Specifically, the first duration set by the first timer needs to be determined by the message receiving time between the network devices, for example, the first duration may be set to 1s, 5s, and 10s, which are only exemplary, and the present invention is not limited thereto.
The method and the network device thereof provided by the embodiment of the invention can determine whether to immediately adopt the message for route calculation by judging whether the survival time carried in the received message reaches the maximum aging time, when the network device sending the message is in an abnormal state and the survival time carried in the message reaches the maximum aging time, the state information of the link is temporarily deleted, and when the message is determined not to be deleted wrongly, the message is deleted, otherwise, the route calculation is carried out according to the state information of the local current existing link. Therefore, the route oscillation caused by the message deleted by mistake can be reduced, and the possibility of causing the loss of the service flow is reduced.
Optionally, as an embodiment of the present invention, before the first network device receives the first packet, the method further includes: the first network equipment receives a second message sent by the second network equipment, the second message carries topology state information of a second link, and the time-to-live carried by the second message reaches the maximum aging time; and determining that the second network equipment is in an abnormal state according to the second message.
Specifically, the topology state information of the second link refers to a link state used for describing topology relationship information, for example, the link state may be an ISIS zero-fragmentation LSP or an OSPF Router LSA, and the time until the lifetime carried by the second packet reaches the maximum aging time indicates that the second packet is to be deleted in participating in route calculation, and the packet carrying the second link state may refer to an ISIS zero-fragmentation LSP packet or an OSPF Router LSA packet of MaxAge.
After receiving the second message sent by the second network device, the first network device determines that the second network device is in an abnormal state, or marks the second network device generating the second link state as an abnormal state, that is, triggers the first network device to enter the link state of the second network device into a special state for suppressing the route calculation. It should be understood that the first packet and the second packet may be the same packet, that is, the topology state information of the second link carried by the first packet may be the same as the state information of the first link carried by the second packet, and both the lifetime of the first packet and the lifetime of the second packet carried by the second packet reach the maximum aging time, that is, the trigger condition for marking the second network device as the abnormal state is that the lifetime of the second packet sent by the second network device received by the first network device reaches the maximum aging time and the second packet carries the topology state information of the link state.
Optionally, as an embodiment of the present invention, the second packet is an intermediate system to intermediate system protocol zero-fragmentation link state packet (ISIS zero-fragmentation) or an open shortest path first protocol routing link state issue (ospf route LSA).
It should be understood that for OSPF, Router LSAs will always exist and will not be deleted by the producer as long as there is an active area. Similarly, the zero segment of the LSP of ISIS always exists as long as there is an active ISIS process, and may or may not exist for other types of LSAs or other segments of LSPs. When the OSPF Router LSA/ISIS zero-fragmentation whole network deletion is caused, the deletion can only be caused by device hosting or various software bugs or inaccurate timers.
Optionally, as an embodiment of the present invention, determining that the second network device is in an abnormal state according to the second packet includes: the first network device determines that the second network device is in an abnormal state within a second time length, wherein the second time length takes the time when the first network device receives the second message as an initial time, and the second time length is a time interval for the second network device to generate the link state information.
Specifically, the first network device marks the second network device to which the second link state belongs as the abnormal state within a second time period after the time when the second link state of the second network device is received. That is to say, when the first network device receives any link state with the maximum aging time belonging to the second network device within the second time period, it needs to determine that the link state with the maximum aging time does not participate in the route calculation immediately within the first time period, but starts the first timer, and after the first timer times out, that is, reaches the first time period, the link state with the maximum aging time does not participate in the route calculation.
Specifically, the second duration is a time interval of the second network device generating the link state information, that is, the second duration is a period of the second network device generating the link state information. That is, in the case of OSPF, the second duration may be a refresh period of LSA, for example 1800s, or may be 900s in the case of ISIS, but the present invention is not limited thereto.
Specifically, the reason for setting the second period of time is as follows: 1. if there is a failure device to delete all link states of the network device a, the deletion process is deletion one by one, therefore, it is determined that all LSPs or LSAs belonging to the network device a and having the maximum aging time enter the process of route calculation inhibition within the second time period, that is, do not participate in route calculation within the first time period; 2. and judging whether the link states of other equipment except the network equipment A are deleted by the equipment in the second time length. Therefore, as long as the time period capable of ensuring the above 1, 2 conditions may be set to the second time period, for example, the second time period may be set to 2000s, 1000s, or the like, to which the present invention is not limited.
Optionally, as an embodiment of the present invention, the method further includes: and when the first network equipment receives the third message when the first timer is not overtime, canceling the first timer, and performing routing calculation by adopting the third message, wherein the third message carries the state information of the first link, and the survival time carried by the third message does not reach the maximum aging time.
Specifically, when the first network device receives a third message carrying state information of the first link within a first time period and the generation time carried by the third message does not reach the maximum aging time, immediately performing routing calculation by using the third message, and not performing routing calculation by using the state information of the first link, the generation time of which reaches the maximum aging time; and when the first network equipment does not receive the third message within the first time length, carrying out routing calculation on the first message with the generation time reaching the maximum aging time, namely deleting the first message after the first time length.
In other words, within a first time period from the time when the first network device receives the first packet, if the third packet is received, it may be immediately determined that the previously received first packet is sent by the network device in error, so that the first packet is not allowed to participate in the routing calculation, but performs the routing calculation on the received first packet, so as to implement the routing update.
The method and the network device thereof provided by the embodiment of the invention can determine whether to immediately adopt the message for route calculation by judging whether the survival time carried in the received message reaches the maximum aging time, when the network device sending the message is in an abnormal state and the survival time carried in the message reaches the maximum aging time, the state information of the link is temporarily deleted, and when the message is determined not to be deleted wrongly, the message is deleted, otherwise, the route calculation is carried out according to the state information of the local current existing link. Therefore, the route oscillation caused by the message deleted by mistake can be reduced, and the possibility of causing the loss of the service flow is reduced.
Fig. 2 is a schematic flow chart of a method for processing a packet according to an embodiment of the present invention. As shown in fig. 2, the method 200 includes:
network device a is determined to be flagged as an abnormal state by the local network device 201. That is, in this abnormal state, all the link states of the network device a having the largest aging time enter a special state in which the route calculation is suppressed.
The local network device receives 202 a link state belonging to network device a for which the lifetime has reached the maximum aging time. Specifically, for example, when the local network device receives the MaxAgeLSP sent by the network device a, the local device will quickly flood the link state LSP to quickly trigger the network device a that generates the LSP to refresh again, and when the LSP of the network device a is deleted by error, the network device a will produce a new LSP and send the updated LSP to the local network device, so that the local network device performs routing calculation according to the updated LSP.
203, the link state with the maximum aging time enters a route slow calculation state, that is, the link state with the maximum aging time does not perform route calculation within the time length of T1, and a T1 timer is started when the link state is received.
204, when the generation time of the link state updated by the network device a does not reach the maximum aging time within the duration of T1, immediately replacing the link state whose survival time does not reach the maximum aging time with the link state with the maximum aging time received before, and immediately participating in the route calculation, and canceling the T1 timer. For example, within the duration of T1, when the local network device receives an LSP/LSA whose generation time updated by the network device a does not reach the maximum aging time, the updated LSP/LSA is substituted for the LSP or LSA that has reached the maximum aging time and is received before, and immediately, the updated LSP or LSA is subjected to route calculation.
205, when the local network device does not receive the link status whose lifetime has not reached the maximum aging time updated by the network device a within the time duration of T1, the link status whose generation time has reached the maximum aging time received in step 202 participates in the route calculation after the time duration of T1, that is, the link status with the maximum aging time is deleted.
For example, in steps 204 and 205, the local network device delays for a time period of T1 to perform route calculation for the link state whose generation time has reached the maximum aging time, and waits for the generator device of the link state to refresh the link state. If the local network device receives the link state of which the generation time refreshed by the network device A does not reach the maximum aging time within the time length of T1, replacing the link state of which the generation time reaches the maximum aging time received before with the link state of which the generation time reaches the maximum aging time received before; if the link state without the maximum aging time is not received within the time length of T1, the link state is deleted after T1 time, and the link state with the maximum aging time is subjected to route calculation. That is, the original device that waits for the purge message/flush message during the delay route calculation at time T2 refreshes the message for correction. If receiving the LSP/LSA refresh before the timer overtime, carrying out LSP/LSA merging processing to avoid deleting the route; if no receiving the refreshed LSP/LSA, then notifying the route calculation module after the timer is overtime, and performing route deletion processing.
The method and the network device thereof provided by the embodiment of the invention can determine whether to immediately adopt the message for route calculation by judging whether the survival time carried in the received message reaches the maximum aging time, when the network device sending the message is in an abnormal state and the survival time carried in the message reaches the maximum aging time, the state information of the link is temporarily deleted, and when the message is determined not to be deleted wrongly, the message is deleted, otherwise, the route calculation is carried out according to the state information of the local current existing link. Therefore, the route oscillation caused by the message deleted by mistake can be reduced, and the possibility of causing the loss of the service flow is reduced.
Fig. 3 is a schematic flow chart of a method for processing a packet according to another embodiment of the present invention, which is used for determining that a network device belonging to a certain network device is marked as an abnormal state locally. As shown in fig. 3, the method includes:
local network devices receive a link state belonging to network device a, such as receiving an LSA or LSP 301.
302, the local network device determines whether the received link state is a link state in which the lifetime has reached the maximum aging time and which carries the topology relationship of the network device a, for example, whether the received link state is a MaxAge ISIS zero-fragmentation LSP or a MaxAge OSPF Router LSA sent by the device a.
303, it is determined whether network device a is marked locally as an abnormal state, i.e., as a special state that inhibits routing computations.
304, if the local device has identified network device a as being in the abnormal state, then it needs to continue to maintain network device a as being in the abnormal state for the following time period T2, and the specific implementation manner may be implemented by refreshing the T2 timer.
305, if the local device is marked as abnormal, then it is necessary to mark the network device a as abnormal for the next time period T2 and start the timer T2.
306, after the timer T2 times out, that is, the network device does not receive the link state that the generation time has reached the maximum aging time and carries the topology relationship of the network device a within the time length T2, then the network device a is identified on the local network device to leave the abnormal state, that is, the link state of the network device a does not need to enter the state of suppressing the route calculation.
It should be understood that the main purposes of setting the duration of T2 are the following two: 1. if there is a failure device to delete all link states of the network device a, the deletion process is deletion one by one, so it is necessary to determine that all LSPs or LSAs belonging to the network device a and having the maximum aging time enter the process of route calculation inhibition within the first period of time, that is, do not participate in route calculation within the time duration of T1; 2. it is determined whether the failed device will delete the link states of devices other than network device a.
It should also be appreciated that the timer needs to be refreshed if router LSA/ISIS LSP zero-fragmentation of MaxAge is received before T2 times out. The T2 timer is not stopped when a router LSA/Isis zero-slice is received that is not MaxAge before the T2 timer times out. The T1 timer is different from the T2 timer, and when receiving the router LSA/Isis LSP zero fragment which is not MaxAge, the T1 timer is directly stopped to participate in the route calculation.
The method and the network device thereof provided by the embodiment of the invention can determine whether to immediately adopt the message for route calculation by judging whether the survival time carried in the received message reaches the maximum aging time, when the network device sending the message is in an abnormal state and the survival time carried in the message reaches the maximum aging time, the state information of the link is temporarily deleted, and when the message is determined not to be deleted wrongly, the message is deleted, otherwise, the route calculation is carried out according to the state information of the local current existing link. Therefore, the route oscillation caused by the message deleted by mistake can be reduced, and the possibility of causing the loss of the service flow is reduced.
Fig. 4 is a schematic flow chart of a method for processing a message according to another embodiment of the present invention.
As shown in fig. 4, an OSPF/ISIS neighbor is established between devices, a route is imported from a tester, a path of the route is tester- > PE1- > PE2- > P2- > P1- > P4- > PE3- > PE4- > tester, and a node fault source exists.
In the prior art, the failure of the failure source timer causes the aging to be too fast, for example, when the timer is 100 times faster, the time of the LSAs of other devices is 36S (less than the refresh time), the LSAs of other devices of the failed device have already reached 3600S, and the failed device notifies all the LSAs from PE1, PE2, P1, P2, P3, P4, PE3, and PE4 to be deleted. (the LSA of the failed device itself is not deleted, and is refreshed and notified to other devices when 18S arrives), so when P4 receives the MaxAge LSA generated by itself, it regenerates again, but when it receives MaxAge LSAs of other devices, it will immediately calculate the route, delete the route, and also notify all networks to delete these MaxAge LSAs, and other devices are similar. So the route is deleted. These LSA full-network floods are regenerated only if all devices are subjected to the respective largest maxagelsas. The route will be restored.
The failure source periodically deletes LSAs on PE1, PE2, P1, P2, P3, P4, PE3, and PE4, assuming that the network device a with the deleted route is PE1 and the failed network device B is P4. The failure source periodically deletes all LSAs for network device a.
As an embodiment of the present invention, for the failed network device B, the period of the failure source timer deletion is less than the time duration T2 for marking the network device in the special state (T2 selected by OSPF is the refresh time of OSPF, and ISIS selects the default refresh time), the LSA on the failure source has not reached 3600S, the updated LSA of other devices is received, and the time is calculated from zero. There is no net deletion.
As an embodiment of the present invention, for the network device a, the period of deletion of the failure source is less than T1 time, and the failed network device B deletes the LSA of the network device a, where the sequence of deleting the LSA is indefinite, and may be other LSAs, then Router LSAs, and then other LSAs.
When the failed device first deletes another LSA of the network device a, at this time, on the network device B, none of the previous non-Router LSAs may enter slow computation, and the route may be deleted, because the network device a is not marked as a special state at the network device B yet, only after the network device B receives the MaxAge Router LSA belonging to the network device a, the network device a is marked as the special state by the network device B from the time when the MaxAge Router LSA is received, and in the time duration T2 after the MaxAge Router LSA is received, the Router LSA belonging to the network device a and the subsequent other LSAs belonging to the network device a may enter slow computation, that is, the other LSAs may not be deleted in the time duration T1.
Specifically, the duration of T2 may be set as the refresh time of OSPF, and when the fault source deletes the LSA next time periodically (the time is less than T2 device), the sequence of deleting the LSA of device a in the whole network may also be that other LSAs are deleted first, routerlas are deleted second, and other LSAs are deleted again. On network device B, since network device a is still identified as a failed state during time T2, all flush LSAs enter slow computation, i.e., no route is deleted during time T1. When the network device receives the MaxAgRouter LSA, the timer is refreshed for the time of T1, and then all received flush LSAs enter slow calculation, so that route oscillation can be reduced. The subsequent processes are repeated according to the above process cycle, and for the sake of brevity, are not described herein.
Similarly, the methods of embodiments of the present invention may also be implemented in ISIS and other protocols, to which the present invention is not limited.
The method and the network device thereof provided by the embodiment of the invention can determine whether to immediately adopt the message for route calculation by judging whether the survival time carried in the received message reaches the maximum aging time, when the network device sending the message is in an abnormal state and the survival time carried in the message reaches the maximum aging time, the state information of the link is temporarily deleted, and when the message is determined not to be deleted wrongly, the message is deleted, otherwise, the route calculation is carried out according to the state information of the local current existing link. Therefore, the route oscillation caused by the message deleted by mistake can be reduced, and the possibility of causing the loss of the service flow is reduced.
Fig. 5 is a schematic block diagram of a first network device of an embodiment of the present invention. As shown in fig. 5, the first network device 500 includes:
a receiving unit 510, configured to receive a first packet sent by a second network device, where the first packet carries state information of a first link, and a lifetime carried by the first packet reaches a maximum aging time.
A processing unit 520, configured to determine that, if the second network device is in an abnormal state, the first network device starts a first timer at an initial time of receiving the first packet, where a timing duration of the first timer is a first duration, and after the first timer is overtime, the first packet participates in route calculation.
The method and the network device thereof provided by the embodiment of the invention can determine whether to immediately adopt the message for route calculation by judging whether the survival time carried in the received message reaches the maximum aging time, when the network device sending the message is in an abnormal state and the survival time carried in the message reaches the maximum aging time, the state information of the link is temporarily deleted, and when the message is determined not to be deleted wrongly, the message is deleted, otherwise, the route calculation is carried out according to the state information of the local current existing link. Therefore, the route oscillation caused by the message deleted by mistake can be reduced, and the possibility of causing the loss of the service flow is reduced.
Optionally, as an embodiment of the present invention, the receiving unit 510 is further configured to: receiving a second message sent by the second network equipment, wherein the second message carries topology state information of a second link, and the time-to-live carried by the second message reaches the maximum aging time; the processing unit 520 is further configured to determine that the second network device is in an abnormal state according to the second packet.
Optionally, as an embodiment of the present invention, the second packet is a zero-fragmentation link state packet of an intermediate system to intermediate system protocol or an open shortest path first protocol routing link state issue.
Optionally, as an embodiment of the present invention, the processing unit 520 is further configured to determine that the second network device is in an abnormal state within a second duration, where the second duration takes a time when the first network device receives the second packet as a starting time, and the second duration is a time interval when the second network device generates the link state information.
Optionally, as an embodiment of the present invention, the processing unit 520 is further configured to receive a third packet when the first network device 500 does not time out by the first timer, cancel the first timer, and perform routing calculation by using the third packet, where the third packet carries state information of the first link, and a lifetime carried by the third packet does not reach the maximum aging time.
It should be understood that the first network device 500 according to the embodiment of the present invention may correspond to an execution main body of the method for processing a packet according to the embodiment of the present invention, and the above and other operations and/or functions of each module in the first network device 500 are respectively for implementing corresponding flows of each method in fig. 1 to fig. 4, and are not described herein again for brevity. For example, the first network device 500 may be the first network device in the embodiment shown in fig. 1, may be the network device a in the embodiment shown in fig. 2, and may also be the local network device in the embodiment shown in fig. 3 or the network device B in the embodiment shown in fig. 4.
The method and the network device thereof provided by the embodiment of the invention can determine whether to immediately adopt the message for route calculation by judging whether the survival time carried in the received message reaches the maximum aging time, when the network device sending the message is in an abnormal state and the survival time carried in the message reaches the maximum aging time, the state information of the link is temporarily deleted, and when the message is determined not to be deleted wrongly, the message is deleted, otherwise, the route calculation is carried out according to the state information of the local current existing link. Therefore, the route oscillation caused by the message deleted by mistake can be reduced, and the possibility of causing the loss of the service flow is reduced.
Fig. 6 is a schematic block diagram of an apparatus of an embodiment of the present invention. As shown in fig. 6, an embodiment of the present invention further provides a first network device 600, where the first network device 600 includes a processor 601, a memory 602, a bus system 603, and a receiver 604. Wherein, the processor 601, the memory 602 and the receiver 604 are connected via a bus system 603, the memory 602 is used for storing instructions, and the processor 601 is used for executing the instructions stored in the memory 602 and controlling the receiver 604 to receive information. Wherein the content of the first and second substances,
the receiver 604 is configured to receive a first message sent by a second network device, where the first message carries state information of a first link, and a lifetime carried by the first message reaches a maximum aging time;
the processor 601 is configured to determine that, if the second network device is in an abnormal state, the network device starts a first timer at an initial time of receiving a first packet, where a timing duration of the first timer is a first duration, and after the first timer is overtime, the first packet participates in route calculation.
The method and the network device thereof provided by the embodiment of the invention can determine whether to immediately adopt the message for route calculation by judging whether the survival time carried in the received message reaches the maximum aging time, when the network device sending the message is in an abnormal state and the survival time carried in the message reaches the maximum aging time, the state information of the link is temporarily deleted, and when the message is determined not to be deleted wrongly, the message is deleted, otherwise, the route calculation is carried out according to the state information of the local current existing link. Therefore, the route oscillation caused by the message deleted by mistake can be reduced, and the possibility of causing the loss of the service flow is reduced.
It should be understood that, in the embodiment of the present invention, the processor 601 may be a Central Processing Unit (CPU), and the processor 601 may also be other general-purpose processors, Digital Signal Processors (DSP), Application Specific Integrated Circuits (ASIC), Field-Programmable Gate arrays (FPGA) or other Programmable logic devices, discrete Gate or transistor logic devices, discrete hardware components, and so on. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
The memory 602 may include both read-only memory and random access memory and provides instructions and data to the processor 601. A portion of the memory 602 may also include non-volatile random access memory. For example, the memory 602 may also store device type information.
The bus system 603 may include a power bus, a control bus, a status signal bus, etc., in addition to a data bus. For clarity of illustration, the various buses are designated in the figure as the bus system 603.
In implementation, the steps of the above method may be performed by integrated logic circuits of hardware or instructions in the form of software in the processor 601. The steps of a method disclosed in connection with the embodiments of the present invention may be directly implemented by a hardware processor, or may be implemented by a combination of hardware and software modules in the processor. The software module may be located in ram, flash memory, rom, prom, or eprom, registers, etc. storage media as is well known in the art. The storage medium is located in the memory 602, and the processor 601 reads the information in the memory 602 and completes the steps of the method in combination with the hardware thereof. To avoid repetition, it is not described in detail here.
Optionally, as an embodiment of the present invention, the receiver 604 is further configured to: receiving a second message sent by a second network device, wherein the second message carries topology state information of a second link, and the time-to-live carried by the second message reaches the maximum aging time; the processor 601 is configured to: and determining that the second network equipment is in an abnormal state according to the second message.
Optionally, as an embodiment of the present invention, the second packet is a zero-fragmentation link state packet of an intermediate system to intermediate system protocol or an open shortest path first protocol routing link state issue.
Optionally, as an embodiment of the present invention, the processor 601 is further configured to: determining that the second network device is in an abnormal state within a second time length, where the second time length takes a time when the first network device 600 receives the second packet as an initial time, and the second time length is a time interval when the second network device generates the link state information.
Optionally, as an embodiment of the present invention, the processor 601 is further configured to: when the first network device 600 receives the third message when the first timer is not overtime, the first timer is cancelled, and the third message is used for performing routing calculation, wherein the third message carries the state information of the first link, and the lifetime carried by the third message does not reach the maximum aging time.
It should be understood that the network device 600 according to the embodiment of the present invention may correspond to an execution main body of the method for processing a packet according to the embodiment of the present invention, and the above and other operations and/or functions of each module in the network device 600 are respectively for implementing corresponding flows of each method in fig. 1 to fig. 4, and are not described herein again for brevity. For example, the first network device 600 may be the first network device in the embodiment of fig. 1, may be the network device a in the embodiment shown in fig. 2, and may also be a local network device in the embodiment shown in fig. 3, a network device B in the embodiment shown in fig. 4, or a first network device shown in the embodiment of fig. 5.
The method and the network device thereof provided by the embodiment of the invention can determine whether to immediately adopt the message for route calculation by judging whether the survival time carried in the received message reaches the maximum aging time, when the network device sending the message is in an abnormal state and the survival time carried in the message reaches the maximum aging time, the state information of the link is temporarily deleted, and when the message is determined not to be deleted wrongly, the message is deleted, otherwise, the route calculation is carried out according to the state information of the local current existing link. Therefore, the route oscillation caused by the message deleted by mistake can be reduced, and the possibility of causing the loss of the service flow is reduced.
The system for processing the message according to the embodiment of the invention may include the foregoing network device and the second network device.
Fig. 7 is a message processing system according to an embodiment of the present invention, where the message processing system 700 includes: a first network device 701 and a second network device 702, wherein,
the first network device 701 is configured to receive a first message sent by the second network device 702, where the first message carries state information of a first link, and a lifetime carried by the first message reaches a maximum aging time; the method and the device are configured to determine that, if the second network device 720 is in an abnormal state, the first network device 701 starts a first timer at an initial time of receiving the first packet, where a timing duration of the first timer is a first duration, and after the first timer is overtime, the first packet participates in the route calculation.
The second network device 702 is configured to generate a first packet and send the first packet to the first network device 701.
Optionally, as an embodiment of the present invention, the second network device 702 is further configured to generate a second packet, and send the second packet in parallel to the first network device 701, so that the first network device 701 determines that the first network device 701 is in an abnormal state according to the second packet.
In a specific embodiment, the first network device 701 may be the first network device in fig. 1, and the second network device 702 is the second network device in fig. 1. The first network device 701 may be a first network device in the embodiment shown in fig. 2, and the second network device 702 may be a second network device in the embodiment shown in fig. 2. The first network device 701 may be a local network device in the embodiment shown in fig. 3, and the second network device 702 may be a network device a in the embodiment shown in fig. 3. The first network device 701 may be the network device B in the embodiment shown in fig. 4, and the second network device 702 may be the network device a in the embodiment shown in fig. 4. Or the first network device 701 may be the first network device 500 in the embodiment shown in fig. 5 or the first network device 600 in the embodiment shown in fig. 6, and specific contents related to the first network device 701 may refer to any of the foregoing embodiments, which are not described herein again. The second network device 702 may be the second network device in the embodiment shown in fig. 5, or the second network device in the embodiment shown in fig. 6, and specific contents related to the second network device 702 may refer to any of the foregoing embodiments, which are not described herein again.
The method and the network device thereof provided by the embodiment of the invention can determine whether to immediately adopt the message for route calculation by judging whether the survival time carried in the received message reaches the maximum aging time, when the network device sending the message is in an abnormal state and the survival time carried in the message reaches the maximum aging time, the state information of the link is temporarily deleted, and when the message is determined not to be deleted wrongly, the message is deleted, otherwise, the route calculation is carried out according to the state information of the local current existing link. Therefore, the route oscillation caused by the message deleted by mistake can be reduced, and the possibility of causing the loss of the service flow is reduced.
Those of ordinary skill in the art will appreciate that the various method steps and elements described in connection with the embodiments disclosed herein can be implemented as electronic hardware, computer software, or combinations of both, and that the steps and elements of the various embodiments have been described above generally in terms of their functionality in order to clearly illustrate the interchangeability of hardware and software. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the implementation. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present invention.
The methods or steps described in connection with the embodiments disclosed herein may be embodied in hardware, a software program executed by a processor, or a combination of both. The software routines may reside in Random Access Memory (RAM), memory, Read Only Memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, hard disk, a removable disk, a CD-ROM, or any other form of storage medium known in the art.
Although the present invention has been described in detail by referring to the drawings in connection with the preferred embodiments, the present invention is not limited thereto. Various equivalent modifications or alterations to the embodiments of the present invention may be made by those skilled in the art without departing from the spirit and scope of the present invention, and such modifications or alterations are intended to be within the scope of the present invention.

Claims (11)

1. A method for processing a packet, comprising:
the method comprises the steps that first network equipment receives a first message sent by second network equipment, wherein the first message carries state information of a first link, and the survival time carried by the first message reaches the maximum aging time;
if the second network device is in an abnormal state, the first network device starts a first timer at the initial moment of receiving a first message, the timing duration of the first timer is a first duration, and after the first timer is overtime, the first message participates in route calculation.
2. The method of claim 1, wherein prior to the first network device receiving the first packet, the method further comprises:
the first network equipment receives a second message sent by the second network equipment, the second message carries topology state information of a second link, and the time-to-live carried by the second message reaches the maximum aging time;
and determining that the second network equipment is in an abnormal state according to the second message.
3. The method of claim 2, wherein the second packet is an intermediate system to intermediate system ISIS protocol zero-fragmentation link state packet or an open shortest path first OSPF protocol routing link state issue packet.
4. The method according to claim 2 or 3, wherein determining that the second network device is in an abnormal state according to the second packet comprises:
and the first network equipment determines that the second network equipment is in an abnormal state within a second time length, wherein the second time length takes the time when the first network equipment receives the second message as an initial time, and the second time length is a time interval for the second network equipment to generate link state information.
5. The method according to any one of claims 1 to 3, further comprising:
and when the first network equipment receives a third message when the first timer is not overtime, canceling the first timer, and performing routing calculation by adopting the third message, wherein the third message carries the state information of the first link, and the survival time carried by the third message does not reach the maximum aging time.
6. A first network device, comprising:
a receiving unit, configured to receive a first packet sent by a second network device, where the first packet carries state information of a first link, and a lifetime carried by the first packet reaches a maximum aging time;
and the processing unit is used for determining that the first network equipment starts a first timer at the initial moment of receiving the first message if the second network equipment is in an abnormal state, wherein the timing duration of the first timer is a first duration, and the first message participates in route calculation after the first timer is overtime.
7. The first network device of claim 6,
the receiving unit is further configured to receive a second packet sent by the second network device, where the second packet carries topology state information of a second link, and a lifetime carried by the second packet reaches a maximum aging time;
the processing unit is further configured to determine that the second network device is in an abnormal state according to the second packet.
8. The first network device of claim 7, wherein the second packet is an intermediate system to intermediate system ISIS protocol zero-fragmentation link state packet or an Open Shortest Path First (OSPF) protocol routing link state issue packet.
9. The first network device according to claim 7 or 8, wherein the processing unit is further configured to determine that the second network device is in an abnormal state within a second duration, where the second duration takes a time when the first network device receives the second packet as a starting time, and the second duration is a time interval when the second network device generates link state information.
10. The first network device according to any one of claims 6 to 8, wherein the processing unit is further configured to, when the first network device does not time out at the first timer, receive a third packet, cancel the first timer, and perform routing calculation using the third packet, where the third packet carries state information of the first link, and a lifetime carried by the third packet does not reach a maximum aging time.
11. A system for processing messages, comprising a first network device and a second network device according to any one of claims 6 to 10.
CN201510609202.0A 2015-09-22 2015-09-22 Method, network device and system for processing message Active CN106549866B (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN201510609202.0A CN106549866B (en) 2015-09-22 2015-09-22 Method, network device and system for processing message
CN202010323415.8A CN111683006B (en) 2015-09-22 2015-09-22 Method for processing message and network equipment thereof

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510609202.0A CN106549866B (en) 2015-09-22 2015-09-22 Method, network device and system for processing message

Related Child Applications (1)

Application Number Title Priority Date Filing Date
CN202010323415.8A Division CN111683006B (en) 2015-09-22 2015-09-22 Method for processing message and network equipment thereof

Publications (2)

Publication Number Publication Date
CN106549866A CN106549866A (en) 2017-03-29
CN106549866B true CN106549866B (en) 2020-04-28

Family

ID=58365466

Family Applications (2)

Application Number Title Priority Date Filing Date
CN202010323415.8A Active CN111683006B (en) 2015-09-22 2015-09-22 Method for processing message and network equipment thereof
CN201510609202.0A Active CN106549866B (en) 2015-09-22 2015-09-22 Method, network device and system for processing message

Family Applications Before (1)

Application Number Title Priority Date Filing Date
CN202010323415.8A Active CN111683006B (en) 2015-09-22 2015-09-22 Method for processing message and network equipment thereof

Country Status (1)

Country Link
CN (2) CN111683006B (en)

Families Citing this family (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108259358B (en) 2017-05-24 2020-12-04 新华三技术有限公司 Route publishing method and device
CN110932921B (en) 2018-09-19 2022-10-11 华为技术有限公司 Method for determining route oscillation information and related equipment thereof
CN110336728B (en) * 2019-07-26 2021-08-06 新华三大数据技术有限公司 Message processing method, node equipment, electronic equipment and readable storage medium
CN112398729B (en) * 2019-08-14 2022-03-29 华为技术有限公司 Method and device for processing link state information
CN115334136B (en) * 2022-07-05 2024-02-02 北京天融信网络安全技术有限公司 Connection aging control method, system, equipment and storage medium

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1741505A (en) * 2005-09-19 2006-03-01 杭州华为三康技术有限公司 Method for group transmitting static group backup and method of group transmitting message retransmission
CN102035716A (en) * 2009-09-29 2011-04-27 中国移动通信集团公司 Routing updating method and system and router
US8374095B2 (en) * 2009-03-23 2013-02-12 Cisco Technology, Inc. Connection verification for MPLS label switched paths and pseudowires
CN103095590A (en) * 2013-01-05 2013-05-08 杭州华三通信技术有限公司 Method and network device for suppressing link status message periodical refreshing and aging
WO2013077090A1 (en) * 2011-11-21 2013-05-30 三菱電機株式会社 Ad hoc network system and communication device
CN104579718A (en) * 2013-10-10 2015-04-29 杭州迪普科技有限公司 Device and method for optimizing ARP aging mechanism

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101562531B (en) * 2008-04-15 2012-08-15 中国移动通信集团公司 Method and system for processing network fault and router
CN101841453B (en) * 2009-03-20 2012-09-05 华为技术有限公司 Method and system for processing network error source and network node
US8339942B2 (en) * 2009-10-15 2012-12-25 Telefonaktiebolaget L M Ericsson (Publ) RSVP-TE graceful restart under fast re-route conditions
CN102023926B (en) * 2010-12-08 2013-12-11 杭州华三通信技术有限公司 Method and device for data overtime aging processing
CN102739462B (en) * 2011-04-08 2014-12-31 中国移动通信集团公司 Test message sending method and device

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1741505A (en) * 2005-09-19 2006-03-01 杭州华为三康技术有限公司 Method for group transmitting static group backup and method of group transmitting message retransmission
US8374095B2 (en) * 2009-03-23 2013-02-12 Cisco Technology, Inc. Connection verification for MPLS label switched paths and pseudowires
CN102035716A (en) * 2009-09-29 2011-04-27 中国移动通信集团公司 Routing updating method and system and router
WO2013077090A1 (en) * 2011-11-21 2013-05-30 三菱電機株式会社 Ad hoc network system and communication device
CN103095590A (en) * 2013-01-05 2013-05-08 杭州华三通信技术有限公司 Method and network device for suppressing link status message periodical refreshing and aging
CN104579718A (en) * 2013-10-10 2015-04-29 杭州迪普科技有限公司 Device and method for optimizing ARP aging mechanism

Also Published As

Publication number Publication date
CN111683006A (en) 2020-09-18
CN111683006B (en) 2023-12-08
CN106549866A (en) 2017-03-29

Similar Documents

Publication Publication Date Title
CN106549866B (en) Method, network device and system for processing message
US9838246B1 (en) Micro-loop prevention using source packet routing
US7675860B2 (en) Method and apparatus for determining a preferred backup tunnel to protect point-to-multipoint label switch paths
CN110086711B (en) Flow back-switching method and device, electronic equipment and readable storage medium
CN103391247B (en) The method and apparatus of the quick heavy-route of use LFA next-hop of execution multiple spot LSP
US20160269293A1 (en) Reducing link state protocol traffic during graceful restart
US11711281B2 (en) Methods and network devices for detecting and resolving abnormal routes
US10567272B2 (en) Bit error information transfer method, network device, and communications system
US20210029017A1 (en) System and method for handling igp flooding topology inconsistency
WO2016123904A1 (en) Routing convergence method, device and virtual private network system
CN113615132A (en) Fast flooding topology protection
CN106789673B (en) Link state synchronization method and device
CN111277494B (en) Message transmission method and device
WO2017190675A1 (en) Link information processing method, apparatus and system
CN112671652A (en) Message forwarding method and device
Deng et al. Comparison of RIP, OSPF and EIGRP Routing Protocols based on OPNET
US8514876B2 (en) Method and apparatus for sequencing operations for an incoming interface check in data center ethernet
CN109150716A (en) Change in topology response method, path calculating client and path computing system
US8699376B2 (en) Method and system for de-synchronizing link state message refreshes
US20200169497A1 (en) Intermediate system to intermediate system routing protocol based notification method and apparatus
Singh Effects of OSPF timers configurations on network convergence in new generation routers
WO2020244471A1 (en) Processing method and apparatus based on link error code
US11870684B2 (en) Micro-loop avoidance in networks
CN115277528A (en) Traffic scheduling method and device
CN109729006B (en) Message processing method and device and computer readable storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant