A virtual machine resource scheduling method

By inertial monitoring and resource scheduling of the tuned virtual direction in the virtual machine environment, the problems of resource coordination and allocation in multiple virtual machine environments are solved, and efficient resource utilization and abnormal monitoring are achieved.

CN114647486BActive Publication Date: 2025-04-04HANGZHOU ZHONGGANG TECH CO LTD
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202210249967.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-03-14
Publication Date
2025-04-04
Estimated Expiration
2042-03-14

AI Technical Summary

Technical Problem

In multiple virtual machine environments, how to effectively coordinate and allocate resources to ensure efficient and rational resource utilization, especially when different users use virtual machines at the same time.

Method used

By monitoring all adjusted virtual directions inertia, analyzing their usage habits and resource requirements, calculating inertia values ​​to sort active segments, and scheduling and abnormal identification based on inertial data to ensure the fairness and rationality of resource allocation.

Benefits of technology

It realizes efficient allocation and coordination of resources in a multi-virtual machine environment, allocates resources according to user inertia, monitors and analyzes the usage of virtual machines simultaneously, and avoids resource waste and abnormal use.

✦ Generated by Eureka AI based on patent content.
Patent Text Reader

Abstract

The present invention discloses a virtual machine resource scheduling method. The method first monitors all the regulated virtual directions and performs inertia monitoring on them to obtain inertia data consisting of the regulated virtual direction Di and its corresponding familiar segment and use point range. Then, resource scheduling is performed according to the inertia data. For different use situations, resources are allocated according to suitability based on the inertia of the user, and the use of each virtual machine is coordinated synchronously. Meanwhile, when the regulated virtual direction Di is used, abnormal identification is performed. According to the use point range in the inertia data of the regulated virtual direction, it is determined whether there is an abnormal use situation of the regulated virtual direction, and adaptive reminder is performed. The present invention is simple, effective, and easy to use.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of virtual machine resource allocation, and in particular to a virtual machine resource scheduling method. Background Art

[0002] The patent with announcement number CN107479945B discloses a virtual machine resource scheduling method, which implants N virtual controllers as middleware carriers in the virtual machine memory, each virtual controller corresponds to a data memory area, and N≥1; implants a computing executor and a data scheduling module in the virtual machine; when the virtual machine starts, the N virtual controllers read the data of the corresponding virtual control node; the data scheduling module adds each virtual controller to the computing scheduling list, and scans all the virtual controller data in the scheduling list to confirm whether there is a priority tag, and schedules the data of each virtual controller to the computing executor in sequence according to the priority tag or order; the computing executor directly calls the virtual central processing unit to calculate the data of each virtual controller, without scheduling the kernel of the user operating system. After the calculation is completed, the data scheduling module schedules the calculation result to each virtual controller, and each virtual controller writes the calculation result to the corresponding data memory area.

[0003] However, when scheduling virtual machines, how to confirm any main device, when there are multiple virtual machines, how to coordinate and cooperate between resources, how to analyze the different usage habits of virtual machines by users of the main devices, and allocate resources for the usage of virtual machines based on the analysis results, and simultaneously analyze whether there are any abnormalities in the use of virtual machines; based on this, a solution is provided. Summary of the invention

[0004] The purpose of the present invention is to provide a virtual machine resource scheduling method;

[0005] The purpose of the present invention can be achieved through the following technical solutions:

[0006] A virtual machine resource scheduling method, the method specifically comprising the following steps:

[0007] Step 1: Monitor all the adjusted virtual directions and perform inertia monitoring on them. The specific method of inertia monitoring is as follows:

[0008] S1: mark all modulated virtual directions as Di, i=1...n;

[0009] S2: Let i=1, select the corresponding modulated virtual direction D1, obtain the previous usage of the main device, and obtain the usage data, which is the usage start time and usage end time;

[0010] S3: Perform data calibration according to the use start time and use end time to determine the use point range;

[0011] S4: Then, data delineation is performed to determine an active time group consisting of several active time ranges;

[0012] S5: Obtain the total duration of the active time range, divide it into 10 time periods, mark them as active segments, and mark them as Hj, where j=1...10; if there is a single active time range that cannot be divided, combine its time with other time periods;

[0013] S6: Get the usage point range and active segment Hj;

[0014] S7: Then, the usage times and usage duration of the corresponding virtual direction D1 in the active segment in the past two months are obtained. The usage times are the usage data of the corresponding virtual direction D1 in any active segment, and the corresponding usage duration is obtained. The usage times are marked as Cj, and the usage duration is marked as Pj, where j=1...10, and Cj, Pj and Hj are all in one-to-one correspondence;

[0015] S8: Calculate the inertia value Gj according to the formula. The specific calculation formula is:

[0016] Gj=0.56*Cj+0.44*Pj;

