WO2021043086A1 - Method, device and system for establishing sbfd session - Google Patents

Method, device and system for establishing sbfd session Download PDF

Info

Publication number
WO2021043086A1
WO2021043086A1 PCT/CN2020/112310 CN2020112310W WO2021043086A1 WO 2021043086 A1 WO2021043086 A1 WO 2021043086A1 CN 2020112310 W CN2020112310 W CN 2020112310W WO 2021043086 A1 WO2021043086 A1 WO 2021043086A1
Authority
WO
WIPO (PCT)
Prior art keywords
sbfd
network device
tunnel
message
session
Prior art date
Application number
PCT/CN2020/112310
Other languages
French (fr)
Chinese (zh)
Inventor
吴燕飞
Original Assignee
华为技术有限公司
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 华为技术有限公司 filed Critical 华为技术有限公司
Publication of WO2021043086A1 publication Critical patent/WO2021043086A1/en

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/28Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
    • H04L12/46Interconnection of networks
    • H04L12/4633Interconnection of networks using encapsulation techniques, e.g. tunneling
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/28Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
    • H04L12/46Interconnection of networks
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/12Shortest path evaluation
    • 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
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/50Routing or path finding of packets in data switching networks using label swapping, e.g. multi-protocol label switch [MPLS]

Definitions

  • This application relates to the field of communication technology, and in particular to a method, device and system for establishing a seamless BFD (SBFD) session.
  • SBFD seamless BFD
  • Segment routing is a protocol designed to forward data packets on the network based on the concept of source routing.
  • MPLS refers to Segment Routing based on the MPLS forwarding plane.
  • Segment routing-best effort is a new type of tunneling technology that uses SR as a control protocol.
  • SR-BE is based on the interior gateway protocol (IGP) and the shortest path first (SPF) calculation to obtain the optimal SR label switched path (LSP).
  • the SR-BE tunnel can control the transmission path of the message in the network according to the MPLS label of the first node.
  • the SR-BE tunnel is used for connectionless, Mesh service bearer, provides service connections of any topology and simplifies tunnel planning and deployment.
  • the fault detection of the SR-BE tunnel requires the deployment of a bidirectional forwarding detection (bidirectional forwarding detection, BFD) mechanism.
  • BFD bidirectional forwarding detection
  • SBFD Seamless bidirectional forwarding detection
  • SR-BE tunnels are established based on end-to-end network devices in the network, and the network devices at both ends of each SR-BE tunnel enable the SBFD mechanism. Therefore, as long as the SR-BE service exists in the SR-BE tunnel, the network devices at both ends of the SR-BE tunnel will establish an SBFD session. However, only network devices with a node protection mechanism need to implement fast failover based on the detection result of the SBFD session. In this way, there may be a large number of useless SBFD sessions in the network, resulting in a waste of bandwidth resources in the network.
  • the embodiments of the present application provide a method, device, and system for establishing an SBFD session.
  • the first network device receives the SBFD information sent by the second network device, thereby determining, according to the SBFD information, to avoid creating an SBFD session for the tunnel, where the tunnel is from the first network device to the second network device. Tunneling of network devices, thereby reducing the number of SBFD sessions in the network.
  • a method for establishing an SBFD session includes a first network device receiving a first packet sent by a second network device, the first packet including SBFD information.
  • the SBFD information is used to instruct the network device corresponding to the destination address of the first packet to determine whether to establish an SBFD session for the tunnel, and the tunnel is a tunnel from the first network device to the second network device
  • the SBFD session is used to detect the state of the tunnel, and the destination address is the address of the first network device.
  • the first network device obtains the SBFD information in the first packet, and the SBFD information determines whether the first network device establishes the SBFD session for the tunnel.
  • the first network device determines according to the SBFD information that the first network device does not need to establish the SBFD session for the tunnel, the first network device avoids creating the SBFD session.
  • the first network device receives the SBFD information sent by the second network device, thereby determining whether it is necessary to create an SBFD session for the tunnel according to the SBFD information, where the tunnel is from all
  • the tunnel from the first network device to the second network device is thus avoided to create unnecessary SBFD sessions, and the number of SBFD sessions in the network is reduced.
  • the first network device when the first network device determines that the first network device needs to establish the SBFD session for the tunnel according to the SBFD information, the first network device Create the SBFD session.
  • the creation of the SBFD session by the first network device includes: sending an SBFD message to the second network device, where the SBFD message is used to request the establishment of the SBFD session; and receiving the second network device An SBFD response message sent by the device to the SBFD message, the SBFD response message indicating that the second network device is in a working state; and, according to the SBFD response message, the corresponding of the first network device
  • the port of the tunnel is set to the UP state.
  • the method includes: The second network device sends an SBFD echo message, and the SBFD echo message is used to detect the state of the tunnel.
  • a method for establishing an SBFD session includes that a second network device generates a first packet, and the first packet includes SBFD information.
  • the SBFD information is used to instruct the network device corresponding to the destination address of the first packet to determine whether to establish an SBFD session for the tunnel, and the tunnel is a tunnel from the first network device to the second network device, so The SBFD session is used to detect the state of the tunnel, and the destination address is the address of the first network device.
  • the second network device sends the first message to the first network device, where the SBFD information in the first message is used to prevent the first network device from establishing SBFD session of the tunnel.
  • the first network device receives the SBFD information sent by the second network device, thereby determining whether it is necessary to create an SBFD session for the tunnel according to the SBFD information, where the tunnel is from all
  • the tunnel from the first network device to the second network device is thus avoided to create unnecessary SBFD sessions, and the number of SBFD sessions in the network is reduced.
  • the first message is a link state protocol data unit (link state protocol data unit) based on the intermediate system to intermediate system (intermediate system to intermediate system, IS-IS) protocol.
  • protocol data unit, LSP protocol data unit
  • LSU link state update
  • OSPF Open Shortest Path First
  • the first message includes a flag field, and the flag field is used to carry the SBFD information.
  • the tunnel is an SR-BE tunnel.
  • a first network device in a third aspect, has a function of implementing the behavior of the first network device in the foregoing method.
  • the functions can be implemented based on hardware, or implemented by corresponding software based on hardware.
  • the hardware or software includes one or more modules corresponding to the above-mentioned functions.
  • the structure of the first network device includes a processor and an interface, and the processor is configured to support the first network device to perform corresponding functions in the foregoing method.
  • the interface is used to support the communication between the first network device and the second network device, send the information or instructions involved in the above method to the second network device, or receive the information involved in the above method from the second network device Or instructions.
  • the first network device may further include a memory, which is configured to be coupled with the processor and stores program instructions and data necessary for the first network device.
  • the first network device includes: a processor, a transmitter, a receiver, a random access memory, a read-only memory, and a bus.
  • the processor is respectively coupled to the transmitter, the receiver, the random access memory, and the read-only memory through the bus.
  • the basic input/output system solidified in the read-only memory or the bootloader guide system in the embedded system is started to guide the first network device into a normal operating state.
  • the application program and the operating system are run in the random access memory, so that the processor executes the first aspect or the method in any possible implementation manner of the first aspect.
  • a first network device in a fourth aspect, includes a main control board and an interface board, and may further include a switching network board.
  • the first network device is configured to execute the first aspect or the method in any possible implementation manner of the first aspect.
  • the first network device includes a module for executing the first aspect or the method in any possible implementation manner of the first aspect.
  • a first network device in a fifth aspect, includes a controller and a first forwarding sub-device.
  • the first forwarding sub-device includes: an interface board, and further, may also include a switching network board.
  • the first forwarding sub-device is used to perform the function of the interface board in the fourth aspect, and further, may also perform the function of the switching network board in the fourth aspect.
  • the controller includes a receiver, a processor, a transmitter, a random access memory, a read-only memory, and a bus. Among them, the processor is respectively coupled to the receiver, the transmitter, the random access memory, and the read-only memory through the bus.
  • the basic input/output system solidified in the read-only memory or the bootloader in the embedded system is used to guide the system to start, and the controller is guided to enter a normal operating state.
  • the application program and the operating system are run in the random access memory, so that the processor executes the function of the main control board in the fourth aspect.
  • a computer storage medium for storing programs, codes, or instructions used by the above-mentioned first network device.
  • a processor or hardware device executes these programs, codes, or instructions, the first in the above-mentioned aspect can be completed.
  • the function or procedure of a network device is provided for storing programs, codes, or instructions used by the above-mentioned first network device.
  • a second network device in a seventh aspect, has a function of realizing the behavior of the second network device in the foregoing method.
  • the functions can be implemented based on hardware, or implemented by corresponding software based on hardware.
  • the hardware or software includes one or more modules corresponding to the above-mentioned functions.
  • the structure of the second network device includes a processor and an interface, and the processor is configured to support the second network device to perform corresponding functions in the foregoing method.
  • the interface is used to support the communication between the second network device and the first network device, send the information or instructions involved in the above method to the first network device, or receive the information or instructions involved in the above method from the first network device The information or instructions involved.
  • the second network device may further include a memory, which is configured to be coupled with the processor and stores necessary program instructions and data for the second network device.
  • the second network device includes: a processor, a transmitter, a receiver, a random access memory, a read-only memory, and a bus.
  • the processor is respectively coupled to the transmitter, the receiver, the random access memory, and the read-only memory through the bus.
  • the basic input/output system solidified in the read-only memory or the bootloader in the embedded system is used to boot the system to guide the second network device into a normal operating state.
  • the application program and the operating system are run in the random access memory, so that the processor executes the second aspect or the method in any possible implementation manner of the second aspect.
  • a second network device in an eighth aspect, includes a main control board and an interface board, and may further include a switching network board.
  • the second network device is used to execute the second aspect or the method in any possible implementation manner of the second aspect.
  • the second network device includes a module for executing the second aspect or the method in any possible implementation manner of the second aspect.
  • a second network device in a ninth aspect, includes a controller and a second forwarding sub-device.
  • the second forwarding sub-device includes: an interface board, and further, may also include a switching network board.
  • the second forwarding sub-device is used to perform the function of the interface board in the eighth aspect, and further, may also perform the function of the switching network board in the eighth aspect.
  • the controller includes a receiver, a processor, a transmitter, a random access memory, a read-only memory, and a bus. Among them, the processor is respectively coupled to the receiver, the transmitter, the random access memory, and the read-only memory through the bus.
  • the basic input/output system solidified in the read-only memory or the bootloader in the embedded system is used to guide the system to start, and the controller is guided to enter a normal operating state.
  • the application program and the operating system are run in the random access memory, so that the processor executes the function of the main control board in the eighth aspect.
  • a computer storage medium for storing programs, codes, or instructions used by the above-mentioned second network device.
  • a processor or hardware device executes these programs, codes or instructions, the second aspect of the above-mentioned aspect can be completed.
  • the function or procedure of a network device is provided for storing programs, codes, or instructions used by the above-mentioned second network device.
  • An eleventh aspect provides a message processing system.
  • the system includes a first network device and a second network device.
  • the first network device is the third aspect or the fourth aspect or the fifth aspect described above.
  • a network device, where the second network device is the second network device in the aforementioned seventh aspect or the eighth aspect or the ninth aspect.
  • the first network device receives the SBFD information sent by the second network device, thereby determining whether it is necessary to create an SBFD session for the tunnel according to the SBFD information, where the tunnel is from the first network device.
  • a tunnel from the network device to the second network device thereby avoiding the creation of unnecessary SBFD sessions, and reducing the number of SBFD sessions in the network.
  • FIG. 1 is a schematic diagram of a network structure according to an embodiment of the application.
  • FIG. 2 is a flowchart of a method for detecting an SR-BE tunnel according to an embodiment of the application
  • FIG. 3 is a flowchart of another SR-BE tunnel detection method according to an embodiment of the application.
  • FIG. 4 is a schematic structural diagram of a first network device according to an embodiment of the application.
  • FIG. 5 is a schematic diagram of the hardware structure of a first network device according to an embodiment of the application.
  • FIG. 6 is a schematic diagram of the hardware structure of another first network device according to an embodiment of the application.
  • FIG. 7 is a schematic structural diagram of a second network device according to an embodiment of the application.
  • FIG. 8 is a schematic diagram of the hardware structure of a second network device according to an embodiment of the application.
  • FIG. 9 is a schematic diagram of the hardware structure of another second network device according to an embodiment of the application.
  • FIG. 1 is a schematic diagram of a network structure according to an embodiment of the application.
  • FIG. 1 relates to a hierarchical virtual private network (HVPN).
  • the HVPN includes a base station side gateway (cell site gateway, CSG), an aggregation side gateway (aggregation site gateway, ASG), and a base station controller side gateway (radio network controller site gateway, RSG).
  • Figure 1 shows four CSG devices, namely CSG1, CSG2, CSG3 and CSG4.
  • CSG1 communicates with CSG2 through a communication link
  • CSG2 communicates with CSG3 through a communication link
  • CSG3 communicates with CSG4 through a communication link.
  • CSG1, CSG2, CSG3 and CSG4 can be connected to one or more base stations respectively.
  • Figure 1 shows two ASG devices, ASG1 and ASG2.
  • ASG1 communicates with ASG2 through a communication link.
  • ASG2 is the redundant device of ASG1.
  • CSG1 communicates with ASG1 through a communication link
  • CSG4 communicates with ASG2 through a communication link.
  • Figure 1 shows two RSG devices, RSG1 and RSG2.
  • RSG1 communicates with RSG2 through a communication link.
  • RSG2 is the redundant device of RSG1.
  • ASG1 communicates with RSG1 through a communication link
  • ASG4 communicates with RSG2 through a communication link.
  • RSG1 and RSG2 can be respectively connected to servers in a data center (DC).
  • DC data center
  • the data traffic is sent from the CSG device in FIG. 1 to the RSG device.
  • the description will be made by taking CSG1 sending data traffic to RSG1 as an example.
  • ASG2 is the redundant device of ASG1. That is, ASG1 is the main ASG device in the HVPN, and ASG2 is the backup ASG device in the HVPN.
  • the data traffic sent by CSG1 reaches RSG1 via ASG1.
  • ASG1 fails, a master-backup switchover occurs between ASG1 and ASG2, ASG1 switches to a backup ASG device, and ASG2 switches to a master ASG device.
  • RSG2 in FIG. 1 can also be used as a backup RSG device of RSG1, and the specific working mode is the same as that of the ASG device in FIG. 1, which will not be repeated here.
  • a tunnel can be used to transmit data traffic.
  • the tunnel is an SR-BE tunnel.
  • an SR-BE tunnel is taken as an example for description. It should be understood that the solution of this application can also be applied to other types of tunnels.
  • the SR-BE tunnel is established based on end-to-end equipment, that is, as long as there is an SR-BE data traffic service, an SR-BE tunnel needs to be established.
  • CSG1 establishes SR-BE tunnels to CSG2, CSG3, CSG4, ASG1, ASG2, RSG1 and RSG2 in Figure 1 respectively.
  • CSG2 is established to CSG1, CSG3, CSG4, ASG1, ASG2, RSG1, and RSG2 in Figure 1, respectively.
  • SR-BE tunnels; CSG3 is established to CSG1, CSG2, CSG4, ASG1, ASG2, RSG1 and RSG1 in Figure 1.
  • the SR-BE tunnel of RSG2; CSG4 is established to the SR-BE tunnels of CSG1, CSG2, CSG3, ASG1, ASG2, RSG1 and RSG2 in Figure 1 respectively.
  • the method for establishing SR-BE tunnels by ASG1, ASG2, RSG1, and RSG2 is similar to the way for CSG devices to establish SR-BE tunnels, and will not be repeated here.
  • the SBFD session is used to detect the failure of the SR-BE tunnel. Take the example of detecting the failure of the SR-BE tunnel from CSG1 to ASG1 based on the SBFD session mechanism.
  • the SR-BE1 tunnel is used to represent the SR-BE tunnel from CSG1 to ASG1.
  • CSG1 is the initiator of the SBFD session, and it can also become the detection end.
  • the initial state of the SBFD state machine in CSG1 is the DOWN state, that is, the state of the port of the CSG1 corresponding to the SR-BE1 tunnel is the DOWN state.
  • the protocol state of the port corresponding to the SR-BE1 tunnel of CSG1 is DOWN with respect to the SBFD protocol.
  • ASG1 sends a first SBFD packet to ASG1 via the SR-BE1 tunnel, where the first SBFD packet is used to request the second network device to establish the SBFD session.
  • the first SBFD packet carries DOWN state information.
  • ASG1 is the reflecting end of the SBFD session. After the ASG1 receives the first SBFD message, it determines whether the peer identifier (your discriminator, YD) in the first SBFD message matches the identifier stored locally in the ASG1. The YD in the first SBFD message is used to indicate ASG1. After the ASG1 determines that the two match and the DOWN state information carried in the first SBFD packet, the ASG1 determines whether the ASG1 is in a working state.
  • ASG1 sends the first SBFD response message of the first SBFD message to CSG1 via the SR-BE tunnel; if ASG1 is in a non-working state, ASG1 does not send the first SBFD response message, and discards the first SBFD response message.
  • An SBFD message wherein, when ASG1 sends the first SBFD response message of the first SBFD message to CSG1 via the SR-BE tunnel, the first SBFD response message carries UP state information, indicating that CSG1 can be switched to the UP state.
  • CSG1 After receiving the first SBFD response message, CSG1 switches the SBFD state machine in CSG1 from DOWN state to UP state according to the UP state information carried in the first SBFD response message, that is, CSG1 switches CSG1 The state of the port corresponding to the SR-BE1 tunnel is switched from the DOWN state to the UP state. Then, CSG1 periodically sends SBFD echo packets to ASG1 at predetermined intervals, where the predetermined duration is, for example, 100 milliseconds. If CSG1 can periodically receive SBFD echo messages sent by itself, CSG1 can determine that the SR-BE1 tunnel or ASG1 is working normally.
  • CSG1 can determine that the SR-BE1 tunnel or ASG1 is faulty.
  • CSG1 determines that the SR-BE1 tunnel or ASG1 is faulty, it triggers the active/standby switchover of the ASG device. Specifically, ASG1 is switched to the standby ASG device, and ASG2 is switched to the main ASG device.
  • CSG1 does not send data traffic through the SR-BE1 tunnel, but sends data traffic through the SR-BE2 tunnel.
  • the SR-BE2 tunnel is an SR-BE tunnel from CSG1 to ASG2.
  • the tunnel endpoint device (for example, CSG1) of the SR-BE tunnel creates an SBFD session, and periodically detects the state of the SR-BE tunnel based on the SBFD session.
  • CSG1 establishes SR-BE tunnels to CSG2, CSG3, CSG4, ASG1, ASG2, RSG1, and RSG2 in Figure 1, respectively, and a total of 7 SR-BE tunnels.
  • CSG1 establishes 7 SBFD sessions corresponding to the 7 SR-BE tunnels mentioned above.
  • ASG1 is the active ASG device
  • ASG2 is the standby ASG device.
  • CSG1 needs to periodically detect the tunnel status of the SR-BE1 tunnel from CSG1 to ASG1 and periodically detect the tunnel status of the SR-BE2 tunnel from CSG1 to ASG2, so that when the SR-BE1 tunnel or ASG1 fails
  • the data traffic sent by CSG1 can be quickly switched from the SR-BE1 tunnel to the SR-BE2 tunnel.
  • the embodiments of the present application provide a method, device, and system for establishing an SBFD session.
  • ASG1 After the SR-BE1 tunnel from CSG1 to ASG1 is established, ASG1 generates a first packet.
  • the first packet includes SBFD information, and the SBFD information is used to indicate the first packet.
  • the network device corresponding to the destination address of a message determines whether to establish an SBFD session for the tunnel, where the destination address is the address of the first network device.
  • the SBFD information indicates whether to start the detection mechanism for the SR-BE1 tunnel.
  • ASG1 sends the first message to CSG1.
  • the CSG1 determines whether the CSG1 is an SR-BE1 tunnel to establish the SBFD session according to the SBFD information in the first message. If CSG1 determines according to the SBFD information that CSG1 does not need to establish an SBFD session for the SR-BE1 tunnel, CSG1 avoids establishing the SBFD session. That is, CSG1 does not send the first SBFD message to ASG1, and the first SBFD message is used to request ASG1 to establish the SBFD session. Specifically, CSG1 will not notify the SBFD state machine in CSG1 to send the first SBFD message.
  • CSG1 determines that an SBFD session needs to be established for the SR-BE1 tunnel according to the SBFD information, CSG1 creates the SBFD session. That is, CSG1 will send a second SBFD message to ASG1, and the second SBFD message is used to request ASG1 to establish the SBFD session. Specifically, CSG1 will notify the SBFD state machine in CSG1 to send the second SBFD message.
  • ASG1 may send the first message carrying SBFD-1 information to CSG1, CSG2, CSG3, and CSG4, respectively.
  • the SBFD-1 information indicates that the network device corresponding to the destination address of the first packet determines that an SBFD session needs to be established for the corresponding SR-BE tunnel.
  • CSG1 is on the SR-BE tunnel from CSG1 to ASG1
  • CSG2 is on the SR-BE tunnel from CSG2 to ASG1
  • CSG3 is on the SR-BE tunnel from CSG3 to ASG1
  • CSG4 is on the SR from CSG4 to ASG1.
  • ASG1 can send a second message carrying SBFD-2 information to ASG2, RSG1 and RSG2, respectively.
  • the SBFD-2 information indicates that the network device receiving the second message determines that it is not necessary to establish an SBFD session for the corresponding SR-BE tunnel.
  • ASG2 does not create an SBFD session on the SR-BE tunnel from ASG2 to ASG1, RSG1 on the SR-BE tunnel from RSG1 to ASG1, and RSG2 on the SR-BE tunnel from RSG2 to ASG1.
  • other network nodes in FIG. 1 can notify the peer device whether it is necessary to establish an SBFD session for the corresponding SR-BE tunnel in the foregoing manner. Therefore, in the network shown in FIG. 1, a large number of useless SBFD sessions will not be established, thereby reducing the occupation of network bandwidth resources.
  • Fig. 2 is a flow chart of a method for detecting an SR-BE tunnel according to an embodiment of the application.
  • the method shown in FIG. 2 can be applied to the network structure shown in FIG. 1.
  • an SR-BE tunnel is taken as an example for description. It should be understood that the solution of this application can also be applied to other types of tunnels.
  • the method includes S101-S105, specifically:
  • the second network device generates a first packet, where the first packet includes SBFD information, and the SBFD information is used to indicate that the network device corresponding to the destination address of the first packet determines whether to establish an SR-BE tunnel.
  • SBFD session the SR-BE tunnel is a tunnel from the first network device to the second network device, the SBFD session is used to detect the status of the SR-BE tunnel, and the destination address is the first The address of the network device.
  • the first network device corresponds to CSG1 in FIG. 1 and the second network device corresponds to CSG2 in FIG. 1 as an example for description.
  • An SR-BE tunnel that is, an SR-BE12 tunnel, is established between CSG1 and CSG2.
  • the SR-BE12 tunnel is an SR-BE tunnel from CSG1 to CSG2.
  • ASG2 is the redundant device of ASG1, that is, ASG1 is the main ASG device
  • ASG2 is the backup ASG device.
  • the CSG2 in Figure 1 is not set with a backup CSG device, that is, CSG2 does not have a corresponding protection device. Therefore, no SBFD session needs to be established on the SR-BE tunnel to CSG2.
  • CSG2 can generate a first message, and the first message includes SBFD information.
  • the SBFD information is used to instruct the CSG1 that received the first message to determine whether to establish an SBFD session for the SR-BE12 tunnel, that is, the SBFD information indicates whether to start the SR-BE12 tunnel detection mechanism (SBFD). Conversation).
  • CSG2 generates the first message based on an intermediate system to intermediate system (intermediate system to intermediate system, IS-IS) protocol.
  • the first message is a link state protocol data unit (LSP) message.
  • the first message includes a segment identifier (SID).
  • SID is a prefix SID (Prefix-SID).
  • Prefix-SID is used for path calculation. Before transmitting data traffic, the Prefix-SID needs to be configured first. Therefore, the first message can be used to issue the Prefix-SID.
  • the first message includes a first type-length-value (type-length-value, TLV) field, and the first TLV field is used to carry the Prefix-SID.
  • the first TLV field includes a flag (flags) field, and the length of the flag field is 8 bits.
  • the flag field is used to carry the SBFD information. For example, the 6th or 7th bit of the flag field is used to carry the SBFD information.
  • CSG2 generates the first message based on the Open Shortest Path First (OSPF) protocol.
  • the first message is a link state update (LSU) message.
  • the first message includes SID.
  • the LSU message includes link-state advertisement (link-state advertisement, LSA) information, the LSA information includes the SID, and the SID is the Prefix-SID.
  • Prefix-SID is used for path calculation. Before transmitting data traffic, the Prefix-SID needs to be configured first, so the first message can be used to issue the Prefix-SID.
  • the first message includes a second type length value (type-length-value, TLV) field, and the second TLV field is used to carry the Prefix-SID.
  • the second TLV field includes a flags field, and the flag field has a length of 8 bits.
  • the flag field is used to carry the SBFD information. For example, the 6th or 7th bit of the flag field is used to carry the SBFD information.
  • the destination address of the SR-BE tunnel is the address corresponding to the SID.
  • multiple SR-BE tunnels may be included between the first network device and the second network device.
  • the second network device may include multiple SIDs, and the multiple SIDs have a one-to-one correspondence with the destination addresses of the multiple SR-BE tunnels.
  • the first network device can determine which SR-BE tunnel of the plurality of SR-BE tunnels needs to be operated according to the value of the SID, that is, for the connection between the first network device and the second network device
  • the specific SR-BE tunnel determines whether an SBFD session needs to be created.
  • the first network device and the second network device include an SR-BE-1 tunnel, an SR-BE-2 tunnel, and an SR-BE-3 tunnel.
  • the destination address of the SR-BE-1 tunnel corresponds to SID-1
  • the destination address of the SR-BE-2 tunnel corresponds to SID-2
  • the destination address of the SR-BE-3 tunnel corresponds to SID-3.
  • the first network device can determine the destination address of the SR-BE-2 tunnel through SID-2, so that the first network The device can determine that it needs to operate on the SR-BE-2 tunnel, that is, whether it needs to create an SBFD session for the SR-BE-2 tunnel.
  • the SBFD session creation process can be implemented for some of the SR-BE tunnels.
  • the SID may be a Prefix-SID
  • the destination address of the SR-BE tunnel may be an Internet Protocol (IP) address.
  • IP Internet Protocol
  • the second network device sends the first packet to the first network device.
  • CSG2 After CSG2 generates the first message, it sends the first message to other network devices in the network structure shown in FIG. 1.
  • the specific CSG2 is sent to CSG1, CSG3, CSG4, ASG1, ASG2, RSG1, and RSG2 respectively The first message.
  • CSG2 sends LSP packets to CSG1, CSG3, CSG4, ASG1, ASG2, RSG1, and RSG2 respectively;
  • CSG2 sends LSP packets to CSG1, CSG3, CSG4, ASG1, ASG2, and RSG1 respectively Send LSU message with RSG2.
  • CSG2 is not configured with a backup CSG device, that is, CSG2 does not have a corresponding protection device.
  • the SBFD information in the first message is used to prevent CSG1 from establishing an SBFD session for the SR-BE12 tunnel. Therefore, no SBFD session needs to be established on the SR-BE tunnel to CSG2. Therefore, the value of the SBFD information included in the first message sent by CSG2 may be "0", so as to prevent CSG1 from initiating an SBFD session for the SR-BE12 tunnel.
  • the first network device receives the first packet sent by the second network device.
  • the first network device determines whether the first network device establishes the SBFD session for the SR-BE tunnel according to the SBFD information.
  • CSG1 parses the first packet to obtain the SBFD information carried in the first packet.
  • CSG1 may determine that the first message is a message sent by CSG2 according to the Prefix-SID carried in the first message, that is, CSG1 may determine that the first message is a message sent by CSG2 according to the Prefix-SID carried in the first message.
  • the SID determines that the SBFD information is detection information indicating the SR-BE12 tunnel.
  • the CSG1 determines whether an SBFD session needs to be established for the SR-BE12 tunnel according to the SBFD information, that is, the CSG1 determines whether to establish an SBFD session on the SR-BE12 tunnel according to the value of the SBFD information. For example, if the value of the SBFD information is "1", CSG1 determines to establish an SBFD session on the SR-BE12 tunnel; the value of the SBFD information is "0", and CSG1 determines not to establish an SBFD session on the SR-BE12 tunnel.
  • the first network device determines according to the SBFD information that the first network device does not need to establish the SBFD session for the SR-BE tunnel, the first network device avoids creating the SBFD session.
  • CSG2 is not configured with a backup CSG device, that is, CSG2 does not have a corresponding protection device. Therefore, no SBFD session needs to be established on the SR-BE tunnel to CSG2. Therefore, the value of the SBFD information included in the first message sent by CSG2 may be "0", so as to prevent CSG1 from creating an SBFD session for the SR-BE12 tunnel.
  • CSG1 determines not to establish the SBFD session of the SR-BE12 tunnel according to the SBFD information, CSG1 does not send the first SBFD packet to CSG2.
  • the first SBFD message is a first message for establishing an SBFD session, and is used to request CSG2 to establish the SBFD session.
  • CSG1 does not send the first SBFD message to CSG2, which means that CSG1 does not establish an SBFD session for the SR-BE12 tunnel.
  • CSG2 will not receive the first SBFD message, and therefore, CSG2 will not send the first SBFD response message of the first SBFD message to CSG1.
  • the SBFD session for the SR-BE12 tunnel will not be established. Specifically, after determining that the value of the SBFD information is "0", the processor in CSG1 will not send a notification message to the SBFD state machine in CSG1. In this way, the SBFD state machine in CSG1 will not trigger the first Generation and transmission of SBFD messages.
  • CSG2 can also send the first message to CSG3, CSG4, RSG1 and RSG2 respectively, so that CSG3, CSG4, RSG1 and RSG2 will not establish an SBFD session to the SR-BE tunnel of CSG2. Therefore, through the implementation of the present application, a large number of useless SBFD sessions will not be established, thereby reducing the occupation of network bandwidth resources.
  • FIG. 3 is a flowchart of another SR-BE tunnel detection method according to an embodiment of the application.
  • the method shown in FIG. 3 can be applied to the network structure shown in FIG. 1.
  • an SR-BE tunnel is taken as an example for description. It should be understood that the solution of this application can also be applied to other types of tunnels.
  • the first network device corresponds to CSG1 in FIG. 1 and the second network device corresponds to ASG1 in FIG. 1 as an example for description.
  • An SR-BE tunnel that is, an SR-BE11 tunnel, is established between CSG1 and ASG1.
  • the SR-BE11 tunnel is an SR-BE tunnel from CSG1 to ASG1.
  • the method shown in Figure 3 includes S101-S112.
  • S101, S102, S103, and S104 shown in FIG. 3 are the same as those of S101, S102, S103, and S104 shown in FIG. 2, and will not be repeated here.
  • the implementation of S101-S104 in FIG. 3 exemplified based on CSG1 and ASG2 is similar to the exemplification of S101-S104 in FIG. 2 based on CSG1 and CSG2, and will not be repeated here.
  • the first network device sends a second SBFD packet to the second network device, where the second SBFD packet is used to request the second network device to establish the SBFD session.
  • ASG2 is the redundant device of ASG1, that is, ASG1 is the main ASG device, and ASG2 is the backup ASG device. Therefore, ASG2 is the corresponding protection device of ASG1, so an SBFD session needs to be established on the SR-BE tunnel to ASG1. Therefore, the value of the SBFD information included in the first message sent by ASG1 may be "1", so that CSG1 can create an SBFD session for the SR-BE11 tunnel.
  • CSG1 determines according to the SBFD information that CSG1 needs to establish an SBFD session for the SR-BE11 tunnel, CSG1 sends the second SBFD message to ASG1.
  • the second SBFD message is the first message for establishing the SBFD session, and is used to request the ASG1 to establish the SBFD session.
  • CSG1 sends the second SBFD message to ASG1, which means that CSG1 initiates a request for establishing an SBFD session for the SR-BE11 tunnel.
  • the processor in CSG1 will send a notification message to the SBFD state machine in CSG1, so that the SBFD state machine in CSG1 will trigger the second SBFD message Generation and delivery.
  • the second SBFD packet carries DOWN state information.
  • the second network device receives the second SBFD packet sent by the first network device.
  • the second network device sends a second SBFD response message of the second SBFD message to the first network device, where the second SBFD response message indicates that the second network device is in a working state.
  • ASG1 is the reflection end of the SBFD session. After the ASG1 receives the second SBFD message, it determines whether the opposite end YD in the second SBFD message matches the identifier stored locally in the ASG1. The YD in the second SBFD message is used to indicate ASG1. After the ASG1 determines that the two match and the DOWN state information carried in the second SBFD packet, the ASG1 determines whether the ASG1 is in a working state. If ASG1 is in the working state, ASG1 sends the second SBFD response message of the second SBFD message to CSG1 via the SR-BE11 tunnel. Wherein, the second SBFD response message carries UP state information, which indicates that CSG1 can be switched to the UP state.
  • the first network device receives the second SBFD response message.
  • the first network device sets the port of the first network device corresponding to the SR-BE tunnel to the UP state according to the second SBFD response message.
  • the first network device sends an SBFD echo message to the second network device, where the SBFD echo message is used to detect the state of the SR-BE tunnel.
  • CSG1 switches the SBFD state machine in CSG1 from the DOWN state to the UP state according to the UP state information carried in the second SBFD response message, that is, CSG1 switches the status of the port corresponding to the SR-BE11 tunnel of CSG1 from the DOWN state to the UP state. Then, CSG1 periodically sends SBFD echo messages to ASG1 at intervals of a predetermined duration, where the predetermined duration is, for example, 100 milliseconds. If CSG1 can periodically receive the SBFD echo message sent by itself, CSG1 can determine that the SR-BE11 tunnel or ASG1 is working normally.
  • CSG1 can determine that the SR-BE11 tunnel or ASG1 is faulty.
  • CSG1 determines that the SR-BE11 tunnel or ASG1 is faulty, it triggers the active/standby switchover of the ASG device. Specifically, ASG1 is switched to the standby ASG device, and ASG2 is switched to the main ASG device.
  • CSG1 does not send data traffic through the SR-BE11 tunnel, but sends data traffic through the SR-BE22 tunnel.
  • the SR-BE22 tunnel is the SR-BE tunnel from CSG1 to ASG2.
  • SBFD sessions can be established only on SR-BE tunnels that require SBFD detection. Therefore, a large number of useless SBFD sessions will not be established, thus reducing the occupation of network bandwidth resources.
  • FIG. 4 is a schematic structural diagram of a first network device 1000 according to an embodiment of the application.
  • the first network device 1000 shown in FIG. 4 can execute the corresponding steps performed by the first network device in the method of the foregoing embodiment.
  • the first network device 1000 includes a receiving unit 1002 and a processing unit 1004.
  • the receiving unit 1002 is configured to receive a first packet sent by a second network device, where the first packet includes SBFD information, and the SBFD information is used to indicate the network device corresponding to the destination address of the first packet Determine whether to establish an SBFD session for a tunnel, where the tunnel is a tunnel from the first network device to the second network device, the SBFD session is used to detect the state of the tunnel, and the destination address is the first network device.
  • the address of a network device is
  • the processing unit 1004 is configured to determine whether the first network device establishes the SBFD session for the tunnel according to the SBFD information
  • the processing unit 1004 determines according to the SBFD information that the first network device does not need to establish the SBFD session for the tunnel, the processing unit 1004 is further configured to avoid creating the SBFD session.
  • the processing unit 1004 determines according to the SBFD information that the first network device needs to establish the SBFD session for the tunnel, the processing unit 1004 is further configured to create the SBFD session.
  • the processing unit 1004 when the processing unit 1004 is further configured to create the SBFD session, the processing unit 1004 is specifically configured to: send an SBFD message to the second network device, where the SBFD message is used to request establishment The SBFD session; receiving an SBFD response message for the SBFD message sent by the second network device, the SBFD response message indicating that the second network device is in a working state; and, responding according to the SBFD The message sets the port of the first network device corresponding to the tunnel to the UP state.
  • the processing unit 1004 is further configured to report to the second network device Send an SBFD echo message, where the SBFD echo message is used to detect the state of the tunnel.
  • the first message is an LSP message based on the IS-IS protocol, or the first message is an LSU message based on the OSPF protocol, and the first message further includes the second network
  • the SID of the device, and the destination address of the tunnel is the address corresponding to the SID.
  • the first message includes a flag field, and the flag field is used to carry the SBFD information.
  • the tunnel is an SR-BE tunnel.
  • the first network device shown in FIG. 4 can execute the corresponding steps performed by the first network device in the method of the foregoing embodiment.
  • the first network device receives the SBFD information sent by the second network device, thereby determining whether it is necessary to create an SBFD session for the tunnel according to the SBFD information, where the tunnel is from the first network device to the The tunnel of the second network device is thus avoided to create unnecessary SBFD sessions, and the number of SBFD sessions in the network is reduced.
  • FIG. 5 is a schematic diagram of the hardware structure of the first network device 1100 according to an embodiment of the application.
  • the first network device 1100 shown in FIG. 5 can execute the corresponding steps performed by the first network device in the method of the foregoing embodiment.
  • the first network device 1100 includes a processor 1101, a memory 1102, an interface 1103, and a bus 1104.
  • the interface 1103 may be implemented in a wireless or wired manner, and specifically may be a network card.
  • the aforementioned processor 1101, memory 1102, and interface 1103 are connected through a bus 1104.
  • the interface 1103 may specifically include a transmitter and a receiver, which are used to send and receive information between the first network device and the second network device in the foregoing embodiment.
  • the interface 1103 is used to support receiving the first packet and the SBFD response packet of the SBFD packet sent by the second network device; it is used to support the sending of the SBFD packet and the SBFD echo packet to the second network device.
  • the interface 1103 is used to support the processes S103, S107, S110, and S112 in FIG. 2 and FIG. 3.
  • the processor 1101 is configured to execute the processing performed by the first network device in the foregoing embodiment.
  • the processor 1101 determines whether to establish an SBFD session for the tunnel; is used to avoid establishing an SBFD session according to the determination result or establish an SBFD session according to the determination result; and/or is used in other processes of the technology described herein.
  • the processor 1101 is used to support the processes S104, S105, S106, and S111 in FIG. 2 and FIG. 3.
  • the memory 1102 includes an operating system 11021 and an application program 11022 for storing programs, codes, or instructions. When a processor or hardware device executes these programs, codes, or instructions, the processing process involving the first network device in the method embodiment can be completed.
  • the memory 1102 may include a read-only memory (English: Read-only Memory, abbreviation: ROM) and a random access memory (English: Random Access Memory, abbreviation: RAM).
  • the ROM includes a basic input/output system (English: Basic Input/Output System, abbreviation: BIOS) or an embedded system;
  • the RAM includes an application program and an operating system.
  • BIOS Basic Input/Output System
  • the system is booted by the BIOS solidified in the ROM or the bootloader in the embedded system to guide the first network device 1100 into a normal operating state.
  • the application program and the operating system run in the RAM, thereby completing the processing procedure involving the first network device in the method embodiment.
  • FIG. 5 only shows a simplified design of the first network device 1100.
  • the first network device may include any number of interfaces, processors or memories.
  • FIG. 6 is a schematic diagram of the hardware structure of another first network device 1200 according to an embodiment of the application.
  • the first network device 1200 shown in FIG. 6 can execute the corresponding steps performed by the first network device in the method of the foregoing embodiment.
  • the first network device 1200 includes: a main control board 1210, an interface board 1230, a switching network board 1220, and an interface board 1240.
  • the main control board 1210, the interface boards 1230 and 1240, and the switching network board 1220 are connected to the system backplane through the system bus to achieve intercommunication.
  • the main control board 1210 is used to complete functions such as system management, equipment maintenance, and protocol processing.
  • the switching network board 1220 is used to complete data exchange between various interface boards (interface boards are also called line cards or service boards).
  • the interface boards 1230 and 1240 are used to provide various service interfaces (for example, POS interface, GE interface, ATM interface, etc.), and realize data packet forwarding
  • the interface board 1230 may include a central processing unit 1231, a forwarding entry memory 1234, a physical interface card 1233, and a network processor 1232.
  • the central processing unit 1231 is used to control and manage the interface board and communicate with the central processing unit on the main control board.
  • the forwarding entry storage 1234 is used to store forwarding entries.
  • the physical interface card 1233 is used to complete the reception and transmission of traffic.
  • the network storage 1232 is used to control the receiving and sending traffic of the physical interface card 1233 according to the forwarding entry.
  • the physical interface card 1233 is configured to receive the first message and the SBFD response message of the SBFD message sent by the second network device, and is configured to send the SBFD message and the SBFD echo message to the second network device. Text.
  • the central processor 1211 is used to determine whether to establish an SBFD session for the tunnel; and used to avoid establishing an SBFD session according to the determination result or establish an SBFD session according to the determination result.
  • the central processor 1211 is also configured to process the received first message and the SBFD response message of the SBFD message; and generate the sent SBFD message and the SBFD echo message.
  • the physical interface card 1233 After receiving the first message and the SBFD response message of the SBFD message, the physical interface card 1233 sends the first message and the SBFD response message of the SBFD message to the central processing unit 1211 via the central processing unit 1231. 1211 processes the first message and the SBFD response message of the SBFD message.
  • the central processing unit 1231 is also used to control the network storage 1232 to obtain forwarding entries in the forwarding entry storage 1234, and the central processing unit 1231 is also used to control the network storage 1232 to receive and send traffic via the physical interface card 1233.
  • the operations on the interface board 1240 in the embodiment of the present invention are consistent with the operations on the interface board 1230, and will not be repeated for the sake of brevity.
  • the first network device 1200 in this embodiment may correspond to the functions and/or various steps implemented in the foregoing method embodiments, and details are not described herein again.
  • main control boards there may be one or more main control boards, and when there are more than one, it may include a main main control board and a standby main control board.
  • the switching network board may not exist, or there may be one or more. When there are more than one, the load sharing and redundant backup can be realized together. Under the centralized forwarding architecture, the first network device may not need to switch the network board, and the interface board undertakes the processing function of the service data of the entire system.
  • the first network device may have at least one switching network board, and data exchange between multiple interface boards is realized through the switching network board, providing large-capacity data exchange and processing capabilities. Therefore, the data access and processing capability of the first network device of the distributed architecture is greater than that of the device of the centralized architecture.
  • the specific architecture used depends on the specific networking deployment scenario, and there is no restriction here.
  • FIG. 7 is a schematic structural diagram of a second network device 2000 according to an embodiment of the application.
  • the second network device 2000 shown in FIG. 7 can execute the corresponding steps performed by the second network device in the method of the foregoing embodiment.
  • the second network device 2000 includes a processing unit 2004 and a sending unit 2006.
  • the processing unit 2004 is configured to generate a first message, the first message including seamless bidirectional forwarding detection SBFD information, and the SBFD information is used to indicate that the network device corresponding to the destination address of the first message is determined Whether to establish an SBFD session for the tunnel, the tunnel is a tunnel from the first network device to the second network device, the SBFD session is used to detect the state of the tunnel, and the destination address is the first network device the address of;
  • the sending unit 2006 is configured to send the first message to the first network device, where the SBFD information in the first message is used to prevent the first network device from establishing SBFD session of the tunnel.
  • the first message is an LSP message based on the IS-IS protocol, or the first message is an LSU message based on the OSPF protocol, and the first message further includes the second network
  • the SID of the device, and the destination address of the tunnel is the address corresponding to the SID.
  • the first message includes a flag field, and the flag field is used to carry the SBFD information.
  • the tunnel is an SR-BE tunnel.
  • the second network device shown in FIG. 7 can execute the corresponding steps performed by the second network device in the method of the foregoing embodiment.
  • the first network device receives the SBFD information sent by the second network device, thereby determining whether it is necessary to create an SBFD session for the tunnel according to the SBFD information, where the tunnel is from the first network device to the The tunnel of the second network device is thus avoided to create unnecessary SBFD sessions, and the number of SBFD sessions in the network is reduced.
  • FIG. 8 is a schematic diagram of the hardware structure of the second network device 2100 according to an embodiment of the application.
  • the second network device 2100 shown in FIG. 8 can execute the corresponding steps performed by the second network device in the method of the foregoing embodiment.
  • the second network device 2100 includes a processor 2101, a memory 2102, an interface 2103 and a bus 2104.
  • the interface 2103 may be implemented in a wireless or wired manner, and specifically may be a network card.
  • the aforementioned processor 2101, memory 2102, and interface 2103 are connected through a bus 2104.
  • the interface 2103 may specifically include a transmitter and a receiver, which are used to send and receive information between the second network device and the first network device in the foregoing embodiment.
  • the interface 2103 is used to support sending a first message and an SBFD message to the first network device; and is used to support receiving an SBFD response message and an SBFD echo message of an SBFD message sent by the first network device.
  • the interface 2103 is used to support the processes S102, S108, and S109 in FIG. 2 and FIG. 3.
  • the processor 2101 is configured to execute the processing performed by the second network device in the foregoing embodiment.
  • the processor 2101 is used to generate the first message; and/or used in other processes of the technology described herein.
  • the processor 2101 is used to support the process S101 in FIG. 2 and FIG. 3.
  • the memory 2102 includes an operating system 21021 and an application program 21022, which are used to store programs, codes, or instructions. When the processor or hardware device executes these programs, codes, or instructions, the processing process involving the second network device in the method embodiment can be completed.
  • the memory 2102 may include a read-only memory (English: Read-only Memory, abbreviation: ROM) and a random access memory (English: Random Access Memory, abbreviation: RAM).
  • the ROM includes a basic input/output system (English: Basic Input/Output System, abbreviation: BIOS) or an embedded system;
  • the RAM includes an application program and an operating system.
  • the system is booted by the BIOS solidified in the ROM or the bootloader in the embedded system to guide the second network device 2100 into a normal operating state.
  • the application program and the operating system run in the RAM, thereby completing the processing procedure involving the second network device in the method embodiment.
  • FIG. 8 only shows a simplified design of the second network device 2100.
  • the second network device may include any number of interfaces, processors or memories.
  • FIG. 9 is a schematic diagram of the hardware structure of another second network device 2200 according to an embodiment of the application.
  • the second network device 2200 shown in FIG. 9 can execute the corresponding steps performed by the second network device in the method of the foregoing embodiment.
  • the second network device 2200 includes: a main control board 2210, an interface board 2230, a switching network board 2220, and an interface board 2240.
  • the main control board 2210, the interface boards 2230 and 2240, and the switching network board 2220 are connected to the system backplane through the system bus to achieve intercommunication.
  • the main control board 2210 is used to complete functions such as system management, equipment maintenance, and protocol processing.
  • the switching network board 2220 is used to complete data exchange between various interface boards (interface boards are also called line cards or service boards).
  • the interface boards 2230 and 2240 are used to provide various service interfaces (for example, POS interface, GE interface, ATM interface, etc.), and realize the forwarding of data packets
  • the interface board 2230 may include a central processing unit 2231, a forwarding entry memory 2234, a physical interface card 2233, and a network processor 2232.
  • the central processing unit 2231 is used to control and manage the interface board and communicate with the central processing unit on the main control board.
  • the forwarding entry storage 2234 is used to store forwarding entries.
  • the physical interface card 2233 is used to complete the reception and transmission of traffic.
  • the network storage 2232 is used for controlling the receiving and sending traffic of the physical interface card 2233 according to the forwarding entry.
  • the physical interface card 2233 is configured to send a first message and an SBFD message to the first network device; and is configured to receive an SBFD response message and an SBFD echo message of the SBFD message sent by the first network device.
  • the central processing unit 2211 is configured to generate the first message.
  • the central processing unit 2211 sends the first message to the physical interface card 2233 via the central processing unit 2231.
  • the physical interface card 2233 sends the first packet to the NAT device.
  • the central processing unit 2231 is also used to control the network storage 2232 to obtain forwarding entries in the forwarding entry storage 2234, and the central processing unit 2231 is also used to control the network storage 2232 to complete the reception and transmission of traffic via the physical interface card 2233.
  • the operations on the interface board 2240 in the embodiment of the present invention are consistent with the operations on the interface board 2230, and will not be repeated for the sake of brevity.
  • the second network device 2200 in this embodiment may correspond to the functions and/or various steps implemented in the foregoing method embodiments, and details are not described herein again.
  • main control boards there may be one or more main control boards, and when there are more than one, it may include a main main control board and a standby main control board.
  • the switching network board may not exist, or there may be one or more. When there are more than one, the load sharing and redundant backup can be realized together. Under the centralized forwarding architecture, the second network device may not need a switching network board, and the interface board is responsible for processing the service data of the entire system.
  • the second network device may have at least one switching network board, and data exchange between multiple interface boards is realized through the switching network board, providing large-capacity data exchange and processing capabilities. Therefore, the data access and processing capability of the second network device of the distributed architecture is greater than that of the device of the centralized architecture.
  • the specific architecture used depends on the specific networking deployment scenario, and there is no restriction here.
  • an embodiment of the present application provides a computer storage medium for storing computer software instructions used for the above-mentioned first network device, which includes a program for executing the above-mentioned method embodiment.
  • an embodiment of the present application provides a computer storage medium for storing computer software instructions used for the above-mentioned second network device, which includes a program for executing the above-mentioned method embodiment.
  • the embodiment of the present application also includes a system for processing a message.
  • the system includes a first network device and a second network device.
  • the first network device is the first network device in FIG. 4 or FIG. 5 or FIG.
  • the second network device is the second network device in FIG. 7 or FIG. 8 or FIG. 9 described above.
  • the steps of the method or algorithm described in combination with the disclosure of this application can be implemented in a hardware manner, or can be implemented in a manner in which a processor executes software instructions.
  • Software instructions can be composed of corresponding software modules, which can be stored in RAM memory, flash memory, ROM memory, EPROM memory, EEPROM memory, registers, hard disk, mobile hard disk, CD-ROM or any other form of storage known in the art Medium.
  • An exemplary storage medium is coupled to the processor, so that the processor can read information from the storage medium and write information to the storage medium.
  • the storage medium may also be an integral part of the processor.
  • the processor and the storage medium may be located in the ASIC.
  • the ASIC may be located in the user equipment.
  • the processor and the storage medium may also exist as discrete components in the user equipment.
  • the functions described in this application can be implemented by hardware or a combination of hardware and software.
  • the software can be stored in a computer-readable medium or transmitted as one or more instructions or codes on the computer-readable medium.
  • the computer-readable medium includes a computer storage medium and a communication medium, where the communication medium includes any medium that facilitates the transfer of a computer program from one place to another.
  • the storage medium may be any available medium that can be accessed by a general-purpose or special-purpose computer.

