A load balancing method and device for scheduling traffic, equipment and storage medium
By acquiring and utilizing information about SRv6 scheduled traffic to control its load balancing on the end-to-end path, the problem of SRv6 scheduled traffic disrupting path load balancing is solved, achieving flexible traffic balancing and path stability.
Patent Information
- Application Number
- CN202311154179.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-09-07
- Publication Date
- 2025-11-28
- Estimated Expiration
- 2043-09-07
AI Technical Summary
In tunneling technology based on IPv6 segmented routing (SRv6) protocol, network devices forward data to the end-to-end path directly according to the SID specified outgoing interface for SRv6 scheduled traffic, which disrupts the original load balancing on the path and causes traffic congestion risk.
By acquiring the first and second information of the scheduled traffic, the load balancing of the scheduled traffic on the end-to-end path can be controlled. The first information indicates the impact of the scheduled traffic on the load balancing, and the second information indicates whether each node participates in load sharing. Based on these two types of information, the load balancing behavior of the scheduled traffic can be flexibly controlled to maintain or restore the load balancing on the path.
It enables flexible load balancing control of SRv6 scheduled traffic, avoiding traffic congestion and maintaining load balancing on the path.
Smart Images

Figure CN118827556B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of communication, and particularly relates to a load balancing method and device for scheduling traffic, equipment and a storage medium. BACKGROUND
[0002] At present, in a tunnel policy technology based on a segment routing over IPv6 (SRv6) protocol, when network equipment performs data forwarding on an end-to-end path of SRv6 scheduling traffic, the network equipment directly forwards according to an interface specified by a segment identifier (SID), so that when the SRv6 scheduling traffic is introduced, the original load balancing on the path is destroyed, and a traffic congestion risk is caused. SUMMARY
[0003] The present application provides a load balancing method and device for scheduling traffic, equipment and a storage medium, and solves the problem that in the related art, network equipment directly forwards according to an interface specified by a segment identifier (SID) when performing data forwarding on an end-to-end path of SRv6 scheduling traffic, so that when the SRv6 scheduling traffic is introduced, the original load balancing on the path is destroyed, and a traffic congestion risk is caused.
[0004] The technical scheme of the present application is implemented as follows:
[0005] A load balancing method for scheduling traffic, comprising:
[0006] obtaining scheduling traffic;
[0007] obtaining first information and second information of the scheduling traffic; the first information indicates an influence of the scheduling traffic on load balancing, and the second information indicates whether each node on an end-to-end path decides that the scheduling traffic participates in load sharing;
[0008] controlling load balancing of the scheduling traffic on the end-to-end path according to the first information and the second information.
[0009] A load balancing device for scheduling traffic, comprising:
[0010] an obtaining module configured to obtain scheduling traffic;
[0011] an obtaining module configured to obtain first information and second information of the scheduling traffic; the first information indicates an influence of the scheduling traffic on load balancing, and the second information indicates whether each node on an end-to-end path decides that the scheduling traffic participates in load sharing;
[0012] a processing module configured to control load balancing of the scheduling traffic on the end-to-end path according to the first information and the second information.
[0013] A load balancing device for scheduling traffic, comprising:
[0014] a memory for storing executable instructions;
[0015] a processor for executing the executable instructions stored in the memory to implement the steps of the load balancing method for scheduling traffic described above.
[0016] A computer-readable storage medium storing executable instructions, when the executable instructions are executed, for causing a processor to perform the steps of the load balancing method for scheduling traffic described above.
[0017] The embodiment of the present application provides a load balancing method for scheduling traffic, which comprises the following steps: obtaining scheduling traffic; obtaining first information and second information of the scheduling traffic; the first information indicates an influence of the scheduling traffic on load balancing, and the second information indicates whether each node on an end-to-end path decides that the scheduling traffic participates in load sharing; and according to the first information and the second information, load balancing of the scheduling traffic on the end-to-end path is controlled. The method solves the problem that network devices in the related art directly perform data forwarding of the end-to-end path according to the interface specified by SRv6 scheduling traffic, so that when the SRv6 scheduling traffic is introduced, original load balancing on the path is damaged, and congestion risk of traffic is caused. BRIEF DESCRIPTION OF DRAWINGS
[0018] Figure 1 A flowchart of a load balancing method for scheduling traffic provided by the embodiment of the present application is provided.
[0019] Figure 2 A schematic diagram of a load balancing device for scheduling traffic provided by the embodiment of the present application is provided.
[0020] Figure 3 A schematic diagram of a load balancing device for scheduling traffic provided by the embodiment of the present application is provided.
[0021] Figure 4 A flowchart of control of scheduling traffic participating in load sharing calculation provided by the embodiment of the present application is provided.
[0022] Figure 5 A flowchart of a load balancing method in an actual scene provided by the embodiment of the present application is provided.
[0023] Figure 6 A result schematic diagram of all paths participating in load balancing provided by the embodiment of the present application is provided.
[0024] Figure 7 A result schematic diagram of all paths not participating in load balancing provided by the embodiment of the present application is provided.
[0025] Figure 8 The schematic diagram of the full-path segmentation participation load balancing result provided by the embodiment of the present application. DETAILED DESCRIPTION
[0026] In order to make the purposes, technical solutions and advantages of the present application clearer, the present application will be described in further detail below with reference to the drawings, and the described embodiments should not be regarded as limiting the present application. All other embodiments obtained by those skilled in the art without creative labor fall within the scope of protection of the present application.
[0027] In the following description, "some embodiments" are referred to, which describe a subset of all possible embodiments, but it can be understood that "some embodiments" can be the same subset or different subsets of all possible embodiments, and can be combined with each other without conflict.
[0028] In the following description, the terms "first\second\third" are only to distinguish similar objects, and do not represent a specific order of the objects. It can be understood that "first\second\third" can be interchanged in a specific order or sequence as allowed, so that the embodiments of the present application described herein can be implemented in an order other than that illustrated or described herein.
[0029] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which the present application belongs. The terms used herein are only for the purpose of describing the embodiments of the present application and are not intended to limit the present application.
[0030] The embodiments of the present application provide a load balancing method for scheduling traffic, referring to Figure 1 The method comprises the following steps:
[0031] Step 101, obtaining scheduling traffic.
[0032] SRv6 is a segment routing based on Internet Protocol Version 6 (IPv6), which uses existing IPv6 technology to encapsulate data packets in IPv6 packets and SRH (Segment Routing Header), takes traffic as a carrier, and realizes data forwarding of SRv6 scheduling traffic through multiple nodes on an end-to-end path.
[0033] In the embodiments of the present application, the SRv6 scheduling traffic is obtained by analyzing the data packet based on the SRv6 protocol. It can be understood that the traffic corresponding to the data packet of other non-SRv6 protocol is non-scheduling traffic.
[0034] Step 102, obtaining first information and second information of the scheduling traffic; the first information indicates an influence of the scheduling traffic on load balancing, and the second information indicates whether each node on an end-to-end path decides the scheduling traffic to participate in load sharing.
[0035] In the embodiment of the present application, the first information is used to control an influence mode of the SRv6 scheduling traffic on load balancing. It can be understood that, after the SRv6 scheduling traffic is introduced into the end-to-end data forwarding path, the original load balancing will be affected. According to the first information, it can be determined that the influence mode is to participate in the original load balancing or not to participate in the original load balancing. The second information is used to control whether each node on the end-to-end path decides the scheduling traffic to participate in load sharing. It can be understood that, when the SRv6 scheduling traffic performs data forwarding on the end-to-end path, the routing device set on each node on the end-to-end path can control, according to the second information, the SRv6 scheduling traffic to participate in load sharing calculation or not to participate in load sharing calculation.
[0036] In the embodiment of the present application, after the SRv6 scheduling traffic is introduced into the end-to-end data forwarding path, the original load balancing will be affected. According to the first information, it can be determined that the influence mode is to participate in the original load balancing or not to participate in the original load balancing. The second information is used to control whether each node on the end-to-end path decides the scheduling traffic to participate in load sharing. It can be understood that, when the SRv6 scheduling traffic performs data forwarding on the end-to-end path, the routing device set on each node on the end-to-end path can control, according to the second information, the SRv6 scheduling traffic to participate in load sharing calculation or not to participate in load sharing calculation.
[0037] Step 103, controlling load balancing of the scheduling traffic on the end-to-end path according to the first information and the second information.
[0038] In the embodiment of the present application, according to the obtained first information, it is determined that the scheduling traffic affects the load balancing, and according to the obtained second information, it is determined whether each node on the end-to-end path decides the scheduling traffic to participate in load sharing, so as to determine whether the SRv6 scheduling traffic participates in the load balancing, and on this basis, the routing device of each node determines whether the SRv6 scheduling traffic participates in the load sharing calculation, thereby realizing flexible control of the load sharing behavior of the SRv6 scheduling traffic on each node, so as to realize the load balancing of the SRv6 scheduling traffic on the end-to-end path.
[0039] In the embodiment of the present application, the effective priority of the first information is higher than the effective priority of the second information. It can be understood that the first information can be effective alone, and the second information must be used jointly with the first information to be effective.
[0040] The embodiment of the present application provides a load balancing method, device and equipment for scheduling traffic and a storage medium. The method comprises the following steps: obtaining scheduling traffic; obtaining first information and second information of the scheduling traffic; the first information indicates the influence of the scheduling traffic on load balancing, and the second information indicates whether each node on an end-to-end path determines that the scheduling traffic participates in load sharing; according to the first information and the second information, the load balancing of the scheduling traffic on the end-to-end path is controlled; the first information and the second information of the scheduling traffic are redefined to identify whether the scheduling traffic participates in load balancing and whether the scheduling traffic participates in load sharing of each node, so that when additional scheduling traffic is introduced for data forwarding of the end-to-end path, the additional scheduling traffic is first added to the original load sharing, the original load balancing is maintained, and then the interface is specified according to the SID for forwarding. The method not only realizes flexible control of the load balancing behavior of the scheduling traffic, but also realizes load balancing on the end-to-end path. The method solves the problem that network equipment in the related art directly forwards data of the end-to-end path according to the interface specified by the SID of the SRv6 scheduling traffic, so that when the SRv6 scheduling traffic is introduced, the original load balancing on the path is destroyed, and the risk of traffic congestion is caused.
[0041] In some embodiments of the present application, the step of controlling the load balancing of the scheduling traffic on the end-to-end path according to the first information and the second information in step 103 can be implemented through the following steps:
[0042] If the first information meets the first condition and the second information meets the second condition, the scheduling traffic is added to the load sharing by each node on the end-to-end path.
[0043] Further, in the embodiment of the present application, the first condition comprises that the first information indicates that the scheduling traffic participates in load balancing at each node on the end-to-end path; and the second condition comprises that the second information indicates that each node on the end-to-end path determines that the scheduling traffic participates in load sharing.
[0044] In the embodiment of the present application, the first information comprises a first identifier. Illustratively, the first identifier can be an identifier (Flags) in SRH, which can be represented in the form of a numerical value, for example, 00000010. It can be understood that the first information can also be other, and the first identifier can also be represented in other forms, which are not limited in the present application.
[0045] In the embodiment of the present application, the second information comprises a first type. Illustratively, the first type can be a SID type in SRH, which can be represented in the form of a letter, for example, End.XH. It can be understood that the second information can also be other, and the first type can also be represented in other forms, which are not limited in the present application.
[0046] In the embodiments of the present application, if the first information obtained meets the first condition and the second information meets the second condition, it indicates that the measure taken for the scheduling traffic is to control the scheduling traffic to participate in load balancing at all nodes on the end-to-end path. At this time, the load balancing method to be taken for the scheduling traffic is to control the scheduling traffic to participate in load balancing at each node on the end-to-end path, and the routing device at each node on the end-to-end path controls the scheduling traffic to participate in load sharing. It can be understood that participating in load sharing means that the routing device set on each node counts the scheduling traffic in load sharing calculation, thereby realizing load balancing on the whole path.
[0047] Exemplarily, after the datagram based on the SRv6 protocol is parsed, the Flags identifier and the SID type of the SRv6 scheduling traffic are obtained. When the obtained Flags identifier is 00000010 and the SID type is End.XH, it indicates that the measure to be taken for the scheduling traffic at this time is to control the scheduling traffic to participate in load balancing at all nodes on the end-to-end path. At this time, the load balancing method to be taken for the SRv6 scheduling traffic is to control the scheduling traffic to participate in original load balancing at each node on the end-to-end path after the SRv6 scheduling traffic is introduced into the data forwarding path of the end-to-end, and the routing device at each node on the end-to-end path counts the SRv6 scheduling traffic in load sharing calculation.
[0048] In some embodiments of the present application, the step of controlling the load balancing of the scheduling traffic on the end-to-end path according to the first information and the second information in step 103 can also be realized by the following steps:
[0049] If the first information meets the third condition and the second information meets the fourth condition, the scheduling traffic is not counted in load sharing by each node on the end-to-end path.
[0050] Further, in the embodiments of the present application, the third condition includes that the first information indicates that the scheduling traffic does not participate in load balancing at each node on the end-to-end path, and the fourth condition includes that the second information indicates that each node on the end-to-end path determines that the scheduling traffic does not participate in load sharing.
[0051] In the embodiments of the present application, the first information includes a second identifier. Exemplarily, the second identifier can be the Flags identifier in the SRH, which can be represented in the form of a numerical value, for example, 00000011. It can be understood that the first information can also be other, and the second identifier can also be represented in other forms, which are not limited in the present application.
[0052] In the embodiments of the present application, the second information includes a second type. Exemplarily, the second type can be a SID type in the SRH, and can be represented in the form of a letter, for example, non-End.XH. It can be understood that the second information can also be other, and the second type can also be represented in other forms, which are not limited in the present application.
[0053] In the embodiments of the present application, if the first information obtained meets the third condition and the second information meets the fourth condition, it indicates that the measure to be taken for the scheduling traffic at this time is to control the scheduling traffic to be independent of load balancing at all nodes on the end-to-end path. At this time, the load balancing method to be taken for the scheduling traffic is to control the scheduling traffic not to participate in load balancing at each node on the end-to-end path, and the routing device of each node on the end-to-end path does not control the scheduling traffic to participate in load sharing. It can be understood that not participating in load sharing means that the routing device set on each node does not count the scheduling traffic in the load sharing calculation, that is, at this time, the routing device directly forwards the data of the scheduling traffic according to the interface specified by the SID, so as to realize the independent scheduling traffic of the whole path from load balancing.
[0054] Exemplarily, after the SRv6 protocol-based data packet is parsed, the Flags identifier and the SID type of the SRv6 scheduling traffic are obtained. When the obtained Flags identifier is 00000011 and the SID type is non-End.XH, it indicates that the measure to be taken for the scheduling traffic at this time is to control the scheduling traffic to be independent of load balancing at all nodes on the end-to-end path. At this time, the load balancing method to be taken for the SRv6 scheduling traffic is to control the scheduling traffic not to participate in the original load balancing at each node on the end-to-end path after the SRv6 scheduling traffic is introduced into the data forwarding path of the end-to-end, and the routing device of each node on the end-to-end path does not count the SRv6 scheduling traffic in the load sharing calculation, and directly forwards the data according to the interface specified by the SID.
[0055] In some embodiments of the present application, the step of controlling the load balancing of the scheduling traffic on the end-to-end path according to the first information and the second information in step 103 can also be implemented through the following steps:
[0056] If the first information meets the fifth condition and the second information meets the sixth condition, the at least one node on the end-to-end path is controlled to count the scheduling traffic in the load sharing.
[0057] Further, in the embodiments of the present application, the fifth condition includes that the first information indicates that the scheduling traffic participates in load balancing at at least one node on the end-to-end path; and the sixth condition includes that the second information indicates whether the scheduling traffic participates in load sharing according to the node type of each node on the end-to-end path.
[0058] In the embodiments of the present application, the first information includes a third identifier. Exemplarily, the first identifier can be an identifier of Flags in the SRH, which can be represented in the form of a numerical value, for example, 00000001. It can be understood that the first information can also be other, and the first identifier can also be represented in other forms, which are not limited in the present application.
[0059] In the embodiments of the present application, the second information includes a first type. Exemplarily, the first type can be a SID type in the SRH, which can be represented in the form of a letter, for example, End.XH. The second information also includes a second type. Exemplarily, the second type can be a SID type in the SRH, which can be represented in the form of a letter, for example, non-End.XH. It can be understood that the second information can also be other, and the second type can also be represented in other forms, which are not limited in the present application.
[0060] In the embodiments of the present application, if the first information obtained meets the fifth condition and the second information meets the sixth condition, it indicates that the measure to be taken for the scheduling traffic at this time is that the scheduling traffic should participate in load balancing at at least one node on the end-to-end path according to the specific type of the second information. At this time, the load balancing method to be taken for the scheduling traffic is that the scheduling traffic participates in load balancing at at least one node on the end-to-end path, and each node on the end-to-end path determines whether to participate in load sharing according to the node type. When the node type is the first type, the routing device set at the node on the end-to-end path controls the scheduling traffic to participate in load sharing. When the node type is the second type, the routing device set at the node on the end-to-end path does not control the scheduling traffic to participate in load sharing, that is, at this time, the routing device set at the node directly forwards the data of the scheduling traffic according to the SID to specify the interface, thereby realizing the segmented control of the scheduling traffic participating in load balancing on the whole path.
[0061] Exemplarily, after the data packet based on the SRv6 protocol is parsed, the Flags identifier and the SID type of the SRv6 scheduling traffic are obtained. When the obtained Flags identifier is 00000001 and the SID type is End.XH, it indicates that the measure to be taken for the scheduling traffic at this time is that the scheduling traffic should participate in load balancing at at least one node on the end-to-end path according to the specific type of the second information. At this time, the load balancing method to be taken for the SRv6 scheduling traffic is that after the SRv6 scheduling traffic is introduced into the data forwarding path of the end-to-end, the End.XH type corresponding node on the end-to-end path controls the SRv6 scheduling traffic to participate in the original load balancing, and the routing device on the node on the end-to-end path counts the SRv6 scheduling traffic into the load sharing calculation.
[0062] Exemplarily, after the datagram based on the SRv6 protocol is parsed, the Flags identifier and the SID type of the SRv6 scheduling traffic are obtained. When the obtained Flags identifier is 00000001 and the SID type is non-End.XH, it indicates that the measure to be taken for the scheduling traffic at this time is that the scheduling traffic should participate in load balancing at at least one node on the end-to-end path according to the specific type of the second information. At this time, the load balancing method to be taken for the SRv6 scheduling traffic is that after the SRv6 scheduling traffic is introduced into the end-to-end data forwarding path, the SRv6 scheduling traffic is controlled not to participate in the original load balancing at the node corresponding to the non-End.XH type on the end-to-end path, and the routing device on the node on the end-to-end path does not count the SRv6 scheduling traffic in the load sharing calculation, that is, at this time, the routing device directly performs normal forwarding of data according to the SID to specify the interface for the scheduling traffic.
[0063] The embodiment of the present application provides a load balancing device for scheduling traffic, as shown in the figure, the load balancing device 200 comprises an obtaining module 201 and a processing module 202, wherein Figure 2
[0064] The obtaining module 201 is used for obtaining the scheduling traffic.
[0065] The obtaining module 201 is used for obtaining first information and second information of the scheduling traffic, wherein the first information indicates the influence of the scheduling traffic on load balancing, and the second information indicates whether each node on an end-to-end path decides the scheduling traffic to participate in load sharing.
[0066] The processing module 202 is used for controlling the load balancing of the scheduling traffic on the end-to-end path according to the first information and the second information.
[0067] In some embodiments of the present application, the obtaining module 201 is used for obtaining the scheduling traffic, and obtaining first information and second information of the scheduling traffic, wherein the first information indicates the influence of the scheduling traffic on load balancing, and the second information indicates whether each node on an end-to-end path decides the scheduling traffic to participate in load sharing.
[0068] The processing module 202 is used for controlling the load balancing of the scheduling traffic on the end-to-end path according to the first information and the second information.
[0069] In some embodiments of the present application, the processing module 202 is used for, if the first information meets a first condition and the second information meets a second condition, controlling the each node on the end-to-end path to count the scheduling traffic in load sharing.
[0070] In some embodiments of the present application, the first condition comprises that the first information indicates that the scheduled traffic is involved in load balancing at each node on the end-to-end path; and the second condition comprises that the second information indicates that the scheduled traffic is determined to be involved in load sharing at each node on the end-to-end path.
[0071] In some embodiments of the present application, the processing module 202 is configured to control each node on the end-to-end path to not count the scheduled traffic into load sharing if the first information meets a third condition and the second information meets a fourth condition.
[0072] In some embodiments of the present application, the third condition comprises that the first information indicates that the scheduled traffic is not involved in load balancing at each node on the end-to-end path; and the fourth condition comprises that the second information indicates that the scheduled traffic is determined to be not involved in load sharing at each node on the end-to-end path.
[0073] In some embodiments of the present application, the processing module 202 is configured to control at least one node on the end-to-end path to count the scheduled traffic into load sharing if the first information meets a fifth condition and the second information meets a sixth condition.
[0074] In some embodiments of the present application, the fifth condition comprises that the first information indicates that the scheduled traffic is involved in load balancing at the at least one node on the end-to-end path; and the sixth condition comprises that the second information indicates that each node on the end-to-end path determines whether to involve the scheduled traffic in load sharing according to a node type.
[0075] It should be noted that the same steps and the same content in the present embodiment and other embodiments are described in other embodiments, and will not be described here.
[0076] The embodiments of the present application provide a load balancing device for scheduled traffic, as shown in Figure 3 The load balancing device 300 comprises a memory 301 and a processor 302; wherein,
[0077] The memory 301 is configured to store executable instructions.
[0078] The processor 302 is connected with the memory 301 through a bus 303, and is configured to execute the executable instructions stored in the memory 301 to realize the steps of the load balancing method for scheduled traffic, which will not be described here.
[0079] The present embodiment provides a method for controlling scheduled traffic to participate in load sharing calculation, as shown in Figure 4 The method comprises the following steps:
[0080] Step 401, obtaining non-scheduled traffic corresponding to each link between the first node and the second node.
[0081] The second node is a node that is a next hop of the first node.
[0082] In the embodiments of the present application, there are multiple links between the first node and the second node, and the sizes of the non-scheduled traffic corresponding to the multiple links between the first node and the second node are obtained.
[0083] Step 402, obtaining a traffic parameter and an interface mapping relationship of the scheduled traffic.
[0084] In the embodiments of the present application, the traffic parameter includes a destination address of a data packet and a length of the data packet. The interface mapping relationship refers to a mapping relationship between the first node and the second node, including a segment list (SID).
[0085] Step 403, determining the scheduled traffic according to the traffic parameter and the interface mapping relationship.
[0086] In the embodiments of the present application, according to the obtained interface mapping relationship, the traffic parameter with the same SID is determined, the traffic value of a certain SID is calculated, and the scheduled traffic is obtained.
[0087] Exemplarily, the nodes corresponding to a certain SID include a node where a router A is located and a node where a router B is located, the traffic value on a data link between the router A and the router B is determined, and the size of the SRv6 scheduled traffic is obtained.
[0088] Step 404, calculating a load balancing ratio of each link between the first node and the second node according to the scheduled traffic and the non-scheduled traffic.
[0089] In the embodiments of the present application, the router at the node calculates the load balancing ratio of each link between the first node and the second node by adjusting the size of the non-scheduled traffic according to the size of the scheduled traffic, so as to realize the load balancing of each link between the first node and the second node. In this way, a method for controlling how the SRv6 scheduled traffic participates in the interface load sharing calculation is provided, and the SRv6 scheduled traffic is counted into the router load sharing calculation, so that the router can still maintain load balancing after each node where the router is located introduces the SRv6 scheduled traffic by adjusting the load sharing ratio.
[0090] Exemplarily, in the embodiments of the present application, the load balancing ratio of each link between the first node and the second node can be calculated based on the remaining effective bandwidth obtained by subtracting the scheduled traffic at the interface from the physical bandwidth. In this way, the problem of uneven load sharing caused by multiple calculations of the remaining bandwidth occupied by the additional scheduled traffic can be avoided when the physical bandwidth is directly used for calculation.
[0091] Next, the load balancing method provided by the present application is described below by taking an actual scenario as an example, referring to FIG. 1. Figure 5
[0092] The Flags bit in the segment routing header (SRH) of the SRv6 data packet is defined in advance by the ingress interface router, and the SID type of the Segment list is added. The Flags is predefined as 00000000, 00000001, 0000010 and 00000011, and the added SID is the End.XH SID of each hop corresponding to the Segment list.
[0093] The definition of the Flags is described as follows.
[0094] The Flags is 00000000: reserved.
[0095] The Flags is 00000001: indicating that each hop participates in load sharing, and the router further selects how to perform load balancing on the data packet according to the added SID type.
[0096] The Flags is 0000010: indicating that the whole process participates in load sharing, and the data packet participates in the existing Unequal Cost Multiple Path (UCMP) or Equal Cost Multiple Path (ECMP) load balancing of the interface throughout the whole process.
[0097] The Flags is 00000011: indicating that the whole process is independent of load sharing, and the data packet does not participate in the existing UCMP\ECMP load balancing of the interface throughout the whole process.
[0098] The added SID is described as follows.
[0099] The SID type is End.XH and non-End.XH.
[0100] Wherein, End.XH represents a three-layer cross-connection node (Endpoint.XH) for identifying a certain link in the network, and the router performing the SID will include the data packet in the existing UCMP\ECMP load sharing calculation of the identified link and forward it, maintaining the original load sharing result. End.XH must be used in combination with Flags identification 00000001 to take effect, and the effective priority of Flags identification is higher than that of End.XH.
[0101] Based on this, the steps of forwarding the SRv6 protocol-based data packet and load balancing the SRv6 scheduling traffic include:
[0102] Step 501, SRv6 scheduling traffic flows in.
[0103] SRv6 scheduling traffic flows into each node router, and the node router obtains the SRv6 data packet.
[0104] Step 502, identify the FLAGS bit.
[0105] The node router reads the FLAGS bit in the SRv6 data packet when forwarding the data, and determines the load sharing mode according to the Flags identification corresponding to the FLAGS bit. If the read Flags identification is 00000001, further check the specific SID type, enter step 503; if the read Flags identification is 00000010, it indicates that the router at each node on the entire path needs to include the data packet in the existing UCMP\ECMP load sharing calculation of the link and forward it to maintain the original load balancing, enter step 504; when the read Flags identification is 00000011 or 00000000, it indicates that the router at each node on the entire path does not include the data packet in the existing UCMP\ECMP load sharing calculation of the link, enter step 511.
[0106] Step 503, identify whether the SID is End.XH, yes enter step 504, otherwise enter step 511. When the SID type is End.XH, it indicates that the node router corresponding to the SID needs to include the data packet in the existing UCMP\ECMP load sharing calculation of the link identified by End.XH and forward it to maintain the original load balancing, enter step 504. When the SID type is not End.XH, it indicates that it is not the link identified by End.XH, and it is not included in the existing UCMP\ECMP load sharing calculation of the link identified by End.XH, enter step 511.
[0107] Step 504, the traffic sampling module obtains the traffic parameters of the scheduling traffic.
[0108] The traffic sampling module collects traffic parameters of SRv6 scheduling traffic with the same SID as the destination address, calculates the traffic of a certain SID, and pushes the traffic to the interface scheduling traffic calculator.
[0109] Step 505, the configuration module obtains the interface mapping relationship of the scheduling traffic. The configuration module finds and collects the local SID interface mapping relationship, and pushes the SID interface mapping relationship to the interface scheduling traffic calculator.
[0110] Step 506, the interface scheduling traffic calculator determines the scheduling traffic according to the traffic parameters and the interface mapping relationship.
[0111] The interface scheduling traffic calculator converts the received traffic of a certain SID and the SID interface mapping relationship into the interface scheduling traffic result, and pushes the result to the load balancing calculation module.
[0112] Step 507, the load balancing calculation module performs load balancing calculation according to the interface scheduling traffic result and the non-scheduling traffic.
[0113] The load balancing calculation module adjusts the size of the non-SRv6 scheduling traffic based on the physical bandwidth of the data forwarding link minus the remaining effective bandwidth of the interface SRv6 scheduling traffic, and calculates the load balancing ratio of the link.
[0114] Step 508, the node router finds the out interface specified by the SID according to the destination address, and forwards the data according to the calculated load balancing ratio.
[0115] Step 509, the node router updates the SL pointer and replaces the corresponding SID in the Segment list into the packet destination address.
[0116] Step 510, the out interface data is sent.
[0117] The router sends the modified packet to the opposite router according to the updated packet destination address, completes the data forwarding based on the SRv6 protocol, and performs load balancing on the SRv6 scheduling traffic.
[0118] Step 511, the node router corresponding to the SID controls the data packet not to participate in load sharing calculation, and only performs ordinary forwarding on the data packet.
[0119] Further, in combination with Table 1, under different FLAGS+SID combinations, the load sharing mode of SRv6 scheduling traffic is as follows:
[0120] Numbering FLAGS SID Load sharing mode 1 00000010 Non-End.XH / End.XH Each node participates in load sharing calculation 2 00000011 Non-End.XH / End.XH Each node does not participate in load sharing calculation 3 00000001 End.XH The node where the SID is located participates in load sharing calculation 4 00000001 Non-End.XH The node where the SID is located does not participate in load sharing calculation 5 00000000 Non-End.XH / End.XH Reserved
[0121] Table 1
[0122] As Figures 6 to 8 shown, when there are 2 100M wide equivalent links between the router at node P1 and the router at node P2, the original non-scheduled traffic is 50Mbps, and after ECMP equivalent load sharing, each link is balanced to share non-scheduled traffic of 25Mbps, the bandwidth utilization rate of each link is 50%, and both links are not congested; when the original non-scheduled traffic is 40Mbps, after ECMP equivalent load sharing, each link is balanced to share non-scheduled traffic of 20Mbps, the bandwidth utilization rate of each link is 40%, and both links are not congested. Based on the same reasons as described above, each link is not congested when there are 2 100M wide equivalent links between the router at node P2 and the router at node P3.
[0123] Based on this, when additional SRv6 traffic is introduced to the link, based on different FLAGS+SID combinations, the method of taking corresponding load sharing ways for SRv6 scheduled traffic is as follows:
[0124] 1) Flags identification 00000010 + End.XH / non-End.XH.
[0125] When the FLAGS+SID combination is Flags identification 00000010 + non-End.XH, the router at each node on the end-to-end path controls the SRv6 scheduled traffic to be counted in load sharing calculation, so that the SRv6 scheduled traffic participates in load balancing throughout the process, thereby realizing full-process control of SRv6 scheduled traffic participating in load balancing, and being able to meet the traffic scheduling needs of the corresponding scene.
[0126] Referring to Figure 6 shown, the router at node P2 balances non-scheduled traffic of 25Mbps with the router at node P1 and the router at node P3, respectively, when additional scheduled traffic of 10Mbps (SRv6 scheduled traffic) is introduced to one of the links, the original non-scheduled traffic size is correspondingly reduced to non-scheduled traffic of 15Mbps, the load balancing ratio of the original non-scheduled traffic is reduced, so that after the SRv6 scheduled traffic and the original non-scheduled traffic are shared together, the original bandwidth utilization rate of 50% of each link is maintained while load balancing is realized, thereby realizing that the load sharing of the original link can still be maintained after the introduction of additional SRv6 traffic scheduling, and avoiding traffic congestion.
[0127] 2) Flags identification 00000011 + End.XH / non-End.XH.
[0128] When the combination of FLAGS+SID is Flags identifier 00000011+End.XH, the routers at each node on the end-to-end path control the SRv6 scheduling traffic not to be counted in the load sharing calculation, and only perform ordinary data forwarding, so that the SRv6 scheduling traffic does not participate in load balancing throughout the path, thereby realizing the whole-path independent control of the SRv6 scheduling traffic not participating in load balancing, and being able to meet the traffic scheduling requirements of the corresponding scene.
[0129] With reference to Figure 7 As shown, the routers at node P2 balance the non-scheduling traffic 20Mbps between the routers at node P1 and the routers at node P3 on each link. When additional scheduling traffic 10Mbps (SRv6 scheduling traffic) is introduced to one of the links, the routers directly perform ordinary forwarding of data according to the interface specified by the SID for the SRv6 scheduling traffic, so that there is a total scheduling traffic of 30Mbps on one of the links, which is jointly shared by the SRv6 scheduling traffic 10Mbps and the original non-scheduling traffic 20Mbps, and the original non-scheduling traffic on the other link is 20Mbps, thereby realizing independent load balancing of the scheduling traffic throughout the path.
[0130] 3) Flags identifier 00000001+End.XH; Flags identifier 00000001+non-End.XH.
[0131] When the combination of FLAGS+SID is Flags identifier 00000001+End.XH, the routers at each node on the end-to-end path control the SRv6 scheduling traffic not to be counted in the load sharing calculation, and only perform ordinary data forwarding, so that the SRv6 scheduling traffic does not participate in load balancing throughout the path, thereby realizing the whole-path independent control of the SRv6 scheduling traffic not participating in load balancing, and being able to meet the traffic scheduling requirements of the corresponding scene.
[0132] With reference to Figure 8As shown, the corresponding FLAGS+SID combination between the router at node P1 and the router at node P2 is Flags identifier 00000001+End.XH, and each link equally shares the non-scheduled traffic of 25Mbps. When an additional scheduled traffic of 10Mbps (SRv6 scheduled traffic) is introduced to one of the links, the original non-scheduled traffic size is correspondingly reduced to 15Mbps, and the load balancing ratio of the original non-scheduled traffic is reduced. After the SRv6 scheduled traffic and the original non-scheduled traffic are jointly shared, the load on the link remains the original load sharing result. Referring to Figure 8 As shown, the corresponding FLAGS+SID combination between the router at node P2 and the router at node P3 is Flags identifier 00000001+non-End.XH, and each link equally shares the non-scheduled traffic of 20Mbps. When an additional scheduled traffic of 10Mbps (SRv6 scheduled traffic) is introduced to one of the links, the router directly performs normal forwarding of data according to the interface specified by the SID for the SRv6 scheduled traffic, so that the total scheduled traffic of 30Mbps is jointly shared by the SRv6 scheduled traffic of 10Mbps and the original non-scheduled traffic of 20Mbps on one of the links, and the original non-scheduled traffic on the other link is 20Mbps. In this way, the load sharing of the original link between the router at node P1 and the router at node P2 remains unchanged when additional SRv6 traffic scheduling is introduced, avoiding traffic congestion, and the scheduled traffic on the entire path is independently load balanced between the router at node P2 and the router at node P3.
[0133] 4) Flags identifier 00000000+non-End.XH / End.XH.
[0134] The application regards the identifier 00000000 as a reserved identifier, which can be extended for actual needs, and the application does not make specific limitations on this.
[0135] The embodiment of the application provides a computer readable storage medium, which stores executable instructions, and the executable instructions are executed to implement the method for load balancing of scheduled traffic as Figure 1 、 Figures 4 to 5 The corresponding embodiment provides a method for load balancing of scheduled traffic, and the implementation process of the method is not described herein.
[0136] The bus mentioned above can be Peripheral Component Interconnect (PCI) or Peripheral Component Interconnect Express (PCIE) and the like. The communication bus can be divided into address bus, data bus, control bus and the like. For the convenience of representation, only one thick line is used in the figure, but it does not mean that there is only one bus or one type of bus. The communication interface is used for communication between the server and other devices. The computer storage medium / memory mentioned above can be Read Only Memory (ROM), Programmable Read-Only Memory (PROM), Erasable Programmable Read-Only Memory (EPROM), Electrically Erasable Programmable Read-Only Memory (EEPROM), Ferromagnetic Random Access Memory (FRAM), Flash Memory, magnetic surface memory, optical disc, or Compact Disc Read-Only Memory (CD-ROM) and the like; it can also be various terminals including one or any combination of the above memories, such as mobile phones, computers, tablet devices, personal digital assistants and the like. The processor mentioned above can be a general-purpose processor, including Central Processing Unit (CPU), Network Processor (NP) and the like; it can also be Digital Signal Processing (DSP), Application Specific Integrated Circuit (ASIC), Field-Programmable Gate Array (FPGA) or other programmable logic device, discrete gate or transistor logic device, discrete hardware component.
[0137] It should be understood that every feature, structure, or characteristic described in relation to one embodiment is applicable to at least one other embodiment, unless the context clearly dictates otherwise. Thus, appearances of the language "one embodiment" or "an embodiment" or "the application embodiment" or "the preceding embodiment" or "some embodiments" or "some aspects" in various places in the specification are not necessarily referring to the same embodiment. Furthermore, some embodiments can be implemented only in combination with one or more other embodiments. It should be understood that the various embodiments can be implemented in hardware, software, or a combination of hardware and software. It should be understood that the various embodiments can be implemented in hardware, software, or a combination of hardware and software.
[0138] In several embodiments provided in the present application, it should be understood that the disclosed devices and methods can be implemented in other ways. The device embodiments described above are merely illustrative, for example, the division of units is only a logical function division, and actual implementation can have another division manner, for example, multiple units or components can be combined, or can be integrated into another system, or some features can be ignored or not executed. In addition, the coupling or direct coupling or communication connection between the displayed or discussed components can be indirect coupling or communication connection through some interfaces, devices or units, which can be electrical, mechanical or other forms.
[0139] The units described above as separate components can or can not be physically separate, and the components displayed as units can or can not be physical units; they can be located in one place or distributed on multiple network units; part or all of the units can be selected according to actual needs to achieve the purpose of the embodiment scheme.
[0140] In addition, each functional unit in each embodiment of the present application can be integrated into one processing unit, or each unit can be a separate unit, or two or more units can be integrated into one unit; the integrated unit can be realized in the form of hardware or in the form of hardware plus software functional unit.
[0141] The methods disclosed in several method embodiments provided in the present application can be combined in any way without conflict, to obtain new method embodiments.
[0142] The features disclosed in several product embodiments provided in the present application can be combined in any way without conflict, to obtain new product embodiments.
[0143] The features disclosed in several method or device embodiments provided by the present application can be arbitrarily combined, without conflict, to obtain new method embodiments or device embodiments.
[0144] Those skilled in the art can understand that all or part of the steps of the above method embodiments can be completed by relevant hardware instructed by programs, and the foregoing programs can be stored in a computer readable storage medium, and the programs execute the steps of the above method embodiments when executed; and the foregoing storage medium includes mobile storage devices, read-only memories (ROM), magnetic discs or optical discs, and various media that can store program codes.
[0145] Alternatively, the integrated units in the above embodiments of the present application, if realized in the form of software function modules and sold or used as independent products, can also be stored in a computer readable storage medium. Based on this understanding, the technical solutions of the embodiments of the present application can be embodied in the form of software products, and the computer software products are stored in a storage medium, and include several instructions for causing a data synchronization device (which can be a personal computer, a server, or a network device, etc.) to execute all or part of the methods described in the embodiments of the present application. The foregoing storage medium includes mobile storage devices, ROM, magnetic discs or optical discs, and various media that can store program codes.
[0146] It is worth noting that the drawings in the embodiments of the present application are only used to illustrate the schematic positions of the devices on the terminal device, and do not represent the real positions in the terminal device, and the real positions of the devices or the regions can be changed or offset according to the actual situation (for example, the structure of the terminal device), and the proportions of different parts in the drawings do not represent the real proportions.
[0147] The above is only the implementation of the present application, but the protection scope of the present application is not limited thereto, and any person skilled in the art can easily think of changes or replacements within the technical range disclosed in the present application, which should be covered in the protection scope of the present application. Therefore, the protection scope of the present application should be subject to the protection scope of the claims.
Claims
1. A load balancing method of scheduling traffic, characterized by, The method comprises: obtaining SRv6 scheduling traffic; obtaining first information and second information of the scheduling traffic; the first information indicates an influence of the scheduling traffic on original load balancing of an end-to-end path, and the second information indicates that each node on the end-to-end path decides whether the scheduling traffic participates in load sharing; the first information is used to determine an influence mode, which is participating in original load balancing or not participating in original load balancing; controlling load balancing of the scheduling traffic on the end-to-end path according to the first information and the second information.
2. The method of claim 1, wherein, The controlling load balancing of the scheduling traffic on the end-to-end path according to the first information and the second information comprises: if the first information meets a first condition and the second information meets a second condition, controlling the each node on the end-to-end path to count the scheduling traffic into load sharing.
3. The method of claim 2, wherein, The first condition comprises that the first information indicates that the each node on the end-to-end path participates in load balancing, and the second condition comprises that the second information indicates that the each node on the end-to-end path determines that the scheduling traffic participates in load sharing. The controlling load balancing of the scheduling traffic on the end-to-end path according to the first information and the second information comprises:
4. The method of claim 2, wherein, if the first information meets a third condition and the second information meets a fourth condition, controlling the each node on the end-to-end path not to count the scheduling traffic into load sharing. The third condition comprises that the first information indicates that the each node on the end-to-end path does not participate in load balancing, and the fourth condition comprises that the second information indicates that the each node on the end-to-end path determines that the scheduling traffic does not participate in load sharing.
5. The method of claim 4, wherein, The controlling load balancing of the scheduling traffic on the end-to-end path according to the first information and the second information comprises: if the first information meets a fifth condition and the second information meets a sixth condition, controlling at least one node on the end-to-end path to count the scheduling traffic into load sharing.
6. The method of claim 4, wherein, The fifth condition comprises that the first information indicates that the at least one node on the end-to-end path participates in load balancing, and the sixth condition comprises that the second information indicates that the each node on the end-to-end path determines whether to participate in load sharing according to a node type. The method comprises:
7. The method of claim 6, wherein, obtaining SRv6 scheduling traffic; the obtaining module is configured to obtain first information and second information of the scheduling traffic; 8. A load balancing apparatus for scheduling traffic, characterized by the first information indicates an influence of the scheduling traffic on original load balancing of an end-to-end path, and the second information indicates that each node on the end-to-end path decides whether the scheduling traffic participates in load sharing; the first information is used to determine an influence mode, which is participating in original load balancing or not participating in original load balancing; a processing module is configured to control load balancing of the scheduling traffic on the end-to-end path according to the first information and the second information. The method comprises: a memory is configured to store executable instructions; 9. A load balancing device that schedules traffic, characterized by A processor configured to execute executable instructions stored in the memory to implement the load balancing method of scheduling traffic as claimed in any one of claims 1 to 7.
10. A computer-readable storage medium, characterized in that, A storage medium having stored therein executable instructions that, when executed, cause a processor to perform the load balancing method of scheduling traffic as claimed in any one of claims 1 to 7.
Citation Information
Patent Citations
Load balancing method and load balancing system for routing node
CN106998303A
Load balancing method, device and system
CN114024969A