[0017] S9: Sort the active segments Hj in descending order of the inertia value Gj, and mark the top three as the corresponding familiar segments of the adjusted virtual direction;

[0018] S10: Obtain the familiar segment and use point range of the adjusted virtual direction D1;

[0019] S11: Repeat steps S2 to S10, perform the same analysis on all Di, and obtain the corresponding familiar segments and usage point ranges; mark the adjusted virtual direction Di and its corresponding familiar segments and usage point ranges as inertial data.

[0020] Furthermore, before proceeding to step 1, the following steps need to be performed:

[0021] The scheduled main device is obtained, the virtual machine running on the main device is obtained, and the virtual machine is marked as the scheduled virtual machine.

[0022] Furthermore, the specific method of data calibration in step S3 is:

[0023] Get the usage data for the past two months, select the data from the first day in sequence, and get all the usage data for that day;

[0024] Get the earliest start time in the usage data and mark it as the initial start time. Then get the latest end time in the usage data and mark it as the initial end time.

[0025] Then, the usage data of the next day is obtained, and the usage start time is compared with the initial opening time. If the usage start time is earlier than the initial opening time, the initial opening time is replaced;

[0026] Similarly, the end time of use is compared with the initial settlement time, and replaced according to the situation; the usage data of the next day is continuously obtained, and it is replaced and replaced; until the usage data of the past two months are compared;

[0027] Get the updated initial opening time and initial closing time, and mark the initial opening time and initial closing time as the usage point range.

[0028] Furthermore, the specific method of delineating the data in step S4 is:

[0029] Get all usage data, combine the single usage start time and usage end time in all usage data with other time, and if the interval is less than T1 time, merge the two;

[0030] The use start time and the end time of a single use with an interval shorter than T1 are marked as a use time range;

[0031] If the usage start time and the interval are not less than T1, they are marked as two time periods. If the usage start time and usage end time of any group overlap with the usage start time and usage end time of another group, the two will be merged and marked as the active time range.

[0032] After all the usage data are processed in the above manner, an active time group corresponding to the modulated virtual direction D1 is obtained, and the active time group includes several active time ranges.

[0033] Furthermore, the interval refers to the previous use end time and the closest next use start time.

[0034] Furthermore, after completing step 1, the following steps are required:

[0035] Step 2: Perform resource scheduling based on inertia data. The specific method of resource scheduling is as follows:

[0036] SS1: time monitoring. When entering a familiar segment of any virtual direction, the virtual direction will be automatically recommended to the user, who can choose whether to use it.

[0037] SS2: If there are two or more adjusted virtual directions at the same time point, the one with the highest ranking will be recommended first according to the ranking of the familiar segment in the original calculated inertia value Gj, and resources will be allocated first when used. If the rankings are the same, it will automatically detect whether there is a priority label. Resources will be allocated first if there is a priority label. If there is no priority label, they will be evenly allocated. If there is still a collision, the user will be asked to select the priority and resources will be allocated according to the user's priority.

[0038] Furthermore, after performing step 2, the following steps are required:

[0039] When the modulated virtual direction is used, abnormal identification is carried out. The specific method is as follows:

[0040] If any regulated virtual direction Di uses resources outside the usage point range, the resource is computing power. If the occupied resources exceed the preset value X1 and exceed the T2 time, an abnormal usage signal is generated and the administrator is prompted to pay attention to the abnormal situation of the regulated virtual direction.

[0041] Furthermore, X1, T1 and T2 are all preset values.

[0042] Beneficial effects of the present invention:

[0043] The present invention first monitors all the regulated virtual directions and performs inertia monitoring on them to obtain inertia data consisting of the regulated virtual direction Di and its corresponding familiar segment and usage point range; then, according to the inertia data, resource scheduling is performed, and for different usage situations, applicability of resources is allocated based on the inertia of the user, and the use of each virtual machine is synchronously coordinated;

[0044] At the same time, when the regulated virtual direction Di is used, abnormal identification is performed. According to the use point range in the previous inertial data of the regulated virtual direction, it is determined whether there is abnormal use of the regulated virtual direction, and adaptive reminders are given; the present invention is simple, effective, and easy to use. DETAILED DESCRIPTION

[0045] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0046] The present invention is a virtual machine resource scheduling method, which specifically includes the following steps:

[0047] Step 1: Obtain the scheduled main device, obtain the virtual machine running on the main device, and mark the virtual machine as the scheduled virtual machine;

[0048] Step 2: Monitor all the adjusted virtual directions and perform inertia monitoring on them. The specific method of inertia monitoring is as follows:

[0049] S1: mark all modulated virtual directions as Di, i=1...n;

