A system for virtual machine scheduling scheme generation

By generating a virtual machine scheduling scheme, the system solves the problems of low timeliness and resource waste in traditional scheduling strategies, and achieves cluster load balancing and efficient resource utilization, adapting to different load scenarios.

CN123178079APending Publication Date: 2026-11-27NORTHWEST ELECTROMECHANICAL ENG RES INST
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611420957.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-09-14
Publication Date
2026-11-27

AI Technical Summary

Technical Problem

Traditional virtual machine scheduling strategies rely on real-time collection of cluster load information, which reduces the timeliness of migration solutions, strains computing resources, and fails to cope with tidal scenarios, resulting in resource waste and load imbalance.

Method used

A virtual machine scheduling scheme generation system was designed, including a data acquisition module, a scheduling module, an algorithm module, and a scoring software module. By deploying acquisition software and services on host nodes, the system monitors the cluster status in real time, generates migration schemes with performance and cost modes, and ensures cluster load balancing and resource utilization efficiency.

Benefits of technology

It improves the efficiency of migration scheme generation, ensures that the cluster reaches the ideal state, enhances resource utilization and virtual machine performance, adapts to different load scenarios, and reduces resource waste.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123178079A_ABST
    Figure CN123178079A_ABST
Patent Text Reader

Abstract

The application relates to a system for generating a virtual machine scheduling scheme and belongs to the technical field of virtual machines. A collecting module collects data of hosts and virtual machines from each host node and stores the data in a database and a cache middleware; a scoring module regularly obtains cluster data from the database, calculates scores of hosts and virtual machines of a current cluster and stores the scores in the database; a scheduling module regularly obtains current cluster load state information from the cache middleware, judges whether a virtual machine scheduling suggestion scheme needs to be generated according to the state information, and sends a request for generating the suggestion scheme to an algorithm module if the suggestion scheme needs to be generated; and the algorithm module judges whether a cost mode or a performance mode is used to generate the virtual machine scheduling scheme according to an instruction. The application realizes generation of a cluster scheduling scheme, pays attention to not only resources of the whole cluster but also performance of all virtual machines in the cluster, and can satisfy a more ideal state of the cluster.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of virtual machine technology, specifically relating to a system for generating virtual machine scheduling schemes. Background Technology

[0002] Virtual machines (VMs) run on multiple hosts within a cluster. Because the distribution of VMs across the server cluster is random, two problems arise: First, multiple VMs may run on a single host, causing resource strain on that host while other hosts remain idle, leading to insufficient cluster performance. Second, even when only a small number of VMs are running on the cluster, their distribution across different hosts results in low utilization of all hosts. Both of these problems require real-time monitoring of the cluster status via software, along with migration strategies to maintain the cluster in an ideal state.

[0003] Traditional resource scheduling strategies collect cluster load information in real time and calculate the most load-balanced virtual machine migration scheme among all simulated strategies by accumulating this load information. However, this traditional method has the following shortcomings: First, real-time data collection affects the efficiency of generating migration schemes, reducing their timeliness. Furthermore, when the data collection and generation algorithms run simultaneously, it can lead to computational resource constraints and excessively high peak computing demands. Second, simply accumulating load information means the calculated migration scheme only considers load, neglecting the performance of the host and virtual machines. Finally, because current migration schemes only consider cluster load balancing, they cannot handle cyclical scenarios. When cluster workloads are low, all hosts in the cluster work at a balanced load, leaving no hosts idle and resulting in resource waste. Summary of the Invention

[0004] (a) Technical problems to be solved The technical problem this invention aims to solve is how to provide a system for generating virtual machine scheduling schemes, addressing the shortcomings of traditional resource scheduling strategies that rely on real-time collection of cluster load information and calculation of the most load-balanced virtual machine migration scheme among all simulated strategies.