Abstract

A method, device, and system for establishing an SBFD session. The method comprises: a first network device receives a first packet transmitted by a second network device, the first packet comprising SBFD information; the first network device determines, on the basis of the SBFD information, whether the first network device is to establish an SBFD session for a tunnel; moreover, when the first network device determines, on the basis of the SBFD information, that the first network device does not need to establish the SBFD session for the tunnel, the first network device refrains from establishing the SBFD session. Hence, the establishment of an unnecessary SBFD session is avoided, and the number of SBFD sessions in a network is reduced.

Description

一种SBFD会话的建立方法、设备及系统Method, equipment and system for establishing SBFD session
本申请要求于2019年09月05日提交国家知识产权局、申请号为201910839079.X、发明名称为“一种SBFD会话的建立方法、设备及系统”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。This application claims the priority of a Chinese patent application filed with the State Intellectual Property Office, the application number is 201910839079.X, and the invention title is "A method, equipment and system for establishing an SBFD session" on September 5, 2019, and its entire contents Incorporated in this application by reference.
技术领域Technical field
本申请涉及通信技术领域,尤其涉及一种无缝双向转发检测(seamless BFD,SBFD)会话的建立方法、设备及系统。This application relates to the field of communication technology, and in particular to a method, device and system for establishing a seamless BFD (SBFD) session.
背景技术Background technique
段路由(segment routing,SR)是基于源路由理念而设计的在网络上转发数据包的一种协议。SR多协议标签交换(multi-protocol label switch,MPLS)是指基于MPLS转发平面的Segment Routing。分段路由尽力而为(segment routing-best effort,SR-BE)是使用SR作为控制协议的一种新型的隧道技术。SR-BE基于内部网关协议(interior gateway protocol,IGP)、通过最短路径优先(shortest path first,SPF)计算得到最优SR标签交换路径(label switched path,LSP)。采用了SR-BE的隧道可以根据首节点的MPLS标签控制报文在网络中的传输路径。SR-BE隧道用于面向无连接的、Mesh业务承载,提供任意拓扑业务连接并简化隧道规划和部署。Segment routing (SR) is a protocol designed to forward data packets on the network based on the concept of source routing. SR multi-protocol label switch (MPLS) refers to Segment Routing based on the MPLS forwarding plane. Segment routing-best effort (SR-BE) is a new type of tunneling technology that uses SR as a control protocol. SR-BE is based on the interior gateway protocol (IGP) and the shortest path first (SPF) calculation to obtain the optimal SR label switched path (LSP). The SR-BE tunnel can control the transmission path of the message in the network according to the MPLS label of the first node. The SR-BE tunnel is used for connectionless, Mesh service bearer, provides service connections of any topology and simplifies tunnel planning and deployment.
SR-BE隧道的故障检测需要依靠部署双向转发检测(bidirectional forwarding detection,BFD)机制实现。当网络中出现网络设备节点故障时,根据BFD的检测结果实现快速切换。无缝双向转发检测(seamless BFD,SBFD)简化了BFD的状态机,缩短了协商时间,提高了整个网络的灵活性,能够支撑SR-BE隧道检测。The fault detection of the SR-BE tunnel requires the deployment of a bidirectional forwarding detection (bidirectional forwarding detection, BFD) mechanism. When a network device node failure occurs in the network, fast switching is realized according to the detection result of BFD. Seamless bidirectional forwarding detection (seamless BFD, SBFD) simplifies the BFD state machine, shortens the negotiation time, improves the flexibility of the entire network, and can support SR-BE tunnel detection.
在实际的网络场景中,SR-BE隧道是基于网络中端到端的网络设备建立的,每条SR-BE隧道两端的网络设备均使能SBFD机制。因此,SR-BE隧道中只要存在SR-BE业务,SR-BE隧道两端的网络设备就会建立SBFD会话。然而,只有具备节点保护机制的网络设备需要根据SBFD会话的检测结果实现故障快速切换。这样,网络中,可能存在大量无用的SBFD会话,从而造成网络中带宽资源的浪费。In actual network scenarios, SR-BE tunnels are established based on end-to-end network devices in the network, and the network devices at both ends of each SR-BE tunnel enable the SBFD mechanism. Therefore, as long as the SR-BE service exists in the SR-BE tunnel, the network devices at both ends of the SR-BE tunnel will establish an SBFD session. However, only network devices with a node protection mechanism need to implement fast failover based on the detection result of the SBFD session. In this way, there may be a large number of useless SBFD sessions in the network, resulting in a waste of bandwidth resources in the network.
发明内容Summary of the invention
有鉴于此,本申请实施例提供了一种SBFD会话的建立方法、设备及系统。在网络中,第一网络设备接收第二网络设备发送的SBFD信息,从而根据所述SBFD信息确定避免为隧道创建SBFD会话,其中,所述隧道是从所述第一网络设备到所述第二网络设备的隧道,从而,减少所述网络中的SBFD会话的数量。In view of this, the embodiments of the present application provide a method, device, and system for establishing an SBFD session. In the network, the first network device receives the SBFD information sent by the second network device, thereby determining, according to the SBFD information, to avoid creating an SBFD session for the tunnel, where the tunnel is from the first network device to the second network device. Tunneling of network devices, thereby reducing the number of SBFD sessions in the network.
本申请实施例提供的技术方案如下。The technical solutions provided by the embodiments of the present application are as follows.
第一方面,提供了一种SBFD会话的建立方法,所述方法包括,第一网络设备接收第二网络设备发送的第一报文,所述第一报文包括SBFD信息。其中,所述SBFD信息用于指示所述第一报文的目的地址对应的网络设备确定是否为隧道建立SBFD会话,所述隧道是从所述第一网络设备到所述第二网络设备的隧道,所述SBFD会话用于检测所述隧道的状态,所述目的地址是所述第一网络设备的地址。然后,所述第一网络设备获取所述第一报文中的所述SBFD信息,并所述SBFD信息确定所述第一网络设备是否为所述隧道建立所述SBFD会话。当所述第一网络设备根据所述SBFD信息确定所述第一网络设备不需要为所述隧道建立所述SBFD会话时,所述第一网络设备避免创建所述SBFD会话。In a first aspect, a method for establishing an SBFD session is provided. The method includes a first network device receiving a first packet sent by a second network device, the first packet including SBFD information. Wherein, the SBFD information is used to instruct the network device corresponding to the destination address of the first packet to determine whether to establish an SBFD session for the tunnel, and the tunnel is a tunnel from the first network device to the second network device The SBFD session is used to detect the state of the tunnel, and the destination address is the address of the first network device. Then, the first network device obtains the SBFD information in the first packet, and the SBFD information determines whether the first network device establishes the SBFD session for the tunnel. When the first network device determines according to the SBFD information that the first network device does not need to establish the SBFD session for the tunnel, the first network device avoids creating the SBFD session.
基于实施例提供的方案,在实际网络场景中,第一网络设备接收第二网络设备发送的SBFD信息,从而根据所述SBFD信息确定是否需要为隧道创建SBFD会话,其中,所述隧道是从所述第一网络设备到所述第二网络设备的隧道,从而,避免创建不必要的SBFD会话,减少所述网络中的SBFD会话的数量。Based on the solution provided in the embodiment, in an actual network scenario, the first network device receives the SBFD information sent by the second network device, thereby determining whether it is necessary to create an SBFD session for the tunnel according to the SBFD information, where the tunnel is from all The tunnel from the first network device to the second network device is thus avoided to create unnecessary SBFD sessions, and the number of SBFD sessions in the network is reduced.
在第一方面的一种可能的实现方式中,当所述第一网络设备根据所述SBFD信息确定所述第一网络设备需要为所述隧道建立所述SBFD会话时,所述第一网络设备创建所述SBFD会话。In a possible implementation manner of the first aspect, when the first network device determines that the first network device needs to establish the SBFD session for the tunnel according to the SBFD information, the first network device Create the SBFD session.
可选的,所述第一网络设备创建所述SBFD会话,包括:向所述第二网络设备发送SBFD报文,所述SBFD报文用于请求建立所述SBFD会话;接收所述第二网络设备发送的针对所述SBFD报文的SBFD回应报文,所述SBFD回应报文指示所述第二网络设备处于工作状态;和,根据所述SBFD回应报文将所述第一网络设备的对应所述隧道的端口设置为UP状态。Optionally, the creation of the SBFD session by the first network device includes: sending an SBFD message to the second network device, where the SBFD message is used to request the establishment of the SBFD session; and receiving the second network device An SBFD response message sent by the device to the SBFD message, the SBFD response message indicating that the second network device is in a working state; and, according to the SBFD response message, the corresponding of the first network device The port of the tunnel is set to the UP state.
可选的,在所述第一网络设备根据所述SBFD回应报文将所述第一网络设备的对应所述隧道的端口设置为UP状态之后,所述方法包括:所述第一网络设备向所述第二网络设备发送SBFD回声报文,所述SBFD回声报文用于检测所述隧道的状态。Optionally, after the first network device sets the port corresponding to the tunnel of the first network device to the UP state according to the SBFD response message, the method includes: The second network device sends an SBFD echo message, and the SBFD echo message is used to detect the state of the tunnel.
第二方面,提供了一种SBFD会话的建立方法,所述方法包括,第二网络设备生成第一报文,所述第一报文包括SBFD信息。其中,所述SBFD信息用于指示所述第一报文的目的地址对应的网络设备确定是否为隧道建立SBFD会话,所述隧道是从第一网络设备到所述第二网络设备的隧道,所述SBFD会话用于检测所述隧道的状态,所述目的地址是所述第一网络设备的地址。然后,所述第二网络设备向所述第一网络设备发送所述第一报文,其中,所述第一报文中的所述SBFD信息用于阻止所述第一网络设备建立针对所述隧道的SBFD会话。In a second aspect, a method for establishing an SBFD session is provided. The method includes that a second network device generates a first packet, and the first packet includes SBFD information. Wherein, the SBFD information is used to instruct the network device corresponding to the destination address of the first packet to determine whether to establish an SBFD session for the tunnel, and the tunnel is a tunnel from the first network device to the second network device, so The SBFD session is used to detect the state of the tunnel, and the destination address is the address of the first network device. Then, the second network device sends the first message to the first network device, where the SBFD information in the first message is used to prevent the first network device from establishing SBFD session of the tunnel.
基于实施例提供的方案,在实际网络场景中,第一网络设备接收第二网络设备发送的SBFD信息,从而根据所述SBFD信息确定是否需要为隧道创建SBFD会话,其中,所述隧道是从所述第一网络设备到所述第二网络设备的隧道,从而,避免创建不必要的SBFD会话,减少所述网络中的SBFD会话的数量。Based on the solution provided in the embodiment, in an actual network scenario, the first network device receives the SBFD information sent by the second network device, thereby determining whether it is necessary to create an SBFD session for the tunnel according to the SBFD information, where the tunnel is from all The tunnel from the first network device to the second network device is thus avoided to create unnecessary SBFD sessions, and the number of SBFD sessions in the network is reduced.
在上述第一方面或第二方面中,可选的,所述第一报文是基于中间系统到中间系统(intermediate system to intermediate system,IS-IS)协议的链路状态协议数据单元(link state protocol data unit,LSP)报文,或者所述第一报文是基于开放式最短路径优先(Open Shortest Path First,OSPF)协议的链路状态更新(link state update,LSU),所述第一报文还包括所述第二网络设备的段标识(segment identifier,SID),所述隧道的目的地址为对应所述SID的地址。进一步可选的,所述第一报文包括标志字段,所述标志字段用于承载所述SBFD信息。In the foregoing first aspect or second aspect, optionally, the first message is a link state protocol data unit (link state protocol data unit) based on the intermediate system to intermediate system (intermediate system to intermediate system, IS-IS) protocol. protocol data unit, LSP) message, or the first message is a link state update (LSU) based on the Open Shortest Path First (Open Shortest Path First, OSPF) protocol, the first message The text also includes the segment identifier (SID) of the second network device, and the destination address of the tunnel is the address corresponding to the SID. Further optionally, the first message includes a flag field, and the flag field is used to carry the SBFD information.
可选的,所述隧道是SR-BE隧道。Optionally, the tunnel is an SR-BE tunnel.
第三方面,提供了一种第一网络设备,所述第一网络设备具有实现上述方法中第一网络设备行为的功能。所述功能可以基于硬件实现,也可以基于硬件执行相应的软件实现。所述硬件或软件包括一个或多个与上述功能相对应的模块。In a third aspect, a first network device is provided, and the first network device has a function of implementing the behavior of the first network device in the foregoing method. The functions can be implemented based on hardware, or implemented by corresponding software based on hardware. The hardware or software includes one or more modules corresponding to the above-mentioned functions.
在一个可能的设计中,第一网络设备的结构中包括处理器和接口,所述处理器被配置为支持第一网络设备执行上述方法中相应的功能。所述接口用于支持第一网络设备与第二网络设备之间的通信,向第二网络设备发送上述方法中所涉及的信息或者指令, 或者从第二网络设备接收上述方法中所涉及的信息或者指令。所述第一网络设备还可以包括存储器,所述存储器用于与处理器耦合,其保存第一网络设备必要的程序指令和数据。In a possible design, the structure of the first network device includes a processor and an interface, and the processor is configured to support the first network device to perform corresponding functions in the foregoing method. The interface is used to support the communication between the first network device and the second network device, send the information or instructions involved in the above method to the second network device, or receive the information involved in the above method from the second network device Or instructions. The first network device may further include a memory, which is configured to be coupled with the processor and stores program instructions and data necessary for the first network device.
在另一个可能的设计中,所述第一网络设备包括:处理器、发送器、接收器、随机存取存储器、只读存储器以及总线。其中,处理器通过总线分别耦接发送器、接收器、随机存取存储器以及只读存储器。其中,当需要运行第一网络设备时,通过固化在只读存储器中的基本输入/输出系统或者嵌入式系统中的bootloader引导系统进行启动,引导第一网络设备进入正常运行状态。在第一网络设备进入正常运行状态后,在随机存取存储器中运行应用程序和操作系统,使得该处理器执行第一方面或第一方面的任意可能的实现方式中的方法。In another possible design, the first network device includes: a processor, a transmitter, a receiver, a random access memory, a read-only memory, and a bus. Among them, the processor is respectively coupled to the transmitter, the receiver, the random access memory, and the read-only memory through the bus. Wherein, when the first network device needs to be operated, the basic input/output system solidified in the read-only memory or the bootloader guide system in the embedded system is started to guide the first network device into a normal operating state. After the first network device enters the normal operating state, the application program and the operating system are run in the random access memory, so that the processor executes the first aspect or the method in any possible implementation manner of the first aspect.
第四方面,提供一种第一网络设备,所述第一网络设备包括:主控板和接口板,进一步,还可以包括交换网板。所述第一网络设备用于执行第一方面或第一方面的任意可能的实现方式中的方法。具体地,所述第一网络设备包括用于执行第一方面或第一方面的任意可能的实现方式中的方法的模块。In a fourth aspect, a first network device is provided. The first network device includes a main control board and an interface board, and may further include a switching network board. The first network device is configured to execute the first aspect or the method in any possible implementation manner of the first aspect. Specifically, the first network device includes a module for executing the first aspect or the method in any possible implementation manner of the first aspect.
第五方面,提供一种第一网络设备,所述第一网络设备包括控制器和第一转发子设备。所述第一转发子设备包括:接口板,进一步,还可以包括交换网板。所述第一转发子设备用于执行第四方面中的接口板的功能,进一步,还可以执行第四方面中交换网板的功能。所述控制器包括接收器、处理器、发送器、随机存取存储器、只读存储器以及总线。其中,处理器通过总线分别耦接接收器、发送器、随机存取存储器以及只读存储器。其中,当需要运行控制器时,通过固化在只读存储器中的基本输入/输出系统或者嵌入式系统中的bootloader引导系统进行启动,引导控制器进入正常运行状态。在控制器进入正常运行状态后,在随机存取存储器中运行应用程序和操作系统,使得该处理器执行第四方面中主控板的功能。In a fifth aspect, a first network device is provided. The first network device includes a controller and a first forwarding sub-device. The first forwarding sub-device includes: an interface board, and further, may also include a switching network board. The first forwarding sub-device is used to perform the function of the interface board in the fourth aspect, and further, may also perform the function of the switching network board in the fourth aspect. The controller includes a receiver, a processor, a transmitter, a random access memory, a read-only memory, and a bus. Among them, the processor is respectively coupled to the receiver, the transmitter, the random access memory, and the read-only memory through the bus. Among them, when the controller needs to be operated, the basic input/output system solidified in the read-only memory or the bootloader in the embedded system is used to guide the system to start, and the controller is guided to enter a normal operating state. After the controller enters the normal operating state, the application program and the operating system are run in the random access memory, so that the processor executes the function of the main control board in the fourth aspect.
第六方面,提供了一种计算机存储介质,用于储存为上述第一网络设备所用的程序、代码或指令,当处理器或硬件设备执行这些程序、代码或指令时可以完成上述方面中第一网络设备的功能或步骤。In a sixth aspect, a computer storage medium is provided for storing programs, codes, or instructions used by the above-mentioned first network device. When a processor or hardware device executes these programs, codes, or instructions, the first in the above-mentioned aspect can be completed. The function or procedure of a network device.
第七方面,提供了一种第二网络设备,所述第二网络设备具有实现上述方法中第二网络设备行为的功能。所述功能可以基于硬件实现,也可以基于硬件执行相应的软件实现。所述硬件或软件包括一个或多个与上述功能相对应的模块。In a seventh aspect, a second network device is provided, and the second network device has a function of realizing the behavior of the second network device in the foregoing method. The functions can be implemented based on hardware, or implemented by corresponding software based on hardware. The hardware or software includes one or more modules corresponding to the above-mentioned functions.
在一个可能的设计中,第二网络设备的结构中包括处理器和接口,所述处理器被配置为支持第二网络设备执行上述方法中相应的功能。所述接口用于支持第二网络设备与第一网络设备之间的通信,向所述第一网络设备发送上述方法中所涉及的信息或者指令,或者从所述第一网络设备接收上述方法中所涉及的信息或者指令。所述第二网络设备还可以包括存储器,所述存储器用于与处理器耦合,其保存第二网络设备必要的程序指令和数据。In a possible design, the structure of the second network device includes a processor and an interface, and the processor is configured to support the second network device to perform corresponding functions in the foregoing method. The interface is used to support the communication between the second network device and the first network device, send the information or instructions involved in the above method to the first network device, or receive the information or instructions involved in the above method from the first network device The information or instructions involved. The second network device may further include a memory, which is configured to be coupled with the processor and stores necessary program instructions and data for the second network device.
在另一个可能的设计中,所述第二网络设备包括:处理器、发送器、接收器、随机存取存储器、只读存储器以及总线。其中,处理器通过总线分别耦接发送器、接收器、随机存取存储器以及只读存储器。其中,当需要运行第二网络设备时,通过固化在只读存储器中的基本输入/输出系统或者嵌入式系统中的bootloader引导系统进行启动,引导第二网络设备进入正常运行状态。在第二网络设备进入正常运行状态后,在随机 存取存储器中运行应用程序和操作系统,使得该处理器执行第二方面或第二方面的任意可能的实现方式中的方法。In another possible design, the second network device includes: a processor, a transmitter, a receiver, a random access memory, a read-only memory, and a bus. Among them, the processor is respectively coupled to the transmitter, the receiver, the random access memory, and the read-only memory through the bus. Wherein, when the second network device needs to be operated, the basic input/output system solidified in the read-only memory or the bootloader in the embedded system is used to boot the system to guide the second network device into a normal operating state. After the second network device enters the normal operating state, the application program and the operating system are run in the random access memory, so that the processor executes the second aspect or the method in any possible implementation manner of the second aspect.
第八方面,提供一种第二网络设备,所述第二网络设备包括:主控板和接口板,进一步,还可以包括交换网板。所述第二网络设备用于执行第二方面或第二方面的任意可能的实现方式中的方法。具体地,所述第二网络设备包括用于执行第二方面或第二方面的任意可能的实现方式中的方法的模块。In an eighth aspect, a second network device is provided. The second network device includes a main control board and an interface board, and may further include a switching network board. The second network device is used to execute the second aspect or the method in any possible implementation manner of the second aspect. Specifically, the second network device includes a module for executing the second aspect or the method in any possible implementation manner of the second aspect.
第九方面,提供一种第二网络设备,所述第二网络设备包括控制器和第二转发子设备。所述第二转发子设备包括:接口板,进一步,还可以包括交换网板。所述第二转发子设备用于执行第八方面中的接口板的功能,进一步,还可以执行第八方面中交换网板的功能。所述控制器包括接收器、处理器、发送器、随机存取存储器、只读存储器以及总线。其中,处理器通过总线分别耦接接收器、发送器、随机存取存储器以及只读存储器。其中,当需要运行控制器时,通过固化在只读存储器中的基本输入/输出系统或者嵌入式系统中的bootloader引导系统进行启动,引导控制器进入正常运行状态。在控制器进入正常运行状态后,在随机存取存储器中运行应用程序和操作系统,使得该处理器执行第八方面中主控板的功能。In a ninth aspect, a second network device is provided, and the second network device includes a controller and a second forwarding sub-device. The second forwarding sub-device includes: an interface board, and further, may also include a switching network board. The second forwarding sub-device is used to perform the function of the interface board in the eighth aspect, and further, may also perform the function of the switching network board in the eighth aspect. The controller includes a receiver, a processor, a transmitter, a random access memory, a read-only memory, and a bus. Among them, the processor is respectively coupled to the receiver, the transmitter, the random access memory, and the read-only memory through the bus. Among them, when the controller needs to be operated, the basic input/output system solidified in the read-only memory or the bootloader in the embedded system is used to guide the system to start, and the controller is guided to enter a normal operating state. After the controller enters the normal operating state, the application program and the operating system are run in the random access memory, so that the processor executes the function of the main control board in the eighth aspect.
第十方面,提供了一种计算机存储介质,用于储存为上述第二网络设备所用的程序、代码或指令,当处理器或硬件设备执行这些程序、代码或指令时可以完成上述方面中第二网络设备的功能或步骤。In a tenth aspect, a computer storage medium is provided for storing programs, codes, or instructions used by the above-mentioned second network device. When a processor or hardware device executes these programs, codes or instructions, the second aspect of the above-mentioned aspect can be completed. The function or procedure of a network device.
第十一方面,提供一种处理报文的系统,所述系统包括第一网络设备和第二网络设备,所述第一网络设备为前述第三方面或第四方面或第五方面中的第一网络设备,所述第二网络设备为前述第七方面或第八方面或第九方面中的第二网络设备。An eleventh aspect provides a message processing system. The system includes a first network device and a second network device. The first network device is the third aspect or the fourth aspect or the fifth aspect described above. A network device, where the second network device is the second network device in the aforementioned seventh aspect or the eighth aspect or the ninth aspect.
通过上述方案,在实际网络场景中,第一网络设备接收第二网络设备发送的SBFD信息,从而根据所述SBFD信息确定是否需要为隧道创建SBFD会话,其中,所述隧道是从所述第一网络设备到所述第二网络设备的隧道,从而,避免创建不必要的SBFD会话,减少所述网络中的SBFD会话的数量。Through the above solution, in an actual network scenario, the first network device receives the SBFD information sent by the second network device, thereby determining whether it is necessary to create an SBFD session for the tunnel according to the SBFD information, where the tunnel is from the first network device. A tunnel from the network device to the second network device, thereby avoiding the creation of unnecessary SBFD sessions, and reducing the number of SBFD sessions in the network.
附图说明Description of the drawings
图1为本申请实施例的一种网络结构示意图;FIG. 1 is a schematic diagram of a network structure according to an embodiment of the application;
图2为本申请实施例的一种SR-BE隧道的检测方法流程图;FIG. 2 is a flowchart of a method for detecting an SR-BE tunnel according to an embodiment of the application;
图3为本申请实施例的另一种SR-BE隧道的检测方法流程图;FIG. 3 is a flowchart of another SR-BE tunnel detection method according to an embodiment of the application;
图4为本申请实施例的第一网络设备的结构示意图;FIG. 4 is a schematic structural diagram of a first network device according to an embodiment of the application;
图5为本申请实施例的第一网络设备的硬件结构示意图;FIG. 5 is a schematic diagram of the hardware structure of a first network device according to an embodiment of the application;
图6为本申请实施例的另第一网络设备的硬件结构示意图;6 is a schematic diagram of the hardware structure of another first network device according to an embodiment of the application;
图7为本申请实施例的第二网络设备的结构示意图;FIG. 7 is a schematic structural diagram of a second network device according to an embodiment of the application;
图8为本申请实施例的第二网络设备的硬件结构示意图;FIG. 8 is a schematic diagram of the hardware structure of a second network device according to an embodiment of the application;
图9为本申请实施例的另第二网络设备的硬件结构示意图。FIG. 9 is a schematic diagram of the hardware structure of another second network device according to an embodiment of the application.
具体实施方式detailed description
下面通过具体实施例,分别进行详细的说明。Detailed descriptions will be given below through specific embodiments.
图1为本申请实施例的一种网络结构示意图。示例性的,图1涉及一种分层虚拟专用网(hierarchy virtual private network,HVPN)。所述HVPN包括基站侧网关(cell site gateway,CSG),汇聚侧网关(aggregation site gateway,ASG)和基站控制器侧 网关(radio network controller site gateway,RSG)。图1中示出了4台CSG设备,分别为CSG1,CSG2,CSG3和CSG4。CSG1通过通信链路与CSG2通信,CSG2通过通信链路与CSG3通信,CSG3通过通信链路与CSG4通信。CSG1,CSG2,CSG3和CSG4分别可以连接一个或多个基站。图1中示出了2台ASG设备,分别为ASG1和ASG2。ASG1通过通信链路与ASG2通信。在HVPN中,ASG2是ASG1的冗余设备。CSG1通过通信链路与ASG1通信,CSG4通过通信链路与ASG2通信。图1中示出了2台RSG设备,分别为RSG1和RSG2。RSG1通过通信链路与RSG2通信。在HVPN中,RSG2是RSG1的冗余设备。ASG1通过通信链路与RSG1通信,ASG4通过通信链路与RSG2通信。其中,RSG1和RSG2可以分别连接数据中心(data center,DC)中的服务器。Fig. 1 is a schematic diagram of a network structure according to an embodiment of the application. Exemplarily, FIG. 1 relates to a hierarchical virtual private network (HVPN). The HVPN includes a base station side gateway (cell site gateway, CSG), an aggregation side gateway (aggregation site gateway, ASG), and a base station controller side gateway (radio network controller site gateway, RSG). Figure 1 shows four CSG devices, namely CSG1, CSG2, CSG3 and CSG4. CSG1 communicates with CSG2 through a communication link, CSG2 communicates with CSG3 through a communication link, and CSG3 communicates with CSG4 through a communication link. CSG1, CSG2, CSG3 and CSG4 can be connected to one or more base stations respectively. Figure 1 shows two ASG devices, ASG1 and ASG2. ASG1 communicates with ASG2 through a communication link. In HVPN, ASG2 is the redundant device of ASG1. CSG1 communicates with ASG1 through a communication link, and CSG4 communicates with ASG2 through a communication link. Figure 1 shows two RSG devices, RSG1 and RSG2. RSG1 communicates with RSG2 through a communication link. In HVPN, RSG2 is the redundant device of RSG1. ASG1 communicates with RSG1 through a communication link, and ASG4 communicates with RSG2 through a communication link. Among them, RSG1 and RSG2 can be respectively connected to servers in a data center (DC).
在实施例中,数据流量从图1中的CSG设备发送到RSG设备。示例性的,以CSG1向RSG1发送数据流量为例进行说明。根据前述,ASG2是ASG1的冗余设备。也就是说,ASG1是所述HVPN中的主用ASG设备,ASG2是所述HVPN中的备用ASG设备。在正常情况下,CSG1发送的数据流量经由ASG1到达RSG1。当ASG1发生故障时,ASG1和ASG2之间发生主备切换,ASG1切换成备用ASG设备,ASG2切换成主用ASG设备。然后,CSG1发送的数据流量经由CSG2,CSG3,CSG4,ASG2和RSG2,到达RSG1。同样道理,在图1中RSG2也可以作为RSG1的备用RSG设备,具体工作方式同图1中的ASG设备,此处不进行赘述。In the embodiment, the data traffic is sent from the CSG device in FIG. 1 to the RSG device. Exemplarily, the description will be made by taking CSG1 sending data traffic to RSG1 as an example. According to the foregoing, ASG2 is the redundant device of ASG1. That is, ASG1 is the main ASG device in the HVPN, and ASG2 is the backup ASG device in the HVPN. Under normal circumstances, the data traffic sent by CSG1 reaches RSG1 via ASG1. When ASG1 fails, a master-backup switchover occurs between ASG1 and ASG2, ASG1 switches to a backup ASG device, and ASG2 switches to a master ASG device. Then, the data traffic sent by CSG1 reaches RSG1 via CSG2, CSG3, CSG4, ASG2 and RSG2. In the same way, RSG2 in FIG. 1 can also be used as a backup RSG device of RSG1, and the specific working mode is the same as that of the ASG device in FIG. 1, which will not be repeated here.
在图1所示的HVPN中,可以应用隧道方式传输数据流量。可选的,所述隧道是SR-BE隧道。在本申请实施方式中,以SR-BE隧道为例进行说明,应当理解,本申请的方案也可以应用于其他类型的隧道。其中,SR-BE隧道是基于端到端设备建立的,也就是说,只要存在SR-BE数据流量业务,均需要建立SR-BE隧道。举例说明,CSG1分别建立到图1中的CSG2,CSG3,CSG4,ASG1,ASG2,RSG1和RSG2的SR-BE隧道。同样道理,CSG2分别建立到图1中的CSG1,CSG3,CSG4,ASG1,ASG2,RSG1和RSG2的SR-BE隧道;CSG3分别建立到图1中的CSG1,CSG2,CSG4,ASG1,ASG2,RSG1和RSG2的SR-BE隧道;CSG4分别建立到图1中的CSG1,CSG2,CSG3,ASG1,ASG2,RSG1和RSG2的SR-BE隧道。ASG1,ASG2,RSG1和RSG2建立SR-BE隧道的方式与CSG设备建立SR-BE隧道的方式类似,此处不进行赘述。In the HVPN shown in Figure 1, a tunnel can be used to transmit data traffic. Optionally, the tunnel is an SR-BE tunnel. In the embodiments of this application, an SR-BE tunnel is taken as an example for description. It should be understood that the solution of this application can also be applied to other types of tunnels. Among them, the SR-BE tunnel is established based on end-to-end equipment, that is, as long as there is an SR-BE data traffic service, an SR-BE tunnel needs to be established. For example, CSG1 establishes SR-BE tunnels to CSG2, CSG3, CSG4, ASG1, ASG2, RSG1 and RSG2 in Figure 1 respectively. In the same way, CSG2 is established to CSG1, CSG3, CSG4, ASG1, ASG2, RSG1, and RSG2 in Figure 1, respectively. SR-BE tunnels; CSG3 is established to CSG1, CSG2, CSG4, ASG1, ASG2, RSG1 and RSG1 in Figure 1. The SR-BE tunnel of RSG2; CSG4 is established to the SR-BE tunnels of CSG1, CSG2, CSG3, ASG1, ASG2, RSG1 and RSG2 in Figure 1 respectively. The method for establishing SR-BE tunnels by ASG1, ASG2, RSG1, and RSG2 is similar to the way for CSG devices to establish SR-BE tunnels, and will not be repeated here.
SBFD会话用于检测SR-BE隧道的故障。基于SBFD会话机制检测CSG1到ASG1的SR-BE隧道的故障为例进行说明。为方便说明,使用SR-BE1隧道表示从CSG1到ASG1的SR-BE隧道。CSG1是SBFD会话的发起端,也可以成为检测端。CSG1中的SBFD状态机的初始状态为DOWN状态,也就是说,CSG1对应SR-BE1隧道的端口的状态为DOWN状态。具体的,CSG1对应SR-BE1隧道的端口相对于SBFD协议的协议状态为DOWN状态。CSG1经由SR-BE1隧道向ASG1发送第一SBFD报文,所述第一SBFD报文用于向所述第二网络设备请求建立所述SBFD会话。其中,所述第一SBFD报文携带DOWN状态信息。ASG1是所述SBFD会话的反射端。ASG1接收到所述第一SBFD报文后,确定所述第一SBFD报文中的对端识别符(your discriminator,YD)与ASG1本地保存的识别符是否匹配。其中所述第一SBFD报文中的YD用于指示ASG1。当ASG1确定两者匹配和所述第一SBFD报文携带的所述DOWN状态信息后,ASG1确定ASG1是否处于工作状态。如果ASG1处于工作状态,ASG1经由SR-BE 隧道向CSG1发送第一SBFD报文的第一SBFD回应报文;如果ASG1处于非工作状态,ASG1不发送第一SBFD回应报文,并且丢弃所述第一SBFD报文。其中,当ASG1经由SR-BE隧道向CSG1发送第一SBFD报文的第一SBFD回应报文时,所述第一SBFD回应报文携带UP状态信息,表示,CSG1可以切换为UP状态。CSG1接收到所述第一SBFD回应报文后,根据所述第一SBFD回应报文携带的UP状态信息,将CSG1中的SBFD状态机由DOWN状态切换为UP状态,也就是说,CSG1将CSG1对应SR-BE1隧道的端口的状态由DOWN状态切换为UP状态。然后,CSG1间隔预定时长、周期性的向ASG1发送SBFD回声报文(Echo packet),其中所述预定时长例如是100毫秒。如果CSG1能够周期性的接收到自身发送的SBFD回声报文,CSG1可以确定SR-BE1隧道或ASG1工作正常。如果CSG1在预定周期内没有收到自身发送的SBFD回声报文,CSG1可以确定SR-BE1隧道或ASG1发生故障。当CSG1确定SR-BE1隧道或ASG1发生故障后,触发ASG设备的主备切换。具体的,ASG1切换为备用ASG设备,ASG2切换为主用ASG设备。并且,CSG1不在通过SR-BE1隧道发送数据流量,而是经由SR-BE2隧道发送数据流量。其中,SR-BE2隧道是从CSG1到ASG2的SR-BE隧道。The SBFD session is used to detect the failure of the SR-BE tunnel. Take the example of detecting the failure of the SR-BE tunnel from CSG1 to ASG1 based on the SBFD session mechanism. For the convenience of description, the SR-BE1 tunnel is used to represent the SR-BE tunnel from CSG1 to ASG1. CSG1 is the initiator of the SBFD session, and it can also become the detection end. The initial state of the SBFD state machine in CSG1 is the DOWN state, that is, the state of the port of the CSG1 corresponding to the SR-BE1 tunnel is the DOWN state. Specifically, the protocol state of the port corresponding to the SR-BE1 tunnel of CSG1 is DOWN with respect to the SBFD protocol. CSG1 sends a first SBFD packet to ASG1 via the SR-BE1 tunnel, where the first SBFD packet is used to request the second network device to establish the SBFD session. Wherein, the first SBFD packet carries DOWN state information. ASG1 is the reflecting end of the SBFD session. After the ASG1 receives the first SBFD message, it determines whether the peer identifier (your discriminator, YD) in the first SBFD message matches the identifier stored locally in the ASG1. The YD in the first SBFD message is used to indicate ASG1. After the ASG1 determines that the two match and the DOWN state information carried in the first SBFD packet, the ASG1 determines whether the ASG1 is in a working state. If ASG1 is in working state, ASG1 sends the first SBFD response message of the first SBFD message to CSG1 via the SR-BE tunnel; if ASG1 is in a non-working state, ASG1 does not send the first SBFD response message, and discards the first SBFD response message. An SBFD message. Wherein, when ASG1 sends the first SBFD response message of the first SBFD message to CSG1 via the SR-BE tunnel, the first SBFD response message carries UP state information, indicating that CSG1 can be switched to the UP state. After receiving the first SBFD response message, CSG1 switches the SBFD state machine in CSG1 from DOWN state to UP state according to the UP state information carried in the first SBFD response message, that is, CSG1 switches CSG1 The state of the port corresponding to the SR-BE1 tunnel is switched from the DOWN state to the UP state. Then, CSG1 periodically sends SBFD echo packets to ASG1 at predetermined intervals, where the predetermined duration is, for example, 100 milliseconds. If CSG1 can periodically receive SBFD echo messages sent by itself, CSG1 can determine that the SR-BE1 tunnel or ASG1 is working normally. If CSG1 does not receive the SBFD echo message sent by itself within a predetermined period, CSG1 can determine that the SR-BE1 tunnel or ASG1 is faulty. When CSG1 determines that the SR-BE1 tunnel or ASG1 is faulty, it triggers the active/standby switchover of the ASG device. Specifically, ASG1 is switched to the standby ASG device, and ASG2 is switched to the main ASG device. In addition, CSG1 does not send data traffic through the SR-BE1 tunnel, but sends data traffic through the SR-BE2 tunnel. Among them, the SR-BE2 tunnel is an SR-BE tunnel from CSG1 to ASG2.
从上述实现方式可以看出,SR-BE隧道在传输数据流量时,SR-BE隧道的隧道端点设备(例如CSG1)创建SBFD会话,并基于SBFD对话周期性的检测SR-BE隧道的状态。如前述所示,CSG1分别建立到图1中的CSG2,CSG3,CSG4,ASG1,ASG2,RSG1和RSG2的SR-BE隧道,总共7条SR-BE隧道。相应的,CSG1建立7个SBFD会话,分别对应上述7条SR-BE隧道。假设在图1所示的HVPN场景中,只有ASG设备需要实现主备保护,也就是说,ASG1是主用ASG设备,ASG2是备用ASG设备。如此这样,CSG1需要周期性的检测从CSG1到ASG1的SR-BE1隧道的隧道状态和周期性的检测从CSG1到ASG2的SR-BE2隧道的隧道状态,以便,当SR-BE1隧道或ASG1发生故障时,CSG1发送的数据流量能够快速从SR-BE1隧道切换到SR-BE2隧道。因此,从CSG1分别到CSG2,CSG3,CSG4,RSG1和RSG2的SR-BE隧道上不需要建立相应的SBFD会话。也就是说,在上述实现方式中,CSG1只需要建立基于SR-BE1隧道和SR-BE2隧道的SBFD会话,而不需要建立另外的5个SBFD会话。因此,现有的SR-BE场景中,大量的无用SBFD会话被建立,这些SBFD会话导致网络带宽资源的浪费。It can be seen from the above implementation that when the SR-BE tunnel transmits data traffic, the tunnel endpoint device (for example, CSG1) of the SR-BE tunnel creates an SBFD session, and periodically detects the state of the SR-BE tunnel based on the SBFD session. As shown above, CSG1 establishes SR-BE tunnels to CSG2, CSG3, CSG4, ASG1, ASG2, RSG1, and RSG2 in Figure 1, respectively, and a total of 7 SR-BE tunnels. Correspondingly, CSG1 establishes 7 SBFD sessions corresponding to the 7 SR-BE tunnels mentioned above. Assume that in the HVPN scenario shown in Figure 1, only the ASG device needs to implement active/standby protection, that is, ASG1 is the active ASG device, and ASG2 is the standby ASG device. In this way, CSG1 needs to periodically detect the tunnel status of the SR-BE1 tunnel from CSG1 to ASG1 and periodically detect the tunnel status of the SR-BE2 tunnel from CSG1 to ASG2, so that when the SR-BE1 tunnel or ASG1 fails At this time, the data traffic sent by CSG1 can be quickly switched from the SR-BE1 tunnel to the SR-BE2 tunnel. Therefore, there is no need to establish corresponding SBFD sessions on the SR-BE tunnels from CSG1 to CSG2, CSG3, CSG4, RSG1 and RSG2 respectively. That is to say, in the foregoing implementation manner, CSG1 only needs to establish an SBFD session based on the SR-BE1 tunnel and the SR-BE2 tunnel, and does not need to establish another 5 SBFD sessions. Therefore, in the existing SR-BE scenario, a large number of useless SBFD sessions are established, and these SBFD sessions cause a waste of network bandwidth resources.
本申请实施例提供了一种SBFD会话的建立方法、设备及系统。例如在图1所示的HVPN中,从CSG1到ASG1的SR-BE1隧道被建立之后,ASG1生成第一报文,所述第一报文包括SBFD信息,所述SBFD信息用于指示所述第一报文的目的地址对应的网络设备确定是否为隧道建立SBFD会话,其中,所述目的地址是所述第一网络设备的地址。也就是说,所述SBFD信息指示了是否启动对SR-BE1隧道的检测机制。然后,ASG1将所述第一报文发送到CSG1。CSG1接收到所述第一报文后,根据所述第一报文中的所述SBFD信息确定CSG1是否为SR-BE1隧道建立所述SBFD会话。如果CSG1根据所述SBFD信息确定CSG1不需要为SR-BE1隧道建立SBFD会话,CSG1避免创建所述SBFD会话。也就是说,CSG1不向ASG1发送第一SBFD报文,所述第一SBFD报文用于向ASG1请求建立所述SBFD会话。具体的,CSG1不会通知CSG1中的SBFD状态机发送所述第一SBFD报文。相反,如果CSG1根据所述SBFD 信息确定需要为SR-BE1隧道建立SBFD会话,CSG1创建所述SBFD会话。也就是说,CSG1会向ASG1发送第二SBFD报文,所述第二SBFD报文用于向ASG1请求建立所述SBFD会话。具体的,CSG1会通知CSG1中的SBFD状态机发送所述第二SBFD报文。The embodiments of the present application provide a method, device, and system for establishing an SBFD session. For example, in the HVPN shown in FIG. 1, after the SR-BE1 tunnel from CSG1 to ASG1 is established, ASG1 generates a first packet. The first packet includes SBFD information, and the SBFD information is used to indicate the first packet. The network device corresponding to the destination address of a message determines whether to establish an SBFD session for the tunnel, where the destination address is the address of the first network device. In other words, the SBFD information indicates whether to start the detection mechanism for the SR-BE1 tunnel. Then, ASG1 sends the first message to CSG1. After receiving the first message, the CSG1 determines whether the CSG1 is an SR-BE1 tunnel to establish the SBFD session according to the SBFD information in the first message. If CSG1 determines according to the SBFD information that CSG1 does not need to establish an SBFD session for the SR-BE1 tunnel, CSG1 avoids establishing the SBFD session. That is, CSG1 does not send the first SBFD message to ASG1, and the first SBFD message is used to request ASG1 to establish the SBFD session. Specifically, CSG1 will not notify the SBFD state machine in CSG1 to send the first SBFD message. On the contrary, if CSG1 determines that an SBFD session needs to be established for the SR-BE1 tunnel according to the SBFD information, CSG1 creates the SBFD session. That is, CSG1 will send a second SBFD message to ASG1, and the second SBFD message is used to request ASG1 to establish the SBFD session. Specifically, CSG1 will notify the SBFD state machine in CSG1 to send the second SBFD message.
举例说明,在图1所示的网络拓扑中,ASG1可以向CSG1,CSG2,CSG3和CSG4分别发送携带有SBFD-1信息的第一报文。其中,SBFD-1信息指示了所述第一报文的目的地址对应的网络设备确定需要为相应的SR-BE隧道建立SBFD会话。如此这样,CSG1在从CSG1到ASG1的SR-BE隧道上,CSG2在从CSG2到ASG1的SR-BE隧道上,CSG3在从CSG3到ASG1的SR-BE隧道上和CSG4在从CSG4到ASG1的SR-BE隧道上创建SBFD会话。相应的,ASG1可以向ASG2,RSG1和RSG2分别发送携带有SBFD-2信息的第二报文。其中,SBFD-2信息指示了接收到所述第二报文的网络设备确定不需要为相应的SR-BE隧道建立SBFD会话。如此这样,ASG2在从ASG2到ASG1的SR-BE隧道上,RSG1在从RSG1到ASG1的SR-BE隧道上和RSG2在从RSG2到ASG1的SR-BE隧道上不创建SBFD会话。类似的,图1中的其他网络节点均可以按照上述方式通知对端设备是否需要为相应的SR-BE隧道建立SBFD会话。因此,图1所示的网络中,大量的无用SBFD会话不会被建立,从而减少了网络带宽资源的占用。For example, in the network topology shown in FIG. 1, ASG1 may send the first message carrying SBFD-1 information to CSG1, CSG2, CSG3, and CSG4, respectively. Wherein, the SBFD-1 information indicates that the network device corresponding to the destination address of the first packet determines that an SBFD session needs to be established for the corresponding SR-BE tunnel. In this way, CSG1 is on the SR-BE tunnel from CSG1 to ASG1, CSG2 is on the SR-BE tunnel from CSG2 to ASG1, CSG3 is on the SR-BE tunnel from CSG3 to ASG1, and CSG4 is on the SR from CSG4 to ASG1. -Create an SBFD session on the BE tunnel. Correspondingly, ASG1 can send a second message carrying SBFD-2 information to ASG2, RSG1 and RSG2, respectively. Wherein, the SBFD-2 information indicates that the network device receiving the second message determines that it is not necessary to establish an SBFD session for the corresponding SR-BE tunnel. In this way, ASG2 does not create an SBFD session on the SR-BE tunnel from ASG2 to ASG1, RSG1 on the SR-BE tunnel from RSG1 to ASG1, and RSG2 on the SR-BE tunnel from RSG2 to ASG1. Similarly, other network nodes in FIG. 1 can notify the peer device whether it is necessary to establish an SBFD session for the corresponding SR-BE tunnel in the foregoing manner. Therefore, in the network shown in FIG. 1, a large number of useless SBFD sessions will not be established, thereby reducing the occupation of network bandwidth resources.
图2为本申请实施例的一种SR-BE隧道的检测方法流程图。图2所示的方法可以应用在图1所示的网络结构中。在本申请实施方式中,以SR-BE隧道为例进行说明,应当理解,本申请的方案也可以应用于其他类型的隧道。所述方法包括S101-S105,具体的:Fig. 2 is a flow chart of a method for detecting an SR-BE tunnel according to an embodiment of the application. The method shown in FIG. 2 can be applied to the network structure shown in FIG. 1. In the embodiments of this application, an SR-BE tunnel is taken as an example for description. It should be understood that the solution of this application can also be applied to other types of tunnels. The method includes S101-S105, specifically:
S101、第二网络设备生成第一报文,所述第一报文包括SBFD信息,所述SBFD信息用于指示所述第一报文的目的地址对应的网络设备确定是否为SR-BE隧道建立SBFD会话,所述SR-BE隧道是从第一网络设备到所述第二网络设备的隧道,所述SBFD会话用于检测所述SR-BE隧道的状态,所述目的地址是所述第一网络设备的地址。S101. The second network device generates a first packet, where the first packet includes SBFD information, and the SBFD information is used to indicate that the network device corresponding to the destination address of the first packet determines whether to establish an SR-BE tunnel. SBFD session, the SR-BE tunnel is a tunnel from the first network device to the second network device, the SBFD session is used to detect the status of the SR-BE tunnel, and the destination address is the first The address of the network device.
在本实施方式中,以第一网络设备对应图1中的CSG1,第二网络设备对应图1中的CSG2为例进行说明。CSG1和CSG2之间建立有SR-BE隧道,即SR-BE12隧道。SR-BE12隧道是从CSG1到CSG2的SR-BE隧道。根据前述实施方式的描述,在图1所述的场景中,ASG2是ASG1的冗余设备,也就是说,ASG1是主用ASG设备,ASG2是备用ASG设备。图1中的CSG2没有被设置备用CSG设备,也就是说,CSG2没有相对应的保护设备。因此,到达CSG2的SR-BE隧道上不需要被建立SBFD会话。In this embodiment, the first network device corresponds to CSG1 in FIG. 1 and the second network device corresponds to CSG2 in FIG. 1 as an example for description. An SR-BE tunnel, that is, an SR-BE12 tunnel, is established between CSG1 and CSG2. The SR-BE12 tunnel is an SR-BE tunnel from CSG1 to CSG2. According to the description of the foregoing embodiment, in the scenario described in FIG. 1, ASG2 is the redundant device of ASG1, that is, ASG1 is the main ASG device, and ASG2 is the backup ASG device. The CSG2 in Figure 1 is not set with a backup CSG device, that is, CSG2 does not have a corresponding protection device. Therefore, no SBFD session needs to be established on the SR-BE tunnel to CSG2.
相应的,CSG2可以生成第一报文,第一报文包括SBFD信息。所述SBFD信息用于指示接收到所述第一报文的CSG1确定是否为SR-BE12隧道建立SBFD会话,也就是说,所述SBFD信息指示了是否启动对SR-BE12隧道的检测机制(SBFD会话)。Correspondingly, CSG2 can generate a first message, and the first message includes SBFD information. The SBFD information is used to instruct the CSG1 that received the first message to determine whether to establish an SBFD session for the SR-BE12 tunnel, that is, the SBFD information indicates whether to start the SR-BE12 tunnel detection mechanism (SBFD). Conversation).
在一种可能的实现方式中,CSG2基于中间系统到中间系统(intermediate system to intermediate system,IS-IS)协议生成所述第一报文。具体的,所述第一报文是链路状态协议数据单元(link state protocol data unit,LSP)报文。所述第一报文包括段标识(segment identifier,SID)。具体的,所述SID为前缀SID(Prefix-SID)。在SR-BE的应用场景中,Prefix-SID被用于路径计算。在传输数据流量前,首先需要配置 Prefix-SID,因此,所述第一报文可以被用于发布Prefix-SID。示例性的,所述第一报文携带Prefix-SID的方式,可以参见因特网工程任务组(Internet Engineering Task Force,IETF)的草案1:IS-IS Extensions for Segment Routing(draft-ietf-isis-segment-routing-extensions-25)中的相应定义,例如参见草案1中第2.1章节的描述。具体的,所述第一报文包括第一类型长度值(type-length-value,TLV)字段,所述第一TLV字段用于承载所述Prefix-SID。所述第一TLV字段包括标志(flags)字段,所述标志字段长度为8位。所述标志字段用于承载所述SBFD信息。例如,所述标志字段的第6位或第7位用于承载所述SBFD信息。例如,当所述标志字段中的第6位的值取“1”时,表示使能SBFD会话对SR-BE12隧道进行检测;当所述标志字段中的第6位的值取“0”时,表示不使能SBFD会话对SR-BE12隧道进行检测。In a possible implementation manner, CSG2 generates the first message based on an intermediate system to intermediate system (intermediate system to intermediate system, IS-IS) protocol. Specifically, the first message is a link state protocol data unit (LSP) message. The first message includes a segment identifier (SID). Specifically, the SID is a prefix SID (Prefix-SID). In the application scenario of SR-BE, Prefix-SID is used for path calculation. Before transmitting data traffic, the Prefix-SID needs to be configured first. Therefore, the first message can be used to issue the Prefix-SID. Exemplarily, for the manner in which the first message carries the Prefix-SID, please refer to Internet Engineering Task Force (IETF) Draft 1: IS-IS Extensions for Segment Routing (draft-ietf-isis-segment) -routing-extensions-25), for example, see the description in Chapter 2.1 of Draft 1. Specifically, the first message includes a first type-length-value (type-length-value, TLV) field, and the first TLV field is used to carry the Prefix-SID. The first TLV field includes a flag (flags) field, and the length of the flag field is 8 bits. The flag field is used to carry the SBFD information. For example, the 6th or 7th bit of the flag field is used to carry the SBFD information. For example, when the value of the 6th bit in the flag field is "1", it means that the SBFD session is enabled to detect the SR-BE12 tunnel; when the value of the 6th bit in the flag field is "0" , Which means that the SBFD session is not enabled to detect the SR-BE12 tunnel.
在另一种可能的实现方式中,CSG2基于开放式最短路径优先(Open Shortest Path First,OSPF)协议生成所述第一报文。具体的,所述第一报文是链路状态更新(link state update,LSU)报文。所述第一报文包括SID。具体的,LSU报文包括链路状态公告(link-state advertisement,LSA)信息,所述LSA信息包括所述SID,所述SID为Prefix-SID。在SR-BE的应用场景中,Prefix-SID被用于路径计算。在传输数据流量前,首先需要配置Prefix-SID,因此,所述第一报文可以被用于发布Prefix-SID。示例性的,所述第一报文携带Prefix-SID的方式,可以参见因特网工程任务组(Internet Engineering Task Force,IETF)的草案2:OSPF Extensions for Segment Routing(draft-ietf-ospf-segment-routing-extensions-27)中的相应定义,例如参见草案2中第5章节的描述。具体的,所述第一报文包括第二类型长度值(type-length-value,TLV)字段,所述第二TLV字段用于承载所述Prefix-SID。所述第二TLV字段包括标志(flags)字段,所述标志字段长度为8位。所述标志字段用于承载所述SBFD信息。例如,所述标志字段的第6位或第7位用于承载所述SBFD信息。例如,当所述标志字段中的第6位的值取“1”时,表示使能SBFD会话对SR-BE12隧道进行检测;当所述标志字段中的第6位的值取“0”时,表示不使能SBFD会话对SR-BE12隧道进行检测。In another possible implementation manner, CSG2 generates the first message based on the Open Shortest Path First (OSPF) protocol. Specifically, the first message is a link state update (LSU) message. The first message includes SID. Specifically, the LSU message includes link-state advertisement (link-state advertisement, LSA) information, the LSA information includes the SID, and the SID is the Prefix-SID. In the application scenario of SR-BE, Prefix-SID is used for path calculation. Before transmitting data traffic, the Prefix-SID needs to be configured first, so the first message can be used to issue the Prefix-SID. Exemplarily, for the manner in which the first message carries the Prefix-SID, please refer to Internet Engineering Task Force (IETF) Draft 2: OSPF Extensions for Segment Routing (draft-ietf-ospf-segment-routing) -extensions-27), for example, see the description in Chapter 5 of Draft 2. Specifically, the first message includes a second type length value (type-length-value, TLV) field, and the second TLV field is used to carry the Prefix-SID. The second TLV field includes a flags field, and the flag field has a length of 8 bits. The flag field is used to carry the SBFD information. For example, the 6th or 7th bit of the flag field is used to carry the SBFD information. For example, when the value of the 6th bit in the flag field is "1", it means that the SBFD session is enabled to detect the SR-BE12 tunnel; when the value of the 6th bit in the flag field is "0" , Which means that the SBFD session is not enabled to detect the SR-BE12 tunnel.
可选的,在上述两种可能的实现方式中,SR-BE隧道的目的地址为对应所述SID的地址。具体的,第一网络设备与第二网络设备之间可能包括多条SR-BE隧道。如此这样,第二网络设备可以包括多个SID,所述多个SID与所述多条SR-BE隧道的目的地址一一对应。这样,第一网络设备可以根据SID的值确定需要针对所述多条SR-BE隧道中的哪条SR-BE隧道进行操作,也就是说,针对第一网络设备和第二网络设备之间的具体SR-BE隧道确定是否需要创建SBFD会话。举例说明,第一网络设备与第二网络设备之间包括SR-BE-1隧道、SR-BE-2隧道和SR-BE-3隧道。SR-BE-1隧道的目的地址与SID-1对应,SR-BE-2隧道的目的地址与SID-2对应,SR-BE-3隧道的目的地址与SID-3对应。假设,第二网络设备向第一网络设备发送的第一报文中包括SID-2,那么,第一网络设备通过SID-2可以确定SR-BE-2隧道的目的地址,从而,第一网络设备可以确定需要针对SR-BE-2隧道进行操作,也就是说,确定是否需要为SR-BE-2隧道创建SBFD会话。因此,通过上述实现方式,当第一网络设备和第二网络设备之间存在多条SR-BE隧道时,可以针对其中的部分SR-BE隧道实现SBFD会话创建过程。其中,SID可以是Prefix-SID,SR-BE隧道的目的地址可以是互联网协议(Internet Protocol,IP)地址。Optionally, in the above two possible implementation manners, the destination address of the SR-BE tunnel is the address corresponding to the SID. Specifically, multiple SR-BE tunnels may be included between the first network device and the second network device. In this way, the second network device may include multiple SIDs, and the multiple SIDs have a one-to-one correspondence with the destination addresses of the multiple SR-BE tunnels. In this way, the first network device can determine which SR-BE tunnel of the plurality of SR-BE tunnels needs to be operated according to the value of the SID, that is, for the connection between the first network device and the second network device The specific SR-BE tunnel determines whether an SBFD session needs to be created. For example, the first network device and the second network device include an SR-BE-1 tunnel, an SR-BE-2 tunnel, and an SR-BE-3 tunnel. The destination address of the SR-BE-1 tunnel corresponds to SID-1, the destination address of the SR-BE-2 tunnel corresponds to SID-2, and the destination address of the SR-BE-3 tunnel corresponds to SID-3. Assuming that the first packet sent by the second network device to the first network device includes SID-2, then the first network device can determine the destination address of the SR-BE-2 tunnel through SID-2, so that the first network The device can determine that it needs to operate on the SR-BE-2 tunnel, that is, whether it needs to create an SBFD session for the SR-BE-2 tunnel. Therefore, through the foregoing implementation manner, when there are multiple SR-BE tunnels between the first network device and the second network device, the SBFD session creation process can be implemented for some of the SR-BE tunnels. The SID may be a Prefix-SID, and the destination address of the SR-BE tunnel may be an Internet Protocol (IP) address.
S102、所述第二网络设备向所述第一网络设备发送所述第一报文。S102. The second network device sends the first packet to the first network device.
CSG2在生成所述第一报文之后,向图1所示网络结构中的其他网络设备发送所述第一报文,具体的CSG2分别向CSG1,CSG3,CSG4,ASG1,ASG2,RSG1和RSG2发送所述第一报文。举例说明,在IS-IS场景中,CSG2分别向CSG1,CSG3,CSG4,ASG1,ASG2,RSG1和RSG2发送LSP报文;在OSPF场景中,CSG2分别向CSG1,CSG3,CSG4,ASG1,ASG2,RSG1和RSG2发送LSU报文。After CSG2 generates the first message, it sends the first message to other network devices in the network structure shown in FIG. 1. The specific CSG2 is sent to CSG1, CSG3, CSG4, ASG1, ASG2, RSG1, and RSG2 respectively The first message. For example, in an IS-IS scenario, CSG2 sends LSP packets to CSG1, CSG3, CSG4, ASG1, ASG2, RSG1, and RSG2 respectively; in an OSPF scenario, CSG2 sends LSP packets to CSG1, CSG3, CSG4, ASG1, ASG2, and RSG1 respectively Send LSU message with RSG2.
在本实施方式中,CSG2没有被设置备用CSG设备,也就是说,CSG2没有相对应的保护设备。所述第一报文中的所述SBFD信息用于阻止CSG1建立针对所述SR-BE12隧道的SBFD会话。因此,到达CSG2的SR-BE隧道上不需要被建立SBFD会话。从而,CSG2发送的所述第一报文中包括的SBFD信息的取值可以为“0”,以便阻止CSG1发起针对所述SR-BE12隧道的SBFD会话。In this embodiment, CSG2 is not configured with a backup CSG device, that is, CSG2 does not have a corresponding protection device. The SBFD information in the first message is used to prevent CSG1 from establishing an SBFD session for the SR-BE12 tunnel. Therefore, no SBFD session needs to be established on the SR-BE tunnel to CSG2. Therefore, the value of the SBFD information included in the first message sent by CSG2 may be "0", so as to prevent CSG1 from initiating an SBFD session for the SR-BE12 tunnel.
S103、所述第一网络设备接收第二网络设备发送的所述第一报文。S103. The first network device receives the first packet sent by the second network device.
S104、所述第一网络设备根据所述SBFD信息确定所述第一网络设备是否为所述SR-BE隧道建立所述SBFD会话。S104: The first network device determines whether the first network device establishes the SBFD session for the SR-BE tunnel according to the SBFD information.
举例说明,CSG1接收到CSG2发送的所述第一报文后,解析所述第一报文,获取所述第一报文携带的所述SBFD信息。可选的,CSG1可以根据所述第一报文中携带的Prefix-SID确定所述第一报文是CSG2发送的报文,也就是说,CSG1可以根据所述第一报文中携带的Prefix-SID确定所述SBFD信息是指示所述SR-BE12隧道的检测信息。For example, after receiving the first packet sent by CSG2, CSG1 parses the first packet to obtain the SBFD information carried in the first packet. Optionally, CSG1 may determine that the first message is a message sent by CSG2 according to the Prefix-SID carried in the first message, that is, CSG1 may determine that the first message is a message sent by CSG2 according to the Prefix-SID carried in the first message. -The SID determines that the SBFD information is detection information indicating the SR-BE12 tunnel.
CSG1根据所述SBFD信息确定是否需要为所述SR-BE12隧道建立SBFD会话,也就是说,CSG1根据所述SBFD信息的值确定在SR-BE12隧道上是否建立SBFD会话。例如,所述SBFD信息的值为“1”,CSG1确定在SR-BE12隧道上建立SBFD会话;所述SBFD信息的值为“0”,CSG1确定在SR-BE12隧道上不建立SBFD会话。The CSG1 determines whether an SBFD session needs to be established for the SR-BE12 tunnel according to the SBFD information, that is, the CSG1 determines whether to establish an SBFD session on the SR-BE12 tunnel according to the value of the SBFD information. For example, if the value of the SBFD information is "1", CSG1 determines to establish an SBFD session on the SR-BE12 tunnel; the value of the SBFD information is "0", and CSG1 determines not to establish an SBFD session on the SR-BE12 tunnel.
S105、当所述第一网络设备根据所述SBFD信息确定所述第一网络设备不需要为所述SR-BE隧道建立所述SBFD会话时,所述第一网络设备避免创建所述SBFD会话。S105. When the first network device determines according to the SBFD information that the first network device does not need to establish the SBFD session for the SR-BE tunnel, the first network device avoids creating the SBFD session.
举例说明,根据前述,CSG2没有被设置备用CSG设备,也就是说,CSG2没有相对应的保护设备。因此,到达CSG2的SR-BE隧道上不需要被建立SBFD会话。从而,CSG2发送的所述第一报文中包括的SBFD信息的取值可以为“0”,以便阻止CSG1创建针对所述SR-BE12隧道的SBFD会话。当CSG1根据所述SBFD信息确定不建立所述SR-BE12隧道的SBFD会话时,CSG1不向CSG2发送所述第一SBFD报文。所述第一SBFD报文是建立SBFD会话的首报文,用于向CSG2请求建立所述SBFD会话。CSG1不向CSG2发送所述第一SBFD报文,意味着,CSG1不建立针对所述SR-BE12隧道的SBFD会话。如此这样,CSG2不会收到所述第一SBFD报文,从而,CSG2也不会向CSG1发送所述第一SBFD报文的第一SBFD回应报文。最终,针对所述SR-BE12隧道的SBFD会话不会被建立。具体的,CSG1中的处理器在确定所述SBFD信息的值为“0”后,不会向CSG1中的SBFD状态机发送通知消息,这样,CSG1中的SBFD状态机不会触发所述第一SBFD报文的生成和发送。For example, according to the foregoing, CSG2 is not configured with a backup CSG device, that is, CSG2 does not have a corresponding protection device. Therefore, no SBFD session needs to be established on the SR-BE tunnel to CSG2. Therefore, the value of the SBFD information included in the first message sent by CSG2 may be "0", so as to prevent CSG1 from creating an SBFD session for the SR-BE12 tunnel. When CSG1 determines not to establish the SBFD session of the SR-BE12 tunnel according to the SBFD information, CSG1 does not send the first SBFD packet to CSG2. The first SBFD message is a first message for establishing an SBFD session, and is used to request CSG2 to establish the SBFD session. CSG1 does not send the first SBFD message to CSG2, which means that CSG1 does not establish an SBFD session for the SR-BE12 tunnel. In this way, CSG2 will not receive the first SBFD message, and therefore, CSG2 will not send the first SBFD response message of the first SBFD message to CSG1. Finally, the SBFD session for the SR-BE12 tunnel will not be established. Specifically, after determining that the value of the SBFD information is "0", the processor in CSG1 will not send a notification message to the SBFD state machine in CSG1. In this way, the SBFD state machine in CSG1 will not trigger the first Generation and transmission of SBFD messages.
同样的道理,CSG2也可以分别向CSG3,CSG4,RSG1和RSG2发送所述第一报文,从而CSG3,CSG4,RSG1和RSG2也不会建立到达CSG2的SR-BE隧道的SBFD会话。从而,通过本申请的实施方式,大量的无用SBFD会话不会被建立,从而减少 了网络带宽资源的占用。In the same way, CSG2 can also send the first message to CSG3, CSG4, RSG1 and RSG2 respectively, so that CSG3, CSG4, RSG1 and RSG2 will not establish an SBFD session to the SR-BE tunnel of CSG2. Therefore, through the implementation of the present application, a large number of useless SBFD sessions will not be established, thereby reducing the occupation of network bandwidth resources.
图3为本申请实施例的另一种SR-BE隧道的检测方法流程图。图3所示的方法可以应用在图1所示的网络结构中。在本申请实施方式中,以SR-BE隧道为例进行说明,应当理解,本申请的方案也可以应用于其他类型的隧道。在本实施方式中,以第一网络设备对应图1中的CSG1,第二网络设备对应图1中的ASG1为例进行说明。CSG1和ASG1之间建立有SR-BE隧道,即SR-BE11隧道。SR-BE11隧道是从CSG1到ASG1的SR-BE隧道。图3所示的方法包括S101-S112。图3中所示的S101、S102、S103和S104与图2中所示的S101、S102、S103和S104表述相同,此处不进行赘述。进一步,基于CSG1和ASG2对图3中的S101-S104进行举例说明的实现方式,类似于基于CSG1和CSG2对图2中的S101-S104进行举例说明,此处不进行赘述。FIG. 3 is a flowchart of another SR-BE tunnel detection method according to an embodiment of the application. The method shown in FIG. 3 can be applied to the network structure shown in FIG. 1. In the embodiments of this application, an SR-BE tunnel is taken as an example for description. It should be understood that the solution of this application can also be applied to other types of tunnels. In this embodiment, the first network device corresponds to CSG1 in FIG. 1 and the second network device corresponds to ASG1 in FIG. 1 as an example for description. An SR-BE tunnel, that is, an SR-BE11 tunnel, is established between CSG1 and ASG1. The SR-BE11 tunnel is an SR-BE tunnel from CSG1 to ASG1. The method shown in Figure 3 includes S101-S112. The expressions of S101, S102, S103, and S104 shown in FIG. 3 are the same as those of S101, S102, S103, and S104 shown in FIG. 2, and will not be repeated here. Furthermore, the implementation of S101-S104 in FIG. 3 exemplified based on CSG1 and ASG2 is similar to the exemplification of S101-S104 in FIG. 2 based on CSG1 and CSG2, and will not be repeated here.
S106、当所述第一网络设备根据所述SBFD信息确定所述第一网络设备需要为所述SR-BE隧道建立SBFD会话时,所述第一网络设备创建所述SBFD会话。S106: When the first network device determines according to the SBFD information that the first network device needs to establish an SBFD session for the SR-BE tunnel, the first network device creates the SBFD session.
S107、所述第一网络设备向所述第二网络设备发送第二SBFD报文,所述第二SBFD报文用于向所述第二网络设备请求建立所述SBFD会话。S107. The first network device sends a second SBFD packet to the second network device, where the second SBFD packet is used to request the second network device to establish the SBFD session.
举例说明,根据前述,ASG2是ASG1的冗余设备,也就是说,ASG1是主用ASG设备,ASG2是备用ASG设备。因此,ASG2是ASG1的相对应的保护设备,那么,到达ASG1的SR-BE隧道上需要被建立SBFD会话。从而,ASG1发送的所述第一报文中包括的SBFD信息的取值可以为“1”,以便CSG1能够创建针对所述SR-BE11隧道的SBFD会话。当CSG1根据所述SBFD信息确定CSG1需要为所述SR-BE11隧道建立SBFD会话时,CSG1向ASG1发送所述第二SBFD报文。所述第二SBFD报文是建立SBFD会话的首报文,用于向ASG1请求建立所述SBFD会话。CSG1向ASG1发送所述第二SBFD报文,意味着,CSG1发起建立针对所述SR-BE11隧道的SBFD会话的请求。具体的,CSG1中的处理器在确定所述SBFD信息的值为“1”后,会向CSG1中的SBFD状态机发送通知消息,这样,CSG1中的SBFD状态机会触发所述第二SBFD报文的生成和发送。其中,根据前述实施方式的说明,所述第二SBFD报文携带DOWN状态信息。For example, according to the foregoing, ASG2 is the redundant device of ASG1, that is, ASG1 is the main ASG device, and ASG2 is the backup ASG device. Therefore, ASG2 is the corresponding protection device of ASG1, so an SBFD session needs to be established on the SR-BE tunnel to ASG1. Therefore, the value of the SBFD information included in the first message sent by ASG1 may be "1", so that CSG1 can create an SBFD session for the SR-BE11 tunnel. When CSG1 determines according to the SBFD information that CSG1 needs to establish an SBFD session for the SR-BE11 tunnel, CSG1 sends the second SBFD message to ASG1. The second SBFD message is the first message for establishing the SBFD session, and is used to request the ASG1 to establish the SBFD session. CSG1 sends the second SBFD message to ASG1, which means that CSG1 initiates a request for establishing an SBFD session for the SR-BE11 tunnel. Specifically, after determining that the value of the SBFD information is "1", the processor in CSG1 will send a notification message to the SBFD state machine in CSG1, so that the SBFD state machine in CSG1 will trigger the second SBFD message Generation and delivery. According to the description of the foregoing embodiment, the second SBFD packet carries DOWN state information.
S108、所述第二网络设备接收所述第一网络设备发送的所述第二SBFD报文。S108. The second network device receives the second SBFD packet sent by the first network device.
S109、所述第二网络设备向所述第一网络设备发送所述第二SBFD报文的第二SBFD回应报文,所述第二SBFD回应报文指示所述第二网络设备处于工作状态。S109. The second network device sends a second SBFD response message of the second SBFD message to the first network device, where the second SBFD response message indicates that the second network device is in a working state.
举例说明,ASG1是所述SBFD会话的反射端。ASG1接收到所述第二SBFD报文后,确定所述第二SBFD报文中的对端YD与ASG1本地保存的识别符是否匹配。其中所述第二SBFD报文中的YD用于指示ASG1。当ASG1确定两者匹配和所述第二SBFD报文携带的所述DOWN状态信息后,ASG1确定ASG1是否处于工作状态。如果ASG1处于工作状态,ASG1经由SR-BE11隧道向CSG1发送第二SBFD报文的第二SBFD回应报文。其中,所述第二SBFD回应报文携带UP状态信息,表示,CSG1可以切换为UP状态。For example, ASG1 is the reflection end of the SBFD session. After the ASG1 receives the second SBFD message, it determines whether the opposite end YD in the second SBFD message matches the identifier stored locally in the ASG1. The YD in the second SBFD message is used to indicate ASG1. After the ASG1 determines that the two match and the DOWN state information carried in the second SBFD packet, the ASG1 determines whether the ASG1 is in a working state. If ASG1 is in the working state, ASG1 sends the second SBFD response message of the second SBFD message to CSG1 via the SR-BE11 tunnel. Wherein, the second SBFD response message carries UP state information, which indicates that CSG1 can be switched to the UP state.
S110、所述第一网络设备接收所述第二SBFD回应报文。S110. The first network device receives the second SBFD response message.
S111、所述第一网络设备根据所述第二SBFD回应报文将所述第一网络设备的对应所述SR-BE隧道的端口设置为UP状态。S111. The first network device sets the port of the first network device corresponding to the SR-BE tunnel to the UP state according to the second SBFD response message.
S112、所述第一网络设备向所述第二网络设备发送SBFD回声报文,所述SBFD 回声报文用于检测所述SR-BE隧道的状态。S112. The first network device sends an SBFD echo message to the second network device, where the SBFD echo message is used to detect the state of the SR-BE tunnel.
举例说明,CSG1接收到所述第二SBFD回应报文后,根据所述第二SBFD回应报文携带的UP状态信息,将CSG1中的SBFD状态机由DOWN状态切换为UP状态,也就是说,CSG1将CSG1的对应SR-BE11隧道的端口的状态由DOWN状态切换为UP状态。然后,CSG1间隔预定时长、周期性的向ASG1发送SBFD回声报文,其中所述预定时长例如是100毫秒。如果CSG1能够周期性的接收到自身发送的SBFD回声报文,CSG1可以确定SR-BE11隧道或ASG1工作正常。如果CSG1在预定周期内没有收到自身发送的SBFD回声报文,CSG1可以确定SR-BE11隧道或ASG1发生故障。当CSG1确定SR-BE11隧道或ASG1发生故障后,触发ASG设备的主备切换。具体的,ASG1切换为备用ASG设备,ASG2切换为主用ASG设备。并且,CSG1不在通过SR-BE11隧道发送数据流量,而是经由SR-BE22隧道发送数据流量。其中,SR-BE22隧道是从CSG1到ASG2的SR-BE隧道。For example, after receiving the second SBFD response message, CSG1 switches the SBFD state machine in CSG1 from the DOWN state to the UP state according to the UP state information carried in the second SBFD response message, that is, CSG1 switches the status of the port corresponding to the SR-BE11 tunnel of CSG1 from the DOWN state to the UP state. Then, CSG1 periodically sends SBFD echo messages to ASG1 at intervals of a predetermined duration, where the predetermined duration is, for example, 100 milliseconds. If CSG1 can periodically receive the SBFD echo message sent by itself, CSG1 can determine that the SR-BE11 tunnel or ASG1 is working normally. If CSG1 does not receive the SBFD echo message sent by itself within a predetermined period, CSG1 can determine that the SR-BE11 tunnel or ASG1 is faulty. When CSG1 determines that the SR-BE11 tunnel or ASG1 is faulty, it triggers the active/standby switchover of the ASG device. Specifically, ASG1 is switched to the standby ASG device, and ASG2 is switched to the main ASG device. In addition, CSG1 does not send data traffic through the SR-BE11 tunnel, but sends data traffic through the SR-BE22 tunnel. Among them, the SR-BE22 tunnel is the SR-BE tunnel from CSG1 to ASG2.
通过本申请的实施方式,只有在需要依靠SBFD检测的SR-BE隧道上,SBFD会话才会被建立,从而,大量的无用SBFD会话不会被建立,因此减少了网络带宽资源的占用。Through the implementation of the present application, SBFD sessions can be established only on SR-BE tunnels that require SBFD detection. Therefore, a large number of useless SBFD sessions will not be established, thus reducing the occupation of network bandwidth resources.
图4为本申请实施例的第一网络设备1000的结构示意图。图4所示的第一网络设备1000可以执行上述实施例的方法中第一网络设备执行的相应步骤。如图4所示,所述第一网络设备1000包括接收单元1002和处理单元1004。FIG. 4 is a schematic structural diagram of a first network device 1000 according to an embodiment of the application. The first network device 1000 shown in FIG. 4 can execute the corresponding steps performed by the first network device in the method of the foregoing embodiment. As shown in FIG. 4, the first network device 1000 includes a receiving unit 1002 and a processing unit 1004.
所述接收单元1002,用于接收第二网络设备发送的第一报文,所述第一报文包括SBFD信息,所述SBFD信息用于指示所述第一报文的目的地址对应的网络设备确定是否为隧道建立SBFD会话,所述隧道是从所述第一网络设备到所述第二网络设备的隧道,所述SBFD会话用于检测所述隧道的状态,所述目的地址是所述第一网络设备的地址;The receiving unit 1002 is configured to receive a first packet sent by a second network device, where the first packet includes SBFD information, and the SBFD information is used to indicate the network device corresponding to the destination address of the first packet Determine whether to establish an SBFD session for a tunnel, where the tunnel is a tunnel from the first network device to the second network device, the SBFD session is used to detect the state of the tunnel, and the destination address is the first network device. The address of a network device;
所述处理单元1004,用于根据所述SBFD信息确定所述第一网络设备是否为所述隧道建立所述SBFD会话;The processing unit 1004 is configured to determine whether the first network device establishes the SBFD session for the tunnel according to the SBFD information;
当所述处理单元1004根据所述SBFD信息确定所述第一网络设备不需要为所述隧道建立所述SBFD会话时,所述处理单元1004还用于避免创建所述SBFD会话。When the processing unit 1004 determines according to the SBFD information that the first network device does not need to establish the SBFD session for the tunnel, the processing unit 1004 is further configured to avoid creating the SBFD session.
在一种可能的实现方式中,当所述处理单元1004根据所述SBFD信息确定所述第一网络设备需要为所述隧道建立所述SBFD会话时,所述处理单元1004还用于创建所述SBFD会话。In a possible implementation manner, when the processing unit 1004 determines according to the SBFD information that the first network device needs to establish the SBFD session for the tunnel, the processing unit 1004 is further configured to create the SBFD session.
可选的,在所述处理单元1004还用于创建所述SBFD会话中,所述处理单元1004具体用于:向所述第二网络设备发送SBFD报文,所述SBFD报文用于请求建立所述SBFD会话;接收所述第二网络设备发送的针对所述SBFD报文的SBFD回应报文,所述SBFD回应报文指示所述第二网络设备处于工作状态;和,根据所述SBFD回应报文将所述第一网络设备的对应所述隧道的端口设置为UP状态。Optionally, when the processing unit 1004 is further configured to create the SBFD session, the processing unit 1004 is specifically configured to: send an SBFD message to the second network device, where the SBFD message is used to request establishment The SBFD session; receiving an SBFD response message for the SBFD message sent by the second network device, the SBFD response message indicating that the second network device is in a working state; and, responding according to the SBFD The message sets the port of the first network device corresponding to the tunnel to the UP state.
可选的,在处理单元1004根据所述SBFD回应报文将所述第一网络设备的对应所述隧道的端口设置为UP状态之后,所述处理单元1004还用于向所述第二网络设备发送SBFD回声报文,所述SBFD回声报文用于检测所述隧道的状态。Optionally, after the processing unit 1004 sets the port of the first network device corresponding to the tunnel to the UP state according to the SBFD response message, the processing unit 1004 is further configured to report to the second network device Send an SBFD echo message, where the SBFD echo message is used to detect the state of the tunnel.
可选的,所述第一报文是基于IS-IS协议的LSP报文,或者所述第一报文是基于OSPF协议的LSU报文,所述第一报文还包括所述第二网络设备的SID,所述隧道的 目的地址为对应所述SID的地址。进一步可选的,所述第一报文包括标志字段,所述标志字段用于承载所述SBFD信息。Optionally, the first message is an LSP message based on the IS-IS protocol, or the first message is an LSU message based on the OSPF protocol, and the first message further includes the second network The SID of the device, and the destination address of the tunnel is the address corresponding to the SID. Further optionally, the first message includes a flag field, and the flag field is used to carry the SBFD information.
可选的,所述隧道是SR-BE隧道。Optionally, the tunnel is an SR-BE tunnel.
图4所示的第一网络设备可以执行上述实施例的方法中第一网络设备执行的相应步骤。在实际网络场景中,第一网络设备接收第二网络设备发送的SBFD信息,从而根据所述SBFD信息确定是否需要为隧道创建SBFD会话,其中,所述隧道是从所述第一网络设备到所述第二网络设备的隧道,从而,避免创建不必要的SBFD会话,减少所述网络中的SBFD会话的数量。The first network device shown in FIG. 4 can execute the corresponding steps performed by the first network device in the method of the foregoing embodiment. In an actual network scenario, the first network device receives the SBFD information sent by the second network device, thereby determining whether it is necessary to create an SBFD session for the tunnel according to the SBFD information, where the tunnel is from the first network device to the The tunnel of the second network device is thus avoided to create unnecessary SBFD sessions, and the number of SBFD sessions in the network is reduced.
图5为本申请实施例的第一网络设备1100的硬件结构示意图。图5所示的第一网络设备1100可以执行上述实施例的方法中第一网络设备执行的相应步骤。FIG. 5 is a schematic diagram of the hardware structure of the first network device 1100 according to an embodiment of the application. The first network device 1100 shown in FIG. 5 can execute the corresponding steps performed by the first network device in the method of the foregoing embodiment.
如图5所示,所述第一网络设备1100包括处理器1101、存储器1102、接口1103和总线1104。其中接口1103可以通过无线或有线的方式实现,具体来讲可以是网卡。上述处理器1101、存储器1102和接口1103通过总线1104连接。As shown in FIG. 5, the first network device 1100 includes a processor 1101, a memory 1102, an interface 1103, and a bus 1104. The interface 1103 may be implemented in a wireless or wired manner, and specifically may be a network card. The aforementioned processor 1101, memory 1102, and interface 1103 are connected through a bus 1104.
所述接口1103具体可以包括发送器和接收器,用于第一网络设备与上述实施例中的第二网络设备之间收发信息。例如,所述接口1103用于支持接收所述第二网络设备发送的第一报文和SBFD报文的SBFD回应报文;用于支持向第二网络设备发送SBFD报文和SBFD回声报文。作为举例,所述接口1103用于支持图2和图3中的过程S103、S107、S110和S112。所述处理器1101用于执行上述实施例中由第一网络设备进行的处理。例如,所述处理器1101确定是否为隧道建立SBFD会话;用于根据确定结果避免建立SBFD会话或者根据确定结果建立SBFD会话;和/或用于本文所描述的技术的其他过程。作为举例,所述处理器1101用于支持图2和图3中的过程S104、S105、S106和S111。存储器1102包括操作系统11021和应用程序11022,用于存储程序、代码或指令,当处理器或硬件设备执行这些程序、代码或指令时可以完成方法实施例中涉及第一网络设备的处理过程。可选的,所述存储器1102可以包括只读存储器(英文:Read-only Memory,缩写:ROM)和随机存取存储器(英文:Random Access Memory,缩写:RAM)。其中,所述ROM包括基本输入/输出系统(英文:Basic Input/Output System,缩写:BIOS)或嵌入式系统;所述RAM包括应用程序和操作系统。当需要运行第一网络设备1100时,通过固化在ROM中的BIOS或者嵌入式系统中的bootloader引导系统进行启动,引导第一网络设备1100进入正常运行状态。在第一网络设备1100进入正常运行状态后,运行在RAM中的应用程序和操作系统,从而,完成方法实施例中涉及第一网络设备的处理过程。The interface 1103 may specifically include a transmitter and a receiver, which are used to send and receive information between the first network device and the second network device in the foregoing embodiment. For example, the interface 1103 is used to support receiving the first packet and the SBFD response packet of the SBFD packet sent by the second network device; it is used to support the sending of the SBFD packet and the SBFD echo packet to the second network device. As an example, the interface 1103 is used to support the processes S103, S107, S110, and S112 in FIG. 2 and FIG. 3. The processor 1101 is configured to execute the processing performed by the first network device in the foregoing embodiment. For example, the processor 1101 determines whether to establish an SBFD session for the tunnel; is used to avoid establishing an SBFD session according to the determination result or establish an SBFD session according to the determination result; and/or is used in other processes of the technology described herein. As an example, the processor 1101 is used to support the processes S104, S105, S106, and S111 in FIG. 2 and FIG. 3. The memory 1102 includes an operating system 11021 and an application program 11022 for storing programs, codes, or instructions. When a processor or hardware device executes these programs, codes, or instructions, the processing process involving the first network device in the method embodiment can be completed. Optionally, the memory 1102 may include a read-only memory (English: Read-only Memory, abbreviation: ROM) and a random access memory (English: Random Access Memory, abbreviation: RAM). Wherein, the ROM includes a basic input/output system (English: Basic Input/Output System, abbreviation: BIOS) or an embedded system; the RAM includes an application program and an operating system. When the first network device 1100 needs to be operated, the system is booted by the BIOS solidified in the ROM or the bootloader in the embedded system to guide the first network device 1100 into a normal operating state. After the first network device 1100 enters the normal operating state, the application program and the operating system run in the RAM, thereby completing the processing procedure involving the first network device in the method embodiment.
可以理解的是,图5仅仅示出了第一网络设备1100的简化设计。在实际应用中,第一网络设备可以包含任意数量的接口,处理器或者存储器。It is understandable that FIG. 5 only shows a simplified design of the first network device 1100. In practical applications, the first network device may include any number of interfaces, processors or memories.
图6为本申请实施例的另一种第一网络设备1200的硬件结构示意图。图6所示的第一网络设备1200可以执行上述实施例的方法中第一网络设备执行的相应步骤。FIG. 6 is a schematic diagram of the hardware structure of another first network device 1200 according to an embodiment of the application. The first network device 1200 shown in FIG. 6 can execute the corresponding steps performed by the first network device in the method of the foregoing embodiment.
如图6所述,第一网络设备1200包括:主控板1210、接口板1230、交换网板1220和接口板1240。主控板1210、接口板1230和1240,以及交换网板1220之间通过系统总线与系统背板相连实现互通。其中,主控板1210用于完成系统管理、设备维护、协议处理等功能。交换网板1220用于完成各接口板(接口板也称为线卡或业务板)之间的数据交换。接口板1230和1240用于提供各种业务接口(例如,POS接口、GE 接口、ATM接口等),并实现数据包的转发As shown in FIG. 6, the first network device 1200 includes: a main control board 1210, an interface board 1230, a switching network board 1220, and an interface board 1240. The main control board 1210, the interface boards 1230 and 1240, and the switching network board 1220 are connected to the system backplane through the system bus to achieve intercommunication. Among them, the main control board 1210 is used to complete functions such as system management, equipment maintenance, and protocol processing. The switching network board 1220 is used to complete data exchange between various interface boards (interface boards are also called line cards or service boards). The interface boards 1230 and 1240 are used to provide various service interfaces (for example, POS interface, GE interface, ATM interface, etc.), and realize data packet forwarding
接口板1230可以包括中央处理器1231、转发表项存储器1234、物理接口卡1233和网络处理器1232。其中,中央处理器1231用于对接口板进行控制管理并与主控板上的中央处理器进行通信。转发表项存储器1234用于保存转发表项。物理接口卡1233用于完成流量的接收和发送。网络存储器1232用于根据所述转发表项控制物理接口卡1233收发流量。The interface board 1230 may include a central processing unit 1231, a forwarding entry memory 1234, a physical interface card 1233, and a network processor 1232. Among them, the central processing unit 1231 is used to control and manage the interface board and communicate with the central processing unit on the main control board. The forwarding entry storage 1234 is used to store forwarding entries. The physical interface card 1233 is used to complete the reception and transmission of traffic. The network storage 1232 is used to control the receiving and sending traffic of the physical interface card 1233 according to the forwarding entry.
具体的,物理接口卡1233用于接收所述第二网络设备发送的第一报文和SBFD报文的SBFD回应报文,以及用于向所述第二网络设备发送SBFD报文和SBFD回声报文。Specifically, the physical interface card 1233 is configured to receive the first message and the SBFD response message of the SBFD message sent by the second network device, and is configured to send the SBFD message and the SBFD echo message to the second network device. Text.
中央处理器1211用于确定是否为隧道建立SBFD会话;以及用于根据确定结果避免建立SBFD会话或者根据确定结果建立SBFD会话。The central processor 1211 is used to determine whether to establish an SBFD session for the tunnel; and used to avoid establishing an SBFD session according to the determination result or establish an SBFD session according to the determination result.
中央处理器1211还用于处理接收的第一报文和SBFD报文的SBFD回应报文;以及生成发送的SBFD报文和SBFD回声报文。The central processor 1211 is also configured to process the received first message and the SBFD response message of the SBFD message; and generate the sent SBFD message and the SBFD echo message.
物理接口卡1233接收到第一报文和SBFD报文的SBFD回应报文后,将第一报文和SBFD报文的SBFD回应报文经由中央处理器1231发送到中央处理器1211,中央处理器1211处理该第一报文和SBFD报文的SBFD回应报文。After receiving the first message and the SBFD response message of the SBFD message, the physical interface card 1233 sends the first message and the SBFD response message of the SBFD message to the central processing unit 1211 via the central processing unit 1231. 1211 processes the first message and the SBFD response message of the SBFD message.
中央处理器1231还用于控制网络存储器1232获取转发表项存储器1234中的转发表项,并且,中央处理器1231还用于控制网络存储器1232经由物理接口卡1233完成流量的接收和发送。The central processing unit 1231 is also used to control the network storage 1232 to obtain forwarding entries in the forwarding entry storage 1234, and the central processing unit 1231 is also used to control the network storage 1232 to receive and send traffic via the physical interface card 1233.
应理解,本发明实施例中接口板1240上的操作与所述接口板1230的操作一致,为了简洁,不再赘述。应理解,本实施例的第一网络设备1200可对应于上述方法实施例所具有的功能和/或所实施的各种步骤,在此不再赘述。It should be understood that the operations on the interface board 1240 in the embodiment of the present invention are consistent with the operations on the interface board 1230, and will not be repeated for the sake of brevity. It should be understood that the first network device 1200 in this embodiment may correspond to the functions and/or various steps implemented in the foregoing method embodiments, and details are not described herein again.
此外,需要说明的是,主控板可能有一块或多块,有多块的时候可以包括主用主控板和备用主控板。接口板可能有一块或多块,第一网络设备的数据处理能力越强,提供的接口板越多。接口板上的物理接口卡也可以有一块或多块。交换网板可能没有,也可能有一块或多块,有多块的时候可以共同实现负荷分担冗余备份。在集中式转发架构下,第一网络设备可以不需要交换网板,接口板承担整个系统的业务数据的处理功能。在分布式转发架构下,第一网络设备可以有至少一块交换网板,通过交换网板实现多块接口板之间的数据交换,提供大容量的数据交换和处理能力。所以,分布式架构的第一网络设备的数据接入和处理能力要大于集中式架构的设备。具体采用哪种架构,取决于具体的组网部署场景,此处不做任何限定。In addition, it should be noted that there may be one or more main control boards, and when there are more than one, it may include a main main control board and a standby main control board. There may be one or more interface boards. The stronger the data processing capability of the first network device, the more interface boards provided. There may also be one or more physical interface cards on the interface board. The switching network board may not exist, or there may be one or more. When there are more than one, the load sharing and redundant backup can be realized together. Under the centralized forwarding architecture, the first network device may not need to switch the network board, and the interface board undertakes the processing function of the service data of the entire system. Under the distributed forwarding architecture, the first network device may have at least one switching network board, and data exchange between multiple interface boards is realized through the switching network board, providing large-capacity data exchange and processing capabilities. Therefore, the data access and processing capability of the first network device of the distributed architecture is greater than that of the device of the centralized architecture. The specific architecture used depends on the specific networking deployment scenario, and there is no restriction here.
图7为本申请实施例的第二网络设备2000的结构示意图。图7所示的第二网络设备2000可以执行上述实施例的方法中第二网络设备执行的相应步骤。如图7所示,所述第二网络设备2000包括处理单元2004和发送单元2006。FIG. 7 is a schematic structural diagram of a second network device 2000 according to an embodiment of the application. The second network device 2000 shown in FIG. 7 can execute the corresponding steps performed by the second network device in the method of the foregoing embodiment. As shown in FIG. 7, the second network device 2000 includes a processing unit 2004 and a sending unit 2006.
所述处理单元2004,用于生成第一报文,所述第一报文包括无缝双向转发检测SBFD信息,所述SBFD信息用于指示所述第一报文的目的地址对应的网络设备确定是否为隧道建立SBFD会话,所述隧道是从第一网络设备到所述第二网络设备的隧道,所述SBFD会话用于检测所述隧道的状态,所述目的地址是所述第一网络设备的地址;The processing unit 2004 is configured to generate a first message, the first message including seamless bidirectional forwarding detection SBFD information, and the SBFD information is used to indicate that the network device corresponding to the destination address of the first message is determined Whether to establish an SBFD session for the tunnel, the tunnel is a tunnel from the first network device to the second network device, the SBFD session is used to detect the state of the tunnel, and the destination address is the first network device the address of;
所述发送单元2006,用于向所述第一网络设备发送所述第一报文,其中,所述第一报文中的所述SBFD信息用于阻止所述第一网络设备建立针对所述隧道的SBFD会 话。The sending unit 2006 is configured to send the first message to the first network device, where the SBFD information in the first message is used to prevent the first network device from establishing SBFD session of the tunnel.
可选的,所述第一报文是基于IS-IS协议的LSP报文,或者所述第一报文是基于OSPF协议的LSU报文,所述第一报文还包括所述第二网络设备的SID,所述隧道的目的地址为对应所述SID的地址。进一步可选的,所述第一报文包括标志字段,所述标志字段用于承载所述SBFD信息。Optionally, the first message is an LSP message based on the IS-IS protocol, or the first message is an LSU message based on the OSPF protocol, and the first message further includes the second network The SID of the device, and the destination address of the tunnel is the address corresponding to the SID. Further optionally, the first message includes a flag field, and the flag field is used to carry the SBFD information.
可选的,所述隧道是SR-BE隧道。Optionally, the tunnel is an SR-BE tunnel.
图7所示的第二网络设备可以执行上述实施例的方法中第二网络设备执行的相应步骤。在实际网络场景中,第一网络设备接收第二网络设备发送的SBFD信息,从而根据所述SBFD信息确定是否需要为隧道创建SBFD会话,其中,所述隧道是从所述第一网络设备到所述第二网络设备的隧道,从而,避免创建不必要的SBFD会话,减少所述网络中的SBFD会话的数量。The second network device shown in FIG. 7 can execute the corresponding steps performed by the second network device in the method of the foregoing embodiment. In an actual network scenario, the first network device receives the SBFD information sent by the second network device, thereby determining whether it is necessary to create an SBFD session for the tunnel according to the SBFD information, where the tunnel is from the first network device to the The tunnel of the second network device is thus avoided to create unnecessary SBFD sessions, and the number of SBFD sessions in the network is reduced.
图8为本申请实施例的第二网络设备2100的硬件结构示意图。图8所示的第二网络设备2100可以执行上述实施例的方法中第二网络设备执行的相应步骤。FIG. 8 is a schematic diagram of the hardware structure of the second network device 2100 according to an embodiment of the application. The second network device 2100 shown in FIG. 8 can execute the corresponding steps performed by the second network device in the method of the foregoing embodiment.
如图8所示,所述第二网络设备2100包括处理器2101、存储器2102、接口2103和总线2104。其中接口2103可以通过无线或有线的方式实现,具体来讲可以是网卡。上述处理器2101、存储器2102和接口2103通过总线2104连接。As shown in FIG. 8, the second network device 2100 includes a processor 2101, a memory 2102, an interface 2103 and a bus 2104. The interface 2103 may be implemented in a wireless or wired manner, and specifically may be a network card. The aforementioned processor 2101, memory 2102, and interface 2103 are connected through a bus 2104.
所述接口2103具体可以包括发送器和接收器,用于第二网络设备与上述实施例中的第一网络设备之间收发信息。例如,所述接口2103用于支持向所述第一网络设备发送第一报文和SBFD报文;用于支持接收第一网络设备发送的SBFD报文的SBFD回应报文和SBFD回声报文。作为举例,所述接口2103用于支持图2和图3中的过程S102、S108和S109。所述处理器2101用于执行上述实施例中由第二网络设备进行的处理。例如,所述处理器2101用于生成第一报文;和/或用于本文所描述的技术的其他过程。作为举例,所述处理器2101用于支持图2和图3中的过程S101。存储器2102包括操作系统21021和应用程序21022,用于存储程序、代码或指令,当处理器或硬件设备执行这些程序、代码或指令时可以完成方法实施例中涉及第二网络设备的处理过程。可选的,所述存储器2102可以包括只读存储器(英文:Read-only Memory,缩写:ROM)和随机存取存储器(英文:Random Access Memory,缩写:RAM)。其中,所述ROM包括基本输入/输出系统(英文:Basic Input/Output System,缩写:BIOS)或嵌入式系统;所述RAM包括应用程序和操作系统。当需要运行第二网络设备2100时,通过固化在ROM中的BIOS或者嵌入式系统中的bootloader引导系统进行启动,引导第二网络设备2100进入正常运行状态。在第二网络设备2100进入正常运行状态后,运行在RAM中的应用程序和操作系统,从而,完成方法实施例中涉及第二网络设备的处理过程。The interface 2103 may specifically include a transmitter and a receiver, which are used to send and receive information between the second network device and the first network device in the foregoing embodiment. For example, the interface 2103 is used to support sending a first message and an SBFD message to the first network device; and is used to support receiving an SBFD response message and an SBFD echo message of an SBFD message sent by the first network device. As an example, the interface 2103 is used to support the processes S102, S108, and S109 in FIG. 2 and FIG. 3. The processor 2101 is configured to execute the processing performed by the second network device in the foregoing embodiment. For example, the processor 2101 is used to generate the first message; and/or used in other processes of the technology described herein. As an example, the processor 2101 is used to support the process S101 in FIG. 2 and FIG. 3. The memory 2102 includes an operating system 21021 and an application program 21022, which are used to store programs, codes, or instructions. When the processor or hardware device executes these programs, codes, or instructions, the processing process involving the second network device in the method embodiment can be completed. Optionally, the memory 2102 may include a read-only memory (English: Read-only Memory, abbreviation: ROM) and a random access memory (English: Random Access Memory, abbreviation: RAM). Wherein, the ROM includes a basic input/output system (English: Basic Input/Output System, abbreviation: BIOS) or an embedded system; the RAM includes an application program and an operating system. When the second network device 2100 needs to be operated, the system is booted by the BIOS solidified in the ROM or the bootloader in the embedded system to guide the second network device 2100 into a normal operating state. After the second network device 2100 enters the normal operating state, the application program and the operating system run in the RAM, thereby completing the processing procedure involving the second network device in the method embodiment.
可以理解的是,图8仅仅示出了第二网络设备2100的简化设计。在实际应用中,第二网络设备可以包含任意数量的接口,处理器或者存储器。It is understandable that FIG. 8 only shows a simplified design of the second network device 2100. In practical applications, the second network device may include any number of interfaces, processors or memories.
图9为本申请实施例的另一种第二网络设备2200的硬件结构示意图。图9所示的第二网络设备2200可以执行上述实施例的方法中第二网络设备执行的相应步骤。FIG. 9 is a schematic diagram of the hardware structure of another second network device 2200 according to an embodiment of the application. The second network device 2200 shown in FIG. 9 can execute the corresponding steps performed by the second network device in the method of the foregoing embodiment.
如图9所述,第二网络设备2200包括:主控板2210、接口板2230、交换网板2220和接口板2240。主控板2210、接口板2230和2240,以及交换网板2220之间通过系统总线与系统背板相连实现互通。其中,主控板2210用于完成系统管理、设备维护、 协议处理等功能。交换网板2220用于完成各接口板(接口板也称为线卡或业务板)之间的数据交换。接口板2230和2240用于提供各种业务接口(例如,POS接口、GE接口、ATM接口等),并实现数据包的转发As shown in FIG. 9, the second network device 2200 includes: a main control board 2210, an interface board 2230, a switching network board 2220, and an interface board 2240. The main control board 2210, the interface boards 2230 and 2240, and the switching network board 2220 are connected to the system backplane through the system bus to achieve intercommunication. Among them, the main control board 2210 is used to complete functions such as system management, equipment maintenance, and protocol processing. The switching network board 2220 is used to complete data exchange between various interface boards (interface boards are also called line cards or service boards). The interface boards 2230 and 2240 are used to provide various service interfaces (for example, POS interface, GE interface, ATM interface, etc.), and realize the forwarding of data packets
接口板2230可以包括中央处理器2231、转发表项存储器2234、物理接口卡2233和网络处理器2232。其中,中央处理器2231用于对接口板进行控制管理并与主控板上的中央处理器进行通信。转发表项存储器2234用于保存转发表项。物理接口卡2233用于完成流量的接收和发送。网络存储器2232用于根据所述转发表项控制物理接口卡2233收发流量。The interface board 2230 may include a central processing unit 2231, a forwarding entry memory 2234, a physical interface card 2233, and a network processor 2232. Among them, the central processing unit 2231 is used to control and manage the interface board and communicate with the central processing unit on the main control board. The forwarding entry storage 2234 is used to store forwarding entries. The physical interface card 2233 is used to complete the reception and transmission of traffic. The network storage 2232 is used for controlling the receiving and sending traffic of the physical interface card 2233 according to the forwarding entry.
具体的,物理接口卡2233用于向所述第一网络设备发送第一报文和SBFD报文;用于接收第一网络设备发送的SBFD报文的SBFD回应报文和SBFD回声报文Specifically, the physical interface card 2233 is configured to send a first message and an SBFD message to the first network device; and is configured to receive an SBFD response message and an SBFD echo message of the SBFD message sent by the first network device.
中央处理器2211用于生成所述第一报文。The central processing unit 2211 is configured to generate the first message.
中央处理器2211将第一报文经由中央处理器2231向物理接口卡2233发送。物理接口卡2233向所述NAT设备发送所述第一报文。The central processing unit 2211 sends the first message to the physical interface card 2233 via the central processing unit 2231. The physical interface card 2233 sends the first packet to the NAT device.
中央处理器2231还用于控制网络存储器2232获取转发表项存储器2234中的转发表项,并且,中央处理器2231还用于控制网络存储器2232经由物理接口卡2233完成流量的接收和发送。The central processing unit 2231 is also used to control the network storage 2232 to obtain forwarding entries in the forwarding entry storage 2234, and the central processing unit 2231 is also used to control the network storage 2232 to complete the reception and transmission of traffic via the physical interface card 2233.
应理解,本发明实施例中接口板2240上的操作与所述接口板2230的操作一致,为了简洁,不再赘述。应理解,本实施例的第二网络设备2200可对应于上述方法实施例所具有的功能和/或所实施的各种步骤,在此不再赘述。It should be understood that the operations on the interface board 2240 in the embodiment of the present invention are consistent with the operations on the interface board 2230, and will not be repeated for the sake of brevity. It should be understood that the second network device 2200 in this embodiment may correspond to the functions and/or various steps implemented in the foregoing method embodiments, and details are not described herein again.
此外,需要说明的是,主控板可能有一块或多块,有多块的时候可以包括主用主控板和备用主控板。接口板可能有一块或多块,第二网络设备的数据处理能力越强,提供的接口板越多。接口板上的物理接口卡也可以有一块或多块。交换网板可能没有,也可能有一块或多块,有多块的时候可以共同实现负荷分担冗余备份。在集中式转发架构下,第二网络设备可以不需要交换网板,接口板承担整个系统的业务数据的处理功能。在分布式转发架构下,第二网络设备可以有至少一块交换网板,通过交换网板实现多块接口板之间的数据交换,提供大容量的数据交换和处理能力。所以,分布式架构的第二网络设备的数据接入和处理能力要大于集中式架构的设备。具体采用哪种架构,取决于具体的组网部署场景,此处不做任何限定。In addition, it should be noted that there may be one or more main control boards, and when there are more than one, it may include a main main control board and a standby main control board. There may be one or more interface boards. The stronger the data processing capability of the second network device, the more interface boards provided. There may also be one or more physical interface cards on the interface board. The switching network board may not exist, or there may be one or more. When there are more than one, the load sharing and redundant backup can be realized together. Under the centralized forwarding architecture, the second network device may not need a switching network board, and the interface board is responsible for processing the service data of the entire system. Under the distributed forwarding architecture, the second network device may have at least one switching network board, and data exchange between multiple interface boards is realized through the switching network board, providing large-capacity data exchange and processing capabilities. Therefore, the data access and processing capability of the second network device of the distributed architecture is greater than that of the device of the centralized architecture. The specific architecture used depends on the specific networking deployment scenario, and there is no restriction here.
另外,本申请实施例提供了一种计算机存储介质,用于储存为上述第一网络设备所用的计算机软件指令,其包含用于执行上述方法实施例所设计的程序。In addition, an embodiment of the present application provides a computer storage medium for storing computer software instructions used for the above-mentioned first network device, which includes a program for executing the above-mentioned method embodiment.
另外,本申请实施例提供了一种计算机存储介质,用于储存为上述第二网络设备所用的计算机软件指令,其包含用于执行上述方法实施例所设计的程序。In addition, an embodiment of the present application provides a computer storage medium for storing computer software instructions used for the above-mentioned second network device, which includes a program for executing the above-mentioned method embodiment.
本申请实施例还包括一种处理报文的系统,所述系统包括第一网络设备和第二网络设备,所述第一网络设备为前述图4或图5或图6中的第一网络设备,所述第二网络设备为前述图7或图8或图9中的第二网络设备。The embodiment of the present application also includes a system for processing a message. The system includes a first network device and a second network device. The first network device is the first network device in FIG. 4 or FIG. 5 or FIG. , The second network device is the second network device in FIG. 7 or FIG. 8 or FIG. 9 described above.
结合本申请公开内容所描述的方法或者算法的步骤可以硬件的方式来实现,也可以是由处理器执行软件指令的方式来实现。软件指令可以由相应的软件模块组成,软件模块可以被存放于RAM存储器、闪存、ROM存储器、EPROM存储器、EEPROM存储器、寄存器、硬盘、移动硬盘、CD-ROM或者本领域熟知的任何其它形式的存储介质中。一种示例性的存储介质耦合至处理器,从而使处理器能够从该存储介质读取 信息,且可向该存储介质写入信息。当然,存储介质也可以是处理器的组成部分。处理器和存储介质可以位于ASIC中。另外,该ASIC可以位于用户设备中。当然,处理器和存储介质也可以作为分立组件存在于用户设备中。The steps of the method or algorithm described in combination with the disclosure of this application can be implemented in a hardware manner, or can be implemented in a manner in which a processor executes software instructions. Software instructions can be composed of corresponding software modules, which can be stored in RAM memory, flash memory, ROM memory, EPROM memory, EEPROM memory, registers, hard disk, mobile hard disk, CD-ROM or any other form of storage known in the art Medium. An exemplary storage medium is coupled to the processor, so that the processor can read information from the storage medium and write information to the storage medium. Of course, the storage medium may also be an integral part of the processor. The processor and the storage medium may be located in the ASIC. In addition, the ASIC may be located in the user equipment. Of course, the processor and the storage medium may also exist as discrete components in the user equipment.
本领域技术人员应该可以意识到,在上述一个或多个示例中,本申请所描述的功能可以用硬件或者用硬件和软件的组合来实现。当使用硬件和软件的组合实现时,可以将这些软件存储在计算机可读介质中或者作为计算机可读介质上的一个或多个指令或代码进行传输。计算机可读介质包括计算机存储介质和通信介质,其中通信介质包括便于从一个地方向另一个地方传送计算机程序的任何介质。存储介质可以是通用或专用计算机能够存取的任何可用介质。Those skilled in the art should be aware that, in one or more of the above examples, the functions described in this application can be implemented by hardware or a combination of hardware and software. When implemented using a combination of hardware and software, the software can be stored in a computer-readable medium or transmitted as one or more instructions or codes on the computer-readable medium. The computer-readable medium includes a computer storage medium and a communication medium, where the communication medium includes any medium that facilitates the transfer of a computer program from one place to another. The storage medium may be any available medium that can be accessed by a general-purpose or special-purpose computer.
以上所述的具体实施方式,对本申请的目的、技术方案和有益效果进行了进一步详细说明。所应理解的是,以上所述仅为本申请的具体实施方式而已。The specific implementations described above further describe the purpose, technical solutions, and beneficial effects of the present application in further detail. It should be understood that the above are only specific implementations of the application.

