Method for dynamically balancing system load, computer device, medium and product

By dynamically adjusting the load of NUMA nodes and using the mechanism of redundant tables and overload tables, the problem of load imbalance in NUMA architecture systems is solved, and the system is efficient, stable load balancing and business continuity are achieved.

CN119652893AActive Publication Date: 2025-03-18BEIJING TOPSEC NETWORK SECURITY TECH +2
View PDF 5 Cites 0 Cited by

Patent Information

Application Number
CN202411714805.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-11-27
Publication Date
2025-03-18
Estimated Expiration
2044-11-27

AI Technical Summary

Technical Problem

In NUMA architecture system, due to unbalanced node load, some nodes are overloaded, affecting business continuity.

Method used

By obtaining the real-time input capabilities and maximum processing capabilities of all NUMA nodes, dynamically allocate nodes to redundant tables and overload tables, dynamically adjust task allocations according to the processing requirements of data packets to ensure load balancing.

Benefits of technology

It realizes efficient and stable load balancing in multi-NUMA architecture, avoids system crashes or performance degradation caused by node overload, and ensures the normal operation of the system during peak load periods.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119652893A_ABST
    Figure CN119652893A_ABST
Patent Text Reader

Abstract

The invention discloses a method for dynamically balancing a system load, a computer device, a medium and a product, and the method comprises the steps: obtaining the input capability and the maximum processing capability of NUMA nodes in real time, and dynamically classifying the nodes to a redundancy table or an overload table according to the data; after a data packet is received, whether suitable nodes exist in a redundancy table or not is checked for processing; if not, the overload table is inquired, whether the real-time input capacity of the target node is within the acceptable range or not is judged, and if not, the node with the highest processing capacity in the redundancy table is selected to process the task. According to the method, dynamic adjustment can be achieved, quick response can be achieved in a changing environment, the optimal processing node can be selected, efficient and stable load balancing in the multi-NUMA system architecture is achieved, the service interruption risk caused by node overload is reduced, and the stability and performance of the system are remarkably improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the field of network security and communication technology, and in particular to a method, computer device, medium, and product for dynamically balancing system load. Background Art

[0002] In high-performance computing platforms, the NUMA (Non-Uniform Memory Access) architecture is widely used in industrial control IoT and big data platforms. The NUMA architecture divides the system into multiple nodes, each of which contains a processor and local memory, to reduce memory access latency and improve system performance.

[0003] However, the NUMA architecture also brings some challenges and problems. In a NUMA system, the processor accesses local memory much faster than accessing the memory of a remote node. If the application data is distributed on multiple nodes, the memory access latency of some nodes will increase, thus affecting performance. In actual applications, since each NUMA node receives different traffic or tasks, the system load is unbalanced, causing some nodes to be overloaded, affecting business continuity. Summary of the invention

[0004] In view of this, the embodiments of the present disclosure provide a method, computer device, medium, and product for dynamically balancing system loads, which can solve the problems existing in the prior art such as unbalanced system loads, node overloads, and other problems leading to business interruptions.

[0005] In the first aspect, the present disclosure provides a method for dynamically balancing system loads.

[0006] Specifically include the following:

[0007] Obtaining key information of all NUMA nodes in a multi-NUMA architecture; the key information includes real-time input capability and maximum processing capability;

[0008] If the key information meets the preset conditions, the NUMA node is stored in the redundancy table, otherwise, it is stored in the overload table;

[0009] Based on the received data packet, determining a node type responsible for processing the data packet;

[0010] If the node type does not exist in the redundant table, calling the corresponding NUMA node in the overload table as the target node based on the node type;

[0011] If the real-time input capability of the target node is greater than the corresponding maximum processing capability, the node with the largest difference between the maximum processing capability and the current real-time input capability in the redundant table executes the processing instruction for the data packet;

[0012] If the real-time input capability of the target node is not greater than the corresponding maximum processing capability, the target node executes the processing instruction for the data packet.

[0013] Optionally, if the key information meets a preset condition, the NUMA node is stored in a redundancy table, otherwise, it is stored in an overload table, specifically including:

[0014] Storing NUMA nodes whose real-time input capacity is not greater than the corresponding maximum processing capacity into a redundancy table;

[0015] The NUMA nodes whose real-time input capabilities are greater than the corresponding maximum processing capabilities are stored in the overload table.

[0016] Optionally, the method for acquiring the maximum processing capacity includes: when the target system is under a no-load condition, performing a maximum task stress test on each NUMA node in the target system to obtain the maximum processing capacity of the corresponding NUMA node.

[0017] Optionally, determining the type of node responsible for processing the data packet based on the received data packet includes:

[0018] Acquire first information of the received data packet, the first information including a destination IP address and a port number;

[0019] Based on the first information and the preset mapping mechanism, the node type responsible for processing is determined.

[0020] Optionally, after determining the node type, the method further includes:

[0021] Acquire the time interval from the determination time of the node type to the creation time of the redundant table and the overload table;

[0022] When the time interval is greater than a preset interval threshold, the redundant table and the overload table are updated.

[0023] Optionally, the updating the redundant table and the overload table based on the update strategy includes:

[0024] Obtain the real-time input capacity of all NUMA nodes in the redundant table at the current moment, recorded as the first input capacity;

[0025] Obtaining the real-time input capacity of all NUMA nodes in the NUMA computing resource overload table at the current moment, recorded as the second input capacity;

[0026] Move the NUMA node whose first input capacity is greater than the corresponding maximum processing capacity to the overload table;

