A time slice rotation-based flowlet packet-by-packet load sharing method
By introducing a time-slice round-robin-like per-packet load balancing method into a multi-path network, and utilizing global synchronized time slices and hash routing, high-granularity load balancing is achieved. This solves the problems of uncontrollable granularity and out-of-order load balancing in existing technologies, and improves network performance and resource utilization.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- NANJING YITAI MICROELECTRONICS TECH CO LTD
- Filing Date
- 2026-03-05
- Publication Date
- 2026-06-05
AI Technical Summary
Existing technologies struggle to achieve fine-grained load balancing in multipath networks while ensuring the order of data packet transmission. In particular, flow-based load balancing is coarse-grained, packet-based load balancing leads to out-of-order delivery, and flow-based optimization schemes rely on the inherent characteristics of data streams, making it impossible to achieve efficient load balancing.
A time-slice round-robin-based per-packet load balancing method is adopted, which uses globally synchronized time slices as the basic unit of load balancing, generates Flowlets and performs path scheduling, achieves high-granularity load balancing through hash formulas, ensures the order of data packets, and completes data packet processing through ASIC chip hardware logic pipeline.
It achieves high-granularity load balancing without out-of-order conditions, improving the overall performance and resource utilization of multi-path networks. It is applicable to various data centers and cloud computing networks, and solves the problems of uncontrollable granularity and out-of-order conditions in existing technologies.
Smart Images