[0005] (II) Technical Solution To address the aforementioned technical problems, this invention proposes a system for generating virtual machine scheduling schemes, comprising: a data acquisition module, a scheduling module, an algorithm module, and a scoring software module; The data acquisition module is used to acquire and store data from the host and the virtual machines running on the host by deploying acquisition software on each host node in the server cluster and deploying timed acquisition services and data storage services on the master control node. The scheduling module is used to trigger different generation scheduling tasks according to the configured mode. When configured in performance mode, it periodically retrieves load indicators related to key loads from the cache and determines whether the current cluster is unbalanced. If unbalanced, it sends instructions to generate a scheduling scheme that satisfies the cluster load balancing. When configured in cost mode, it does not perform threshold calculations and directly triggers the generation of a scheduling scheme that saves host resources. The algorithm module is used to trigger different generation and migration schemes based on cost mode or performance mode after receiving the command to generate the scheduling scheme; The scoring software module is used to calculate performance scores for hosts and virtual machines.

[0006] (III) Beneficial Effects This invention proposes a system for generating virtual machine scheduling schemes. Compared with existing technologies, this invention has the following technical features: This invention can be deployed in batches on large-scale clusters, facilitating its widespread application. By deploying collection services, scheduling services, algorithm services, and scoring services, this invention generates cluster scheduling schemes, focusing not only on the resources of the entire cluster but also ensuring the performance of all virtual machines in the cluster, thus achieving a more ideal cluster state. Attached Figure Description

[0007] Figure 1 This is a deployment diagram of the data acquisition module of the present invention; Figure 2 This is a performance mode flowchart; Figure 3 This is a cost model flowchart; Figure 4 This is the flowchart of the scheduling module; Figure 5 This is a system architecture diagram of the present invention. Detailed Implementation

[0008] To make the objectives, contents, and advantages of the present invention clearer, the specific embodiments of the present invention will be described in further detail below with reference to the accompanying drawings and examples.

[0009] This invention proposes a system for generating virtual machine scheduling schemes. This system can generate migration suggestions that enable host clusters to reach an ideal state. It can not only improve the efficiency of generating migration schemes, but also support two schemes for cluster state to reach performance mode and cost mode. Performance mode can enable the cluster to achieve a load-balanced state while optimizing the performance of hosts and virtual machines; cost mode can optimize the cluster utilization efficiency, thereby saving costs.

[0010] This invention discloses a system for generating virtual machine scheduling schemes. The system includes: a collection module that collects data from each host node and stores it in a database and a cache middleware; a scoring module that periodically retrieves cluster data from the database, calculates the scores of the hosts and virtual machines in the current cluster, and stores them in the database; a scheduling module that periodically retrieves the current cluster load status information from the cache middleware and determines whether a suggested virtual machine scheduling scheme needs to be generated based on the status information; if so, it sends a request to the algorithm module to generate a suggested scheme; the algorithm module determines whether to generate a virtual machine scheduling scheme in cost mode or performance mode based on the instructions; in performance mode, it calculates the optimal load balancing strategy by traversing the performance scores of all server hosts and virtual machines after simulated migration; in cost mode, it calculates a migration scheme that maximizes the number of available hosts by traversing the load of all server hosts and virtual machines after simulated migration; finally, the algorithm module sends the generated scheduling scheme to the scheduling module, which receives the scheme and stores it in the database.

[0011] To achieve the above objectives, the present invention adopts the following technical solution: A system for generating virtual machine scheduling schemes includes: a data acquisition module, a scheduling module, an algorithm module, and a scoring software module; The data acquisition module is used to acquire and store data from the host and the virtual machines running on the host by deploying acquisition software on each host node in the server cluster and deploying timed acquisition services and data storage services on the master control node. The scheduling module is used to trigger different generation scheduling tasks according to the configured mode. When configured in performance mode, it periodically retrieves load indicators related to key loads from the cache and determines whether the current cluster is unbalanced. If unbalanced, it sends instructions to generate a scheduling scheme that satisfies the cluster load balancing. When configured in cost mode, it does not perform threshold calculations and directly triggers the generation of a scheduling scheme that saves host resources. The algorithm module is used to trigger different generation and migration schemes based on cost mode or performance mode after receiving the command to generate the scheduling scheme; The scoring software module is used to calculate performance scores for hosts and virtual machines.