[0027] The NUMA nodes whose second input capacity is not greater than the corresponding maximum processing capacity are moved to the NUMA computation redundancy table.

[0028] Optionally, the method for acquiring the real-time input capability includes: monitoring the usage rate and memory usage of each NUMA node in real time based on a system monitoring tool, and obtaining the corresponding real YY+242249P

[0029] Input capability.

[0030] Optionally, if the node type exists in the redundant table, a corresponding NUMA node of the redundant table is called based on the node type to execute a processing instruction for the data packet.

[0031] In a second aspect, the embodiment of the present disclosure further provides a system for dynamically balancing system loads, including:

[0032] Capability acquisition module, used to obtain key information of all NUMA nodes in a multi-NUMA architecture;

[0033] A classification module, used for storing the NUMA node in a redundant table when the key information meets a preset condition, and storing it in an overload table otherwise;

[0034] A determination module, for determining the type of node responsible for processing based on the received data packet;

[0035] A dynamic adjustment module, configured to, when the node type exists in the redundant table, call the corresponding NUMA node of the redundant table based on the node type to execute a processing instruction for the data packet;

[0036] If the node type exists in the overload table, the corresponding NUMA node in the overload table is called based on the node type and recorded as the target node;

[0037] The current real-time input capacity of the target node is obtained, and it is determined whether the current real-time input capacity is greater than the maximum processing capacity of the target node. If not, the target node executes the processing instruction for the data packet. If so, the node with the largest difference between the maximum processing capacity and the current real-time input capacity in the redundant table is obtained, and recorded as the target node. The target node executes the processing instruction for the data packet.

[0038] In a third aspect, the present application discloses a method for dynamically balancing system loads, comprising:

[0039] Get the maximum input capacity and maximum YY+242249P of all NUMA nodes in a multi-NUMA architecture.

[0040] Large processing capacity;

[0041] Inserting the NUMA node whose maximum input capacity is not greater than the corresponding maximum processing capacity into the redundancy table; inserting the NUMA node whose maximum input capacity is greater than the corresponding maximum processing capacity into the overload table;

[0042] Based on the received data packet, determine the node type responsible for processing;

[0043] If the node type exists in the redundant table, calling the corresponding NUMA node of the redundant table based on the node type to execute a processing instruction for the data packet;

[0044] If the node type exists in the overload table, the corresponding NUMA node in the overload table is called based on the node type and recorded as the target node;

[0045] The real-time input capability of the target node is obtained, and it is determined whether the real-time input capability is greater than the maximum processing capability of the target node. If not, the target node executes the processing instruction for the data packet. If so, the node with the largest difference between the maximum processing capability and the maximum input capability in the redundant table is obtained and recorded as the target node. The target node executes the processing instruction for the data packet.

[0046] In a fourth aspect, the embodiments of the present disclosure further provide a computer device, which adopts the following technical solution:

[0047] The computer device comprises:

[0048] at least one processor; and,

[0049] a memory communicatively connected to the at least one processor; wherein,

[0050] The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute any of the above methods for dynamically balancing system loads.

[0051] In a fifth aspect, an embodiment of the present disclosure further provides a computer-readable storage medium, which stores computer instructions, and the computer instructions are used to enable a computer to execute any of the above-mentioned methods for dynamically balancing system loads.

[0052] In a sixth aspect, an embodiment of the present disclosure further provides a computer program product, comprising a computer program / instruction, which implements the steps of any of the above methods when executed by a processor.

[0053] The method for dynamically balancing system load disclosed in the present application can automatically allocate tasks according to the current load situation through real-time monitoring and dynamic adjustment to ensure load balancing of each NUMA node, which can avoid the situation where a certain node is overloaded while other nodes are idle, thereby improving the performance and efficiency of the overall system; by reallocating the tasks of the overloaded nodes to redundant nodes, system crashes or performance degradation caused by overload of a single node can be avoided, ensuring that the system can still operate normally during peak load periods, and achieving efficient and stable load balancing in a multi-NUMA architecture, which can effectively improve the performance, stability and resource utilization of the system, and is particularly suitable for high-performance computing environments that need to process large amounts of data and complex computing tasks.

[0054] The above description is only an overview of the technical solution of the present invention. In order to more clearly understand the technical means of the present invention, it can be implemented in accordance with the contents of the specification. In order to make the above and other purposes, features and advantages of the present invention more obvious and easy to understand, the following preferred embodiments are specifically cited and described in detail with reference to the accompanying drawings. BRIEF DESCRIPTION OF THE DRAWINGS

[0055] In order to more clearly illustrate the technical solutions of the embodiments of the present disclosure, the drawings required for use in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present disclosure. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.

[0056] Figure 1 A flowchart of a method for dynamically balancing system loads provided in an embodiment of the present disclosure.

[0057] Figure 2 A flowchart of a method for determining a node type provided in an embodiment of the present disclosure.

[0058] Figure 3 A flowchart of a method for updating and analyzing a NUMA computing resource redundancy table and a NUMA computing overload table provided in an embodiment of the present disclosure.

[0059] Figure 4 A flowchart of a method for updating a NUMA computing resource redundancy table and a NUMA computing overload table based on an update strategy provided in an embodiment of the present disclosure.

[0060] Figure 5 A schematic diagram of the structure of a computer device provided in an embodiment of the present disclosure. DETAILED DESCRIPTION

[0061] The embodiments of the present disclosure are described in detail below with reference to the accompanying drawings.

