Container load balancing scheduling method based on edge computing environment

By using intelligent scheduling methods with simulated annealing algorithm and load prediction model in edge computing environments, the problems of uneven load and insufficient adaptability in container scheduling are solved, and efficient resource allocation and system performance improvement are achieved.

CN119883514APending Publication Date: 2025-04-25EAST CHINA INST OF COMPUTING TECH
View PDF 0 Cites 2 Cited by

Patent Information

Application Number
CN202411967743.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-30
Publication Date
2025-04-25

Smart Images

  • Figure CN119883514A_ABST
    Figure CN119883514A_ABST
Patent Text Reader

Abstract

The invention provides a container load balancing scheduling method based on an edge computing environment, which mainly comprises the steps of resource allocation of a container and load balancing among multiple computing nodes, research on a load balancing scheduling strategy based on a simulated annealing algorithm according to the load balancing requirements of the multiple computing nodes, and dynamic resource allocation and priority scheduling methods are combined. The method supports efficient resource allocation and dynamic task scheduling, solves the problems of unbalanced scheduling results and untimely response of a traditional scheduling algorithm in the existing scheduling technology, and gives full play to the performance advantages of a load balancing algorithm in an embedded system. By introducing the scheduling technology, real-time allocation of different task requests is realized, so that a system can still keep relatively short response time and more balanced resource consumption in a resource constraint scene, and effective support is provided for efficient scheduling of containers in an embedded environment.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of resource allocation and scheduling, and in particular to a container load balancing scheduling method based on an edge computing environment. Background Art

[0002] As the application demand for edge computing continues to grow, traditional embedded operating systems are facing more and more challenges, especially in terms of the efficiency and flexibility of resource management and task scheduling. To solve these problems, Ruihua Container Operating System optimizes the multi-core processing architecture, realizes efficient multi-core real-time scheduling, multi-core task synchronization mechanism and perfect memory protection mechanism, and effectively responds to the challenges of efficiency and flexibility of resource management and task scheduling brought about by the continuous growth of application scale. Ruihua Container Operating System supports containers through lightweight extensions. The management and resource isolation of container instances not only simplifies the task deployment process, but also provides good system isolation and security.

[0003] Ruihua Container Operating System adds support for OCI-compliant containers based on the traditional real-time process operating system, and uses a lightweight extension method to achieve resource isolation, management and monitoring of container instances. Its architecture is modular, configurable and resource-sharing.

[0004] Ruihua Container Operating System manages the parallel execution of tasks on different nodes by combining the global ready queue and affinity ready queue methods, while providing support for container operation and realizing lifecycle management functions such as container creation, start, pause, resume, and delete. In addition, the system also provides a hybrid mechanism of real-time scheduling and non-real-time scheduling to meet the needs of various types of tasks. In the current system, critical tasks are preferentially assigned to real-time containers with high-priority preemption strategies, while ordinary tasks are executed at a lower priority in non-real-time containers, forming a hybrid critical scheduling mode.

[0005] Although the above technologies have achieved certain results in container management and scheduling, since the core idea of ​​the above scheduling technology is a static scheduling algorithm based on list scheduling, there are inevitable defects in the actual application process.

[0006] a) Load balancing issues

[0007] Current container scheduling mainly relies on the combination of global ready queues and affinity ready queues for task management, but this scheduling mechanism still faces the problem of uneven load in multi-core edge computing environments. Since the core idea of ​​this scheduling technology is based on static queue scheduling, the system lacks an effective global load perception mechanism for scheduling containers and tasks. When some processors are over-occupied and other processors are relatively idle, the system cannot reasonably and evenly distribute tasks, resulting in low resource utilization and reduced overall system performance.

[0008] b) Poor adaptability

[0009] The task requirements in edge computing are highly uncertain and dynamic. For example, the tasks of drones will be dynamically adjusted according to real-time reconnaissance results. The existing scheduling mechanism lacks adaptive adjustment capabilities in the face of such dynamic changes. It is unable to reconfigure resources in real time according to changes in task load and system status, resulting in reduced task execution efficiency and difficulty in coping with unpredictable scenarios in edge computing environments.

[0010] It can be summarized into the following two points:

[0011] Lack of dynamic load perception capability: In the existing scheduling mechanism, static task priorities and predefined affinity queues are difficult to reflect the dynamic load conditions of tasks, making it difficult to make reasonable adjustments to the scheduling strategy when the load changes.

[0012] Insufficient response to dynamic changes: The scheduling algorithm does not fully consider the dynamic changes in task requirements, and therefore has obvious deficiencies in dynamic adjustment and adaptability.

[0013] In summary, the current scheduling based on sharpened containers is mainly due to the limitations of static scheduling strategies, which leads to the existing scheduling mechanism being overly dependent on static priorities and predefined affinity queues, lacking the ability to monitor and adaptively adjust task load conditions in real time, ultimately leading to an unbalanced system load. In addition, the existing scheduling method assumes that task requirements are relatively fixed, and therefore lacks flexible scheduling reconfiguration capabilities when facing environmental changes. Summary of the invention

[0014] The purpose of the technical solution of the present invention is to achieve efficient container orchestration and resource scheduling under resource-constrained and dependency-constrained conditions through intelligent optimization algorithms.

[0015] The technical solution of the present invention provides a container load balancing scheduling method based on an edge computing environment, comprising the following steps:

[0016] Obtain resource requirements, execution latency, processing nodes, and node loads for multiple containers;

[0017] Based on the execution delay and time series, the future load of each node is predicted according to the processing nodes and node load;

[0018] Perform task demand analysis on resource requirements and monitor node resources, allocate and map tasks according to processing nodes and node loads to obtain the current load status, and generate the current mapping scheme for initial container and node mapping;

[0019] By randomly exchanging the scheduling nodes of the container, a neighborhood solution search is performed on the current mapping solution to obtain a neighborhood solution mapping solution;

[0020] According to the standard deviation of the node load and the average power consumption of all nodes, the target values ​​of the current mapping scheme and the neighborhood demapping scheme are calculated respectively. According to the acceptance criterion formula, it is judged whether the target value of the neighborhood demapping scheme is better than the target value of the current mapping scheme. If so, the target value of the neighborhood demapping scheme is accepted as the current optimal solution. If not, the target value of the neighborhood demapping scheme is accepted as the current inferior solution under the preset probability.

[0021] The initial cooling rate is determined according to the current optimal solution, and the initial cooling is performed and the container scheduling is adjusted. The initial cooling rate is used as the basic rate and combined with the number of iterations and Gaussian distribution to determine the subsequent cooling rate. Iterative cooling is performed according to the subsequent cooling rate to achieve gradual adjustment of container scheduling, so that the global search load gradually converges and stabilizes to the local load optimality, realizing global container load balancing scheduling.

[0022] Preferably, the formula for the future load condition of each node is as follows:

[0023]

[0024] Among them, L i (t) represents the current load of processing node i at time t, It represents the average load in a certain period of time in the past, and α is the smoothing coefficient used to control the weight relationship between the current load and the historical load.

[0025] Preferably, the target value formula of the current mapping scheme is as follows:

[0026] f(S)=w 1 ·σ L +w 2 ·P avg

[0027] Among them, σ L is the standard deviation of the load of each node, indicating load balancing; P avg is the average power consumption of all computing nodes; w 1 and w 2 are different weight coefficients.

[0028] Preferably, the preset probability formula is as follows:

[0029]

[0030] Where T is the current temperature that decreases with the number of iterations, f(S) is the target value of the current mapping scheme, and f(S ′ ) is the target value of the neighborhood demapping scheme.

[0031] Preferably, the subsequent cooling rate corresponding to the middle stage of the iterative cooling increases compared to the early stage of the iterative cooling, and the subsequent cooling rate corresponding to the late stage of the iterative cooling tends to be relatively stable.

[0032] Preferably, the subsequent cooling rate formula is as follows:

[0033]

[0034] Among them, σ is the variance of the Gaussian distribution, μ is the mean of the Gaussian distribution, and Iter is the number of iterations.