[0012] Example 1: A system for generating a virtual machine scheduling scheme includes: a data acquisition module, a scheduling module, an algorithm module, and a scoring software module.

[0013] The data acquisition module achieves data acquisition and storage by deploying acquisition software on each host node in the server cluster and deploying a timed acquisition service and data storage service on the master control node. The data acquisition software provides an interface for each data acquisition metric. Each interface collects data on one metric—memory, CPU, disk, network, etc.—from each host or all running virtual machines on that host. Each host in the cluster provides multiple acquisition interfaces, and the master node deploys Prometheus service software and relational and time-series database services for data storage. The Prometheus software allows for the configuration of periodically calling different acquisition interfaces to collect relevant metrics from each server at set intervals and storing the data in the database.

[0014] The database uses six tables: a host memory failure table, a host disk failure table, a host RAID card failure table, a host ECC data table, a host data table, and a virtual machine data table, each storing relevant data. Additionally, critical data regarding CPU and memory load is stored in a caching middleware; this invention uses Reids, a middleware with caching capabilities.

[0015] The scheduling module triggers different scheduling tasks based on the configured mode. When configured in performance mode, it periodically retrieves load metrics related to key loads from the cache and determines whether the current cluster is unbalanced. If unbalanced, it sends instructions to generate a scheduling scheme that satisfies cluster load balancing. When configured in cost mode, it does not perform threshold calculations and directly triggers the generation of a scheduling scheme that saves host resources.

[0016] The load metric is a comprehensive measure of the host and virtual machine CPU utilization, memory utilization, and a weighted average of the two. For the host, CPU utilization is the ratio of CPU usage time to total CPU time over a given period; for multiple CPU cores, it's the ratio of total CPU usage time to the total available time. Memory utilization is the ratio of physical memory used at a given moment to the host's total physical memory capacity; the average memory utilization over a period is used as the host's memory utilization rate. For virtual machines, CPU load refers to the ratio of CPU core usage time of a virtual machine thread to the host's total core usage time; similarly, memory utilization is the ratio of physical memory used by a thread to the host's total physical memory capacity.

[0017] In performance mode, the scheduling module determines whether the current load exceeds a set threshold. This determination is made by comparing two metrics. First, it compares the CPU load, memory load, and combined load (weighted average of CPU and memory loads) of all hosts in the cluster to see if they exceed the threshold. Second, it calculates the load difference between the host with the highest load and the host with the lowest load in the cluster and determines whether this load difference is greater than the maximum load difference set by the threshold. When both of these metrics exceed the threshold, the cluster is considered unbalanced, and a migration plan needs to be generated.

[0018] After confirming that a migration plan needs to be generated, it is determined whether the current state is generating a migration plan and whether the current migration plan is being executed. If neither of the above is true, the calculation request algorithm module is triggered to calculate and generate a migration plan.

[0019] After receiving the command to generate a scheduling scheme, the algorithm module triggers different processes for generating migration schemes based on either the cost model or the performance model.

[0020] In performance mode, the algorithm module first retrieves the latest cluster CPU and memory load from the database. When the load exceeds a threshold, it triggers the generation of migration proposals. This proposal iterates through all high-load hosts in descending order. It simulates the optimal state of the virtual machine after scheduling it to another host in the cluster. Based on the host's CPU, memory, and network usage after adding the virtual machine's resource consumption, it removes hosts that do not meet the threshold, hosts with insufficient reliability, and hosts that do not meet the host-virtual machine affinity requirements. Through filtering, a list of schedulable hosts is selected. Then, the remaining hosts are scored and sorted based on their load, and the host with the lowest load is selected as the migration plan for the virtual machine.

[0021] After generating the migration plan, the system simulates the changes in load across all hosts in the cluster, calculating the CPU, memory, and network loads of the source and destination hosts before and after the migration, and updating the cluster status. It then continues simulating the status of the remaining hosts and virtual machines until all high-load virtual machines have finished simulating, at which point all migration recommendations are sent to the scheduling module.