Claims (26)

  1. 一种无缝双向转发检测SBFD会话的建立方法、设备及系统。所述方法包括,第一网络设备接收第二网络设备发送的第一报文,所述第一报文包括SBFD信息,所述SBFD信息用于指示所述第一报文的目的地址对应的网络设备确定是否为隧道建立SBFD会话,所述隧道是从所述第一网络设备到所述第二网络设备的隧道,所述SBFD会话用于检测所述隧道的状态,所述目的地址是所述第一网络设备的地址;A method, equipment and system for establishing a seamless two-way forwarding and detecting SBFD session. The method includes receiving, by a first network device, a first message sent by a second network device, the first message including SBFD information, and the SBFD information is used to indicate a network corresponding to a destination address of the first message The device determines whether to establish an SBFD session for the tunnel. The tunnel is a tunnel from the first network device to the second network device. The SBFD session is used to detect the status of the tunnel. The destination address is the The address of the first network device;
    所述第一网络设备根据所述SBFD信息确定所述第一网络设备是否为所述隧道建立所述SBFD会话;Determining, by the first network device, whether the first network device establishes the SBFD session for the tunnel according to the SBFD information;
    当所述第一网络设备根据所述SBFD信息确定所述第一网络设备不需要为所述隧道建立所述SBFD会话时,所述第一网络设备避免创建所述SBFD会话。When the first network device determines according to the SBFD information that the first network device does not need to establish the SBFD session for the tunnel, the first network device avoids creating the SBFD session.
  2. 如权利要求1所述的方法,其特征在于,所述方法包括:The method of claim 1, wherein the method comprises:
    当所述第一网络设备根据所述SBFD信息确定所述第一网络设备需要为所述隧道建立所述SBFD会话时,所述第一网络设备创建所述SBFD会话。When the first network device determines according to the SBFD information that the first network device needs to establish the SBFD session for the tunnel, the first network device creates the SBFD session.
  3. 如权利要求2所述的方法,其特征在于,所述第一网络设备创建所述SBFD会话,包括:The method according to claim 2, wherein the creation of the SBFD session by the first network device comprises:
    向所述第二网络设备发送SBFD报文,所述SBFD报文用于请求建立所述SBFD会话;Sending an SBFD packet to the second network device, where the SBFD packet is used to request the establishment of the SBFD session;
    接收所述第二网络设备发送的针对所述SBFD报文的SBFD回应报文,所述SBFD回应报文指示所述第二网络设备处于工作状态;Receiving an SBFD response message for the SBFD message sent by the second network device, where the SBFD response message indicates that the second network device is in a working state;
    根据所述SBFD回应报文将所述第一网络设备的对应所述隧道的端口设置为UP状态。Setting the port of the first network device corresponding to the tunnel to the UP state according to the SBFD response message.
  4. 如权利要求3所述的方法,其特征在于,所述方法包括:The method of claim 3, wherein the method comprises:
    所述第一网络设备向所述第二网络设备发送SBFD回声报文,所述SBFD回声报文用于检测所述隧道的状态。The first network device sends an SBFD echo message to the second network device, where the SBFD echo message is used to detect the state of the tunnel.
  5. 如权利要求1-4中任一项所述的方法,其特征在于,所述第一报文是基于中间系统到中间系统IS-IS协议的链路状态协议LSP报文,所述第一报文还包括所述第二网络设备的段标识SID,所述隧道的目的地址为对应所述SID的地址。The method according to any one of claims 1-4, wherein the first message is a link state protocol LSP message based on the intermediate system to the intermediate system IS-IS protocol, and the first message The text also includes the segment identifier SID of the second network device, and the destination address of the tunnel is the address corresponding to the SID.
  6. 如权利要求1-4中任一项所述的方法,其特征在于,所述第一报文是基于开放式最短路径优先OSPF协议的链路状态更新LSU报文,所述第一报文还包括所述第二网络设备的段标识SID,所述隧道的目的地址为对应所述SID的地址。The method according to any one of claims 1-4, wherein the first message is a link state update LSU message based on the Open Shortest Path First OSPF protocol, and the first message also The segment identifier SID of the second network device is included, and the destination address of the tunnel is an address corresponding to the SID.
  7. 如权利要求5或6所述的方法,其特征在于,所述第一报文包括标志字段,所述标志字段用于承载所述SBFD信息。The method according to claim 5 or 6, wherein the first message includes a flag field, and the flag field is used to carry the SBFD information.
  8. 如权利要求1-7中任一项所述的方法,其特征在于,所述隧道是分段路由尽力而为SR-BE隧道。7. The method according to any one of claims 1-7, wherein the tunnel is a segmented best-effort SR-BE tunnel.
  9. 一种无缝双向转发检测SBFD会话的建立方法,其特征在于,所述方法包括:A method for establishing a seamless two-way forwarding detection SBFD session, characterized in that the method includes:
    第二网络设备生成第一报文,所述第一报文包括SBFD信息,所述SBFD信息用于指示所述第一报文的目的地址对应的网络设备确定是否为隧道建立SBFD会话,所述隧道是从第一网络设备到所述第二网络设备的隧道,所述SBFD会话用于检测所述隧道的状态,所述目的地址是所述第一网络设备的地址;The second network device generates a first packet, the first packet includes SBFD information, and the SBFD information is used to indicate that the network device corresponding to the destination address of the first packet determines whether to establish an SBFD session for the tunnel, and A tunnel is a tunnel from a first network device to the second network device, the SBFD session is used to detect the state of the tunnel, and the destination address is the address of the first network device;
    所述第二网络设备向所述第一网络设备发送所述第一报文,其中,所述第一报文中的所述SBFD信息用于阻止所述第一网络设备建立针对所述隧道的SBFD会话。The second network device sends the first message to the first network device, where the SBFD information in the first message is used to prevent the first network device from establishing a connection to the tunnel SBFD session.
  10. 如权利要求9所述的方法,其特征在于,所述第一报文是基于中间系统到中间系统IS-IS协议的链路状态协议LSP报文,所述第一报文还包括所述第二网络设备的段标识SID,所述隧道的目的地址为对应所述SID的地址。The method according to claim 9, wherein the first message is a link state protocol LSP message based on the intermediate system-to-intermediate system IS-IS protocol, and the first message further includes the first message 2. The segment identifier SID of the network device, and the destination address of the tunnel is the address corresponding to the SID.
  11. 如权利要求9所述的方法,其特征在于,所述第一报文是基于开放式最短路径优先OSPF协议的链路状态更新LSU报文,所述第一报文还包括所述第二网络设备的段标识SID,所述隧道的目的地址为对应所述SID的地址。The method according to claim 9, wherein the first message is a link state update LSU message based on the Open Shortest Path First OSPF protocol, and the first message further includes the second network The segment identifier SID of the device, and the destination address of the tunnel is the address corresponding to the SID.
  12. 如权利要求10或11所述的方法,其特征在于,所述第一报文包括标志字段,所述标志字段用于承载所述SBFD信息。The method according to claim 10 or 11, wherein the first message includes a flag field, and the flag field is used to carry the SBFD information.
  13. 如权利要求9-12中任一项所述的方法,其特征在于,所述隧道是分段路由尽力而为SR-BE隧道。The method according to any one of claims 9-12, wherein the tunnel is a segmented best-effort SR-BE tunnel.
  14. 一种第一网络设备,其特征在于,所述第一网络设备包括:A first network device, characterized in that, the first network device includes:
    接收器,用于接收第二网络设备发送的第一报文,所述第一报文包括无缝双向转发检测SBFD信息,所述SBFD信息用于指示所述第一报文的目的地址对应的网络设备确定是否为隧道建立SBFD会话,所述隧道是从所述第一网络设备到所述第二网络设备的隧道,所述SBFD会话用于检测所述隧道的状态,所述目的地址是所述第一网络设备的地址;A receiver, configured to receive a first packet sent by a second network device, the first packet including seamless bidirectional forwarding detection SBFD information, and the SBFD information is used to indicate the destination address of the first packet corresponding to the The network device determines whether to establish an SBFD session for the tunnel. The tunnel is a tunnel from the first network device to the second network device. The SBFD session is used to detect the status of the tunnel. The address of the first network device;
    处理器,用于根据所述SBFD信息确定所述第一网络设备是否为所述隧道建立所述SBFD会话;A processor, configured to determine whether the first network device establishes the SBFD session for the tunnel according to the SBFD information;
    当所述处理器根据所述SBFD信息确定所述第一网络设备不需要为所述隧道建立所述SBFD会话时,所述处理器还用于避免创建所述SBFD会话。When the processor determines according to the SBFD information that the first network device does not need to establish the SBFD session for the tunnel, the processor is further configured to avoid creating the SBFD session.
  15. 如权利要求14所述的第一网络设备,其特征在于,The first network device according to claim 14, wherein:
    当所述处理器根据所述SBFD信息确定所述第一网络设备需要为所述隧道建立所述SBFD会话时,所述处理器还用于创建所述SBFD会话。When the processor determines according to the SBFD information that the first network device needs to establish the SBFD session for the tunnel, the processor is further configured to create the SBFD session.
  16. 如权利要求15所述的第一网络设备,其特征在于,在所述处理器还用于创建所述SBFD会话中,所述处理器具体用于:The first network device according to claim 15, wherein when the processor is further configured to create the SBFD session, the processor is specifically configured to:
    向所述第二网络设备发送SBFD报文,所述SBFD报文用于请求建立所述SBFD会话;Sending an SBFD packet to the second network device, where the SBFD packet is used to request the establishment of the SBFD session;
    接收所述第二网络设备发送的针对所述SBFD报文的SBFD回应报文,所述SBFD回应报文指示所述第二网络设备处于工作状态;Receiving an SBFD response message for the SBFD message sent by the second network device, where the SBFD response message indicates that the second network device is in a working state;
    根据所述SBFD回应报文将所述第一网络设备的对应所述隧道的端口设置为UP状态。Setting the port of the first network device corresponding to the tunnel to the UP state according to the SBFD response message.
  17. 如权利要求16所述的第一网络设备,其特征在于,The first network device of claim 16, wherein:
    所述处理器还用于向所述第二网络设备发送SBFD回声报文,所述SBFD回声报文用于检测所述隧道的状态。The processor is further configured to send an SBFD echo message to the second network device, where the SBFD echo message is used to detect the state of the tunnel.
  18. 如权利要求14-17中任一项所述的第一网络设备,其特征在于,所述第一报文是基于中间系统到中间系统IS-IS协议的链路状态协议LSP报文,所述第一报文还包括所述第二网络设备的段标识SID,所述隧道的目的地址为对应所述SID的地址。The first network device according to any one of claims 14-17, wherein the first message is a link state protocol LSP message based on the intermediate system to the intermediate system IS-IS protocol, and the The first message also includes the segment identifier SID of the second network device, and the destination address of the tunnel is an address corresponding to the SID.
  19. 如权利要求14-17中任一项所述的第一网络设备,其特征在于,所述第一报文是基于开放式最短路径优先OSPF协议的链路状态更新LSU报文,所述第一报文还包括所述第二网络设备的段标识SID,所述隧道的目的地址为对应所述SID的地址。The first network device according to any one of claims 14-17, wherein the first message is a link state update LSU message based on the Open Shortest Path First OSPF protocol, and the first The message also includes the segment identifier SID of the second network device, and the destination address of the tunnel is the address corresponding to the SID.
  20. 如权利要求18或19所述的第一网络设备,其特征在于,所述第一报文包括标志字段,所述标志字段用于承载所述SBFD信息。The first network device according to claim 18 or 19, wherein the first message includes a flag field, and the flag field is used to carry the SBFD information.
  21. 如权利要求14-20中任一项所述的第一网络设备,其特征在于,所述隧道是分段路由尽力而为SR-BE隧道。The first network device according to any one of claims 14-20, wherein the tunnel is a segmented best-effort SR-BE tunnel.
  22. 一种第二网络设备,其特征在于,所述第二网络设备包括:A second network device, characterized in that, the second network device includes:
    处理器,用于生成第一报文,所述第一报文包括无缝双向转发检测SBFD信息,所述SBFD信息用于指示所述第一报文的目的地址对应的网络设备确定是否为隧道建立SBFD会话,所述隧道是从第一网络设备到所述第二网络设备的隧道,所述SBFD会话用于检测所述隧道的状态,所述目的地址是所述第一网络设备的地址;A processor, configured to generate a first packet, the first packet including seamless bidirectional forwarding detection SBFD information, and the SBFD information is used to indicate whether a network device corresponding to the destination address of the first packet determines whether it is a tunnel Establishing an SBFD session, where the tunnel is a tunnel from a first network device to the second network device, the SBFD session is used to detect the state of the tunnel, and the destination address is the address of the first network device;
    发送器,用于向所述第一网络设备发送所述第一报文,其中,所述第一报文中的 所述SBFD信息用于阻止所述第一网络设备建立针对所述隧道的SBFD会话。A transmitter, configured to send the first message to the first network device, where the SBFD information in the first message is used to prevent the first network device from establishing SBFD for the tunnel Conversation.
  23. 如权利要求22所述的第二网络设备,其特征在于,所述第一报文是基于中间系统到中间系统IS-IS协议的链路状态协议LSP报文,所述第一报文还包括所述第二网络设备的段标识SID,所述隧道的目的地址为对应所述SID的地址。The second network device according to claim 22, wherein the first message is a link state protocol (LSP) message based on the intermediate system-to-intermediate system IS-IS protocol, and the first message further includes The segment identifier SID of the second network device, and the destination address of the tunnel is an address corresponding to the SID.
  24. 如权利要求22所述的第二网络设备,其特征在于,所述第一报文是基于开放式最短路径优先OSPF协议的链路状态更新LSU报文,所述第一报文还包括所述第二网络设备的段标识SID,所述隧道的目的地址为对应所述SID的地址。The second network device according to claim 22, wherein the first message is a link state update LSU message based on the Open Shortest Path First OSPF protocol, and the first message further includes the The segment identifier SID of the second network device, and the destination address of the tunnel is the address corresponding to the SID.
  25. 如权利要求23或24所述的第二网络设备,其特征在于,所述第一报文包括标志字段,所述标志字段用于承载所述SBFD信息。The second network device according to claim 23 or 24, wherein the first message includes a flag field, and the flag field is used to carry the SBFD information.
  26. 如权利要求22-25中任一项所述的第二网络设备,其特征在于,所述隧道是分段路由尽力而为SR-BE隧道。The second network device according to any one of claims 22-25, wherein the tunnel is a segmented best-effort SR-BE tunnel.