[0050] S2: Let i=1, select the corresponding modulated virtual direction D1, obtain the previous usage of the main device, and obtain the usage data, which is the usage start time and usage end time;

[0051] S3: According to the start time and end time of use, data calibration is performed to determine the range of use points. The specific method of data calibration is as follows:

[0052] Get the usage data for the past two months, select the data from the first day in sequence, and get all the usage data for that day;

[0053] Get the earliest start time in the usage data and mark it as the initial start time. Then get the latest end time in the usage data and mark it as the initial end time.

[0054] Then, the usage data of the next day is obtained, and the usage start time is compared with the initial opening time. If the usage start time is earlier than the initial opening time, the initial opening time is replaced; similarly, the usage end time is compared with the initial closing time and replaced according to the situation; the usage data of the next day is continuously obtained, and it is replaced and replaced; until all the usage data of the past two months are compared; the updated initial opening time and initial closing time are obtained, and the initial opening time and initial closing time are marked as the usage point range;

[0055] S4: Then, data delineation is performed to determine the active time group. The specific method of data delineation is as follows:

[0056] Get all usage data, combine the single usage start time and usage end time in all usage data with other time, and merge the two if the interval is less than T1 time; here the interval refers to the previous usage end time and the closest next usage start time; mark the usage start time and the single usage end time with an interval less than T1 time as a usage time range;

[0057] If the usage start time and the interval are not less than T1, they are marked as two time periods. If the usage start time and usage end time of any group overlap with the usage start time and usage end time of another group, the two will be merged and marked as the active time range.

[0058] After all the usage data are processed in the above manner, an active time group corresponding to the modulated virtual direction D1 is obtained, and the active time group includes several active time ranges;

[0059] S5: Obtain the total duration of the active time range, divide it into 10 time periods, mark them as active segments, and mark them as Hj, where j=1...10; if there is a single active time range that cannot be divided, combine its time with other time periods;

[0060] S6: Get the usage point range and active segment Hj;

[0061] S7: Then, the usage times and usage duration of the corresponding virtual direction D1 in the active segment in the past two months are obtained. The usage times are the usage data of the corresponding virtual direction D1 in any active segment, and the corresponding usage duration is obtained. The usage times are marked as Cj, and the usage duration is marked as Pj, where j=1...10, and Cj, Pj and Hj are all in one-to-one correspondence;

[0062] S8: Calculate the inertia value Gj according to the formula. The specific calculation formula is:

[0063] Gj=0.56*Cj+0.44*Pj;

[0064] S9: Sort the active segments Hj in descending order of the inertia value Gj, and mark the top three as the corresponding familiar segments of the adjusted virtual direction;

[0065] S10: Obtain the familiar segment and use point range of the adjusted virtual direction D1;

[0066] S11: repeat steps S2 to S10, perform the same analysis on all Di, and obtain the corresponding familiar segments and usage point ranges; mark the adjusted virtual direction Di and its corresponding familiar segments and usage point ranges as inertial data;

[0067] Step 3: Perform resource scheduling based on inertia data. The specific method of resource scheduling is as follows:

[0068] SS1: time monitoring. When entering a familiar segment of any virtual direction, the virtual direction will be automatically recommended to the user, who can choose whether to use it.

[0069] SS2: If there are two or more virtual directions to be adjusted at the same time point, the one with the highest ranking will be recommended first according to the ranking of the familiar segment in the original calculated inertia value Gj, and resources will be allocated first when used. If the rankings are the same, it will automatically detect whether there is a priority label, and resources will be allocated first if there is a priority label. If there is no priority label, resources will be evenly allocated. If there is still a collision, the user will select the priority and resources will be allocated according to the user's priority.

[0070] Step 4: When the adjusted virtual direction is used, perform abnormal identification. The specific method is as follows:

[0071] If any regulated virtual direction Di uses resources outside the usage point range, the resource is the computing power. If the occupied resources exceed the preset value X1 and exceed the time T2, an abnormal usage signal is generated and the administrator is prompted to pay attention to the abnormal situation of the regulated virtual direction; X1, T1 and T2 are all preset values.

[0072] The above is a detailed description of an embodiment of the present invention, but the content is only a preferred embodiment of the present invention and cannot be considered to limit the scope of implementation of the present invention. All equivalent changes and improvements made within the scope of the present invention should still fall within the scope of the patent coverage of the present invention.

Claims