[0022] In cost-based mode, the algorithm module first retrieves the latest cluster CPU and memory load from the database and then iterates through all low-load hosts in ascending order. To simulate the optimal state of a virtual machine after it has been scheduled to another host in the cluster, it first filters the list of migrateable hosts based on the reliability of the destination host and the expected performance after migration. Then, for the filtered host list, it sorts them by load from low to high and selects the host with the lowest performance and load.

[0023] After traversing all hosts and virtual machines, the generated migration plan is simulated, the cluster state after the simulated migration is updated, and the migration plan is sent to the migration module and stored in the database.

[0024] The scoring software module is mainly used to calculate the performance scores of the host and virtual machines. Since both the performance mode and the cost mode require the performance scores of the virtual machines and the host as a condition for algorithm execution, this invention also provides a method for calculating the performance scores of the host and virtual machines: The host's rating is based on its CPU score. Memory rating Online ratings and storage rating The geometric mean.

[0025] Virtual machine rating is CPU rating Memory rating Online ratings and storage rating The geometric mean.

[0026] However, the scoring calculations for the host machine and the virtual machine differ slightly.

[0027] The CPU score for the virtual machine is as follows: h is the collection of all virtual machines on the host.

[0028] The CPU score of a virtual machine is based on the actual time the CPU spends. and the expected time The ratio of the product parameters. Two product parameters, the first parameter... The over-provisioning ratio for the host machine is determined by the number of CPU cores configured across all virtual machines. Divide by the actual number of CPU cores in the host Calculate. The second parameter. This indicates the overload ratio of the host machine and the number of CPU cores required to use virtual machines. Divide by the actual number of CPU cores in the host machine .

[0029] The method for calculating the CPU usage time required by the virtual machine is as follows: The time the CPU needs to use is equal to the time the CPU has already used. Add CPU utilization multiplied by the waiting time before acquiring CPU resources CPU utilization is determined by the amount of time the CPU has been used. CPU sleep time Calculated.

[0030] Virtual machine memory rating: The memory score consists of two parts: the physical memory actually used by the virtual machine. The ratio of the physical memory required to the swap memory size; the physical memory required is the size of the swap memory. Multiply by a memory swap-in / swap-out coefficient With actual physical memory used The sum, coefficient Homepage error per second Obtain; another The coefficient is a correction factor for memory over-provisioning, determined by the memory configuration of all virtual machines. Divided by the host's actual memory For calculation, this item is usually 1 when the host memory is not over-provisioned, and 0.5 when it is over-provisioned.

[0031] Virtual machine network rating: This represents the number of error packets received by the virtual machine. This represents the number of packets lost at the virtual machine receiver. This represents the total number of packets received by the virtual machine receiver. This represents the number of error packets sent by the virtual machine. This represents the number of packets lost at the virtual machine's sending end. The total number of packets received by the virtual machine's sender is the virtual machine's network score, which is determined by the greater of the send packet loss rate and the receive packet rate.

[0032] Virtual machine storage rating: The storage score of a virtual machine is determined based on whether a local copy exists on the current host.

[0033] CPU rating of the host: The CPU score of a host is the number of logical cores used. Add the number of threads when the CPU is in sleep state. Divide by the number of threads when the host is in a running state. Add the number of threads when the CPU is in sleep mode. .

[0034] Host memory rating: Memory rating is based on the amount of host memory used. Divide by the amount of memory used Increase the amount of memory used for swapping. Multiplier This coefficient is calculated by counting homepage errors per second. calculate.

[0035] Host network rating: This represents the number of error packets received by the host. This represents the number of packets lost at the host receiver. This represents the total number of packets received by the host receiver. This represents the number of error packets sent by the host. This represents the number of packets lost at the host sending end. This represents the total number of packets received by the host sending end. The host's network score is the same as the virtual machine's network score, determined by calculating the error rate and packet loss rate of packet reception and transmission.

[0036] Host storage rating: The host's storage score is calculated as the product of two factors, with the util value representing disk I / O utilization. The first factor is the storage score of the virtual machines on the host. The geometric mean of the second term. This is a correction related to the host's storage device utilization.