[0062] It should be clear that the following embodiments of the present disclosure are described by specific specific examples, and those skilled in the art can easily understand other advantages and effects of the present disclosure from the contents disclosed in this specification. Obviously, the described embodiments are only a part of the embodiments of the present disclosure, rather than all of the embodiments. The present disclosure can also be implemented or applied through other different specific embodiments, and the details in this specification can also be modified or changed in various ways based on different viewpoints and applications without departing from the spirit of the present disclosure. It should be noted that the following embodiments and features in the embodiments can be combined with each other in the absence of conflict. Based on the embodiments in the present disclosure, all other embodiments obtained by ordinary technicians in the field without making creative work are within the scope of protection of the present disclosure.

[0063] It should be noted that various aspects of the embodiments within the scope of the appended claims are described below. It should be apparent that the aspects described herein may be embodied in a wide variety of forms, and any specific structure and / or function described herein is merely illustrative. Based on the present disclosure, it should be understood by those skilled in the art that an aspect described herein may be implemented independently of any other aspect, and two or more of these aspects may be combined in various ways. For example, any number of aspects described herein may be used to implement the device and / or practice the method. In addition, other structures and / or functionalities other than one or more of the aspects described herein may be used to implement this device and / or practice this method.

[0064] It should also be noted that the illustrations provided in the following embodiments are only schematic illustrations of the basic concept of the present disclosure. The drawings only show components related to the present disclosure rather than being drawn according to the number, shape and size of components in actual implementation. In actual implementation, the type, quantity and proportion of each component may be changed arbitrarily, and the component layout may also be more complicated.

[0065] Additionally, in the following description, specific details are provided to facilitate a thorough understanding of the examples. However, it will be understood by those skilled in the art that the aspects described may be practiced without these specific details.

[0066] Reference Figure 1 The present application discloses a method for dynamically balancing system loads, which is used to dynamically balance system loads in a single task in a multi-NUMA architecture, specifically comprising:

[0067] S100, obtaining real-time input capabilities and maximum processing capabilities of all NUMA nodes in the multi-NUMA architecture.

[0068] The method for acquiring the real-time input capability includes: monitoring the usage rate and memory usage of each NUMA node in real time based on a system monitoring tool to acquire the corresponding real-time input capability.

[0069] The method for obtaining the maximum processing capacity includes: when the target system is under no-load condition, performing a maximum task stress test on each NUMA node in the target system to obtain the maximum processing capacity of the NUMA node corresponding to YY+242249P.

[0070] S200, inserting a NUMA node whose real-time input capacity is not greater than the corresponding maximum processing capacity into a NUMA computing resource redundancy table;

[0071] The NUMA nodes whose real-time input capabilities are greater than the corresponding maximum processing capabilities are inserted into the NUMA calculation overload table.

[0072] Specifically, two tables are established: a NUMA computing resource redundancy table and a NUMA computing overload table; based on the comparison results of the real-time input capacity and the maximum processing capacity, the NUMA nodes are inserted into the corresponding tables. Through this step, normal nodes and overloaded nodes can be quickly distinguished, which is convenient for subsequent task allocation and processing.

[0073] S300, determining the type of node responsible for processing based on the received data packet.

[0074] specifically refer to Figure 2 , the node type determination method includes:

[0075] S310, obtaining first information of a received data packet, where the first information includes a destination IP address and a port number.

[0076] The data packet is a traffic data packet (such as a network data packet) or an event data packet (such as a log event).

[0077] S320: Determine the node type responsible for processing based on the first information and a preset mapping mechanism.

[0078] Specifically, a pre-configured mapping mechanism (such as a hash table, routing table, etc.) can be used to determine the target NUMA node responsible for processing the traffic based on the destination IP address and port number; this mapping mechanism is usually pre-configured to ensure that each IP address and port number corresponds to a specific NUMA node.

[0079] Through the preset mapping mechanism, the processing node type of the data packet can be determined quickly and accurately, improving the efficiency and accuracy of task allocation.

[0080] Furthermore, the processing requirements of the data packet can be determined by the characteristics of the data packet (such as packet size, type, priority, etc.), and the appropriate node type can be determined according to the processing requirements.

[0081] S400: If the node type exists in the NUMA computing resource redundancy table, a corresponding NUMA node in the NUMA computing resource redundancy table is called based on the node type to execute a processing instruction for the data packet.

[0082] Through this step, the resources of redundant nodes can be fully utilized, the waste of idle resources can be avoided, and the overall performance of the system can be improved.

[0083] S500: If the node type exists in the NUMA calculation overload table, a corresponding NUMA node in the NUMA calculation overload table is called based on the node type and recorded as a target node.

[0084] S600, obtaining the current real-time input capability of the target node. If the current real-time input capability is not greater than the maximum processing capability of the target node, the target node executes the processing instruction for the data packet.

[0085] Specifically, the input capacity of the target node is monitored in real time. If the real-time input capacity of the target node is within an acceptable range, the node directly processes the data packet to ensure that the overloaded node can still process tasks when the load is controllable, avoid unnecessary task redistribution, and improve processing efficiency.

[0086] S700, if the current real-time input capacity is greater than the maximum processing capacity of the target node, obtain the node with the largest difference between the maximum processing capacity and the current real-time input capacity in the NUMA computing resource redundancy table, record it as the target node, and execute the processing instruction for the data packet by the target node.