[0035] The technical solution of the present invention proposes a container load balancing scheduling method based on an edge computing environment, which mainly includes resource allocation of containers and load balancing among multiple computing nodes. Focusing on the load balancing requirements of multiple computing nodes, the load balancing scheduling strategy based on the simulated annealing algorithm is studied, and the dynamic resource allocation and priority scheduling methods are combined to support efficient resource allocation and dynamic task scheduling, solving the problems of unbalanced scheduling results and untimely response of traditional scheduling algorithms in existing scheduling technologies, and giving full play to the performance advantages of load balancing algorithms in embedded systems. By introducing this scheduling technology, real-time allocation of different task requests is realized, so that the system can still maintain a low response time and more balanced resource consumption in resource constraint scenarios, thereby providing effective support for efficient scheduling of containers in embedded environments. BRIEF DESCRIPTION OF THE DRAWINGS

[0036] Figure 1 A scheduling framework for a container load balancing scheduling method based on an edge computing environment provided in an embodiment of the present invention;

[0037] Figure 2 An overall flow chart of a container load balancing scheduling method based on an edge computing environment provided by an embodiment of the present invention;

[0038] Figure 3 A flowchart of the scheduling part of a container load balancing scheduling method based on an edge computing environment provided by an embodiment of the present invention;

[0039] Figure 4A schematic diagram of the performance analysis and experimental verification results of a container load balancing scheduling method based on an edge computing environment provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0040] The present invention will be further described below in conjunction with specific embodiments. It should be understood that these embodiments are only used to illustrate the present invention and are not intended to limit the scope of the present invention. In addition, it should be understood that after reading the content taught by the present invention, those skilled in the art can make various changes or modifications to the present invention, and these equivalent forms fall within the scope limited by the appended claims of the application equally.

[0041] The embodiment of the present invention provides a container load balancing scheduling method based on an edge computing environment. Based on the Ruihua container operating system and combined with the real-time characteristics of the embedded operating system, the method realizes the dynamic balancing of scheduling tasks among multiple processing nodes through an intelligent optimization algorithm, and effectively solves the problems of uneven load and insufficient adaptability in the existing container scheduling technology. The specific technical solution is as follows:

[0042] 1. Construction of embedded operating system and container scheduling framework

[0043] The present invention is based on the Ruihua container operating system and makes full use of the characteristics of embedded systems, especially its advantages in real-time, resource management and security. Ruihua operating system supports multi-computing node SMP parallel processing architecture, and can manage tasks executed in parallel on different computing nodes through a scheduling method combining global ready queues and affinity ready queues.

[0044] In order to achieve efficient scheduling of container tasks, the present invention constructs a new scheduling framework based on the Ruihua container operating system. Figure 1 As shown in the figure, the working steps of the scheduling scheme are as follows Figure 2 The core functions and innovations are as follows:

[0045] Monitor and analyze container tasks to determine the resource requirements, execution time, and execution latency of each container.

[0046] An improved simulated annealing algorithm is introduced to dynamically adjust the mapping relationship between containers and multi-processing nodes to ensure system load balancing and optimize overall performance.

[0047] By utilizing the modular design of the embedded operating system, it supports resource isolation and task scheduling priority setting between containers, ensuring the stability and real-time performance of the system under high load conditions.

[0048] 2. Scheduling algorithm design and implementation

[0049] In order to solve the problems of load imbalance and poor adaptability in the existing scheduling methods, the present invention combines the multi-core scheduling mechanism of Ruihua operating system and proposes an intelligent scheduling algorithm based on the combination of simulated annealing algorithm and load prediction model to achieve the purpose of dynamic load balancing. The scheduling algorithm flow chart is as follows: Figure 3 shown.

[0050] 1. Load Forecasting Model

[0051] The load forecasting model is used to predict the amount of tasks for each processing node in the system to improve the accuracy of scheduling decisions. The load forecasting model is based on the time series forecasting method and calculates the future load of each node through the following formula:

[0052]

[0053] Among them, L i (t) represents the current load of processing node i at time t, It represents the average load in a certain period of time in the past. α is the smoothing coefficient, which is used to control the weight relationship between the current load and the historical load.

[0054] 2. Improved simulated annealing scheduling algorithm

[0055] In order to avoid falling into the local optimum, the simulated annealing algorithm is used to optimize the container scheduling. The simulated annealing algorithm simulates the process of material annealing and gradually reduces the temperature to achieve the effect of the lowest energy state of the system. The "energy" in the scheduling problem is the imbalance of the system. The steps of the algorithm are as follows:

[0056] 1) Initial solution generation: Generate an initial container and node mapping solution based on the current system load status, denoted as S 0 .

[0057] 2) Neighborhood solution search: Based on the current solution S, generate a neighborhood solution S by randomly exchanging the scheduling nodes of the container ′ .

[0058] 3) Objective function calculation: Calculate the target values ​​of the current solution and the neighboring solution, using load balancing and minimum scheduling time as the objective function. The objective function form is as follows:

[0059] f(S)=w 1 ·σ L +w 2 ·P avg

[0060] Among them, σ L is the standard deviation of the load of each node, indicating load balancing; P avg is the average power consumption of all computing nodes in the system; w 1 and w2 are different weight coefficients.

[0061] 4) Acceptance criterion: Based on the acceptance criterion of simulated annealing, when the new solution is better than the current solution, the solution is directly accepted; otherwise, the inferior solution is accepted with a certain probability, and its probability is:

[0062]

[0063] Among them, T is the current temperature, which gradually decreases with the number of iterations.

[0064] 5) Temperature update: By gradually lowering the temperature, the algorithm can converge from global search to local optimum. The temperature update rules are as follows:

[0065] T k+1 =β·T k

[0066] Where β is the cooling rate.

[0067] This paper also improves the cooling rate update. In the traditional simulated annealing algorithm, the cooling rate coefficient β is usually a constant, and its value has an impact on the efficiency of the algorithm. If the value is too large, it will affect the convergence of the algorithm, and if the value is too small, it will easily fall into the local optimal solution. Therefore, this paper improves the cooling rate β, and adopts the method in which β is Gaussian distributed with the number of iterations. In the early stage of the iteration, β is small, and the search can be performed according to the initial cooling rate level. In the middle of the iteration, the β value increases, and the cooling rate is accelerated, which can expand the solution space, facilitate global search, and prevent falling into the local optimal solution. At the end of the iteration, the optimal solution has stabilized. In order to speed up the convergence rate of the algorithm, the β value is reduced to speed up the convergence rate of the algorithm.

[0068]

[0069] Through the above-mentioned improved intelligent scheduling algorithm, the system can timely reallocate container tasks when the load changes to achieve global load balancing.

[0070] 3. Theoretical analysis and performance verification

[0071] In order to verify the effectiveness of the present invention, the system performance was analyzed and experimentally verified. The results are as follows: Figure 4 The experimental results show that after adopting the intelligent scheduling algorithm proposed in the present invention, the system has obvious improvements in load balancing. At the same time, thanks to the improvement in load balancing, the system has also achieved certain optimization in power consumption, reducing the sum of power consumption of computing nodes. Especially in the edge computing environment with multiple processing nodes, compared with the traditional scheduling method, this solution performs better in the following aspects:

[0072] Load balancing: by standard deviation σ LThrough calculation, it is found that the load balancing of the system is significantly improved and the utilization of processing nodes is more balanced.

[0073] Power consumption: after adopting the scheduling method of the present invention, since load balancing is achieved, it is possible to avoid excessive power consumption on nodes caused by unbalanced deployment, and the sum P of the power consumption of each computing node is significantly reduced.

[0074] System adaptability: The system can perform real-time resource reconfiguration according to dynamic changes in task load, improving the overall system response speed and resource utilization.

[0075] The container load balancing scheduling method based on the edge computing environment provided by the embodiment of the present invention has significant advantages and technical effects by combining the characteristics of Ruihua container operating system and intelligent scheduling algorithm. The beneficial effects compared with the prior art are as follows:

[0076] 1. Effectively solve the problem of uneven load.

[0077] Traditional container scheduling methods often face the problem of uneven resource allocation when dealing with load balancing of multi-computing node systems, especially in edge computing environments, where some nodes are overloaded while other nodes are idle, resulting in resource waste and low scheduling efficiency. The present invention introduces a load prediction model and uses time series analysis to accurately predict the load of each processing node, thereby adjusting the task allocation and scheduling strategy in advance. The load prediction model can provide a dynamic adjustment basis for the load changes of each processing node and optimize the task scheduling process. Combined with the simulated annealing algorithm, the system can optimize the mapping relationship between containers and processing nodes on a global scale, effectively avoid uneven load, and ensure that system resources are fully utilized.