[0037] Example 1: To provide a method for generating virtual machine migration schemes to optimize host cluster performance, this invention comprises four software modules: a data acquisition module for collecting and processing information from each host in the cluster; a scheduling module for detecting cluster status and triggering migration scheme generation when cluster status is unsatisfactory; an algorithm module for generating migration schemes; and a calculation module for calculating performance scores for each host and virtual machine.

[0038] See attached document Figure 1 The acquisition module deploys an exporter acquisition service on each server node. This service provides a large number of HTTP interfaces, each of which can implement a specific data acquisition method. In this patent, it implements the acquisition of server node memory failure status, disk status, RAID card status, host ECC status, other host indicators (CPU, memory, network), and related indicators of virtual machines on the host.

[0039] In addition to deploying the exporter data collector, the master node also deploys Prometheus software and a database. The Prometheus software periodically calls the HTTP collection interface on each master node to obtain the collected data, combines the collected data, stores it, and sends it to the database service, where the database stores it in a data table.

[0040] See attached document Figure 2 and Figure 3 The algorithm module is mainly divided into performance mode and cost mode. Performance mode aims to distribute virtual machines as evenly as possible across all hosts in the cluster, ensuring load balancing across the entire cluster and guaranteeing that all virtual machines can achieve optimal performance. Cost mode aims to concentrate virtual machines on a subset of hosts, ensuring that each virtual machine maintains basic performance and stability while freeing up as many hosts as possible.

[0041] Figure 2 The algorithm flow for performance mode is as follows: First, retrieve the latest cluster CPU and memory load from the database. When the load exceeds a threshold, trigger the generation of migration proposals. Based on a certain threshold, divide all hosts into low-load and high-load hosts. Iterate through all high-load hosts in descending order from high to low. For each host, iterate through the virtual machines on the host in ascending order of load.

[0042] This simulation computes the optimal state of a virtual machine (VM) after it is scheduled to other hosts in the cluster. The process is executed in parallel using multiple threads. First, hosts that cannot be scheduled are filtered out. Based on the host's CPU, memory, and network resources combined with the VM's resource usage, hosts that do not meet thresholds, hosts with insufficient reliability, and hosts that do not meet host-VM affinity requirements are removed. A list of schedulable hosts is then selected based on filtering criteria, including: when the VM has specified a host that it cannot run on or a host that it must run on; when the host's CPU cores (or dedicated CPU cores) are less than the VM's configured cores; when the host's available compute memory is less than the VM's configured memory; and host-VM affinity.

[0043] Then, the remaining hosts are scored and sorted based on their load, and the host with the lowest load is selected as the migration plan for the virtual machine.

[0044] After generating the migration plan, the changes in the load of all hosts in the cluster after the virtual machine is migrated to the host are simulated and calculated. The CPU, memory, and network loads of the source and destination hosts before and after the migration are calculated, and the cluster status is updated.

[0045] Continue simulating the state of the remaining hosts and virtual machines until all high-load virtual machines have finished simulating, and then send all migration recommendations to the scheduling module.

[0046] After obtaining migration suggestions, the scheduling module adds an expiration time and stores it in the database.

[0047] Figure 3 Here is the algorithm flowchart for the cost model: First, retrieve the latest cluster CPU and memory load from the database. Based on a certain threshold, divide all hosts into low-load hosts and high-load hosts. Iterate through all low-load hosts in ascending order from low to high. For each host, iterate through the virtual machines on the host in descending order of load.

[0048] The simulation computes the optimal state of a virtual machine after it is scheduled to be migrated to another host in the cluster. This process is executed in parallel by multiple threads. First, the list of migrateable hosts is filtered. The filtering criteria are: the reliability of the destination host, the host load not being overloaded after migration, the performance of the host being greater than a set threshold, the simulated benefit after migration being greater than 0, and the simulated load increase at the destination being less than a set threshold. For the filtered host list, it is sorted from low to high load, and the host with the lowest performance and lowest load is selected.

[0049] After traversing all hosts and virtual machines, the generated migration plan is simulated, the cluster state after the simulated migration is updated, and the migration plan is sent to the migration module and stored in the database.