[0087] This step provides a flexible task allocation strategy. According to the comparison results of real-time input capacity and maximum processing capacity, the most suitable node is dynamically selected to process the task. This strategy not only takes into account the current load of the node, but also the maximum processing capacity of the node, so as to achieve the best balance between resource utilization and service quality. It can respond to load changes in real time and adjust the task allocation strategy as needed. This real-time response and adjustment capability enables the system to maintain high performance in the case of large load fluctuations and adapt to dynamically changing workloads.

[0088] By dynamically querying the NUMA computing resource redundancy table, the node with the strongest processing capability is found, marked as the target node, and processed by it, effectively alleviating the load of overloaded nodes, avoiding system crashes caused by node overload, and improving system stability and reliability; through automated task allocation and load balancing, manual intervention is reduced, management complexity is reduced, and management efficiency is improved.

[0089] The method for dynamically balancing system load disclosed in the present application can automatically allocate tasks according to the current load situation through real-time monitoring and dynamic adjustment to ensure load balancing of each NUMA node, which can avoid the situation where a certain node is overloaded while other nodes are idle, thereby improving the performance and efficiency of the overall system; by reallocating the tasks of the overloaded nodes to redundant nodes, system crashes or performance degradation caused by overload of a single node can be avoided, ensuring that the system can still operate normally during peak load periods, and achieving efficient and stable load balancing in a multi-NUMA architecture, which can effectively improve the performance, stability and resource utilization of the system, and is particularly suitable for high-performance computing environments that need to process large amounts of data and complex computing tasks.

[0090] By allocating tasks reasonably, the system can make full use of the resources of NUMA nodes, avoid resource waste, improve resource utilization of the entire system, and reduce operating costs. Through automated task allocation and load balancing, system administrators can reduce the need for manual intervention and simplify the management and maintenance complexity of the system, which not only reduces management costs but also reduces the possibility of human error.

[0091] Reference Figure 3 The method for dynamically balancing system load disclosed in the present application further includes updating the NUMA computing resource redundancy table and the NUMA computing overload table after determining the node type.

[0092] Analysis, including:

[0093] The time interval from the time when the node type is determined to the time when the NUMA computing resource redundancy table and the NUMA computing overload table are created;

[0094] Determine whether the time interval is greater than a preset interval threshold. If so, update the NUMA computing resource redundancy table and the NUMA computing overload table based on the update strategy, and record the updated NUMA computing resource redundancy table and the NUMA computing overload table as the target redundancy table and the target overload table;

[0095] Determine whether there is a node type in the target redundancy table. If so, call the corresponding NUMA node of the target redundancy table based on the node type to execute the processing instruction for the data packet;

[0096] If not, call the corresponding NUMA node in the target overload table based on the node type and record it as the target node;

[0097] Obtain the current real-time input capacity of the target node, and determine whether the current real-time input capacity is greater than the maximum processing capacity of the target node. If not, the target node executes the processing instruction for the data packet; if so, obtain the node with the largest difference between the maximum processing capacity and the current real-time input capacity in the target redundancy table, record it as the target node, and the target node executes the processing instruction for the data packet;

[0098] If the time interval is not greater than the preset interval threshold, no update is performed.

[0099] In this embodiment, by analyzing the time interval, the timeliness of the NUMA computing resource redundancy table and the NUMA computing overload table can be monitored to ensure that the table data used is up to date, thereby avoiding inaccurate load distribution caused by time delay.

[0100] Determine whether the time interval is greater than the preset interval threshold. If so, update the NUMA computing resource redundancy table and the NUMA computing overload table based on the update strategy, and record the updated NUMA computing resource redundancy table and the NUMA computing overload table as the target redundancy table and the target overload table, wherein the preset interval threshold can be a fixed time (usually 1 second to 1024 seconds) or a dynamically adjusted value; if the time interval is greater than the preset threshold, re-acquire the real-time input capacity and maximum processing capacity of each NUMA node; update the NUMA computing resource redundancy table and the NUMA computing overload table based on the update strategy; record the updated table as the target redundancy table and the target overload table, ensure that the table data used is the latest, avoid inaccurate load distribution caused by outdated data, update the table data in time, adapt to the dynamic changes of the system load, and improve the accuracy and efficiency of load balancing.

[0101] Determine whether the node type exists in the target redundant table. If so, call the corresponding NUMA node of the target redundant table based on the node type to execute the processing instruction of the data packet. By querying the target redundant table, check whether there is a NUMA node matching the node type. If so, call the node to execute the processing instruction of the data packet, make full use of the resources of the redundant nodes, avoid wasting idle resources, improve the overall performance of the system, quickly find the node suitable for processing, and improve the efficiency of task allocation.

[0102] If the node type does not exist in the target redundancy table, the corresponding NUMA node in the target overload table is called based on the node type and recorded as the target node. That is, if the node type does not exist in the target redundancy table, the target overload table is queried to find the matching NUMA node and mark the node as the target node. This allows timely identification of overloaded nodes, providing a basis for subsequent load balancing and task redistribution. When redundant nodes are insufficient, overloaded nodes can be flexibly selected to ensure that tasks can continue to be processed.

[0103] Get the current real-time input capacity of the target node, and determine whether the current real-time input capacity is greater than the maximum processing capacity of the target node. If not, the target node executes the processing instruction for the data packet. If so, get the node with the largest difference between the maximum processing capacity and the current real-time input capacity in the target redundancy table, record it as the target node, and let the target node execute the processing instruction for the data packet. That is, if the real-time input capacity of the target node is within an acceptable range, the data packet is directly processed by the node. If the real-time input capacity of the target node exceeds the maximum processing capacity, query the target redundancy table to find the node with the strongest processing capacity, and let it process the data packet, to ensure that the overloaded node can still process the task when the load is controllable, avoid unnecessary task redistribution, improve processing efficiency, and in the case of overload, quickly find the node with the strongest processing capacity to ensure that the task can be processed efficiently.