PCT/CN2020/112310 2019-09-05 2020-08-29 Method, device and system for establishing sbfd session WO2021043086A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201910839079.XA CN112448877B (en) 2019-09-05 2019-09-05 SBFD session establishment method, device and system
CN201910839079.X 2019-09-05

Publications (1)

Publication Number Publication Date
WO2021043086A1 true WO2021043086A1 (en) 2021-03-11

Family

ID=74733044

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2020/112310 WO2021043086A1 (en) 2019-09-05 2020-08-29 Method, device and system for establishing sbfd session

Country Status (2)

Country Link
CN (1) CN112448877B (en)
WO (1) WO2021043086A1 (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113472653A (en) * 2021-05-25 2021-10-01 新华三信息安全技术有限公司 Method and device for detecting path consistency
CN113472642A (en) * 2021-06-10 2021-10-01 新华三信息安全技术有限公司 Protection switching method and device
CN113726650A (en) * 2021-07-19 2021-11-30 新华三信息安全技术有限公司 SBFD detection method and network equipment
CN113992581A (en) * 2021-09-17 2022-01-28 新华三信息安全技术有限公司 Message processing method and device
CN114338459A (en) * 2021-12-24 2022-04-12 迈普通信技术股份有限公司 Path detection method, path detection device, network equipment and computer readable storage medium

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113794637B (en) * 2021-08-20 2022-10-21 新华三信息安全技术有限公司 SID list processing method and device
CN113992475B (en) * 2021-09-23 2023-12-26 新华三信息安全技术有限公司 Tunnel establishment method and device
CN114513433B (en) * 2022-01-06 2023-10-24 新华三技术有限公司 Message processing method and device
CN116319508B (en) * 2023-05-15 2023-08-18 新华三技术有限公司 Path detection method, path detection device, network equipment and storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102752143A (en) * 2012-07-05 2012-10-24 杭州华三通信技术有限公司 Bi-directional forwarding detection (BFD) method of multiple protocol label switching (MPLS) traffic engineering (TE) bi-directional tunnel and routing equipment
US9497107B1 (en) * 2013-06-06 2016-11-15 Cisco Technology, Inc. Seamless path monitoring and rapid fault isolation using bidirectional forwarding detection in a network environment
US20180077051A1 (en) * 2016-09-15 2018-03-15 Cisco Technology, Inc. Reroute Detection in Segment Routing Data Plane
CN108156050A (en) * 2017-11-28 2018-06-12 盛科网络(苏州)有限公司 Seamless bidirectional forwarding detection (BFD) method and device
CN109587009A (en) * 2018-12-28 2019-04-05 北京华为数字技术有限公司 The method and apparatus for configuring seamless two-way converting detection SBFD mechanism

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101087211B (en) * 2007-07-20 2010-08-11 华为技术有限公司 A method and system for realizing echo function in BFD mechanism and its function entity
CN101163060B (en) * 2007-11-30 2010-06-09 杭州华三通信技术有限公司 BFD session establishing method, BFD session establishing device and routing device
CN101425942A (en) * 2008-12-09 2009-05-06 华为技术有限公司 Method, apparatus and system for bidirectional forwarding detection implementation
CN103916275A (en) * 2014-03-31 2014-07-09 杭州华三通信技术有限公司 BFD detection device and method
US10447571B2 (en) * 2018-01-12 2019-10-15 Cisco Technology, Inc. Dataplane-based seamless bidirectional forwarding detection monitoring for network entities

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102752143A (en) * 2012-07-05 2012-10-24 杭州华三通信技术有限公司 Bi-directional forwarding detection (BFD) method of multiple protocol label switching (MPLS) traffic engineering (TE) bi-directional tunnel and routing equipment
US9497107B1 (en) * 2013-06-06 2016-11-15 Cisco Technology, Inc. Seamless path monitoring and rapid fault isolation using bidirectional forwarding detection in a network environment
US20180077051A1 (en) * 2016-09-15 2018-03-15 Cisco Technology, Inc. Reroute Detection in Segment Routing Data Plane
CN108156050A (en) * 2017-11-28 2018-06-12 盛科网络(苏州)有限公司 Seamless bidirectional forwarding detection (BFD) method and device
CN109587009A (en) * 2018-12-28 2019-04-05 北京华为数字技术有限公司 The method and apparatus for configuring seamless two-way converting detection SBFD mechanism

Cited By (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113472653A (en) * 2021-05-25 2021-10-01 新华三信息安全技术有限公司 Method and device for detecting path consistency
CN113472653B (en) * 2021-05-25 2022-11-18 新华三信息安全技术有限公司 Method and device for detecting path consistency
CN113472642A (en) * 2021-06-10 2021-10-01 新华三信息安全技术有限公司 Protection switching method and device
CN113472642B (en) * 2021-06-10 2023-06-13 新华三信息安全技术有限公司 Protection switching method and device
CN113726650A (en) * 2021-07-19 2021-11-30 新华三信息安全技术有限公司 SBFD detection method and network equipment
CN113726650B (en) * 2021-07-19 2022-11-18 新华三信息安全技术有限公司 SBFD detection method and network equipment
CN113992581A (en) * 2021-09-17 2022-01-28 新华三信息安全技术有限公司 Message processing method and device
CN113992581B (en) * 2021-09-17 2023-03-31 新华三信息安全技术有限公司 Message processing method and device
CN114338459A (en) * 2021-12-24 2022-04-12 迈普通信技术股份有限公司 Path detection method, path detection device, network equipment and computer readable storage medium
CN114338459B (en) * 2021-12-24 2024-02-13 迈普通信技术股份有限公司 Path detection method, path detection device, network equipment and computer readable storage medium

Also Published As

Publication number Publication date
CN112448877B (en) 2022-07-22
CN112448877A (en) 2021-03-05

Similar Documents

Publication Publication Date Title
WO2021043086A1 (en) Method, device and system for establishing sbfd session
CN108574616B (en) Method, equipment and system for processing route
US10917262B2 (en) VXLAN packet forwarding method, device, and system
EP2878105B1 (en) System and method using rsvp hello suppression for graceful restart capable neighbors
US11349687B2 (en) Packet processing method, device, and system
CN100579072C (en) Method and system for communication between IP devices
EP3373547B1 (en) Method for realizing disaster tolerance backup
CN111865779B (en) Route synchronization method and cross-device link aggregation group
US8509059B2 (en) Method for operating a virtual router redundancy protocol router and communication system therefor
JP5691703B2 (en) Multicast network system
EP3694145B1 (en) Method and device for sending messages
US20220124033A1 (en) Method for Controlling Traffic Forwarding, Device, and System
CN111083061B (en) Method, equipment and system for determining DF (distribution function) of multicast flow
EP4044523A1 (en) Packet forwarding method, first network device, and first device group
CN113746733A (en) Table item synchronization method, gateway equipment, networking system and storage medium
CN112995027B (en) Route publishing method and VTEP node
US20210194999A1 (en) Packet sending method, network device, and computer storage medium
CN116233279A (en) Message processing method, device and system
JP2003224586A (en) Signalling system for return protection in double-ring network
EP3720078B1 (en) Anima network information processing method, device, and system
CN112804141B (en) Method for transmitting message, network equipment and computer storage medium
WO2023093786A1 (en) Traffic diversion method, device and system
WO2022194193A1 (en) Method and apparatus for acquiring path
WO2021259097A1 (en) Communication method, communication device, and storage medium
JP2005176268A (en) Ip network rerouting system using life-and-death supervision

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 20860368

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 20860368

Country of ref document: EP

Kind code of ref document: A1