[0050] Figure 4 Here is the flowchart for the scheduling module: The module executes the following process in a loop: First, it checks if the scheduling function is enabled. If enabled, it checks the current configuration mode. If it is performance mode, it obtains the CPU load and memory load from the cache middleware. If any one of the CPU load, memory load, or the average of the two loads is greater than a threshold, it continues to check whether to generate a migration plan. If it is cost mode, it skips the threshold check. Then, it checks whether a scheduling plan is being generated or whether a scheduling plan exists and is being executed. Finally, it checks whether the scheduling plan has expired. The expiration time set in this invention is 10 minutes.

[0051] Beneficial effects: Compared with the prior art, the present invention has the following technical features: This invention can be deployed in batches on large-scale clusters, facilitating its widespread application. By deploying collection services, scheduling services, algorithm services, and scoring services, this invention generates cluster scheduling schemes, focusing not only on the resources of the entire cluster but also ensuring the performance of all virtual machines in the cluster, thus achieving a more ideal cluster state.

[0052] The above description is only a preferred embodiment of the present invention. It should be noted that for those skilled in the art, several improvements and modifications can be made without departing from the technical principles of the present invention, and these improvements and modifications should also be considered within the scope of protection of the present invention.

Claims

1. A system for generating virtual machine scheduling schemes, characterized in that, The system includes: a data acquisition module, a scheduling module, an algorithm module, and a scoring software module; The data acquisition module is used to acquire and store data from the host and the virtual machines running on the host by deploying acquisition software on each host node in the server cluster and deploying timed acquisition services and data storage services on the master control node. The scheduling module is used to trigger different generation scheduling tasks according to the configured mode. When configured in performance mode, it periodically retrieves load indicators related to key loads from the cache and determines whether the current cluster is unbalanced. If unbalanced, it sends instructions to generate a scheduling scheme that satisfies the cluster load balancing. When configured in cost mode, it does not perform threshold calculations and directly triggers the generation of a scheduling scheme that saves host resources. The algorithm module is used to trigger different generation and migration schemes based on cost mode or performance mode after receiving the command to generate the scheduling scheme; The scoring software module is used to calculate performance scores for hosts and virtual machines.

2. The system for generating the virtual machine scheduling scheme as described in claim 1, characterized in that, The data acquisition software provides an interface for each data acquisition metric. Each acquisition interface collects memory, CPU, disk, and network metrics data from each host or all running virtual machines on the host. Each host in the cluster provides multiple acquisition interfaces, and the master control node deploys Prometheus service software and relational database and time-series database service software for data storage. The Prometheus software provides the function of configuring timed calls to different acquisition interfaces to collect relevant metrics from each server at a set time and store the data in the database. The database is configured with six tables: host memory failure table, host disk failure table, host RAID card failure table, host ECC data table, host data table, and virtual machine data table, which store relevant data respectively; in addition, key data on CPU and memory load are stored in the cache middleware.

3. The system generated by the virtual machine scheduling scheme as described in claim 1, characterized in that, The load metric is calculated by taking the CPU utilization, memory utilization, and weighted average of the two utilizations of the host and virtual machines as a comprehensive load. For the host, the CPU utilization is the ratio of the time the CPU is used to the total time over a period of time. For multiple CPU cores, the ratio of the total usage time to the total time is calculated. Memory utilization is the ratio of physical memory occupied at a certain moment to the total physical memory capacity of the host. The average memory utilization over a period of time is used as the host's memory utilization. For virtual machines, the CPU load of a virtual machine refers to the ratio of the CPU core time occupied by the virtual machine thread to the total CPU core time of the host; similarly, memory utilization is the ratio of the physical memory occupied by the thread to the total physical memory capacity of the host.