[0104] If the time interval is not greater than the preset threshold, continue to use the current NUMA computing resource redundancy table and NUMA computing overload table to avoid system overhead caused by frequent updates, improve system performance and stability, and maintain consistency of table data when the load does not change much, ensuring the continuity and stability of load distribution.

[0105] Through this embodiment, it is possible to ensure that the table data used is the latest, avoid inaccurate load distribution caused by expired data, improve the accuracy and efficiency of load balancing, update table data in a timely manner, adapt to dynamic changes in system load, ensure stable operation under high load conditions, make full use of the resources of redundant nodes, avoid waste of idle resources, improve the overall performance of the system, and flexibly select overloaded nodes when redundant nodes are insufficient to ensure that tasks can continue to be processed and that overloaded nodes can still process tasks when the load is controllable, avoid unnecessary task redistribution, improve processing efficiency, avoid system overhead caused by frequent updates, improve system performance and stability, and maintain consistency of table data when the load does not change much to ensure continuity and stability of load distribution.

[0106] By real-time monitoring and dynamic updating of the NUMA computing resource redundancy table and the NUMA computing overload table, this method ensures the accuracy and efficiency of load distribution. It not only improves the system's processing power and resource utilization, but also enhances the system's stability and flexibility. It is suitable for various complex high-performance computing environments.

[0107] Reference Figure 4 The method for updating the NUMA computing resource redundancy table and the NUMA computing overload table based on the update strategy specifically includes:

[0108] A100, obtain the real-time input capacity of all NUMA nodes in the NUMA computing resource redundancy table at the current moment, recorded as the first input capacity.

[0109] A200, obtain the real-time input capacity of all NUMA nodes in the NUMA computing resource overload table at the current moment, which is recorded as the second input capacity.

[0110] Through steps A100 and A200, it can be ensured that the real-time input capacity data obtained is the latest, providing an accurate basis for subsequent node status judgment, real-time monitoring of node status, and timely discovery of changes in node load.

[0111] A300, moving the NUMA node whose first input capacity is greater than the corresponding maximum processing capacity to the NUMA calculation overload table;

[0112] The NUMA nodes whose second input capacity is not greater than the corresponding maximum processing capacity are moved to the NUMA computation redundancy table.

[0113] Specifically, for NUMA nodes whose first input capacity is greater than the corresponding maximum processing capacity, they are removed from the NUMA computing resource redundancy table and added to the NUMA computing overload table. For NUMA nodes whose second input capacity is not greater than the corresponding maximum processing capacity, they are removed from the NUMA computing overload table and added to the NUMA computing redundancy table.

[0114] By dynamically adjusting the table content, we ensure that the nodes in the redundant table are truly idle or low-load nodes, and the nodes in the overload table are truly overloaded nodes. This ensures that the nodes in the redundant table can fully utilize their processing capabilities, and the nodes in the overload table can get task reallocation in time. By dynamically adjusting the node status, we can improve the overall processing capability and response speed of the system, adapt to the dynamic changes in load, ensure that tasks can be assigned to the most suitable nodes, avoid performance bottlenecks caused by uneven load, ensure the accuracy of the table content, and avoid task allocation errors caused by confusion between overloaded nodes and redundant nodes.

[0115] For example, a big data computing platform device has 4 NUMA nodes, each NUMA node has n CPUs; the system has 32 slots, each NUMA takes over a different number of slots, NUMA0 takes over 4 slots, NUMA1 takes over 6 slots, NUMA2 takes over 8 slots, NUMA3 takes over 14 slots, and each slot has a Gigabit, 10 Gigabit or 100 Gigabit interface. The system runs a single task: data unit analysis and forwarding.

[0116] After starting the running system, if the traffic is handled by a node in the NUMA computing resource redundancy table, it is directly processed; if the traffic is handled by a node in the NUMA computing overload table, check whether the maximum processing capacity of the corresponding node in the NUMA computing overload table is greater than the real-time input capacity. If so, the NUMA processes the traffic; otherwise, search the NUMA computing resource redundancy table for the NUMA node with the largest difference between the maximum processing capacity and the real-time input capacity, and the found node will process the traffic.

[0117] For example: NUMA0's maximum processing capacity is 70G / s, and its real-time input capacity is 80G / s (8 10G interfaces). The NUMA0 node information is inserted into the NUMA computing overload table. The table entry information includes: name NUMA0; the difference between the maximum processing capacity and the real-time input capacity is NG; NUMA1's maximum processing capacity is 30G / s, and its real-time input capacity is 20G / s (2 10G interfaces). The NUMA1 node information is inserted into the NUMA computing resource redundancy table. The table entry information includes: name NUMA1, the difference between the maximum processing capacity and the real-time input capacity is MG.

[0118] The NG (i.e., non-positive difference between maximum processing capability and real-time input capability) and MG (i.e., positive difference between maximum processing capability and real-time input capability) values ​​of the NUMA computing resource redundancy table and the NUMA computing overload table may be updated periodically through a timer.

[0119] Different from the traditional static load balancing strategy, the solution disclosed in this application not only distributes the load based on the maximum processing capacity of the node, but also dynamically adjusts the processing nodes by real-time monitoring of traffic and system status. This method avoids the resource waste and performance bottleneck caused by static configuration, ensures that each NUMA node can function within its maximum capacity, thereby improving the overall flexibility and reliability of the system.