1. A virtual machine resource scheduling method, characterized in that: The method specifically comprises the following steps: Step 1: Monitor all the adjusted virtual directions and perform inertia monitoring on them. The specific method of inertia monitoring is as follows: S1: mark all modulated virtual directions as Di, i=1...n; S2: Let i=1, select the corresponding modulated virtual direction D1, obtain the previous usage of the main device, and obtain the usage data, which is the usage start time and usage end time; S3: Perform data calibration according to the use start time and use end time to determine the use point range; S4: Then, data delineation is performed to determine an active time group consisting of several active time ranges; S5: Obtain the total duration of the active time range, divide it into 10 time periods, mark them as active segments, and mark them as Hj, where j=1...10; if there is a single active time range that cannot be divided, combine its time with other time periods; S6: Get the usage point range and active segment Hj; S7: Then, the usage times and usage duration of the corresponding virtual direction D1 in the active segment in the past two months are obtained. The usage times are the usage data of the corresponding virtual direction D1 in any active segment, and the corresponding usage duration is obtained. The usage times are marked as Cj, and the usage duration is marked as Pj, where j=1...10, and Cj, Pj and Hj are all in one-to-one correspondence; S8: Calculate the inertia value Gj according to the formula. The specific calculation formula is: Gj=0.56*Cj+0.44*Pj; S9: Sort the active segments Hj in descending order of the inertia value Gj, and mark the top three as the corresponding familiar segments of the adjusted virtual direction; S10: Obtain the familiar segment and use point range of the adjusted virtual direction D1; S11: Repeat steps S2 to S10, perform the same analysis on all Di, and obtain the corresponding familiar segments and usage point ranges; mark the adjusted virtual direction Di and its corresponding familiar segments and usage point ranges as inertial data.

2. A virtual machine resource scheduling method according to claim 1, characterized in that: Before proceeding to step 1, you also need to do the following steps: The scheduled main device is obtained, the virtual machine running on the main device is obtained, and the virtual machine is marked as the scheduled virtual machine.

3. A virtual machine resource scheduling method according to claim 1, characterized in that: The specific method of data calibration in step S3 is: Get the usage data for the past two months, select the data from the first day in sequence, and get all the usage data for that day; Get the earliest start time in the usage data and mark it as the initial start time. Then get the latest end time in the usage data and mark it as the initial end time. Then, the usage data of the next day is obtained, and the usage start time in the obtained usage data is compared with the initial opening time. If the usage start time is earlier than the initial opening time, the initial opening time is replaced; Similarly, the end time of use is compared with the initial settlement time, and replaced according to the situation; the usage data of the next day is continuously obtained, and it is replaced and replaced; until the usage data of the past two months are compared; Get the updated initial opening time and initial closing time, and mark the initial opening time and initial closing time as the usage point range.

4. A virtual machine resource scheduling method according to claim 1, characterized in that: The specific method of delineating the data in step S4 is: Get all usage data, combine the single usage start time and usage end time in all usage data with other time, and if the interval is less than T1 time, merge the two; The use start time and the end time of a single use with an interval shorter than T1 are marked as a use time range; If the usage start time and the interval are not less than T1, they are marked as two time periods. If the usage start time and usage end time of any group overlap with the usage start time and usage end time of another group, the two will be merged and marked as the active time range. After all the usage data are processed in the above manner, an active time group corresponding to the adjusted virtual direction D1 is obtained, and the active time group includes several active time ranges; T1 is a preset value.

5. A virtual machine resource scheduling method according to claim 4, characterized in that: The interval refers to the previous use end time and the closest next use start time.

6. A virtual machine resource scheduling method according to claim 1, characterized in that: After completing step 1, you need to perform the following steps: Step 2: Perform resource scheduling based on inertia data. The specific method of resource scheduling is as follows: SS1: time monitoring. When entering a familiar segment of any virtual direction, the virtual direction will be automatically recommended to the user, who can choose whether to use it. SS2: If there are two or more adjusted virtual directions at the same time point, the one with the highest ranking will be recommended first according to the ranking of the familiar segment in the original calculated inertia value Gj, and resources will be allocated first when used. If the rankings are the same, it will automatically detect whether there is a priority label. Resources will be allocated first if there is a priority label. If there is no priority label, resources will be evenly allocated.

7. A virtual machine resource scheduling method according to claim 6, characterized in that: After step 2, you need to do the following steps: When the modulated virtual direction is used, abnormal identification is carried out. The specific method is as follows: If any regulated virtual direction Di uses resources outside the usage point range, the resource is computing power. If the occupied resources exceed the preset value X1 and exceed the time T2, an abnormal usage signal is generated and the administrator is prompted to pay attention to the abnormal situation of the regulated virtual direction. X1 is the preset value and T2 is the preset value.

8. A virtual machine resource scheduling method according to claim 6, characterized in that: If there is still a conflict, the user is asked to select a priority and resources are allocated according to the user's priority.

Citation Information

Patent Citations

  • A virtual machine resource scheduling method and apparatus

    CN107479945B

  • Virtual machine cluster resource allocation and scheduling method

    CN103473139A

  • Virtual machine resource distribution method and distributed virtual machine resource scheduling system

    CN106874115A