4. The system generated by the virtual machine scheduling scheme as described in claim 1, characterized in that, In performance mode, the scheduling module determines whether the current load exceeds the set threshold. This determination method compares two indicators: first, it compares whether the CPU load, memory load, and overall load of all hosts in the cluster exceed the threshold; second, it calculates the load difference between the host with the highest load and the host with the lowest load in the cluster, and determines whether this load difference is greater than the maximum load difference set by the threshold. When both of the above indicators exceed the threshold, it is determined that the cluster is unbalanced and a migration plan needs to be generated. After confirming that a migration plan needs to be generated, it is determined whether the current state is generating a migration plan and whether the current migration plan is being executed. If neither of the above is true, the calculation request algorithm module is triggered to calculate and generate a migration plan.

5. The system for generating the virtual machine scheduling scheme as described in claim 1, characterized in that, In performance mode, the algorithm module first retrieves the latest cluster CPU and memory load from the database. When the load exceeds the threshold, it triggers the generation of a migration suggestion plan. This plan will traverse all high-load hosts in descending order from high to low. The simulation computes the optimal state of a virtual machine after it is scheduled to another host in the cluster. Based on the host's CPU, memory, and network usage after adding the virtual machine's resource consumption, the scheduling hosts that do not meet the threshold, hosts with insufficient reliability, and hosts that do not meet the host-virtual machine affinity requirements are removed. The list of scheduling hosts is filtered out by filtering conditions, and then the remaining hosts are scored and sorted according to their load. The host with the lowest load is selected as the solution for the virtual machine migration. After generating the migration plan, the system simulates the changes in the load of all hosts in the cluster, calculates the CPU, memory, and network load of the source and destination hosts before and after the migration, and updates the cluster status. Then, it continues to simulate the status of the remaining hosts and virtual machines until all high-load virtual machines have been simulated, and sends all migration proposals to the scheduling module.

6. The system generated by the virtual machine scheduling scheme as described in claim 1, characterized in that, In cost mode, the algorithm module first retrieves the latest cluster CPU and memory load from the database and then iterates through all low-load hosts in ascending order from low to high. After simulating the optimal state of the virtual machine after it is scheduled to other hosts in the cluster, it first filters the list of hosts that can be migrated. The filtering criteria are the reliability of the destination host and the performance after the migration is completed. For the filtered list of hosts, it sorts them from low to high load and selects the host with the lowest performance and load. After traversing all hosts and virtual machines, the generated migration plan is simulated, the cluster state after the simulated migration is updated, and the migration plan is sent to the migration module and stored in the database.

7. The system generated by the virtual machine scheduling scheme as described in claim 1, characterized in that, Virtual machine performance ratings include: Virtual machine rating is CPU rating Memory rating Online ratings and storage rating The geometric mean; The CPU score for the virtual machine is as follows: h is the collection of all virtual machines on the host; The CPU score of a virtual machine is based on the actual time the CPU spends. and the expected time The ratio of the product parameters; the first parameter of the two product parameters. The over-provisioning ratio for the host machine is determined by the number of CPU cores configured across all virtual machines. Divide by the actual number of CPU cores in the host Calculate; the second parameter This indicates the overload ratio of the host machine and the number of CPU cores required to use virtual machines. Divide by the actual number of CPU cores in the host machine ; The method for calculating the CPU usage time required by the virtual machine is as follows: The time the CPU needs to use is equal to the time the CPU has already used. Add CPU utilization multiplied by the waiting time before acquiring CPU resources CPU utilization is determined by the amount of time the CPU has been used. CPU sleep time Calculated; Virtual machine memory rating: The memory score consists of two parts: the physical memory actually used by the virtual machine. The ratio of the physical memory required to the swap memory size; the physical memory required is the size of the swap memory. Multiply by a memory swap-in / swap-out coefficient With actual physical memory used The sum, coefficient Homepage error per second Obtain; another The coefficient is a correction factor for memory over-provisioning, determined by the memory configuration of all virtual machines. Divided by the host's actual memory calculate; Virtual machine network rating: This represents the number of error packets received by the virtual machine. This represents the number of packets lost at the virtual machine receiver. This represents the total number of packets received by the virtual machine receiver. This represents the number of error packets sent by the virtual machine. This represents the number of packets lost at the virtual machine's sending end. The total number of packets received by the virtual machine's sender is the virtual machine's network score, which is determined by the greater of the send packet loss rate and the receive packet rate. Virtual machine storage rating: The storage score of a virtual machine is determined based on whether a local copy exists on the current host.

