WO2023173989A1 - 转发表的生成方法及装置、存储介质、电子装置 - Google Patents

转发表的生成方法及装置、存储介质、电子装置 Download PDF

Info

Publication number
WO2023173989A1
WO2023173989A1 PCT/CN2023/076262 CN2023076262W WO2023173989A1 WO 2023173989 A1 WO2023173989 A1 WO 2023173989A1 CN 2023076262 W CN2023076262 W CN 2023076262W WO 2023173989 A1 WO2023173989 A1 WO 2023173989A1
Authority
WO
WIPO (PCT)
Prior art keywords
bfr
prefix
domain
target
forwarding table
Prior art date
Application number
PCT/CN2023/076262
Other languages
English (en)
French (fr)
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 WO2023173989A1 publication Critical patent/WO2023173989A1/zh

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching 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/74Address processing for routing
    • H04L45/745Address table lookup; Address filtering
    • H04L45/748Address table lookup; Address filtering using longest matching prefix

Definitions

  • Embodiments of the present invention relate to the field of communications, and specifically to a method and device for generating a forwarding table, a storage medium, and an electronic device.
  • BIER Bit Indexed Explicit Replication
  • the entry node BFIR Bit-Forwarding Ingress Router
  • the exit node BFER of the BIER domain After receiving the BIER message, after stripping off the BIER header, the Payload is forwarded to the corresponding recipient.
  • the data plane forwarding technology of BIER eliminates the delay in establishing a multicast tree because there is no multicast tree establishment problem.
  • the convergence speed is the same as that of OSPF (Open Shortest Path First). Path priority) or ISIS (Intermediate System-to-Intermediate System, intermediate system to intermediate system) protocol, which reduces huge delays compared with the original multicast tree reconstruction.
  • OSPF Open Shortest Path First
  • ISIS Intermediate System-to-Intermediate System, intermediate system to intermediate system
  • BIER Bit-Forwarding Ingress Router
  • protocols such as OSPF or ISIS will support BIER information notification through signaling extensions. All nodes in the BIER domain will receive BIER information from other nodes and use this to build BIER forwarding entries, OSPF or ISIS, etc.
  • the extended signaling supports the BIER information exchange protocol, which is called BIERUnderlay technology.
  • BIER underlay technology can also use BGP (Border Gateway Protocol), BABEL and other protocols for notification.
  • BGP Border Gateway Protocol
  • the main content of the announcement includes routing prefix and BFR-ID (BFR-Identifier, BFR-identifier).
  • BFR-ID BFR-Identifier, BFR-identifier
  • OSPF will, according to the definition of RFC8444, in the routing
  • BIER SUB-TLV is added to carry BFR-ID and other information; after the protocol calculates the route based on the prefix, the BIER forwarding table is correctly generated based on the two;
  • devices in the network perform routing calculations based on the received prefix information after receiving advertisements from other devices to generate a unicast routing table for ordinary forwarding, and then generate a unicast routing table for BIER. Forwarded BIER routing table.
  • Embodiments of the present invention provide a method and device for generating a forwarding table, a storage medium, and an electronic device to at least solve the problems in related technologies such as unnecessary occupation of network bandwidth, excessive equipment burden, and loss of network bandwidth due to excessive notification volume.
  • Package problem
  • a method for generating a forwarding table including: when generating a target forwarding table based on a received first notification message, determining the bit forwarding router identifier BFR that already exists in the target forwarding table.
  • the target BFR-Prefix is determined from the first forwarding router prefix BFR-Prefix corresponding to the first BFR-ID and the second BFR-Prefix corresponding to the second BFR-ID; and the target BFR-Prefix is generated based on the target BFR-Prefix. Describe the target forwarding table.
  • a device for generating a forwarding table including: a determination module configured to determine that the target forwarding table already exists in the target forwarding table when generating the target forwarding table based on the received first notification message. whether there is a second BFR-ID that is the same as the first BFR-ID in the forwarding router identification BFR-ID, wherein the first notification message is used to notify the first BFR-ID of the first BFER; the determination module , is set to determine the target BFR- Prefix; a generation module configured to generate the target forwarding table based on the target BFR-Prefix.
  • a computer-readable storage medium is also provided.
  • a computer program is stored in the computer-readable storage medium, wherein the computer program is configured to execute the above method embodiment when running. A step of.
  • an electronic device including a memory and a processor.
  • a computer program is stored in the memory, and the processor is configured to run the computer program to execute the above method embodiment. steps in.
  • Figure 1 is a network architecture diagram in related technologies
  • Figure 2 is a representation diagram of BIER forwarding on BFR1 in related technology
  • FIG. 3 is a diagram of ordinary forwarding in related technologies
  • FIG. 4 is Figure 2 of the network architecture in related technologies
  • Figure 5 is a representation of unicast routing in related technologies
  • FIG. 6 is diagram 1 of BIER forwarding routing in related technologies
  • Figure 7 is a unicast routing diagram on the BFRm of domain 2 in the related art.
  • FIG 8 is diagram 2 of BIER forwarding routing in related technologies
  • Figure 9 is a hardware structure block diagram of a mobile terminal according to the method for generating a forwarding table according to an embodiment of the present invention.
  • Figure 10 is a flow chart of a method for generating a forwarding table according to an embodiment of the present invention.
  • Figure 11 is a schematic diagram of the out-of-domain SUB-SUB-TLV format according to an embodiment of the present invention.
  • Figure 12 is a schematic diagram 2 of the out-of-domain SUB-SUB-TLV format according to an embodiment of the present invention.
  • Figure 13 is a schematic diagram of the format when the out-of-domain SUB-SUB-TLV carries DOMAIN-ID alone according to an embodiment of the present invention
  • Figure 14 is a schematic diagram 1 of the format when an out-of-domain SUB-SUB-TLV carries a DOMAIN-ID according to an embodiment of the present invention
  • Figure 15 is a schematic diagram 2 of the format when an out-of-domain SUB-SUB-TLV carries a DOMAIN-ID according to an embodiment of the present invention
  • Figure 16 is a schematic diagram of the overall flow of generating a BIER forwarding table by a device according to an embodiment of the present invention.
  • Figure 17 is a unicast routing diagram according to specific embodiment 1 of the present invention.
  • Figure 18 is a representation diagram of BIER forwarding according to specific embodiment 1 of the present invention.
  • Figure 19 is a unicast routing diagram according to specific embodiment 2 of the present invention.
  • Figure 20 is a diagram 1 of BIER forwarding according to specific embodiment 2 of the present invention.
  • Figure 21 is a second diagram of BIER forwarding according to the second specific embodiment of the present invention.
  • Figure 22 is a unicast routing diagram according to the third specific embodiment of the present invention.
  • Figure 23 is a network architecture diagram according to specific embodiment 4 of the present invention.
  • Figure 24 is a unicast routing diagram according to the fourth embodiment of the present invention.
  • Figure 25 is a representation diagram of BIER forwarding according to the fourth embodiment of the present invention.
  • Figure 26 is a structural block diagram of a device for generating a forwarding table according to an embodiment of the present invention.
  • the main contents of the announcement include routing prefixes and BFR-IDs.
  • OSPF will add BIER SUB-TLV when advertising routing prefixes according to the definition of RFC8444. It carries BFR-ID and other information; after the protocol performs route calculation based on the prefix, the BIER forwarding table is correctly generated based on the two.
  • the edge devices in the network include BFIR and several BFERs: BFER1 to BFERn, The edge device will notify its BFR-ID and the corresponding Sub-Domain, BFR-Prefix, etc.
  • the prefix is usually taken from the loopback address of the device to uniquely identify a device in the network; in the same domain , BFR-ID and BFR-Prefix (BFR-Prefix is the Loopback prefix address of the device) are in one-to-one correspondence.
  • BFR-Prefix is the Loopback prefix address of the device
  • the OSPF protocol advertises according to RFC8444, advertises the BFR-Prefix through the Extended Prefix TLV of OSPF, and adds BIER SUB-TLV under this prefix to carry Sub-Domain-ID, BFR-ID and other information; the network's intermediate device BFR will also Advertise according to this protocol extension, but because the intermediate device BFR does not allocate BFR-ID, the BFR-ID advertised is 0.
  • FIG. 1 is the BIER forwarding table on BFR1.
  • BFR1 Before generating this table, BFR1 first needs to generate a normal forwarding table as shown in Figure 3 based on the received OSPF notification. This table is used for unicast routing forwarding. This table It is generated with the prefix as the index.
  • the next hop device corresponding to the route is BFR2
  • the BIER SUB-TLV carried in the advertisement TLV corresponding to the route is taken out and contains
  • the BFR-ID value is used as an index and added to the BIER forwarding table, and so on to generate the forwarding table in Figure 2.
  • a BIER domain consists of multiple IGP domains or AS domains (domain here, and the BIER notification mentioned above (Sub-Domain does not have the same meaning), as shown in Figure 4, this BIER domain consists of 3 domains.
  • each separate domain there will be running protocols, such as OSPF, ISIS, and BGP. Etc., the protocols running in each domain may be the same or different.
  • domain1 may run the BGP protocol
  • domain2 and domain3 may run the OSPF protocol
  • domain1 may run the OSPF protocol
  • domain2 may run the BGP protocol
  • domain3 may run the ISIS protocol, and so on.
  • the scope of protocol notifications in each domain is only within that domain. Assume that multicast traffic needs to be sent from BFIR1 device to BFER1 ⁇ 6.
  • the device In addition to establishing a forwarding table within its own domain, the device also needs to establish a forwarding table that can reach receivers in other domains.
  • Domain boundary devices such as BR1 ⁇ 4 in Figure 4, need to serve as bridges to transmit BFR-ID information in different domains.
  • BR1/2 needs to advertise the BFR-IDs of BFER1 and BFER2 in domain2 to domain1.
  • the BFR-IDs of BFER3 and BFER4 in domain3 received by BR3/4, and the BFR-IDs of BFER5 and BFER6 in domain1 are notified to domain2; similarly, BR3/4 needs to notify the BFR-IDs of BFER3 and BFER4 in domain3.
  • Notify to domain1 the BFR-IDs of BFER1 and BFER2 in domain2 received from BR1/2, and the BFR-IDs of BFER5 and BFER6 in domain1 are notified to domain3.
  • BR1/2 directly advertises the BFR- Prefix and its BFR-ID
  • BFER2's BFR-Prefix and its BFR-ID are notified to domain1; directly notify the BFR-Prefix and its BFR-ID of BFER5, BFER6's BFR-Prefix and its BFR-ID, and BFIR1 in domain1 Notify the BFR-Prefix and its BFR-ID of BFER3 to domain2 directly; directly notify the BFR-Prefix and BFR-ID of BFER3 obtained from BR3/4, and the BFR-Prefix and BFR-ID of BFER4 to domain2;
  • the BFR-Prefix and BFR-ID of the BFER devices in other domains can also be received.
  • the unicast routing table in Figure 5 can be calculated, and the BIER forwarding routing table in Figure 6 is generated. Similarly, the unicast routing table on BFRm of domain2 is shown in Figure 7. The BIER forwarding routing table As shown in Figure 8.
  • BR1 to 4 which are border devices, need to serve as bridges to advertise all BFR-Prefixes and their corresponding BFR-IDs.
  • the amount of device notifications is too large, and it is easy to cause problems such as packet loss.
  • an embodiment of the present invention proposes a method for generating a forwarding table.
  • FIG. 9 is a hardware structure block diagram of a mobile terminal for a forwarding table generation method according to an embodiment of the present invention.
  • the mobile terminal may include one or more (only one is shown in FIG. 9 ) processors 902 (the processor 902 may include but is not limited to a microprocessor MCU or a programmable logic device).
  • the above-mentioned mobile terminal may also include a transmission device 906 and an input and output device 908 for communication functions.
  • the structure shown in FIG. 9 is only illustrative, and it does not limit the structure of the above-mentioned mobile terminal.
  • the mobile terminal may also include more or fewer components than shown in FIG. 9 , or have a different configuration than that shown in FIG. 9 .
  • the memory 904 can be used to store computer programs, for example, software programs and modules of application software, such as the computer program corresponding to the method for generating a forwarding table in the embodiment of the present invention.
  • the processor 902 runs the computer program stored in the memory 904, thereby Execute various functional applications and data processing, that is, implement the above methods.
  • Memory 904 may include high-speed random access memory, and may also include non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory.
  • the memory 904 may further include memory located remotely relative to the processor 902, and these remote memories may be connected to the mobile terminal through a network. Examples of the above-mentioned networks include but are not limited to the Internet, intranets, local area networks, mobile communication networks and combinations thereof.
  • Transmission device 906 is used to receive or send data via a network.
  • Specific examples of the above-mentioned network may include a wireless network provided by a communication provider of the mobile terminal.
  • the transmission device 906 includes a network adapter (Network Interface Controller, NIC for short), which can be connected to other network devices through a base station to communicate with the Internet.
  • the transmission device 906 may be a radio frequency (Radio Frequency, RF for short) module, which is used to communicate with the Internet wirelessly.
  • NIC Network Interface Controller
  • FIG. 10 is a flow chart of a method for generating a forwarding table according to an embodiment of the present invention. As shown in Figure 10, the The process includes the following steps:
  • Step S1002 When generating a target forwarding table based on the received first notification message, determine whether the existing bit forwarding router identifier BFR-ID in the target forwarding table contains a second BFR-ID that is the same as the first BFR-ID. ID, wherein the first notification message is used to notify the first BFR-ID of the first BFER;
  • Step S1004 If it is determined to exist, determine the target BFR-Prefix from the first forwarding router prefix BFR-Prefix corresponding to the first BFR-ID and the second BFR-Prefix corresponding to the second BFR-ID. Prefix;
  • Step S1006 Generate the target forwarding table based on the target BFR-Prefix.
  • the execution subject of the above steps can be the BFR device in the BIER domain.
  • it can also be other devices in the BIER domain, or it can be a processor relatively independent of the above-mentioned BFR device, or it can be other devices with similar processing capabilities. Capacity processing equipment and so on.
  • the final routing prefix needs to be determined from the routing prefixes corresponding to the multiple identical BFR-IDs, and then the entries in the forwarding table are adjusted based on the final routing prefix. It needs to be explained. Yes, if the route prefix finally determined is the route prefix corresponding to the second BFR-ID, there is no need to adjust the entries in the forwarding table.
  • the route prefix finally determined is the route corresponding to the first BFR-ID, there is no need to adjust the entries in the forwarding table.
  • the prefixes of the same BFR-IDs will be compared to determine a more appropriate prefix corresponding to the BFR-ID, thereby It avoids repeatedly establishing multiple forwarding entries corresponding to the same BFR-ID in the forwarding table, avoids unnecessary occupation of network bandwidth, overloaded equipment, and packet loss caused by excessive notification volume, thereby improving network bandwidth utilization. , the effect of reducing equipment burden.
  • the target is determined from multiple BFR-Prefixes corresponding to the same BFR-ID.
  • BFR-Prefix can be comprehensively determined based on the content contained in the BFR-Prefix corresponding to each BFR-ID. The following explains how to comprehensively determine the target BFR-Prefix:
  • the first BFR-Prefix is determined as the target BFR-Prefix; when it is determined that the second content is more detailed than the first content, the second BFR-Prefix is determined as the target BFR-Prefix. .
  • the BFR-Prefix with more detailed content is given priority as the target BFR-Prefix, where the more detailed content may include more content contained in the BFR-Prefix, specifically, the prefix mask of the BFR-Prefix Longer.
  • the first BFR-Prefix is determined as the target BFR-Prefix; in the case where it is determined that the attribute value of the second attribute information is better than the attribute value of the first attribute information, the first BFR-Prefix is determined as the target BFR-Prefix.
  • the second BFR-Prefix is determined as the target BFR-Prefix.
  • the attribute information of the BFR-Prefix may include one or more of the cost attribute, the metric attribute, or other attributes of the BFR-Prefix, wherein a better attribute value may be a smaller value of the cost attribute and a smaller metric value.
  • the attribute value is smaller and so on.
  • generating the target forwarding table based on the target BFR-Prefix includes: when the target BFR-Prefix is the first BFR-Prefix, adding the target forwarding table to the target BFR-Prefix.
  • the second BFR-Prefix corresponding to the existing second BFR-ID and the next hop device are updated to the first BFR-Prefix and the next hop device corresponding to the first BFR-Prefix;
  • the target BFR-Prefix is the second BFR-Prefix, maintain the second BFR-ID that already exists in the forwarding table and the second BFR-Prefix corresponding to the second BFR-ID. And the next hop device remains unchanged.
  • the first BFR-Prefix can be directly discarded.
  • the method when the first notification message also includes the first domain identification DOMAIN-ID information of the domain where the first BFER is located, after determining that the target forwarding table already exists After the second BFR-ID that is the same as the first BFR-ID is stored in the BFR-ID, the method further includes: determining the BFR-Prefix corresponding to the first BFR-ID and the second BFR-ID respectively. If any of them are from within the domain, perform error processing; if it is determined that the BFR-Prefix corresponding to the first BFR-ID and the second BFR-ID respectively comes from outside the domain, determine whether to notify the third The second DOMAIN-ID information of the domain where the second BFER is located carried in the second notification message of the second BFR-ID.
  • the second notification message includes a second out-of-domain TLV, wherein: the second out-of-domain TLV carries the second BFR-ID information; or, the second out-of-domain TLV carries the second BFR-ID information and the second DOMAIN-ID information of the domain where the second BFER is located.
  • the second extra-domain TLV is an additional TLV added in the notification message, or a new type of TLV added under the original TLV.
  • the format of the newly added TLV is different under different protocols. of.
  • the second notification message includes the second BFR-Prefix, and the second out-of-domain TLV is sent following the second BFR-Prefix, wherein the second BFR -Prefix includes one of the following: aggregate route prefix, default route prefix, and BFR-Prefix of the border device.
  • the second notification message can carry domain DOMAIN-ID information; the extra-domain SUB-TLV/extra-domain SUB-SUB-TLV can follow the aggregation or default route prefix advertisement, or can also follow the BFR-Prefix of the border device. notice.
  • the first notification message includes a first out-of-domain TLV, wherein: the first out-of-domain TLV carries the first BFR-ID information; or, the first out-of-domain TLV carries Carrying the first BFR-ID information and the first DOMAIN-ID information of the domain where the first BFER is located.
  • the first extra-domain TLV is an additional TLV added in the notification message, or a new type of TLV added under the original TLV. The format of the newly added TLV is different under different protocols. .
  • the border device when the border device advertises the extra-area BFR-ID, it uses a new extra-area SUB-TLV or extra-area SUB-SUB-TLV (TLV: Type, Length, Value) to advertise.
  • TLV Type, Length, Value
  • the first notification message includes the first BFR-Prefix, and the first out-of-domain TLV is sent following the first BFR-Prefix, wherein the first BFR -Prefix includes one of the following: aggregate route prefix, default route prefix, and BFR-Prefix of the border device.
  • the first notification message may carry domain DOMAIN-ID information; wherein, the extra-domain SUB-TLV/out-of-domain SUB-SUB-TLV may follow the aggregation or default route prefix advertisement, or may follow the BFR- Prefix notification.
  • performing error processing includes at least one of the following: executing an alarm prompt to indicate that there is a problem with the current network deployment; sending alarm information to the controller to indicate that there is a problem with the current network deployment of the controller.
  • error processing can also be other processing methods, such as sending error information to a specific device, or sending error information to an administrator's terminal, etc. When an error occurs, There is no limit to the processing method.
  • the format is similar to that shown in Figure 11.
  • the BFR-ID to be carried can be listed; when the BFR-ID is a set of continuous values, a similar method can be used.
  • the DOMAIN-ID value can also be carried directly in the same SUB-SUB-TLV, so it can also be carried in a manner similar to Figure 14 and Figure 15;
  • the device calculates and generates the BIER forwarding table, it searches to see whether there is an entry with the same BFR-ID as the retrieved BRF-ID;
  • step S1606 if there is no entry with the same BFR-ID, directly add the entry, fill in the corresponding prefix and next hop, and go to step S1620;
  • S1616 Determine whether the entries in the forwarding table need to be updated based on the comparison results. If it is determined that an update is needed, go to S1606; otherwise, go to S1618;
  • the border device when the border device advertises BFR-ID, it will use some means to reduce the number of advertised prefixes, such as using aggregate routes or default route advertisement methods.
  • the aggregated prefixes may cover The prefix of one or more edge devices.
  • the default routing prefix will include the prefixes of all edge devices, so there will be multiple corresponding BFR-IDs.
  • the prefixes no longer correspond to BFR-IDs one-to-one; but for the same domain , the prefix and BFR-ID still have a one-to-one correspondence, so at this time, the BFR-ID advertisements in other domains must be distinguished from the BFR-ID advertisements in this domain; therefore, when announcing the BFR-IDs in other domains, new The TLV is carried instead of the original BIER SUB-TLV, or it is carried by adding a new type of SUB-SUB-TLV under the original BIER SUB-TLV, which is referred to as extraterritorial SUB-SUB-TLV here.
  • the border device wants the traffic sent to BFER1 to pass through BR1. It can choose to configure the configuration on BR1 when advertising the BFR-ID of domain2 to domain1.
  • the aggregate route (assuming its prefix is P11), assuming that P11 only contains the prefix of BFER1, so that when BR1 advertises the P11 prefix, it will only carry the BFR-ID 1 of BFER1; assume that the default route (0/ 0 route, we call it P0 for convenience), contains all the route prefixes of domain2, so when BR2 advertises P0 to domain1, it will carry the BFR-ID 1/2 of BFER1 and BFER2.
  • BIER forwarding table entry when processing the default route P0, it is found that the BFR-IDs it carries are 1 and 2, and the BFR-ID advertisements of the two prefixes are both out-of-area SUB-SUB-TLV. At this time, the original route cannot be directly followed. Process according to certain processing principles, otherwise the entry of BFR-ID 1 in the BIER forwarding table will be updated to prefix P0 and next hop BR2. This cannot achieve our original control purpose.
  • the route prefix P0 needs to be compared with the prefix P11 in the original BFR-ID 1, and it is found that P11 is more detailed (The mask length is longer), so there is no need to update the entry of BFR-ID 1, and the BIER forwarding table finally generated is similar to that shown in Figure 18 (other entries are omitted for simplicity).
  • the notification of the border device can also be further reduced by reducing the notification prefix.
  • the notification of the border device itself can be When using the BFR-Prefix, directly carry the extra-domain SUB-SUB-TLV to carry the BFR-ID of other domains.
  • the prefix of BR1 is PB1 and the prefix of BR2 is PB2.
  • BFR-Prefix in addition to advertising the BIER SUB-TLV in this domain, Carry extra-territorial SUB-SUB-TLV. Therefore, when BR1 advertises its prefix PB1, it also needs to carry the extra-domain SUB-SUB-TLV to carry the BFR-ID1/2 of domain2. The same applies to BR2 equipment.
  • BFR1 is still used as an example.
  • the prefix-based unicast routing table is first calculated as shown in Figure 19.
  • the BFR-ID carried by the PB1 prefix is first taken out. 1/2, two BIER forwarding entries are generated, the BFR-IDs are 1 and 2 respectively, the prefixes are both PB1, and the next hops are both BR1; when processing the BFR-ID carried by PB2, it is found that the BIER forwarding table has been There are corresponding entries.
  • Deployment in the network may sometimes cause problems. Assume that the network is still as shown in Figure 4. Assume that due to a deployment error by the network administrator, the BFR-IDs assigned to the BFER5 and BFER1 devices are both 50, and the BFER5 device has its own BFR-ID.
  • the prefix P5 and BFR-ID 50 are advertised in domain1, and the BFER1 device advertises its own prefix P1 and BFR-ID 50 in domain2; when the border device BR1 advertises the BFR-ID in domain2 to domain1, assume as The out-of-domain SUB-SUB-TLV of BR1 prefix PB1 is advertised; similarly, the advertisement from domain1 to domain2 is similar and will not be repeated here.
  • BFR1 When the device performs route calculation, BFR1 is still used as an example.
  • BFR1 will first generate a common unicast routing table, and the next hops to prefixes P5 and PB1 are BFER5 and BR1 respectively, as shown in Figure 22; further, assume First remove the BIER SUB-TLV carried by the route with prefix P5, and obtain the BIER forwarding entry with BFR-ID 50, prefix P5, and next hop BFER5; process the BIER SUB-TLV carried by prefix PB1 and the out-of-area SUB-SUB- TLV, BFR-ID 50 is found.
  • the notification in the above embodiment takes the OSPF protocol as an example.
  • the corresponding BIER SUB-TLV of the OSPF protocol is the BIER Info SUB-TLV of the ISIS protocol, and the corresponding out-of-domain SUB-SUB-
  • the TLV can be added under the BIER Info SUB-TLV; assuming it is advertised through the BGP protocol, the BIER TLV corresponding to the OSPF protocol BIER SUB-TLV can be added.
  • the extra-territorial notification that can be added under the BIER TLV is the extra-territorial SUB-TLV method.
  • the embodiment of the present invention does not place specific restrictions on the notification location.
  • the same BIER domain spans multiple AS domains
  • domain1/2/3 respectively represent three AS domains.
  • the boundaries of each domain are set
  • the BGP protocol is running between devices. For example, between BR1/2 of domain1 and BR5/6 of domain2, between BR3/4 of domain1 and BR7/8 of domain3. But inside each domain, the OSPF or ISIS protocol may be running, or the same BGP protocol.
  • BR5/6 Assume that the OSPF protocol is running in domain2 and the ISIS protocol is running in domain1. Taking the border device BR5/6 as an example, assume that the BR5/6 configuration needs to publish the BFR-ID information in domain2 to the BR1/2 device. First, BR5 The BFR-ID information of BFER1/2 obtained from the OSPF protocol, followed by its own device prefix, is advertised as an out-of-area SUB-TLV under its BIER TLV. The next hop is set to itself and sent to BR1 and BR2 devices, BR6 The device also announces this.
  • the BR1 device After receiving the advertisements from the BR5 and BR6 devices, the BR1 device calculates its own unicast routing forwarding table in a manner similar to the second embodiment, as shown in Figure 24, and generates a BIER forwarding table entry. It is assumed that the prefix metric advertised by BR5 is considered here. Even better, the BIER forwarding table generated by BR1 is shown in Figure 25. The BR2 device handles this in the same way. In the process of calculating the BIER forwarding table, the BR2 device may think that the prefix metric advertised by BR6 is better. Therefore, the prefix of BFR-ID 1/2 on the BR2 device may correspond to BR6-Prefix and Next hop BR6.
  • BR1 and BR2 devices still need to continue to advertise these two BFR-IDs to domain1. Therefore, BR1 and BR2 devices can carry the out-of-domain SUB-SUB-TLV when advertising their own prefix routes through the ISIS protocol. From this, domain1 BFR-ID information from domain2 will be received. The methods from domain1 to domain2/3 and from domain3 to domain1 are similar and will not be described again here.
  • BFR1 Taking BFR1 as an example, first calculate the unicast routing tables to BR1 and BR2.
  • a similar method to Embodiment 2 is used.
  • the prefix cost update is selected through comparison. The best one is used as a prefix and its next hop is taken, or an ECMP entry is formed when the two details are consistent.
  • the BFR-ID passed from domain3 to domain1 also has the same boundary device BFER1 as domain2.
  • BFR1 as an example, when calculating the BIER forwarding table, it is found that there is already an entry with the same BFR-ID. , the corresponding prefixes are all from outside the domain, but from different domains. This also indicates that the configuration is wrong. It is necessary to stop updating the BIER forwarding entry and display it through an alarm or error message, or send it to the controller with a prompt. There is a problem with the network deployment.
  • edge devices and intermediate devices in the figure is not large.
  • the number of these devices is not limited in the actual network applied by the embodiment of the present invention.
  • the calculated ordinary unicast routing table As for the BIER forwarding table, the next hop is based on the actual device and is not limited to the direct connection described in the embodiment of the present invention.
  • the method according to the above embodiments can be implemented by means of software plus the necessary general hardware platform. Of course, it can also be implemented by hardware, but in many cases the former is Better implementation.
  • the technical solutions of the embodiments of the present invention can be embodied in the form of software products in essence or in part that contribute to the existing technology.
  • the computer software products are stored in a storage medium (such as ROM/RAM, magnetic disc, optical disk), including several instructions to cause a terminal device (which can be a mobile phone, computer, server, or network device, etc.) to execute the methods described in various embodiments of the present invention.
  • This embodiment also provides a device for generating a forwarding table.
  • the device is configured to implement the above embodiments and preferred implementations. What has already been described will not be described again.
  • the term "module” may be a combination of software and/or hardware that implements a predetermined function.
  • the apparatus described in the following embodiments is preferably implemented in software, implementation in hardware, or a combination of software and hardware, is also possible and contemplated.
  • Figure 26 is a structural block diagram of a device for generating a forwarding table according to an embodiment of the present invention. As shown in Figure 26, the device includes:
  • the judgment module 262 is configured to, when generating the target forwarding table based on the received first notification message, judge whether the bit forwarding router identification BFR-ID that already exists in the target forwarding table contains the same third BFR-ID as the first BFR-ID. Two BFR-IDs, wherein the first notification message is used to notify the first BFR-ID of the first BFER;
  • the determination module 264 is configured to, if it is determined to exist, determine from the first forwarding router prefix BFR-Prefix corresponding to the first BFR-ID and the second BFR-Prefix corresponding to the second BFR-ID. targetBFR-Prefix;
  • the generation module 266 is configured to generate the target forwarding table based on the target BFR-Prefix.
  • the determining module 264 includes:
  • a first comparison unit configured to compare the first content included in the first BFR-Prefix with the second content included in the second BFR-Prefix
  • a first determination unit configured to determine the first BFR-Prefix as the target BFR-Prefix when it is determined that the first content is more detailed than the second content
  • the second determination unit is configured to determine the second BFR-Prefix as the target BFR-Prefix when it is determined that the second content is more detailed than the first content.
  • the determining module 264 includes:
  • a second comparison unit configured to compare the first attribute information of the first BFR-Prefix with the second attribute information of the second BFR-Prefix
  • a third determination unit configured to determine the first BFR-Prefix as the target BFR-Prefix when it is determined that the attribute value of the first attribute information is better than the attribute value of the second attribute information
  • the fourth determination unit is configured to determine the second BFR-Prefix as the target BFR-Prefix when it is determined that the attribute value of the second attribute information is better than the attribute value of the first attribute information.
  • the generation module 266 includes:
  • An update module configured to, when the target BFR-Prefix is the first BFR-Prefix, forward the second BFR-Prefix corresponding to the second BFR-ID that already exists in the target forwarding table. And the next hop device is updated to the first BFR-Prefix and the next hop device corresponding to the first BFR-Prefix;
  • a maintenance module configured to maintain the second BFR-ID that already exists in the forwarding table and the corresponding second BFR-ID when the target BFR-Prefix is the second BFR-Prefix.
  • the second BFR-Prefix and next-hop device remain unchanged.
  • the device further includes:
  • the first execution module is configured to, when the first notification message also includes the first domain identifier DOMAIN-ID information of the domain where the first BFER is located, determine the BFR-ID that already exists in the target forwarding table. After the second BFR-ID that is the same as the first BFR-ID is stored in the ID, and it is determined that the BFR-Prefix corresponding to the first BFR-ID and the second BFR-ID respectively comes from within the domain, Perform error handling;
  • the second execution module is configured to further include the first domain identifier of the domain where the first BFER is located in the first notification message.
  • identifying DOMAIN-ID information after determining that the BFR-ID that already exists in the target forwarding table contains a second BFR-ID that is the same as the first BFR-ID, after determining that the first BFR-ID and When the BFR-Prefixes corresponding to the second BFR-ID are from outside the domain, determine the second DOMAIN of the domain where the second BFER is located carried in the second notification message for announcing the second BFR-ID.
  • -ID information if the first DOMAIN-ID information is different from the second DOMAIN-ID information, error processing is performed.
  • the second notification message includes a second out-of-domain TLV, wherein: the second out-of-domain TLV carries the second BFR-ID information; or, the second out-of-domain TLV carries Carrying the second BFR-ID information and the second DOMAIN-ID information of the domain where the second BFER is located.
  • the second notification message includes the second BFR-Prefix
  • the second out-of-domain TLV is sent following the second BFR-Prefix
  • the second BFR -Prefix includes one of the following: aggregate route prefix, default route prefix, and BFR-Prefix of the border device.
  • the first notification message includes a first out-of-domain TLV, wherein: the first out-of-domain TLV carries the first BFR-ID information; or, the first out-of-domain TLV carries Carrying the first BFR-ID information and the first DOMAIN-ID information of the domain where the first BFER is located.
  • the first notification message includes the first BFR-Prefix
  • the first out-of-domain TLV is sent following the first BFR-Prefix
  • the first BFR -Prefix includes one of the following: aggregate route prefix, default route prefix, and BFR-Prefix of the border device.
  • both the first execution module and the second execution module can perform error processing in at least one of the following ways:
  • each of the above modules can be implemented through software or hardware.
  • it can be implemented in the following ways, but is not limited to this: the above modules are all located in the same processor; or the above modules can be implemented in any combination.
  • the forms are located in different processors.
  • Embodiments of the present invention also provide a computer-readable storage medium that stores a computer program, wherein the computer program is configured to execute the steps in any of the above method embodiments when running.
  • the computer-readable storage medium may include but is not limited to: U disk, read-only memory (Read-Only Memory, referred to as ROM), random access memory (Random Access Memory, referred to as RAM) , mobile hard disk, magnetic disk or optical disk and other media that can store computer programs.
  • ROM read-only memory
  • RAM random access memory
  • mobile hard disk magnetic disk or optical disk and other media that can store computer programs.
  • An embodiment of the present invention also provides an electronic device, including a memory and a processor.
  • a computer program is stored in the memory, and the processor is configured to run the computer program to perform the steps in any of the above method embodiments.
  • the above-mentioned electronic device may further include a transmission device and an input-output device, wherein the transmission device is connected to the above-mentioned processor, and the input-output device is connected to the above-mentioned processor.
  • each module or each step of the above embodiments of the present invention can be used in general They can be implemented by computing devices. They can be concentrated on a single computing device or distributed on a network composed of multiple computing devices. They can be implemented by program codes executable by the computing devices, so that they can be stored in the storage.
  • the apparatus is performed by a computing device, and in some cases, the steps shown or described may be performed in a sequence different from that herein, or be fabricated separately into individual integrated circuit modules, or multiple of them
  • the modules or steps are implemented as a single integrated circuit module. As such, embodiments of the present invention are not limited to any specific combination of hardware and software.

Landscapes

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

Abstract

本发明实施例提供了一种转发表的生成方法及装置、存储介质、电子装置,其中,该方法包括:在基于接收到的第一通告消息生成目标转发表时,判断所述目标转发表中已存在的位转发路由器标识BFR-ID中是否存与第一BFR-ID相同的第二BFR-ID,其中,所述第一通告消息用于通告第一BFER的所述第一BFR-ID;在确定存在的情况下,从所述第一BFR-ID对应的第一位转发路由器前缀BFR-Prefix和所述第二BFR-ID对应的第二BFR-Prefix中确定出目标BFR-Prefix;基于所述目标BFR-Prefix生成所述目标转发表。通过本发明实施例,解决了相关技术中存在的由于通告量过大而导致网络带宽的不必要占用,设备负担过重以及丢包的问题。

Description

转发表的生成方法及装置、存储介质、电子装置 技术领域
本发明实施例涉及通信领域,具体而言,涉及一种转发表的生成方法及装置、存储介质、电子装置。
背景技术
BIER(Bit Indexed Explicit Replication,位索引显式复制)(RFC8279)是一种新型组播数据转发技术,该将网络边缘的节点都只用一个BIT位来表示,组播流量在中间网络传输,额外封装一个特定的BIER头,这个报文头以BIT位串的形式标注了该组播流的所有目的节点BFER(Bit-Forwarding Egress Router,位转发出口路由器),中间网络转发节点根据bit位进行路由,保障流量能够发送到所有目的节点。中间节点转发设备事先通过路由协议形成用于指导BIER转发的表,在收到封装BIER头的流量时,依据BIFT(Bit Index Forwarding Table,位索引转发表)来完成报文到目的节点的转发。BIER域的入口节点BFIR(Bit-Forwarding Ingress Router,位转发入口路由器)将进入BIER域的组播流量作为BIER头的payload(载荷)进行封装,通过中间节点的转发后,BIER域的出口节点BFER收到BIER报文,剥除BIER头后,将Payload转发给相应的接收者。BIER这种数据面转发技术因为没有组播树的建立问题,消除了组播树建立的时延,并且在网络出现链路或者节点问题时,收敛速度同OSPF(Open Shortest Path First,开放式最短路径优先)或ISIS(Intermediate System-to-Intermediate System,中间系统到中间系统)协议,比原来的组播树重建降低了巨大的时延。
对于BIER域的入口设备BFIR来说,想要传输某条组播流量,需要知道哪些BIER域的出口设备BFER(Bit-Forwarding Ingress Router)需要这条组播流量,因此在BFIR和BFER之间,需要存在信令交互,这些交互的信令技术称之为BIER Overlay技术。中间单纯用于BIER转发的BFR(Bit-Forwarding Router,位转发路由器)设备则无需知道该组播流量信息。
为了构建BIER转发表项,OSPF或者ISIS等协议,会通过信令扩展支持BIER信息通告,BIER域内所有节点均会收到其他节点的BIER信息,并以此构建BIER转发表项,OSPF或者ISIS等扩展信令支持BIER信息交互的协议,称之为BIERUnderlay技术。
BIER underlay技术除了采用OSPF、ISIS等协议进行通告外,还可以采用BGP(Border Gateway Protocol,边界网关协议)、BABEL等协议进行通告。
在相关技术中,OSPF、ISIS等协议通过扩展在通告BIER信息时,通告的主要内容包括路由前缀和BFR-ID(BFR-Identifier,BFR-标识)等,比如OSPF会根据RFC8444的定义,在路由前缀通告时,增加BIER SUB-TLV的方式携带BFR-ID等信息;协议在根据前缀进行路由计算后,BIER转发表项再根据两者进行正确生成;
借助OSPF协议的泛洪机制,网络中的设备在收到其他设备的通告后根据收到的前缀信息进行路由计算,以生成用于普通转发的单播路由表,并由此再生成用于BIER转发的BIER路由表。
需要说明的是,相关技术中生成路由表的方式会产生路由的泄露,会使得不同域中并不 需要完全互相学习的路由也被各个域内的设备全部学习到,导致通告量巨大,造成网络带宽不必要的占用,设备负担也会加重。此外,过大的通告量,还会容易出现丢包的问题。
针对相关技术中存在的上述问题,目前尚未提出有效的解决方案。
发明内容
本发明实施例提供了一种转发表的生成方法及装置、存储介质、电子装置,以至少解决相关技术中存在的由于通告量过大而导致网络带宽的不必要占用,设备负担过重以及丢包的问题。
根据本发明的一个实施例,提供了一种转发表的生成方法,包括:在基于接收到的第一通告消息生成目标转发表时,判断所述目标转发表中已存在的位转发路由器标识BFR-ID中是否存与第一BFR-ID相同的第二BFR-ID,其中,所述第一通告消息用于通告第一BFER的所述第一BFR-ID;在确定存在的情况下,从所述第一BFR-ID对应的第一位转发路由器前缀BFR-Prefix和所述第二BFR-ID对应的第二BFR-Prefix中确定出目标BFR-Prefix;基于所述目标BFR-Prefix生成所述目标转发表。
根据本发明的另一个实施例,提供了一种转发表的生成装置,包括:判断模块,设置为在基于接收到的第一通告消息生成目标转发表时,判断所述目标转发表中已存在的位转发路由器标识BFR-ID中是否存与第一BFR-ID相同的第二BFR-ID,其中,所述第一通告消息用于通告第一BFER的所述第一BFR-ID;确定模块,设置为在确定存在的情况下,从所述第一BFR-ID对应的第一位转发路由器前缀BFR-Prefix和所述第二BFR-ID对应的第二BFR-Prefix中确定出目标BFR-Prefix;生成模块,设置为基于所述目标BFR-Prefix生成所述目标转发表。
根据本发明的又一个实施例,还提供了一种计算机可读存储介质,所述计算机可读存储介质中存储有计算机程序,其中,所述计算机程序被设置为运行时执行上述方法实施例中的步骤。
根据本发明的又一个实施例,还提供了一种电子装置,包括存储器和处理器,所述存储器中存储有计算机程序,所述处理器被设置为运行所述计算机程序以执行上述方法实施例中的步骤。
附图说明
图1是相关技术中的网络架构图一;
图2是相关技术中的BFR1上的BIER转发表示意图;
图3是相关技术中的普通转发表示意图;
图4是相关技术中的网络架构图二;
图5是相关技术中的单播路由表示意图;
图6是相关技术中的BIER转发路由表示意图一;
图7是相关技术中的domain2的BFRm上的单播路由表示意图;
图8是相关技术中的BIER转发路由表示意图二;
图9是本发明实施例的转发表的生成方法的移动终端的硬件结构框图;
图10是根据本发明实施例的转发表的生成方法的流程图;
图11是根据本发明实施例的域外SUB-SUB-TLV格式示意图一;
图12是根据本发明实施例的域外SUB-SUB-TLV格式示意图二;
图13是根据本发明实施例的域外SUB-SUB-TLV单独携带DOMAIN-ID时的格式示意图;
图14是根据本发明实施例的域外SUB-SUB-TLV携带DOMAIN-ID时的格式示意图一;
图15是根据本发明实施例的域外SUB-SUB-TLV携带DOMAIN-ID时的格式示意图二;
图16是根据本发明实施例的设备生成BIER转发表的整体流程示意图;
图17是根据本发明具体实施例一的单播路由表示意图;
图18是根据本发明具体实施例一的BIER转发表示意图;
图19是根据本发明具体实施例二的单播路由表示意图;
图20是根据本发明具体实施例二的BIER转发表示意图一;
图21是根据本发明具体实施例二的BIER转发表示意图二;
图22是根据本发明具体实施例三的单播路由表示意图;
图23是根据本发明具体实施例四的网络架构图;
图24是根据本发明具体实施例四的单播路由表示意图;
图25是根据本发明具体实施例四的BIER转发表示意图;
图26是根据本发明实施例的转发表的生成装置的结构框图。
具体实施方式
首先对本发明实施例涉及到的相关技术进行说明:
现有的OSPF、ISIS等协议通过扩展在通告BIER信息时,通告的主要内容包括路由前缀和BFR-ID等,比如OSPF会根据RFC8444的定义,在路由前缀通告时,增加BIER SUB-TLV的方式携带BFR-ID等信息;协议在根据前缀进行路由计算后,BIER转发表项再根据两者进行正确生成;以图1为例,该网络中的边缘设备包括BFIR和若干BFER:BFER1到BFERn,边缘设备将就其BFR-ID与对应的Sub-Domain、BFR-Prefix等一并通告,前缀Prefix通常取自于设备的Loopback地址,用以在网络中唯一的标识一台设备;同一个域中,BFR-ID和BFR-Prefix(BFR-Prefix即是设备的Loopback前缀地址)是一一对应的。假设OSPF协议根据RFC8444进行通告,通过OSPF的Extended Prefix TLV通告BFR-Prefix,并在此前缀下增加BIER SUB-TLV来携带Sub-Domain-ID、BFR-ID等信息;网络的中间设备BFR也会按照此协议扩展进行通告,但因中间设备BFR不分配BFR-ID,因此其通告的BFR-ID为0。在图1的示例中,假设BFIR1的BFR-ID是100,其BFR-Prefix是P100;BFER1的BFR-ID是1,其BFR-Prefix是P1;BFER2的BFR-ID是2,其BFR-Prefix是P2;以此类推,假设这些BFR-ID均在Sub-Domain 0中。
借助OSPF协议的泛洪机制,网络中的设备在收到其他设备的通告后根据收到的前缀信息进行路由计算,以生成用于普通转发的单播路由表,并由此再生成用于BIER转发的BIER路由表;如RFC8279中所描述,BIER转发表是BFR-ID为索引,包含BFR-prefix以及下一跳邻居BFR-NBR的表项。例如:图2是BFR1上的BIER转发表,在生成这个表之前,首先BFR1需要根据收到的OSPF通告,生成如图3所示的普通转发表,这个表用于单播路由转发,这个表是以前缀为索引生成,比如对于BFER1所通告的前缀P1,计算出该路由对应的下一跳设备是BFR2,然后将该路由所对应的通告TLV中携带的BIER SUB-TLV取出,将其中包含的BFR-ID值作为索引,加入到BIER转发表,以此类推生成图2的转发表。
在一个BIER域由多个IGP域或者AS域(这里的域domain,与上面提到的BIER通告 时的Sub-Domain并非同一个含义)组成时,如图4所示的网络,这个BIER域由3个域组成,在单独的每个域中,都会有运行的协议,如OSPF、ISIS、BGP等等,各域运行的协议可能相同也可能不同。比如domain1中可能运行的是BGP协议,domain2和domain3中运行的是OSPF协议;或者domain1中运行的是OSPF协议,domain2中运行的是BGP协议,domain3中运行的是ISIS协议等等。各domain内的协议通告范围仅在该domain中。假设组播流量需要从BFIR1设备发送到BFER1~6,设备除了需要建立自己domain内的转发表之外,还需要建立能够到达其他domain接收者的转发表。
Domain的边界设备,如图4中BR1~4,需要作为桥梁将不同域中的BFR-ID信息进行传送,比如BR1/2需要将domain2中BFER1和BFER2的BFR-ID通告到domain1中,将从BR3/4收到的domain3中的BFER3和BFER4的BFR-ID,以及domain1中的BFER5和BFER6的BFR-ID通告到domain2中;类似的,BR3/4需要将domain3中BFER3和BFER4的BFR-ID通告到domain1中,将从BR1/2收到的domain2中的BFER1和BFER2的BFR-ID,以及domain1中的BFER5和BFER6的BFR-ID通告到domain3中。为了达到该目的,一种实现该方法是,将BFIR/BFER的前缀,也就是其loopback地址,直接在Domain的边界设备上进行通告,也就是说,BR1/2直接将domain2中BFER1的BFR-Prefix及其BFR-ID、BFER2的BFR-Prefix及其BFR-ID通告到domain1中;直接将domain1中的BFER5的BFR-Prefix及其BFR-ID、BFER6的BFR-Prefix及其BFR-ID、BFIR1的BFR-Prefix及其BFR-ID通告到domain2中;直接将从BR3/4获取到的BFER3的BFR-Prefix及其BFR-ID、BFER4的BFR-Prefix及其BFR-ID通告到domain2中;以此类推,这样在各domain中,除了本域BFER1和BFER2的信息,同样能收到其他域的BFER设备的BFR-Prefix及其BFR-ID。以BFR1为例,可以计算出图5的单播路由表,并由此产生图6的BIER转发路由表;同理,domain2的BFRm上的单播路由表如图7所示,BIER转发路由表如图8所示。
这种方法的优势是简单直接,缺点也很明显,首先是域间产生了路由的泄漏,比如domain2中2台BFER设备的前缀,在domain1和domain3中都存在,实际上不同域的所有路由并不需要完全互相学习到;其次是假设BFIR/BFER设备的数量非常巨大时,设备的负担很重,假设每个domain中都有200台边缘设备,则3个domain总共600个边缘设备的BFR-Prefix及其BFR-ID都会在每个domain中通告,巨大的通告量除了占用网络带宽、给所有设备造成影响外(比如OSPF设备和ISIS设备的泛洪),还给设备计算造成极大的负担,因为每台设备都首先要计算出600条单播路由,才能生成用于转发的BIER转发表。其中,作为边界设备的BR1~4,要作为桥梁通告所有的BFR-Prefix及其对应的BFR-ID,其设备通告量过大,还很容易出现丢包等情况造成问题。
针对上述问题,本发明实施例中提出了一种转发表的生成方法,下文中将参考附图并结合实施例来详细说明本发明的实施例。
需要说明的是,本发明实施例的说明书和权利要求书及上述附图中的术语“第一”、“第二”等是用于区别类似的对象,而不必用于描述特定的顺序或先后次序。
本申请实施例中所提供的方法实施例可以在移动终端、路由器或者交换机、计算机终端或者类似的运算装置中执行。以运行在移动终端上为例,图9是本发明实施例的一种转发表的生成方法的移动终端的硬件结构框图。如图9所示,移动终端可以包括一个或多个(图9中仅示出一个)处理器902(处理器902可以包括但不限于微处理器MCU或可编程逻辑器件 FPGA等的处理装置)和用于存储数据的存储器904,其中,上述移动终端还可以包括用于通信功能的传输设备906以及输入输出设备908。本领域普通技术人员可以理解,图9所示的结构仅为示意,其并不对上述移动终端的结构造成限定。例如,移动终端还可包括比图9中所示更多或者更少的组件,或者具有与图9所示不同的配置。
存储器904可用于存储计算机程序,例如,应用软件的软件程序以及模块,如本发明实施例中的转发表的生成方法对应的计算机程序,处理器902通过运行存储在存储器904内的计算机程序,从而执行各种功能应用以及数据处理,即实现上述的方法。存储器904可包括高速随机存储器,还可包括非易失性存储器,如一个或者多个磁性存储装置、闪存、或者其他非易失性固态存储器。在一些实例中,存储器904可进一步包括相对于处理器902远程设置的存储器,这些远程存储器可以通过网络连接至移动终端。上述网络的实例包括但不限于互联网、企业内部网、局域网、移动通信网及其组合。
传输装置906用于经由一个网络接收或者发送数据。上述的网络具体实例可包括移动终端的通信供应商提供的无线网络。在一个实例中,传输装置906包括一个网络适配器(Network Interface Controller,简称为NIC),其可通过基站与其他网络设备相连从而可与互联网进行通讯。在一个实例中,传输装置906可以为射频(Radio Frequency,简称为RF)模块,其用于通过无线方式与互联网进行通讯。
在本实施例中提供了一种可以但不限于运行于上述终端中的转发表的生成方法,图10是根据本发明实施例的转发表的生成方法的流程图,如图10所示,该流程包括如下步骤:
步骤S1002,在基于接收到的第一通告消息生成目标转发表时,判断所述目标转发表中已存在的位转发路由器标识BFR-ID中是否存与第一BFR-ID相同的第二BFR-ID,其中,所述第一通告消息用于通告第一BFER的所述第一BFR-ID;
步骤S1004,在确定存在的情况下,从所述第一BFR-ID对应的第一位转发路由器前缀BFR-Prefix和所述第二BFR-ID对应的第二BFR-Prefix中确定出目标BFR-Prefix;
步骤S1006,基于所述目标BFR-Prefix生成所述目标转发表。
其中,上述步骤的执行主体可以是BIER域内的BFR设备,当然,也可以是BIER域内的其他设备,或者还可以是与上述的BFR设备相对独立的处理器,或者还可以是其他的具备类似处理能力的处理设备等等。
在上述实施例中,如果不存在和第一BFR-ID相同的BFR-ID条目的情况下,则直接在转发表新增与该第一BFR-ID对应的条目,并填入相应的前缀和下一跳。如果存在相同的BFR-ID的条目,则需要从该多个相同的BFR-ID对应的路由前缀中确定出最终的路由前缀,进而基于该最终的路由前缀调整转发表中的条目,需要说明的是,如果最终确定出的路由前缀就是该第二BFR-ID对应的路由前缀的情况下,则无需调整转发表中的条目,如果最终确定出的路由前缀是该第一BFR-ID对应的路由前缀的情况下,则需要将转发表中与第一BFR-ID对应的路由前缀和下一跳更新为第一BFR-ID对应的路由前缀和下一跳。
通过上述实施例,在生成转发表时,如果存在多个相同的BFR-ID,会对相同的BFR-ID的前缀进行比对,进而确定出更合适的与该BFR-ID对应的前缀,从而避免在转发表中重复建立多条对应相同BFR-ID的转发条目,避免通告量过大而导致的网络带宽的不必要占用,设备负担过重以及丢包的问题,达到了提高网络带宽利用率、降低设备负担的效果。
在一个可选的实施例中,在从多个相同的BFR-ID对应的BFR-Prefix中确定出目标 BFR-Prefix时,可以基于各BFR-ID对应的BFR-Prefix中所包含的内容来综合确定,下面对如何综合确定该目标BFR-Prefix进行说明:
确定方式一:
比较所述第一BFR-Prefix中所包括的第一内容与所述第二BFR-Prefix中所包括的第二内容;在确定所述第一内容比所述第二内容详细的情况下,将所述第一BFR-Prefix确定为所述目标BFR-Prefix;在确定所述第二内容比所述第一内容详细的情况下,将所述第二BFR-Prefix确定为所述目标BFR-Prefix。
在该确定方式中,优先选择内容更详细的BFR-Prefix作为目标BFR-Prefix,其中,内容更为详细可以包括BFR-Prefix中包含的内容更多,具体而言,BFR-Prefix的前缀掩码长度更长。
确定方式二:
比较所述第一BFR-Prefix的第一属性信息与所述第二BFR-Prefix的第二属性信息;在确定所述第一属性信息的属性值优于所述第二属性信息的属性值的情况下,将所述第一BFR-Prefix确定为所述目标BFR-Prefix;在确定所述第二属性信息的属性值优于所述第一属性信息的属性值的情况下,将所述第二BFR-Prefix确定为所述目标BFR-Prefix。
在该确定方式中,BFR-Prefix的属性信息可以包括BFR-Prefix的cost属性、metric属性或者其他属性中的一个或多个,其中,更优的属性值可以是cost属性取值更小,metric属性取值更小等等。
在一个可选的实施例中,基于所述目标BFR-Prefix生成所述目标转发表包括:在所述目标BFR-Prefix为所述第一BFR-Prefix的情况下,将所述目标转发表中已存在的所述第二BFR-ID对应的所述第二BFR-Prefix以及下一跳设备更新为所述第一BFR-Prefix以及所述第一BFR-Prefix对应的下一跳设备;在所述目标BFR-Prefix为所述第二BFR-Prefix的情况下,维持所述转发表中已存在的所述第二BFR-ID以及所述第二BFR-ID对应的所述第二BFR-Prefix以及下一跳设备不变。在该实施例中,在确定出不需要对转发表已有的条目进行更新的情况下,可以直接丢弃该第一BFR-Prefix。
在一个可选的实施例中,在所述第一通告消息中还包括所述第一BFER所在域的第一域标识DOMAIN-ID信息的情况下,在确定所述目标转发表中已存在的BFR-ID中存与第一BFR-ID相同的第二BFR-ID之后,所述方法还包括:在确定所述第一BFR-ID和所述第二BFR-ID所分别对应的BFR-Prefix中有来自域内的情况下,执行出错处理;在确定所述第一BFR-ID和所述第二BFR-ID所分别对应的BFR-Prefix均来自域外的情况下,确定用于通告所述第二BFR-ID的第二通告消息中所携带的第二BFER所在域的第二DOMAIN-ID信息,在所述第一DOMAIN-ID信息与所述第二DOMAIN-ID信息不同的情况下,执行出错处理。在该实施例中,在确定相同的BFR-ID所分别对应的BFR-Prefix是来自不同域的情况下,说明配置出错,需要停止更新转发表,并执行出错处理。
在一个可选的实施例中,所述第二通告消息中包括第二域外TLV,其中:所述第二域外TLV中携带所述第第二BFR-ID信息;或者,所述第二域外TLV中携带所述第二BFR-ID信息以及所述第二BFER所在域的第二DOMAIN-ID信息。在本实施例中,该第二域外TLV是在通告消息中额外新增的TLV,或者在原有的TLV下新增的新类型的TLV,不同协议下,该新增的TLV的格式是不一样的。例如,在OSPF协议下,边界设备在通告域外BFR-ID时, 采用新的域外SUB-TLV或者域外SUB-SUB-TLV(TLV:Type,Length,Value)等形式进行通告。
在一个可选的实施例中,所述第二通告消息中包括所述第二BFR-Prefix,所述第二域外TLV是跟随所述第二BFR-Prefix发送的,其中,所述第二BFR-Prefix包括以下之一:聚合路由前缀、缺省路由前缀,边界设备的BFR-Prefix。在本实施例中,第二通告消息中可携带域DOMAIN-ID信息;该域外SUB-TLV/域外SUB-SUB-TLV可以跟随聚合或者缺省路由前缀通告,也可以跟随边界设备的BFR-Prefix通告。
在一个可选的实施例中,所述第一通告消息中包括第一域外TLV,其中:所述第一域外TLV中携带所述第一BFR-ID信息;或者,所述第一域外TLV中携带所述第一BFR-ID信息以及所述第一BFER所在域的第一DOMAIN-ID信息。在本实施例中,该第一域外TLV是在通告消息中额外新增的TLV,或者在原有的TLV下新增的新类型的TLV,不同协议下,新增的TLV的格式是不一样的。例如,在OSPF协议下,边界设备在通告域外BFR-ID时,采用新的域外SUB-TLV或者域外SUB-SUB-TLV(TLV:Type,Length,Value)等形式进行通告。
在一个可选的实施例中,所述第一通告消息中包括所述第一BFR-Prefix,所述第一域外TLV是跟随所述第一BFR-Prefix发送的,其中,所述第一BFR-Prefix包括以下之一:聚合路由前缀、缺省路由前缀,边界设备的BFR-Prefix。在本实施例中,第一通告消息中可携带域DOMAIN-ID信息;其中,域外SUB-TLV/域外SUB-SUB-TLV可以跟随聚合或者缺省路由前缀通告,也可以跟随边界设备的BFR-Prefix通告。
在一个可选的实施例中,执行出错处理包括以下至少之一:执行告警提示,以提示当前的网络部署存在问题;向控制器发送告警信息,以指示所述控制器当前的网络部署存在问题。在本实施例中,出错处理除了包括上述所述的具体方式之外,还可以是其他的处理方式,例如,向特定的设备发送报错信息,或者向管理员的终端发送报错信息等等,出错处理方式不限。
下面结合一个整体的实施例对本发明实施例进行说明:
配置边界设备通告域外SUB-SUB-TLV,指明跟随通告的前缀,其格式类似图11所示,可列出要携带的BFR-ID;在BFR-ID是一组连续的值时,可采用类似图12的格式,填入要通告BFR-ID的起始值和结束值;同时可选单独携带DOMAIN-ID值,如图13所示。DOMAIN-ID值也可直接携带在同一个SUB-SUB-TLV中,因此也可采用类似图14和图15的方式来携带;
设备生成BIER转发表的整体流程如图16所示,具体包括如下步骤:
S1602,取出前缀中所携带的BRF-ID;
S1604,设备计算生成BIER转发表时,查找是否存在与取出的BRF-ID相同的BFR-ID的条目;
S1606,如果不存在相同BFR-ID的条目,则直接新增该条目,并填入相应的前缀和下一跳,转步骤S1620;
S1608,如果存在相同BFR-ID的条目,判断是否有其前缀来自域内(判断是否由BIER SUB-TLV携带);
S1610,如果有前缀来自域内,则进行出错处理,包括告警提示或者上报给控制器;
S1612,如果前缀来自域外,则判断各前缀是否来自不同的域,如果是来自不同的域的话, 执行S1610;
S1614,如果是来自相同的域的话,则将相同BFR-ID条目所对应的前缀进行比较,选择更详细的前缀所对应的下一跳,更详细的含义为该前缀掩码长度更长;或者比较前缀的cost/metric等其他属性,选择更优的(比如更小cost/metric)前缀及其对应的下一跳;这个属性也可单独比较,即在步骤1612后跳过比较前缀的详细程度而直接比较前缀的cost/metric等其他属性;
S1616,基于比较结果确定是否需要更新转发表中的条目,在确定需要更新的话,转至S1606,否则,转至S1618;
S1618,处理下一个BFR-ID。
下面结合具体实施例对本发明实施例进行示例性说明:
具体实施例一:
为了减少整网设备的负担,边界设备在通告BFR-ID时,会采用一些手段降低通告的前缀数量,比如采用聚合路由或者默认路由的通告方式,在这些方式里,聚合出来的前缀可能会涵盖一个或多个边界设备的前缀,默认路由前缀则会包含所有的边界设备前缀,因此其对应的BFR-ID也会有多个,前缀不再和BFR-ID一一对应;但对于同一个域中,前缀和BFR-ID仍然是一一对应的,因此这时其他域的BFR-ID通告必须与本域内的BFR-ID通告区分出来;因此在通告其他域的BFR-ID时,要用新的TLV携带而不是原有的BIER SUB-TLV,或者以在原有BIER SUB-TLV下新增新类型SUB-SUB-TLV的方式来携带,在此简称为域外SUB-SUB-TLV。
比如图4中,边界设备为了减少通告的前缀数量,并且想对流量有一定的控制,比如想让发给BFER1的流量经过BR1,可选择在通告domain2的BFR-ID到domain1时,BR1上配置的聚合路由(假设其前缀为P11),假设P11仅包含了BFER1的前缀,这样BR1在通告P11前缀时,仅会携带BFER1的BFR-ID 1;假设BR2上配置的是缺省路由(0/0路由,方便起见我们称之为P0),包含了domain2所有的路由前缀,因此BR2在通告P0到domain1时,会携带BFER1和BFER2的BFR-ID 1/2。在domain1的设备进行路由计算时,仍然以BFR1为例,会生成P11和P0的单播路由,P11的下一跳为BR1,P0的下一跳为BR2,如图17所示(简化起见省略了其他的路由条目)。
接下来计算BIER转发表,假设先处理P11前缀所携带的BFR-ID信息,因为P11所携带的BFR-ID仅有1,因此会生成BFR-ID为1,前缀为P11,下一跳为BR1的BIER转发表项;在处理缺省路由P0时,发现其携带的BFR-ID有1和2,并且两个前缀的BFR-ID通告都是域外SUB-SUB-TLV,这时不能直接按照原有的处理原则进行处理,否则将会更新BIER转发表中BFR-ID 1的条目为前缀P0,下一跳BR2。这无法达到我们原有的控制目的。因此在处理到缺省路由P0,发现其携带的BFR-ID 1已经在BIER转发表中存在时,需将该路由前缀P0与原BFR-ID 1中的前缀P11进行对比,发现P11更为详细(其掩码长度更长),所以无需更新BFR-ID 1的条目,由此最终生成的BIER转发表类似图18所示(简化起见省略了其他的条目)。
具体实施例二:
边界设备的通告,还可以采取更进一步减少通告前缀的方式,可以在通告边界设备自身 的BFR-Prefix时,直接携带域外SUB-SUB-TLV来携带其他域的BFR-ID。比如图4中,假设BR1的前缀是PB1,BR2的前缀是PB2,在通告domain2的BFR-ID到domain1时,在同一个前缀BFR-Prefix下,除了通告本域内的BIER SUB-TLV,还要携带域外SUB-SUB-TLV。因此BR1在通告其前缀PB1时,还需要携带域外SUB-SUB-TLV来携带domain2的BFR-ID1/2,BR2设备同理。
这样在域内的设备进行计算时,仍然以BFR1为例,首先计算出基于前缀的单播路由表如图19所示;在进行BIER转发表的生成时,首先取出PB1前缀所携带的BFR-ID 1/2,生成两个BIER转发条目,BFR-ID分别为1和2,前缀均为PB1,下一跳均为BR1;在处理到PB2所携带的BFR-ID时,发现BIER转发表中已有相应的条目存在,在对PB2和PB1的前缀进行比较时,发现两者明细程度可能是一样的(比如对于前缀为IPv4的情况,都是32位的主机路由;对于前缀为IPv6的情况,都是128位的主机路由),这时可以选择直接生成ECMP(Equal-cost multipath)链路,类似图20所示;也可以选择对两个前缀的cost/metric等其他OSPF协议属性进行比较(这些属性基于前缀的其他TLV进行通告,不一定存在于BIER SUB-TLV或者域外SUB-SUB-TLV中),假设前缀PB1的cost/metric等属性优于前缀PB2,则最终生成的BIER转发表如图21所示。
具体实施例三:
网络中的部署有的时候可能会出现问题,假设仍然是图4的网络,假设因为网络管理员的部署错误,对设备BFER5和BFER1设备所分配的BFR-ID均为50,BFER5设备就自己的前缀P5以及BFR-ID 50在domain1中进行通告,BFER1设备就自己的前缀P1以及BFR-ID 50在domain2中进行通告;在边界设备BR1将domain2中的BFR-ID通告到domain1中时,假设作为BR1前缀PB1的域外SUB-SUB-TLV进行通告;同样的,从domain1到domain2的通告类似,在此不再累述。
在设备进行路由计算时,仍然以BFR1为例,BFR1首先会生成普通的单播路由表,生成到前缀P5和PB1的下一跳分别是BFER5和BR1,如图22所示;进一步的,假设先取出前缀P5路由所携带的BIER SUB-TLV,得到BFR-ID为50,前缀为P5,下一跳为BFER5的BIER转发条目;处理前缀PB1所携带的BIER SUB-TLV及域外SUB-SUB-TLV时,发现BFR-ID 50,查找BIER转发表发现已有该BFR-ID的条目,并且其来源是前缀P5的域内BIER SUB-TLV,这时说明出现错误,需要停止更新该BIER转发条目,并通过告警或错误信息的方式显示出来,或者上送给控制器,提示网络部署出现问题。
需要注意的是,以上实施例的通告是以OSPF协议为例,假设通过ISIS协议通告,则对应于OSPF协议BIER SUB-TLV的是ISIS协议的BIER Info SUB-TLV,相应的域外SUB-SUB-TLV可增加在该BIER Info SUB-TLV下;假设通过BGP协议通告,则对应于OSPF协议BIER SUB-TLV的是BIER TLV,可增加在该BIER TLV下的域外通告则为域外SUB-TLV方式。本发明实施例并不对其通告位置作具体的限制。
具体实施例四:
在遇到跨多个AS域为同一个BIER域的场景时,比如图23所示的网络中,同样是3个domain合成同一个BIER domain,domain1/2/3分别代表的是3个AS域。各domain的边界设 备之间运行的是BGP协议。比如domain1的BR1/2与domain2的BR5/6之间、domain1的BR3/4与domain3的BR7/8之间。但在每个domain内部,可能运行的是OSPF或者ISIS协议,或者同样是BGP协议。
假设配置domain2中运行的是OSPF协议,domain1中运行的是ISIS协议;以边界设备BR5/6为例,假设BR5/6配置需要将domain2中的BFR-ID信息发布给BR1/2设备,首先BR5将从OSPF协议中获取的BFER1/2的BFR-ID信息,跟随自己的设备前缀,作为其BIER TLV下的域外SUB-TLV进行通告,下一跳设为自己,发送给BR1和BR2设备,BR6设备同样如此通告。BR1设备收到BR5和BR6设备的通告后,采用类似实施例二的方式计算自己的单播路由转发表,如图24所示,以及生成BIER转发表项,假设这里认为BR5所通告的前缀metric更优,BR1生成的BIER转发表如图25所示。BR2设备同样如此处理,在BR2设备计算BIER转发表的过程中,可能认为BR6所通告的前缀metric更优,因此BR2设备的上对于BFR-ID 1/2的前缀对应的可能是BR6-Prefix以及下一跳BR6。
BR1和BR2设备,还需要继续将这两个BFR-ID通告到domain1中,因此BR1和BR2设备,可在通过ISIS协议通告自己的前缀路由时,携带域外SUB-SUB-TLV,由此domain1中将收到来自domain2的BFR-ID信息。从domain1到domain2/3,从domain3到domain1的方式类似,在此不再累述。
以BFR1为例,首先计算出到BR1和BR2的单播路由表,在计算BIER转发表时,同样采用类似实施例二的方式,在存在相同域外BFR-ID条目时,通过比较选取前缀cost更优的作为前缀并取其下一跳,或者在两者详细程度一致的时候形成ECMP表项。
假设网络部署又出现了问题,从domain3传递到domain1的BFR-ID中,也有一个与domain2的边界设备BFER1相同,以BFR1为例,在计算BIER转发表时,发现已有相同BFR-ID的条目,其对应的前缀均来自域外,但来自于不同的domain,这时也说明配置出错,需要停止更新该BIER转发条目,并通过告警或错误信息的方式显示出来,或者上送给控制器,提示网络部署出现问题。
需要注意的是,这里为了简化起见,图中的边缘设备和中间设备数量并不多,本发明实施例应用的实际网络中并不会限制这些设备的数量,所计算出的普通单播路由表及BIER转发表,其下一跳以实际的设备为准,并不限于本发明实施例中所描述的直连的情况。
由此根据本发明实施例所述的通告和计算方法,可以为BIER跨域的部署提供正确的通告和计算方法,从而避免出现BIER转发表项计算错误的问题,从而加快BIER技术的广泛部署。此外,BIER的underlay协议在根据通告的前缀计算生成路由表和BIER转发表时,明确区分了域内和域间收到BFR-ID的情况,保证了能够正确生成BIER转发表项,从而使BIER转发无误。
通过以上的实施方式的描述,本领域的技术人员可以清楚地了解到根据上述实施例的方法可借助软件加必需的通用硬件平台的方式来实现,当然也可以通过硬件,但很多情况下前者是更佳的实施方式。基于这样的理解,本发明实施例的技术方案本质上或者说对现有技术做出贡献的部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质(如ROM/RAM、磁碟、光盘)中,包括若干指令用以使得一台终端设备(可以是手机,计算机,服务器,或者网络设备等)执行本发明各个实施例所述的方法。
在本实施例中还提供了一种转发表的生成装置,该装置设置为实现上述实施例及优选实施方式,已经进行过说明的不再赘述。如以下所使用的,术语“模块”可以实现预定功能的软件和/或硬件的组合。尽管以下实施例所描述的装置较佳地以软件来实现,但是硬件,或者软件和硬件的组合的实现也是可能并被构想的。
图26是根据本发明实施例的转发表的生成装置的结构框图,如图26所示,该装置包括:
判断模块262,设置为在基于接收到的第一通告消息生成目标转发表时,判断所述目标转发表中已存在的位转发路由器标识BFR-ID中是否存与第一BFR-ID相同的第二BFR-ID,其中,所述第一通告消息用于通告第一BFER的所述第一BFR-ID;
确定模块264,设置为在确定存在的情况下,从所述第一BFR-ID对应的第一位转发路由器前缀BFR-Prefix和所述第二BFR-ID对应的第二BFR-Prefix中确定出目标BFR-Prefix;
生成模块266,设置为基于所述目标BFR-Prefix生成所述目标转发表。
在一个可选的实施例中,所述确定模块264包括:
第一比较单元,设置为比较所述第一BFR-Prefix中所包括的第一内容与所述第二BFR-Prefix中所包括的第二内容;
第一确定单元,设置为在确定所述第一内容比所述第二内容详细的情况下,将所述第一BFR-Prefix确定为所述目标BFR-Prefix;
第二确定单元,设置为在确定所述第二内容比所述第一内容详细的情况下,将所述第二BFR-Prefix确定为所述目标BFR-Prefix。
在一个可选的实施例中,所述确定模块264包括:
第二比较单元,设置为比较所述第一BFR-Prefix的第一属性信息与所述第二BFR-Prefix的第二属性信息;
第三确定单元,设置为在确定所述第一属性信息的属性值优于所述第二属性信息的属性值的情况下,将所述第一BFR-Prefix确定为所述目标BFR-Prefix;
第四确定单元,设置为在确定所述第二属性信息的属性值优于所述第一属性信息的属性值的情况下,将所述第二BFR-Prefix确定为所述目标BFR-Prefix。
在一个可选的实施例中,所述生成模块266包括:
更新模块,设置为在所述目标BFR-Prefix为所述第一BFR-Prefix的情况下,将所述目标转发表中已存在的所述第二BFR-ID对应的所述第二BFR-Prefix以及下一跳设备更新为所述第一BFR-Prefix以及所述第一BFR-Prefix对应的下一跳设备;
维持模块,设置为在所述目标BFR-Prefix为所述第二BFR-Prefix的情况下,维持所述转发表中已存在的所述第二BFR-ID以及所述第二BFR-ID对应的所述第二BFR-Prefix以及下一跳设备不变。
在一个可选的实施例中,所述装置还包括:
第一执行模块,设置为在所述第一通告消息中还包括所述第一BFER所在域的第一域标识DOMAIN-ID信息的情况下,在确定所述目标转发表中已存在的BFR-ID中存与第一BFR-ID相同的第二BFR-ID之后,在确定所述第一BFR-ID和所述第二BFR-ID所分别对应的BFR-Prefix中有来自域内的情况下,执行出错处理;
第二执行模块,设置为在所述第一通告消息中还包括所述第一BFER所在域的第一域标 识DOMAIN-ID信息的情况下,在确定所述目标转发表中已存在的BFR-ID中存与第一BFR-ID相同的第二BFR-ID之后,在确定所述第一BFR-ID和所述第二BFR-ID所分别对应的BFR-Prefix均来自域外的情况下,确定用于通告所述第二BFR-ID的第二通告消息中所携带的第二BFER所在域的第二DOMAIN-ID信息,在所述第一DOMAIN-ID信息与所述第二DOMAIN-ID信息不同的情况下,执行出错处理。
在一个可选的实施例中,所述第二通告消息中包括第二域外TLV,其中:所述第二域外TLV中携带所述第二BFR-ID信息;或者,所述第二域外TLV中携带所述第二BFR-ID信息以及所述第二BFER所在域的第二DOMAIN-ID信息。
在一个可选的实施例中,所述第二通告消息中包括所述第二BFR-Prefix,所述第二域外TLV是跟随所述第二BFR-Prefix发送的,其中,所述第二BFR-Prefix包括以下之一:聚合路由前缀、缺省路由前缀,边界设备的BFR-Prefix。
在一个可选的实施例中,所述第一通告消息中包括第一域外TLV,其中:所述第一域外TLV中携带所述第一BFR-ID信息;或者,所述第一域外TLV中携带所述第一BFR-ID信息以及所述第一BFER所在域的第一DOMAIN-ID信息。
在一个可选的实施例中,所述第一通告消息中包括所述第一BFR-Prefix,所述第一域外TLV是跟随所述第一BFR-Prefix发送的,其中,所述第一BFR-Prefix包括以下之一:聚合路由前缀、缺省路由前缀,边界设备的BFR-Prefix。
在一个可选的实施例中,所述第一执行模块和所述第二执行模块均可以通过如下方式至少之一执行出错处理:
执行告警提示,以提示当前的网络部署存在问题;
向控制器发送告警信息,以指示所述控制器当前的网络部署存在问题。
需要说明的是,上述各个模块是可以通过软件或硬件来实现的,对于后者,可以通过以下方式实现,但不限于此:上述模块均位于同一处理器中;或者,上述各个模块以任意组合的形式分别位于不同的处理器中。
本发明的实施例还提供了一种计算机可读存储介质,该计算机可读存储介质中存储有计算机程序,其中,该计算机程序被设置为运行时执行上述任一项方法实施例中的步骤。
在一个示例性实施例中,上述计算机可读存储介质可以包括但不限于:U盘、只读存储器(Read-Only Memory,简称为ROM)、随机存取存储器(Random Access Memory,简称为RAM)、移动硬盘、磁碟或者光盘等各种可以存储计算机程序的介质。
本发明的实施例还提供了一种电子装置,包括存储器和处理器,该存储器中存储有计算机程序,该处理器被设置为运行计算机程序以执行上述任一项方法实施例中的步骤。
在一个示例性实施例中,上述电子装置还可以包括传输设备以及输入输出设备,其中,该传输设备和上述处理器连接,该输入输出设备和上述处理器连接。
本实施例中的具体示例可以参考上述实施例及示例性实施方式中所描述的示例,本实施例在此不再赘述。
显然,本领域的技术人员应该明白,上述的本发明实施例的各模块或各步骤可以用通用 的计算装置来实现,它们可以集中在单个的计算装置上,或者分布在多个计算装置所组成的网络上,它们可以用计算装置可执行的程序代码来实现,从而,可以将它们存储在存储装置中由计算装置来执行,并且在某些情况下,可以以不同于此处的顺序执行所示出或描述的步骤,或者将它们分别制作成各个集成电路模块,或者将它们中的多个模块或步骤制作成单个集成电路模块来实现。这样,本发明实施例不限制于任何特定的硬件和软件结合。
以上所述仅为本发明的优选实施例而已,并不用于限制本发明实施例,对于本领域的技术人员来说,本发明实施例可以有各种更改和变化。凡在本发明实施例的原则之内,所作的任何修改、等同替换、改进等,均应包含在本发明实施例的保护范围之内。

Claims (13)

  1. 一种转发表的生成方法,包括:
    在基于接收到的第一通告消息生成目标转发表时,判断所述目标转发表中已存在的位转发路由器标识BFR-ID中是否存与第一BFR-ID相同的第二BFR-ID,其中,所述第一通告消息用于通告第一BFER的所述第一BFR-ID;
    在确定存在的情况下,从所述第一BFR-ID对应的第一位转发路由器前缀BFR-Prefix和所述第二BFR-ID对应的第二BFR-Prefix中确定出目标BFR-Prefix;
    基于所述目标BFR-Prefix生成所述目标转发表。
  2. 根据权利要求1所述的方法,其中,从所述第一BFR-ID对应的第一位转发路由器前缀BFR-Prefix和所述第二BFR-ID对应的第二BFR-Prefix中确定出目标BFR-Prefix包括:
    比较所述第一BFR-Prefix中所包括的第一内容与所述第二BFR-Prefix中所包括的第二内容;
    在确定所述第一内容比所述第二内容详细的情况下,将所述第一BFR-Prefix确定为所述目标BFR-Prefix;
    在确定所述第二内容比所述第一内容详细的情况下,将所述第二BFR-Prefix确定为所述目标BFR-Prefix。
  3. 根据权利要求1所述的方法,其中,从所述第一BFR-ID对应的第一位转发路由器前缀BFR-Prefix和所述第二BFR-ID对应的第二BFR-Prefix中确定出目标BFR-Prefix包括:
    比较所述第一BFR-Prefix的第一属性信息与所述第二BFR-Prefix的第二属性信息;
    在确定所述第一属性信息的属性值优于所述第二属性信息的属性值的情况下,将所述第一BFR-Prefix确定为所述目标BFR-Prefix;
    在确定所述第二属性信息的属性值优于所述第一属性信息的属性值的情况下,将所述第二BFR-Prefix确定为所述目标BFR-Prefix。
  4. 根据权利要求1所述的方法,其中,基于所述目标BFR-Prefix生成所述目标转发表包括:
    在所述目标BFR-Prefix为所述第一BFR-Prefix的情况下,将所述目标转发表中已存在的所述第二BFR-ID对应的所述第二BFR-Prefix以及下一跳设备更新为所述第一BFR-Prefix以及所述第一BFR-Prefix对应的下一跳设备;
    在所述目标BFR-Prefix为所述第二BFR-Prefix的情况下,维持所述转发表中已存在的所述第二BFR-ID以及所述第二BFR-ID对应的所述第二BFR-Prefix以及下一跳设备不变。
  5. 根据权利要求1所述的方法,其中,在所述第一通告消息中还包括所述第一BFER所在域的第一域标识DOMAIN-ID信息的情况下,在确定所述目标转发表中已存在的BFR-ID中存与第一BFR-ID相同的第二BFR-ID之后,所述方法还包括:
    在确定所述第一BFR-ID和所述第二BFR-ID所分别对应的BFR-Prefix中有来自域内的情况下,执行出错处理;
    在确定所述第一BFR-ID和所述第二BFR-ID所分别对应的BFR-Prefix均来自域外的情况下,确定用于通告所述第二BFR-ID的第二通告消息中所携带的第二BFER所在域的第二 DOMAIN-ID信息,在所述第一DOMAIN-ID信息与所述第二DOMAIN-ID信息不同的情况下,执行出错处理。
  6. 根据权利要求5所述的方法,其中,所述第二通告消息中包括第二域外TLV,其中:
    所述第二域外TLV中携带所述第二BFR-ID信息;或者,
    所述第二域外TLV中携带所述第二BFR-ID信息以及所述第二BFER所在域的第二DOMAIN-ID信息。
  7. 根据权利要求6所述的方法,其中,所述第二通告消息中包括所述第二BFR-Prefix,所述第二域外TLV是跟随所述第二BFR-Prefix发送的,其中,所述第二BFR-Prefix包括以下之一:聚合路由前缀、缺省路由前缀,边界设备的BFR-Prefix。
  8. 根据权利要求1所述的方法,其中,所述第一通告消息中包括第一域外TLV,其中:
    所述第一域外TLV中携带所述第一BFR-ID信息;或者,
    所述第一域外TLV中携带所述第一BFR-ID信息以及所述第一BFER所在域的第一DOMAIN-ID信息。
  9. 根据权利要求8所述的方法,其中,所述第一通告消息中包括所述第一BFR-Prefix,所述第一域外TLV是跟随所述第一BFR-Prefix发送的,其中,所述第一BFR-Prefix包括以下之一:聚合路由前缀、缺省路由前缀,边界设备的BFR-Prefix。
  10. 根据权利要求5所述的方法,其中,执行出错处理包括以下至少之一:
    执行告警提示,以提示当前的网络部署存在问题;
    向控制器发送告警信息,以指示所述控制器当前的网络部署存在问题。
  11. 一种转发表的生成装置,包括:
    判断模块,设置为在基于接收到的第一通告消息生成目标转发表时,判断所述目标转发表中已存在的位转发路由器标识BFR-ID中是否存与第一BFR-ID相同的第二BFR-ID,其中,所述第一通告消息用于通告第一BFER的所述第一BFR-ID;
    确定模块,设置为在确定存在的情况下,从所述第一BFR-ID对应的第一位转发路由器前缀BFR-Prefix和所述第二BFR-ID对应的第二BFR-Prefix中确定出目标BFR-Prefix;
    生成模块,设置为基于所述目标BFR-Prefix生成所述目标转发表。
  12. 一种计算机可读存储介质,所述计算机可读存储介质中存储有计算机程序,其中,所述计算机程序被处理器执行时实现所述权利要求1至10任一项中所述的方法的步骤。
  13. 一种电子装置,包括存储器、处理器以及存储在所述存储器上并可在所述处理器上运行的计算机程序,所述处理器执行所述计算机程序时实现所述权利要求1至10任一项中所述的方法的步骤。
PCT/CN2023/076262 2022-03-16 2023-02-15 转发表的生成方法及装置、存储介质、电子装置 WO2023173989A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202210259155.1 2022-03-16
CN202210259155.1A CN116800660A (zh) 2022-03-16 2022-03-16 转发表的生成方法及装置、存储介质、电子装置

Publications (1)

Publication Number Publication Date
WO2023173989A1 true WO2023173989A1 (zh) 2023-09-21

Family

ID=88022285

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2023/076262 WO2023173989A1 (zh) 2022-03-16 2023-02-15 转发表的生成方法及装置、存储介质、电子装置

Country Status (2)

Country Link
CN (1) CN116800660A (zh)
WO (1) WO2023173989A1 (zh)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20150131660A1 (en) * 2013-09-17 2015-05-14 Cisco Technology, Inc. Bit indexed explicit replication packet encapsulation
CN108989209A (zh) * 2017-05-31 2018-12-11 中兴通讯股份有限公司 Bier mpls网络设备、及其报文转发方法和介质
CN109756425A (zh) * 2017-11-07 2019-05-14 中国电信股份有限公司 组播转发方法、装置以及bfr
CN113839895A (zh) * 2021-11-01 2021-12-24 新华三技术有限公司合肥分公司 一种报文转发方法及装置

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20150131660A1 (en) * 2013-09-17 2015-05-14 Cisco Technology, Inc. Bit indexed explicit replication packet encapsulation
CN108989209A (zh) * 2017-05-31 2018-12-11 中兴通讯股份有限公司 Bier mpls网络设备、及其报文转发方法和介质
CN109756425A (zh) * 2017-11-07 2019-05-14 中国电信股份有限公司 组播转发方法、装置以及bfr
CN113839895A (zh) * 2021-11-01 2021-12-24 新华三技术有限公司合肥分公司 一种报文转发方法及装置

Also Published As

Publication number Publication date
CN116800660A (zh) 2023-09-22

Similar Documents

Publication Publication Date Title
US10541905B2 (en) Automatic optimal route reflector root address assignment to route reflector clients and fast failover in a network environment
US11616656B2 (en) Multicast data transmission method, related apparatus, and system
US10164838B2 (en) Seamless segment routing
US10523560B2 (en) Service level agreement based next-hop selection
US10454812B2 (en) Service level agreement based next-hop selection
US8665887B2 (en) Number automatic routing method, updating method, withdrawing method, router and device
CN107968750B (zh) 报文传输方法、装置及节点
US11477114B2 (en) Packet forwarding method and apparatus
US20170149685A1 (en) Address information publishing method and apparatus
US11134004B2 (en) Enhanced flexible-algorithm definition
WO2022041916A1 (zh) 报文头的处理方法及装置、存储介质、电子装置
US11962491B2 (en) Source routing tunnel ingress protection
US11362954B2 (en) Tunneling inter-domain stateless internet protocol multicast packets
EP3754914B1 (en) Class-based traffic engineering in an ip network
WO2021143279A1 (zh) 段路由业务处理方法和装置、路由设备及存储介质
US20210352005A1 (en) Extending BGP Protection for SR Path Ingress Protection
US11303549B2 (en) Segmented traceroute for segment routing traffic engineering
CN110620715B (zh) 虚拟扩展局域网通信方法、隧道端点和控制器
US20220150167A1 (en) Bier packet processing method, network device, and system
US11784919B2 (en) Method for sending BIERv6 packet and first network device
WO2023173989A1 (zh) 转发表的生成方法及装置、存储介质、电子装置
WO2020021558A1 (en) Methods, apparatus and machine-readable media relating to path computation in a communication network
US20240073135A1 (en) BGP Segment Routing optimization by packing multiple prefixes in an update
WO2022042610A1 (zh) 信息处理方法、网络控制器、节点及计算机可读存储介质
WO2023098703A1 (zh) 路径通告方法、拓扑算法组合生成方法、路径计算方法、数据传输方法、电子设备和计算机可读存储介质

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: 23769498

Country of ref document: EP

Kind code of ref document: A1