[0120] In a second aspect, the embodiment of the present disclosure further provides a system for dynamically balancing system loads, including:

[0121] Capacity acquisition module, used to obtain the real-time input capacity and maximum processing capacity of all NUMA nodes in the multi-NUMA architecture;

[0122] A classification module, used for inserting NUMA nodes whose real-time input capacity is not greater than the corresponding maximum processing capacity into the NUMA computing resource redundancy table;

[0123] Inserting NUMA nodes whose real-time input capacity is greater than the corresponding maximum processing capacity into the NUMA calculation overload table;

[0124] A determination module, for determining the type of node responsible for processing based on the received data packet;

[0125] A dynamic adjustment module is used to call a corresponding NUMA node in the NUMA computing resource redundancy table based on the node type when there is a node type in the NUMA computing resource redundancy table, and execute a processing instruction for the data packet;

[0126] If there is a node type in the NUMA calculation overload table, the corresponding NUMA node in the NUMA calculation overload table is called based on the node type and recorded as the target node;

[0127] The current real-time input capacity of the target node is obtained, and it is determined whether the current real-time input capacity is greater than the maximum processing capacity of the target node. If not, the target node executes the processing instruction for the data packet; if so, the node with the largest difference between the maximum processing capacity and the current real-time input capacity in the NUMA computing resource redundancy table is obtained, recorded as the target node, and the target node executes the processing instruction for the data packet.

[0128] It should be noted that the solutions in the method for dynamically balancing system loads disclosed in the first aspect of the embodiments of the present disclosure are all applicable to the acquisition of the solutions in the system for dynamically balancing system loads provided in the second aspect of the embodiments of the present disclosure, so they will not be repeated here.

[0129] In another embodiment, the present application discloses a method for dynamically balancing system loads, comprising:

[0130] S10, obtaining the maximum input capacity and the maximum processing capacity of all NUMA nodes in the multi-NUMA architecture.

[0131] The method for obtaining the maximum input capacity includes: obtaining the maximum processing capacity of each NUMA node in the target system based on a performance testing tool when the target system is under full load.

[0132] The input capacity upper limit threshold usually refers to the maximum data traffic that a node can receive, including network traffic and storage I / O traffic. Determining this threshold can help the system avoid node overload when processing large amounts of data.

[0133] S20, inserting a NUMA node whose maximum input capacity is not greater than the corresponding maximum processing capacity into the NUMA computing resource redundancy table;

[0134] The NUMA nodes whose maximum input capacity is greater than the corresponding maximum processing capacity are inserted into the NUMA calculation overload table.

[0135] Through simple comparison, NUMA nodes are divided into redundant nodes and overloaded nodes, providing a preliminary classification basis for subsequent task allocation, ensuring that the nodes in the redundant table can still process tasks when the load is low, and the nodes in the overload table can be monitored and adjusted in time.

[0136] S30, determining the type of node responsible for processing based on the received data packet.

[0137] S40: If the node type exists in the NUMA computing resource redundancy table, a corresponding NUMA node in the NUMA computing resource redundancy table is called based on the node type to execute a processing instruction for the data packet.

[0138] S50, if the node type exists in the NUMA calculation overload table, call the corresponding NUMA node in the NUMA calculation overload table based on the node type and record it as the target node;

[0139] The real-time input capacity of the target node is obtained, and it is determined whether the real-time input capacity is greater than the maximum processing capacity of the target node. If not, the target node executes the processing instruction for the data packet; if so, the node with the largest difference between the maximum processing capacity and the maximum input capacity in the NUMA computing resource redundancy table is obtained and recorded as the target node, and the target node executes the processing instruction for the data packet.

[0140] Quickly determine the processing requirements of data packets and improve the efficiency of task allocation. According to the destination IP address and port number of the data packet, data packets of similar service types can be allocated to the same node, which is convenient for service management and optimization. It can make full use of the resources of redundant nodes, avoid the waste of idle resources, improve the overall performance of the system, quickly find nodes suitable for processing, and improve the efficiency of task allocation. Query the NUMA computing overload table to check whether there is a NUMA node that matches the node type. If so, mark the node as the target node and monitor the input capacity of the target node in real time. If the real-time input capacity of the target node is within an acceptable range, the data packet will be directly processed by the node. If the real-time input capacity of the target node exceeds the maximum processing capacity, query the NUMA computing resource redundancy table to find the node with the strongest processing capacity and YY+242249P

[0141] It processes the data packets.

[0142] Through steps S30-S50, overloaded nodes can be identified in time, providing a basis for subsequent load balancing and task redistribution. When redundant nodes are insufficient, overloaded nodes can be flexibly selected to ensure that tasks can continue to be processed and that overloaded nodes can still process tasks when the load is controllable, avoiding unnecessary task redistribution and improving processing efficiency. In the event of an overload, the node with the strongest processing capability can be quickly found to ensure that tasks can be processed efficiently.

[0143] The computer device according to the embodiment of the present disclosure includes a memory and a processor. The memory is used to store non-temporary computer-readable instructions. Specifically, the memory may include one or more computer program products, and the computer program product may include various forms of computer-readable storage media, such as volatile memory and / or non-volatile memory. The volatile memory may, for example, include a random access memory (RAM) and / or a cache memory (cache), etc. The non-volatile memory may, for example, include a read-only memory (ROM), a hard disk, a flash memory, etc.