8. The system generated by the virtual machine scheduling scheme as described in claim 7, characterized in that, The host's performance rating includes: The host's rating is based on its CPU score. Memory rating Online ratings and storage rating The geometric mean; CPU rating of the host: The CPU score of a host is the number of logical cores used. Add the number of threads when the CPU is in sleep mode. Divide by the number of threads when the host is running. Add the number of threads when the CPU is in sleep mode. ; Host memory rating: Memory rating is based on the amount of host memory used. Divide by the amount of memory used Increase the amount of memory used for swapping. Multiplier This coefficient is calculated by counting homepage errors per second. calculate; Host network rating: This represents the number of error packets received by the host. This represents the number of packets lost at the host receiver. This represents the total number of packets received by the host receiver. This represents the number of error packets sent by the host. This represents the number of packets lost at the host sending end. The total number of packets received by the host sender. The network score of the host is the same as that of the virtual machine, and is determined by calculating the error rate and packet loss rate of packet reception and transmission. Host storage rating: The host's storage score is calculated as the product of two factors: the util value, which represents disk I / O utilization; and the first factor, which is the storage score of the virtual machines on the host. The geometric mean; the second term This is a correction related to the host's storage device utilization.

9. The system generated by the virtual machine scheduling scheme as described in claim 1, characterized in that, The algorithm flow for performance mode includes: First, retrieve the latest cluster CPU and memory load from the database. When the load exceeds the threshold, trigger the generation of migration proposals. Based on a certain threshold, divide all hosts into low-load hosts and high-load hosts. Traverse all high-load hosts in descending order from high to low. For each traversed host, traverse the virtual machines on the host in ascending order of load. This simulation computes the optimal state of a virtual machine (VM) after it is scheduled to other hosts in the cluster. The process is executed in parallel using multiple threads. First, hosts that cannot be scheduled are filtered out. Based on the host's CPU, memory, and network resources after adding the VM's resource usage, hosts that do not meet the thresholds for scheduling are removed, as are hosts with insufficient reliability and hosts that do not meet the host-VM affinity requirements. A list of scheduled hosts is then compiled using filtering criteria, including: when the VM has already specified a host that is not running or a host that must run; when the host's CPU core count is less than the VM's configured core count; when the host's available compute memory is less than the VM's configured memory; and host-VM affinity. Then, the remaining hosts are scored and sorted according to their load, and the host with the lowest load is selected as the migration plan for the virtual machine. After generating the migration plan, simulate the changes in the load of all hosts in the cluster after the virtual machine is migrated to the host. Calculate the CPU, memory, and network load of the source and destination hosts before and after the migration, and update the cluster status. Continue simulating the state of the remaining hosts and virtual machines until all high-load virtual machines have finished simulating, and then send all migration proposals to the scheduling module. After obtaining migration suggestions, the scheduling module adds an expiration time and stores it in the database.

10. The system for generating the virtual machine scheduling scheme as described in claim 1, characterized in that, The algorithm flow for the cost model includes: First, retrieve the latest cluster CPU and memory load from the database. Then, divide all hosts into low-load hosts and high-load hosts according to a certain threshold. Traverse all low-load hosts in ascending order from low to high. For each host, traverse the virtual machines on the host in descending order of load. The simulation computes the optimal state of a virtual machine after it is scheduled to be migrated to another host in the cluster. This process is executed in parallel by multiple threads. First, the list of hosts that can be migrated is filtered. The filtering conditions are the reliability of the destination host and the fact that the host load will not be overloaded after migration. The performance of the host is greater than a set threshold, the benefit after the simulated migration is greater than 0, and the increase in load on the destination host after the simulated migration is less than a set threshold. For the filtered host list, it is sorted from low to high load, and the host with the lowest performance and load is selected. After traversing all hosts and virtual machines, the generated migration plan is simulated, the cluster state after the simulated migration is updated, and the migration plan is sent to the migration module and stored in the database.