Figure CN122160328A_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of computer network technology, and particularly relates to a time-slice rotation-based... Class-by-package load balancing method. Background Technology
[0002] In multi-path networks such as leaf-spine architectures in data centers, load balancing technology is a core technology for improving overall network throughput, increasing link resource utilization, and avoiding single-path congestion. Its core requirement is to achieve fine-grained data flow scheduling while ensuring the order of data packet transmission.
[0003] Currently, mainstream network load balancing technologies are mainly divided into three categories: First, flow-based load balancing, which allocates fixed forwarding paths to the data flow as a whole. This approach is simple to implement and can completely avoid out-of-order packet loading, but it has the coarsest granularity, and a single large flow can easily occupy the entire link's resources, resulting in poor load balancing performance. Second, packet-based load balancing, which allocates a forwarding path independently to each data packet. This has the finest granularity and the best load balancing performance, but it can lead to severe out-of-order packet problems, disrupt the TCP protocol's congestion control mechanism, and significantly reduce transmission performance. Third, load balancing based on… Load sharing, as a compromise between the first two methods, utilizes the natural bursts in the data stream transmission process. Division, Single Data packets within the same path are forwarded, achieving finer granularity than flow-based systems while maintaining... While it incorporates an internal order, its essence remains a flow-based optimization scheme. The generation of it depends entirely on the inherent characteristics of data flow.
[0004] Therefore, it is necessary to provide a new time-slice rotation-based method. The per-packet load balancing method solves the above technical problems. Summary of the Invention
[0005] This invention solves the technical problem while providing a time-slice rotation-based method. Class-by-package load balancing method.
[0006] To solve the above-mentioned technical problems, the present invention provides a time-slice rotation-based... A per-packet load balancing method, applied to network load balancing devices in multi-path networks, is characterized by: using globally synchronized time slices as the basic unit of load balancing, actively generating Flowlets and performing path scheduling to achieve high-granularity per-packet load balancing while ensuring packet order. Specifically, it includes the following steps: S1. Initialization: Start the network load balancing device, configure the microsecond-level time slice period T, initialize the global time slice counter and assign an initial count value, clear the flow state table, complete the global time synchronization of the network device, and enable the data packet reception and forwarding function; the flow state table is used to store the identifiers of each data flow. The corresponding time slice number of the previous data packet and the current forwarding path ; S2. Data Packet Reception and Flow Identifier Extraction: The network load balancing device receives data packet P, parses the data packet's five-tuple, and generates a unique data flow identifier. The five-tuple includes source IP, destination IP, source port, destination port, and transport layer protocol; S3. Time Slice Number Acquisition and Query: Read the current time slice number Scurrent from the global time slice counter, and based on... Query the corresponding stream status table If it is this The first data packet, by default =0 S4 Judgment and Path Decision: S4-1, if Determine the data packet For new The first packet executes the path selection algorithm for this. Assign a new forwarding path. The core hash formula of the path selection algorithm is: ,in For hash functions, This is a string concatenation operation. This represents the total number of available forwarding paths in a multipath network. For modulo operation; then update the flow state table, and... corresponding Updated to , Updated to ; S4-2, if Determine the data packet Those generated within the current time slice Read directly from the flow state table corresponding ; S5. Packet forwarding: Based on the decision result of step S4, forward the data packets. from or Forward to the next-hop network node; S6. Repeated execution: For each data packet received by the network load balancing device, repeat steps S2-S5 to achieve load balancing of the entire data stream.
[0007] As a further aspect of the present invention, the time slice period The parameters are dynamically configurable, and the configuration is based on one or more combinations of the maximum time delay difference between paths in a multi-path network, link bandwidth, and network traffic density.
[0008] As a further embodiment of the present invention, the hash function is any one of the CRC32 hash function, the Jenkins hash function, or other hash functions with uniform hashing characteristics.
[0009] As a further embodiment of the present invention, the path selection algorithm can be replaced by a dynamic decision-making algorithm based on path quality, wherein path quality includes one or more combinations of path delay, link utilization, and packet loss rate.
[0010] As a further embodiment of the present invention, the network load balancing device is a network device with data forwarding, state storage and logical computing capabilities, including any one of data center switches, routers and Layer 3 switches.
[0011] As a further aspect of the present invention, the global time slice counter is a continuously incrementing counter with an initial count value of 0, which increments after each time slice period. The count is incremented by 1, and a unique number is assigned to each time slice.
[0012] As a further aspect of the present invention, the flow state table is stored in the cache of the network load balancing device, supporting... Quick matching, and Real-time query and update, with query and update latency in the nanosecond range.
[0013] As a further aspect of the present invention, the parsing of the data packet, The generation, time slice number comparison, path query and forwarding operations are all implemented in a hardware pipeline manner through the ASIC chip of the network load balancing device, which meets the requirements of high-speed data packet processing at the microsecond level.
[0014] As a further embodiment of the present invention, different Data stream, or the same Generated in different time slices The path selection processes are independent and do not interfere with each other; within the same slice at the same time... All data packets are transmitted along the same forwarding path.
[0015] Compared with related technologies, the time-slice rotation-based method provided by this invention... The per-packet load balancing method has the following advantages: This invention achieves active controllability Generate, completely freeing yourself from dependence on the natural gaps in the data stream; This invention will The traditional "passive detection" mechanism has been transformed into an "actively generated scheduling tool," triggered by a globally synchronized time-slice signal. The generation process can achieve uniformity and stability regardless of whether there are natural gaps in the data stream. Division, solving the traditional The technology addresses the core pain point of failure in handling smooth, large data streams, and achieves load balancing for all types of data streams without discrimination.
[0016] This invention achieves near-packet-by-packet load balancing without out-of-order loading by using finely granular and linearly adjustable load sharing. The load-sharing granularity of this invention is directly determined by the time slice period T. Theoretically, the smaller T is set, the more load will be generated. The more data points there are, the finer the load balancing granularity becomes, allowing it to infinitely approximate the packet-based load balancing effect. At the same time, network administrators can adjust the single parameter T to achieve a precise and linear trade-off between out-of-order packets and high load balancing, meeting the personalized needs of different network scenarios and solving the problems of uncontrollable granularity and inability to approximate the theoretical optimality in existing technologies.
[0017] This invention features simple and efficient core logic that is easy to implement in hardware and adaptable to the high-speed forwarding requirements of network devices. The core execution logic of this invention includes only three steps: time slice number comparison, flow state table query and update, and hash routing. It eliminates the need for complex data flow gap time calculations and dynamic threshold maintenance, thus avoiding a large number of complex logical operations. At the same time, the storage and query of the flow state table can be implemented through the high-speed cache of the network device, and hash routing can be completed through the hardware logic pipeline of the ASIC chip. It is fully compatible with the microsecond-level high-speed data packet forwarding requirements of network devices such as switches and routers, and has extremely strong engineering implementation value.
[0018] This invention significantly improves the overall performance and resource utilization of multipath networks by being completely independent of traffic patterns; This invention employs a unified time-slicing and scheduling rule for all traffic patterns, including bursty mouse flows, stable elephant flows, and mixed flows, ensuring the stability and consistency of load balancing. By evenly distributing data flows across multiple available paths, it effectively avoids single-path congestion and significantly improves the overall utilization of link resources. Furthermore, by strictly guaranteeing the order of data packets, it does not disrupt the transmission characteristics of the TCP protocol, ultimately achieving a dual improvement in multi-path network throughput and transmission efficiency. It is suitable for high-density traffic multi-path network scenarios such as various data centers and cloud computing. Attached Figure Description
[0019] To facilitate understanding by those skilled in the art, the present invention will be further described below with reference to the accompanying drawings.
[0020] Figure 1 This is a first process diagram provided for the present invention; Figure 2 This is a schematic diagram of the second process provided by the present invention. Detailed Implementation
[0021] Please refer to the following: Figure 1 and Figure 2 ,in, Figure 1 This is a first process diagram provided for the present invention; Figure 2 This is a schematic diagram of the second process provided by the present invention. Based on time-slice rotation. A per-packet load balancing method, applied to network load balancing devices in multipath networks, includes: actively generating load balancing units based on globally synchronized time slices. It also performs path scheduling to achieve high-granularity load balancing per packet while ensuring the order of data packets; By introducing a globally synchronized, periodically adjustable time-slice signal, the traditional passive method based on the natural gaps in the data stream is transformed. Detection has shifted to active detection based on time slice periods. The generation process achieves uniform slicing of the data stream using time slices as units. Combined with the rules of hash routing within time slices and forwarding along the same path within the same slice, it enables actively controllable, packet-by-packet high-granularity load balancing while strictly ensuring the order of data packets. The implementation of this invention is based on network devices with data forwarding, state storage and logical computing capabilities, such as data center switches and routers. The devices need to support global time synchronization, data flow identifier extraction, state recording and updating, and high-speed path selection and forwarding. The following describes the specific implementation parameters and complete workflow. Specifically, the following steps are included: S1. Initialization: Start the network load balancing device, configure the microsecond-level time slice period T, initialize the global time slice counter and assign an initial count value, clear the flow state table, complete the global time synchronization of the network device, and enable the data packet reception and forwarding function; the flow state table is used to store the identifiers of each data flow. The corresponding time slice number of the previous data packet and the current forwarding path ; S2. Data Packet Reception and Flow Identifier Extraction: The network load balancing device receives data packet P, parses the data packet's five-tuple, and generates a unique data flow identifier. The five-tuple includes source IP, destination IP, source port, destination port, and transport layer protocol; S3. Time Slice Number Acquisition and Query: Read the current time slice number Scurrent from the global time slice counter, and based on... Query the corresponding stream status table If it is the The first data packet, by default =0 S4 Judgment and Path Decision: S4-1, if Determine the data packet For new The first packet executes the path selection algorithm for this. Assign a new forwarding path. The core hash formula of the path selection algorithm is: ,in For hash functions, This is a string concatenation operation. This represents the total number of available forwarding paths in a multipath network. For modulo operation; then update the flow state table, and... corresponding Updated to , Updated to ; S4-2, if Determine the data packet For Flowlets generated within the current time slice, the data is read directly from the flow state table. corresponding ; S5. Packet forwarding: Based on the decision result of step S4, forward the data packets. from or Forward to the next-hop network node; S6. Repeated execution: For each data packet received by the network load balancing device, repeat steps S2-S5 to achieve load balancing of the entire data stream.
[0022] The time slice period The parameters are dynamically configurable, and the configuration is based on one or more combinations of the maximum time delay difference between paths in a multi-path network, link bandwidth, and network traffic density.
[0023] Wherein, time slice: defined as the basic period for load sharing, denoted by the symbol This indicates that the core adjustable parameter of the present invention is configured in the global control module of the network device, with a period range in the microsecond range. It can be dynamically adjusted according to the actual network status, and the adjustment is based on factors such as the maximum latency difference between network paths, link bandwidth, and traffic density. In this embodiment, it is set as follows:
[0024] The hash function is any one of the CRC32 hash function, the Jenkins hash function, or other hash functions with uniform hashing characteristics.
[0025] The path selection algorithm can be replaced by a dynamic decision-making algorithm based on path quality, where path quality includes one or more combinations of path latency, link utilization, and packet loss rate.
[0026] The network load balancing device is a network device with data forwarding, state storage and logical computing capabilities, including any one of data center switches, routers and Layer 3 switches.
[0027] The global time slice counter is a continuously incrementing counter, with an initial count value of 0, which increases after each time slice period. The count is incremented by 1, and a unique number is assigned to each time slice.
[0028] Among them, the global time slice counter is initialized and starts counting when the network device starts up. It assigns a unique consecutive number to each time slice, represented by the symbol S (S is a positive integer), to identify the time slice to which the data packet belongs, so as to realize global time slice synchronization.
[0029] The flow state table is stored in the cache of the network load balancing device, supporting... Quick matching, and Real-time query and update, with query and update latency in the nanosecond range.
[0030] Flow State Table: Stored in the network device's cache, used to record each... The corresponding time slice number of the previous data packet and the current forwarding path It supports fast querying and real-time updates, providing a basis for data packet forwarding decisions.
[0031] The parsing of the data packet, The generation, time slice number comparison, path query and forwarding operations are all implemented in a hardware pipeline manner through the ASIC chip of the network load balancing device, which meets the requirements of high-speed data packet processing at the microsecond level.
[0032] different Data stream, or the same Generated in different time slices The path selection processes are independent and do not interfere with each other; within the same slice at the same time... All data packets are transmitted along the same forwarding path.
[0033] Among them, the flow identifier It is generated by extracting the five-tuple (source IP, destination IP, source port, destination port, transport layer protocol) of the data packet and serves as a unique identifier to distinguish different data streams; Among them, time slice triggered Generation rules: As the basic scheduling unit of this invention, its generation is triggered by time slice boundaries and is independent of the natural gaps in the data stream. The specific rules are as follows: For any data packet arriving at the network device, extract its... Query the flow status table The corresponding time slice number of the previous data packet ; Read the current global time slice number ,like If so, the data packet is determined to be new. The first package, completing one Active generation; like If so, the data packet is determined to belong to the data packets generated within the current time slice. No new generate.
[0034] This rule implements time-slice uniform slicing of the data stream. Regardless of whether there are natural gaps in the data stream, a new data packet is generated as soon as it crosses the time-slice boundary. This completely eliminates the dependence on the inherent characteristics of data streams.
[0035] Among them, the path selection rules for hashes within a time slice are as follows: For new Independent forwarding paths are allocated, and intra-slice data packets of the same flow are forwarded along the same path to ensure that individual packets are forwarded together. Internal data packets are absolutely ordered, and the specific rules are as follows: When the data packet is determined to be new During the first package, the path selection algorithm is activated, for this... Assign a new forwarding path ; The path selection algorithm primarily uses a hash algorithm, but it can also be adapted to dynamic decision-making algorithms based on path quality. The core formula of the hash algorithm is:
[0036] in: For hash functions (such as CRC32, Jenkins hash). This is a string concatenation operation. This represents the total number of available forwarding paths in a multipath network. For modulo operation; Within the same time slice, the All subsequent data packets strictly follow... Forward until a new one is generated across the time slice boundary. ; different Data stream, or the same In Flowlets at different time slices, path selection is independent and does not interfere with each other.
[0037] The present invention provides a time-slice rotation-based method The working principle of the per-packet load balancing method is as follows: The load balancing method of this invention is executed cyclically around each data packet received by the network device, combining initialization, packet reception, flow identification, and time slice comparison. The core steps of decision-path allocation-forwarding-state update are implemented as follows, with the logical execution flowchart of this invention providing a complete scheduling and forwarding process: Initialization: Start the network load balancing device and configure the time slice period. Initialize the global time slice counter (initial value) Clear the flow state table, complete global time synchronization of network devices, and enable packet reception and forwarding functions; Receive data packets and extract stream identifiers: The device receives data packets. The hardware parsing module extracts the 5-tuple of the data packet and generates a unique flow identifier. ; Time slice number retrieval and query: Read the number of the current global time slice counter. According to the flow state table Perform a query; if it is this The first data packet is the default. If it is not the first data packet, then retrieve the record from the flow state table. ; Judgment and Path Decision: like :determination For new The first packet, according to the hash formula above, executes the path selection algorithm to determine the path. Assign a new forwarding path Then update the flow state table, and... corresponding Updated to , Updated to ; like :determination Belongs to the present Read directly from the flow state table corresponding No need to choose a new route; Packet forwarding: Based on the above decision results, the data packets are forwarded... from or Forward to the next-hop network node; Looping execution: For each data packet received by the network device, repeat steps 2-5 to achieve time-slice-based round-robin processing of the entire data stream. Load sharing is performed per package.
[0038] In this embodiment, a 4-path network of a data center leaf-spine architecture is selected. Configure time slice period Two typical data streams were selected: one is a bursty rat stream (with random packet intervals, 0.1-1). The second type is the steady-state elephant flow (with a fixed interval of 0.2). (No natural gaps).
[0039] Tests showed that both the rat and elephant strategies were executed according to a 2-point standard. The time slices are evenly divided, and 12 are generated within each time slice. Each Corresponding to 110 data packets; all The resources are evenly distributed across four available paths using a hash algorithm, with link resource utilization deviation controlled within 5%, and each... Data packets within the TCP connection are in perfect order, resulting in no performance loss during TCP transmission. Compared to traditional... The technology improves the load balancing efficiency of the Elephant Stream by more than 80% and the overall network throughput by more than 35%, verifying the effectiveness of the invention. Example 1
[0040] This embodiment adds a real-time network status feedback mechanism to the original fixed time slice period, realizing dynamic adaptive adjustment of the time slice period T. This solves the problem of mismatch between load sharing granularity and network demand when the fixed time slice is affected by network traffic fluctuations and path status changes, further improving the flexibility and adaptability of load sharing.
[0041] Unlike the original fixed time slice period configuration, this embodiment introduces a network status acquisition module and a dynamic time slice adjustment algorithm to collect key status indicators of multi-path networks in real time. The algorithm dynamically calculates the optimal time slice period T to achieve closed-loop linkage of "network status - time slice period - load sharing effect". It can adapt to the dynamic changes of different network scenarios without manual intervention.
[0042] Network status metrics: Key metrics collected in real time include: link utilization for each path. (i=1,2,...,N, where N is the total number of available paths), average path delay Packet loss rate Network traffic density (Total number of data packets received per unit time), collection period is This ensures real-time status feedback.
[0043] Dynamic time slice adjustment algorithm: With the goals of "optimal load balancing, no out-of-order data packets, and minimum device processing overhead", a dynamic adjustment formula is designed to calculate the current optimal time slice period. The formula is as follows:
[0044] in: The reference time slice period (in this embodiment) ); The average link utilization of all available paths ( ; The average latency of all available paths ( ; The average packet loss rate for all available paths ( ); Weighting coefficients ( (This can be configured according to network priority; in this embodiment...) Prioritize ensuring balanced link utilization; Network traffic density; the higher the traffic, the higher the density. The smaller the value, the higher the granularity of load sharing.
[0045] Adjusting constraints: To avoid excessive fluctuations in the time slice period leading to out-of-order data packets, set... (Minimum time slice period) (Maximum time slice period), when the algorithm calculates... When the constraint range is exceeded, the boundary value is taken as the current time slice period.
[0046] Based on the original embodiment, a closed-loop step of "network status acquisition - time slice period adjustment" is added, as follows: During initialization in step S1, in addition to configuring the reference time slice period... In addition, start the network status acquisition module and initialize the weight coefficients. Set the time slice period constraint range ( ); During the cyclic execution of step S6, each acquisition cycle... The network status acquisition module synchronously collects data from each path. and network traffic density ; The current optimal time slice period is calculated using a dynamic adjustment algorithm. The time slice period is then adjusted according to the constraints to obtain the final time slice period. ; The period for updating the global time slice counter is Time slice numbering of subsequent data packets, All generation is performed based on a new time slice cycle, enabling dynamic adaptive adjustment.
[0047] This embodiment uses the same 4-path data center network as the basic embodiment to simulate a network traffic fluctuation scenario (traffic density increases from 10^5 pps to 10^6 pps, link utilization increases from 30% to 80%), and compares it with a fixed time slice (T=2). The effect of dynamic time-slice adaptive adjustment: Test results show that the dynamic time-slice scheme can adjust the period (T in 0.8) in real time according to network conditions. -3.2 (Dynamically changing between time slices), link resource utilization deviation is controlled within 3%. Compared with the fixed time slice scheme, network throughput is increased by more than 18%, data packet latency is reduced by 25%, and packet loss rate is reduced by 40%, effectively solving the problem of reduced load sharing effect when traffic fluctuates in the fixed time slice.
[0048] Example 2 This embodiment, based on the original hash-based routing, integrates a real-time path quality feedback mechanism and designs a dynamic routing algorithm based on path quality weighting to replace the traditional single hash-based routing, achieving " The closed loop of "allocation-path quality feedback-routing optimization" solves the problems of the original routing algorithm not considering the real-time status of the path and being easily assigned to congested paths, further improving the stability of load sharing and transmission performance.
[0049] Unlike the original approach of "primarily hash-based routing with static path selection," this embodiment introduces a path quality assessment module and a weighted dynamic routing algorithm to evaluate the quality of each available path in real time, providing a new... When allocating paths, a weighted approach combining hash uniformity and path quality is used to prioritize paths that are not hashed evenly or in a specific way. It allocates data to higher-quality paths while ensuring load balancing, achieving dual optimization of load sharing and transmission quality.
[0050] Path quality assessment metrics and weights: Path link utilization rate from Example 1 is used. Average latency Packet loss rate Design path quality score The calculation uses inverse normalization; the better the indicator, the higher the score. The formula is as follows:
[0051] in: The link utilization threshold (in this embodiment) ); The time delay threshold (in this embodiment) ); The packet loss rate threshold (in this embodiment) ); Weights for quality indicators ( In this embodiment Prioritize low latency and low utilization.
[0052] Weighted Dynamic Routing Algorithm: Combining the uniformity of hash algorithms and the priority of path quality scores, a weighted routing formula is designed to replace the original single hash routing formula. The new formula is as follows:
[0053] in: This indicates the path number that maximizes the value within the parentheses; Give the quality score to the i-th path; The meanings of the other parameters are consistent with the original hash formula.
[0054] Algorithm logic: First, an initial set of candidate paths is obtained using a hash algorithm. Then, each path is weighted based on its quality score. Finally, the path with the highest weighted value is selected as the new path. The forwarding path ensures both the uniformity of hash routing and prioritizes the selection of higher-quality paths.
[0055] Path quality update mechanism: consistent with Example 1, every time... Update the quality scores for each path. This ensures the real-time nature of route quality assessment, providing an accurate basis for route selection decisions.
[0056] Based on the existing complete workflow, the path selection logic in step S4-1 is modified, and a path quality assessment step is added. The specific modifications are as follows: In step S4-1, when it is determined that data packet P is new... Upon first package delivery, the path quality assessment module is activated to read the quality scores of each currently available path. ; The weighted dynamic routing algorithm is executed to calculate the new forwarding path according to the formula. This replaces the original single hash routing; Update the flow state table, and... corresponding Updated to , Updated to The subsequent procedures remain unchanged; Each collection cycle Simultaneously update the quality scores of each path. For the next new The path selection provides updated quality data.
[0057] This embodiment uses the same network environment as the basic embodiment to simulate a single-path congestion scenario (where the link utilization of one path increases to 85%, latency increases to 120μs, and packet loss rate increases to 0.8%), and compares the effects of the original hash routing with the weighted dynamic routing of this embodiment: Test results show that the original hash routing still has 23% success rate. Assigned to a congested path, the packet loss rate on that path further increased to 1.5%, and the out-of-order packet rate reached 3%; while the weighted dynamic routing in this embodiment only addresses 5% of the congested paths. When assigned to a congested path, the packet loss rate of the congested path is controlled within 0.9%, with no out-of-order packets, and the overall network transmission latency is reduced by 32%, verifying the innovative advantages of this embodiment in improving transmission quality and avoiding congestion.
[0058] This invention achieves this through an active time-slice rotation mechanism. The generation and scheduling of these technologies have broken through the bottlenecks of traditional load balancing techniques. Achieve proactive control Generate, completely freeing yourself from dependence on the natural gaps in the data stream; This invention will The traditional "passive detection" mechanism has been transformed into an "actively generated scheduling tool," triggered by a globally synchronized time-slice signal. The generation process can achieve uniformity and stability regardless of whether there are natural gaps in the data stream. Division, solving the traditional The technology addresses the core pain point of failure in handling smooth, large data streams, and achieves load balancing for all types of data streams without discrimination.
[0059] The load sharing granularity is fine and linearly adjustable, and it approximates the effect of packet-by-packet load balancing without out-of-order conditions. The load sharing granularity of this invention is determined by the time slice period. Directly determined, in theory The smaller the setting, the more... The larger the number of load balancing units, the finer the granularity of load balancing, which can infinitely approximate the effect of packet-based load balancing; at the same time, network administrators can adjust... This single parameter achieves a precise and linear trade-off between packet orderlessness and high load balancing, meeting the personalized needs of different network scenarios and solving the problems of uncontrollable granularity and inability to approximate theoretical optimality in existing technologies.
[0060] The core logic is simple and efficient, easy to implement in hardware, and adaptable to the high-speed forwarding requirements of network devices. The core execution logic of this invention includes only three steps: time slice number comparison, flow state table query and update, and hash routing. It eliminates the need for complex data flow gap time calculations and dynamic threshold maintenance, thus avoiding a large number of complex logical operations. At the same time, the storage and query of the flow state table can be implemented through the high-speed cache of the network device, and hash routing can be completed through the hardware logic pipeline of the ASIC chip. It is fully compatible with the microsecond-level high-speed data packet forwarding requirements of network devices such as switches and routers, and has extremely strong engineering implementation value.
[0061] Completely independent of traffic patterns, it significantly improves the overall performance and resource utilization of multipath networks; This invention employs a unified time-slicing and scheduling rule for all traffic patterns, including bursty mouse flows, stable elephant flows, and mixed flows, ensuring the stability and consistency of load balancing. By evenly distributing data flows across multiple available paths, it effectively avoids single-path congestion and significantly improves the overall utilization of link resources. Furthermore, by strictly guaranteeing the order of data packets, it does not disrupt the transmission characteristics of the TCP protocol, ultimately achieving a dual improvement in multi-path network throughput and transmission efficiency. It is suitable for high-density traffic multi-path network scenarios such as various data centers and cloud computing.
[0062] Although embodiments of the invention have been shown and described, it will be understood by those skilled in the art that various changes, modifications, substitutions, and variations can be made to these embodiments, or they can be used directly or indirectly, without departing from the principles and spirit of the invention. In other related technical fields, the scope of the invention is defined by the appended claims and their equivalents, and they are similarly included within the scope of patent protection of the invention.
Claims
1. A time-slice-based rotation method A per-packet load balancing method, applied to network load balancing devices in multi-path networks, is characterized by: include: Using globally synchronized time slices as the basic unit for load balancing, actively generate It also performs path scheduling to achieve high-granularity load balancing per packet while ensuring the order of data packets. Specifically, it includes the following steps: S1. Initialization: Start the network load balancing device, configure the microsecond-level time slice period T, initialize the global time slice counter and assign an initial count value, clear the flow state table, complete the global time synchronization of the network device, and enable the data packet reception and forwarding function; the flow state table is used to store the identifiers of each data flow. The corresponding time slice number of the previous data packet and the current forwarding path ; S2. Data Packet Reception and Flow Identifier Extraction: The network load balancing device receives data packet P, parses the data packet's five-tuple, and generates a unique data flow identifier. The five-tuple includes source IP, destination IP, source port, destination port, and transport layer protocol; S3. Time Slice Number Acquisition and Query: Read the current time slice number Scurrent from the global time slice counter, and based on... Query the corresponding stream status table If it is this The first data packet, by default =0 S4 Judgment and Path Decision: S4-1, if Determine the data packet For new The first packet executes the path selection algorithm for this. Assign a new forwarding path. The core hash formula of the path selection algorithm is: ,in For hash functions, This is a string concatenation operation. This represents the total number of available forwarding paths in a multipath network. For modulo operation; then update the flow state table, and... corresponding Updated to , Updated to ; S4-2, if Determine the data packet Those generated within the current time slice Read directly from the flow state table corresponding ; S5. Packet forwarding: Based on the decision result of step S4, forward the data packets. from or Forward to the next-hop network node; S6. Repeated execution: For each data packet received by the network load balancing device, repeat steps S2-S5 to achieve load balancing of the entire data stream.
2. The time-slice rotation based method according to claim 1 The per-packet load balancing method is characterized by: The time slice period The parameters are dynamically configurable, and the configuration is based on one or more combinations of the maximum time delay difference between paths in a multi-path network, link bandwidth, and network traffic density.
3. The time-slice rotation based method according to claim 2 The per-packet load balancing method is characterized by: The hash function is any one of the CRC32 hash function, the Jenkins hash function, or other hash functions with uniform hashing characteristics.
4. The time-slice rotation based method according to claim 1 The per-packet load balancing method is characterized by: The path selection algorithm can be replaced by a dynamic decision-making algorithm based on path quality, where path quality includes one or more combinations of path latency, link utilization, and packet loss rate.
5. The time-slice rotation based method according to claim 1 The per-packet load balancing method is characterized by: The network load balancing device is a network device with data forwarding, state storage and logical computing capabilities, including any one of data center switches, routers and Layer 3 switches.
6. The time-slice-based rotation method according to claim 1 The per-packet load balancing method is characterized by: The global time slice counter is a continuously incrementing counter, with an initial count value of 0, which increases after each time slice period. The count is incremented by 1, and a unique number is assigned to each time slice.
7. The time-slice rotation based method according to claim 1 The per-packet load balancing method is characterized by: The flow state table is stored in the cache of the network load balancing device, supporting... Quick matching, and Real-time query and update, with query and update latency in the nanosecond range.
8. The time-slice rotation based method according to claim 2 The per-packet load balancing method is characterized by: The parsing of the data packet, The generation, time slice number comparison, path query and forwarding operations are all implemented in a hardware pipeline manner through the ASIC chip of the network load balancing device, which meets the requirements of high-speed data packet processing at the microsecond level.
9. The time-slice rotation based method according to claim 1 The per-packet load balancing method is characterized by: different Data stream, or the same Generated in different time slices The path selection processes are independent and do not interfere with each other; within the same slice at the same time... All data packets are transmitted along the same forwarding path.