[0144] The processor may be a central processing unit (CPU) or other forms of processing units with data processing capabilities and / or instruction execution capabilities, and may control other components in the computer device to perform desired functions. In one embodiment of the present disclosure, the processor is used to run the computer-readable instructions stored in the memory, so that the computer device performs all or part of the steps of the method for dynamically balancing system loads in the aforementioned embodiments of the present disclosure.

[0145] Those skilled in the art should be able to understand that in order to solve the technical problem of how to obtain a good user experience, the present embodiment may also include well-known structures such as a communication bus and an interface, and these well-known structures should also be included in the protection scope of the present disclosure.

[0146] like Figure 5 A schematic diagram of the structure of a computer device provided in an embodiment of the present disclosure is shown, which is a schematic diagram of the structure of a computer device suitable for implementing the embodiment of the present disclosure. Figure 5 The computer device shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present disclosure.

[0147] like Figure 5 As shown, the computer device may include a processor (e.g., a central processing unit, a graphics processing unit, etc.), which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) or a program loaded from a storage device into a random access memory (RAM). In the RAM, various programs and data required for the operation of the computer device are also stored. The processor, ROM, and RAM are connected to each other via a bus. An input / output (I / O) interface is also connected to the bus.

[0148] Typically, the following devices can be connected to the I / O interface: input devices such as sensors or visual information acquisition devices; output devices such as display screens; storage devices such as tapes, hard disks, etc.; and communication devices. The communication device can allow the computer device to communicate with other devices (such as edge computing devices) wirelessly or by wire to exchange data. Figure 5A computer device having various devices is shown, but it should be understood that it is not required to implement or possess all of the devices shown. More or fewer devices may be implemented or possessed instead.

[0149] In particular, according to an embodiment of the present disclosure, the process described above with reference to the flowchart can be implemented as a computer software program. For example, an embodiment of the present disclosure includes a computer program product, which includes a computer program carried on a non-transitory computer-readable medium, and the computer program contains program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from a network through a communication device, or installed from a storage device, or installed from a ROM. When the computer program is executed by a processor, all or part of the steps of the method for dynamically balancing system loads of an embodiment of the present disclosure are executed.

[0150] For detailed description of this embodiment, reference may be made to the corresponding descriptions in the aforementioned embodiments, which will not be repeated here.

[0151] According to the computer-readable storage medium of the embodiment of the present disclosure, non-transitory computer-readable instructions are stored thereon. When the non-transitory computer-readable instructions are executed by a processor, all or part of the steps of the method for dynamically balancing system loads of the above-mentioned embodiments of the present disclosure are executed.

[0152] The above-mentioned computer-readable storage media include, but are not limited to: optical storage media (e.g., CD-ROM and DVD), magneto-optical storage media (e.g., MO), magnetic storage media (e.g., magnetic tape or mobile hard disk), media with built-in rewritable non-volatile memory (e.g., memory card) and media with built-in ROM (e.g., ROM box).

[0153] For detailed description of this embodiment, reference may be made to the corresponding descriptions in the aforementioned embodiments, which will not be repeated here.

[0154] The basic principles of the present disclosure are described above in conjunction with specific embodiments. However, it should be noted that the advantages, strengths, effects, etc. mentioned in the present disclosure are only examples and not limitations, and it cannot be considered that these advantages, strengths, effects, etc. are required by each embodiment of the present disclosure. In addition, the specific details disclosed above are only for the purpose of illustration and ease of understanding, and are not limitations. The above details do not limit the present disclosure to the necessity of adopting the above specific details to be implemented.

[0155] In the present disclosure, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply that there is any such actual relationship or order between these entities or operations. The block diagrams of the devices, devices, equipment, and systems involved in the present disclosure are only illustrative examples and are not intended to require or imply that they must be connected, arranged, and configured in the manner shown in the block diagram. As will be appreciated by those skilled in the art, these devices, devices, equipment, and systems can be connected, arranged, and configured in any manner. Words such as "including", "comprising", "having", etc. are open words, referring to "including but not limited to", and can be used interchangeably with them. The words "or" and "and" used here refer to the words "and / or" and can be used interchangeably with them, unless the context clearly indicates otherwise. The words "such as" used here refer to the phrase "such as but not limited to", and can be used interchangeably with them.

[0156] Additionally, as used herein, "or" used in a list of items beginning with "at least one" indicates a separate list, so that, for example, a list of "at least one of A, B, or C" means A or B or C, or AB or AC or BC, or ABC (i.e., A and B and C). Furthermore, the word "exemplary" does not mean that the example described is preferred or better than other examples.

[0157] It should also be noted that in the system and method of the present disclosure, each component or each step can be decomposed and / or recombined. Such decomposition and / or recombination should be regarded as equivalent solutions of the present disclosure.

[0158] Various changes, substitutions, and modifications of the techniques described herein may be made without departing from the teachings defined by the appended claims. Furthermore, the scope of the claims of the present disclosure is not limited to the specific aspects of the processes, machines, manufactures, compositions of events, means, methods, and actions described above. Currently existing or later to be developed processes, machines, manufactures, compositions of events, means, methods, or actions that perform substantially the same functions or achieve substantially the same results as the corresponding aspects described herein may be utilized. Thus, the appended claims include such processes, machines, manufactures, compositions of events, means, methods, or actions within their scope.