[0078] Through load prediction and scheduling adjustment, the present invention can achieve load balancing of each processing node, so that computing resources are used more efficiently, the overall system performance is improved, and the delay of task scheduling is reduced.

[0079] 2. Adaptive task scheduling and dynamic resource reconfiguration.

[0080] In an edge computing environment, the load and demand of tasks often change dynamically. Existing scheduling methods usually assume that the task load is static and lack the ability to respond to load changes in real time. The present invention combines the simulated annealing algorithm with the load prediction model, and can automatically adjust the mapping relationship between containers and processing nodes according to changes in system status and dynamic fluctuations in task requirements. This feature enables the present invention to effectively cope with unpredictable workload changes in edge computing and avoid resource waste or untimely scheduling problems caused by task load fluctuations.

[0081] The embodiments of the present invention realize real-time adaptation and resource reconfiguration of the system to changes in task load, improve the flexibility and adaptability of the system, ensure the continuity and stability of task execution, and are particularly suitable for complex and dynamic application scenarios in edge computing.

Claims

1. A container load balancing scheduling method based on edge computing environment, characterized in that: The following steps are involved: Obtain resource requirements, execution latency, processing nodes, and node loads for multiple containers; Based on the execution delay and time series, the future load of each node is predicted according to the processing nodes and node load; Perform task demand analysis on resource requirements and monitor node resources, allocate and map tasks according to processing nodes and node loads to obtain the current load status, and generate the current mapping scheme for initial container and node mapping; By randomly exchanging the scheduling nodes of the container, a neighborhood solution search is performed on the current mapping solution to obtain a neighborhood solution mapping solution; According to the standard deviation of the node load and the average power consumption of all nodes, the target values ​​of the current mapping scheme and the neighborhood demapping scheme are calculated respectively. According to the acceptance criterion formula, it is judged whether the target value of the neighborhood demapping scheme is better than the target value of the current mapping scheme. If so, the target value of the neighborhood demapping scheme is accepted as the current optimal solution. If not, the target value of the neighborhood demapping scheme is accepted as the current inferior solution under the preset probability. The initial cooling rate is determined according to the current optimal solution, and the initial cooling is performed and the container scheduling is adjusted. The initial cooling rate is used as the basic rate and combined with the number of iterations and Gaussian distribution to determine the subsequent cooling rate. Iterative cooling is performed according to the subsequent cooling rate to achieve gradual adjustment of container scheduling, so that the global search load gradually converges and stabilizes to the local load optimality, realizing global container load balancing scheduling.

2. A container load balancing scheduling method based on edge computing environment as claimed in claim 1, characterized in that: The formula for the future load condition of each node is as follows: Among them, L i (t) represents the current load of processing node i at time t, It represents the average load in a certain period of time in the past, and α is the smoothing coefficient used to control the weight relationship between the current load and the historical load.

3. A container load balancing scheduling method based on edge computing environment as claimed in claim 1, characterized in that: The target value formula of the current mapping scheme is as follows: f(S)=w1·σ L +w2·P avg Among them, σ L is the standard deviation of the load of each node, indicating load balancing; P avg is the average power consumption of all computing nodes; w1 and w2 are different weight coefficients.

4. A container load balancing scheduling method based on edge computing environment as claimed in claim 1, characterized in that: The preset probability formula is as follows: Where T is the current temperature that gradually decreases with the number of iterations, f(S) is the target value of the current mapping scheme, and f(S′) is the target value of the neighborhood demapping scheme.

5. The container load balancing scheduling method based on edge computing environment according to claim 1, characterized in that: The subsequent cooling rate corresponding to the middle stage of the iterative cooling increases compared to the initial stage of the iterative cooling, and the subsequent cooling rate corresponding to the final stage of the iterative cooling tends to be relatively stable.

6. A container load balancing scheduling method based on edge computing environment as claimed in claim 1, characterized in that: The subsequent cooling rate formula is as follows: Among them, σ is the variance of the Gaussian distribution, μ is the mean of the Gaussian distribution, and Iter is the number of iterations.

Citation Information

Cited By

  • Software performance load test method and system for large-scale video conference

    CN120872493A

  • Software performance load testing method and system for large-scale video conference

    CN120872493B