[0159] The above description of the disclosed aspects is provided to enable any person skilled in the art to make or use the present disclosure. Various modifications to these aspects will be readily apparent to those skilled in the art, and the general principles defined herein may be applied to other aspects without departing from the scope of the present disclosure. Therefore, the present disclosure is not intended to be limited to the aspects shown herein, but rather to the widest scope consistent with the principles and novel features disclosed herein.

[0160] The above description has been given for the purpose of illustration and description. In addition, this description is not intended to limit the embodiments of the present disclosure to the forms disclosed herein. Although multiple example aspects and embodiments have been discussed above, those skilled in the art will recognize certain variations, modifications, changes, additions and sub-combinations thereof.

Claims

1. A method for dynamically balancing system load, characterized in that: include: Get key information of all NUMA nodes in a multi-NUMA architecture; The key information includes real-time input capability and maximum processing capability; If the key information meets the preset conditions, the NUMA node is stored in the redundancy table, otherwise, it is stored in the overload table; Based on the received data packet, determining a node type responsible for processing the data packet; If the node type does not exist in the redundant table, calling the corresponding NUMA node in the overload table as the target node based on the node type; If the real-time input capability of the target node is greater than the corresponding maximum processing capability, the node with the largest difference between the maximum processing capability and the current real-time input capability in the redundant table executes the processing instruction for the data packet; If the real-time input capability of the target node is not greater than the corresponding maximum processing capability, the target node executes the processing instruction for the data packet.

2. The method for dynamically balancing system load according to claim 1, characterized in that: If the key information meets the preset condition, the NUMA node is stored in the redundancy table, otherwise, it is stored in the overload table, which specifically includes: Storing NUMA nodes whose real-time input capacity is not greater than the corresponding maximum processing capacity into a redundancy table; The NUMA nodes whose real-time input capabilities are greater than the corresponding maximum processing capabilities are stored in the overload table.

3. The method for dynamically balancing system load according to claim 2, characterized in that: The method for obtaining the maximum processing capacity includes: when the target system is under a no-load condition, performing a maximum task stress test on each NUMA node in the target system to obtain the maximum processing capacity of the corresponding NUMA node.

4. The method for dynamically balancing system load according to claim 1, characterized in that: The determining, based on the received data packet, the type of node responsible for processing the data packet comprises: Acquire first information of the received data packet, the first information including a destination IP address and a port number; Based on the first information and the preset mapping mechanism, the node type responsible for processing is determined.

5. The method for dynamically balancing system load according to claim 4, characterized in that: After determining the node type, the following steps are also included: Acquire the time interval from the determination time of the node type to the creation time of the redundant table and the overload table; When the time interval is greater than a preset interval threshold, the redundant table and the overload table are updated.

6. The method for dynamically balancing system load according to claim 5, characterized in that: The updating of the redundant table and the overload table based on the update strategy includes: Obtain the real-time input capacity of all NUMA nodes in the redundant table at the current moment, recorded as the first input capacity; Obtaining the real-time input capacity of all NUMA nodes in the NUMA computing resource overload table at the current moment, recorded as the second input capacity; Move the NUMA node whose first input capacity is greater than the corresponding maximum processing capacity to the overload table; The NUMA nodes whose second input capacity is not greater than the corresponding maximum processing capacity are moved to the NUMA computation redundancy table.

7. The method for dynamically balancing system load according to claim 1, characterized in that: The method for acquiring the real-time input capability includes: monitoring the usage rate and memory usage of each NUMA node in real time based on a system monitoring tool to acquire the corresponding real-time input capability.

8. The method for dynamically balancing system load according to claim 1, characterized in that: If the node type exists in the redundant table, the corresponding NUMA node of the redundant table is called based on the node type to execute the processing instruction for the data packet.

9. A method for dynamically balancing system load, characterized in that: include: Get the maximum input capacity and maximum processing capacity of all NUMA nodes in a multi-NUMA architecture; Inserting the NUMA node whose maximum input capacity is not greater than the corresponding maximum processing capacity into the redundancy table; inserting the NUMA node whose maximum input capacity is greater than the corresponding maximum processing capacity into the overload table; Based on the received data packet, determine the node type responsible for processing; If the node type exists in the redundant table, calling the corresponding NUMA node of the redundant table based on the node type to execute a processing instruction for the data packet; If the node type exists in the overload table, the corresponding NUMA node in the overload table is called based on the node type and recorded as the target node; Acquire the real-time input capability of the target node, determine whether the real-time input capability is greater than the maximum processing capability of the target node, and if not, execute the processing instruction of the data packet by the target node; If so, the node with the largest difference between the maximum processing capacity and the maximum input capacity in the redundant table is obtained and recorded as the target node, and the target node executes the processing instruction for the data packet.

10. A computer device, characterized in that: The computer device comprises: at least one processor; and, a memory communicatively connected to the at least one processor; wherein, The memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute the method for dynamically balancing system loads described in any one of claims 1 to 8 or claim 9.

11. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer instructions, and the computer instructions are used to enable a computer to execute the method for dynamically balancing system loads as described in any one of claims 1 to 8 or claim 9.

12. A computer program product comprising computer instructions, characterized in that: When the computer instructions are executed by a processor, the steps of any one of claims 1 to 8 or the method described in claim 9 are implemented.

Citation Information

Patent Citations

  • Method for cluster load balance and system thereof

    CN103327072A

  • Micro-service dynamic adaptive client load balancing method and system

    CN117155942A

  • Adaptive communication link optimization method based on Internet of Things

    CN118827718A

  • Water-saving eco toilet

    KR1020220082699A

  • Load balancing among multiple endpoint computing systems of a domain

    US20200162385A1