Resource monitoring method and device, equipment and medium
By analyzing historical data on virtual machine resource usage in hyperconverged platforms using large-scale models, classifying business types, predicting future resource usage, and generating alerts, the problem of unpredictable resource utilization exceeding thresholds in hyperconverged platforms is solved, ensuring the reliability of platform operation.
Patent Information
- Application Number
- CN202511284586.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-09-09
- Publication Date
- 2025-12-16
AI Technical Summary
Hyperconverged platforms cannot predict resource utilization exceeding a set threshold in a timely manner, which affects platform performance. Existing monitoring methods lack the ability to predict future resource usage.
By analyzing historical resource usage data of virtual machines through large-scale model analysis, different business types are classified, future resource usage is predicted, and alarm information is generated based on preset thresholds to notify users to make adjustments in advance.
It enables accurate prediction of hyperconverged platform resource usage, reduces platform failures, and ensures the reliability and stability of platform operation.
Smart Images

Figure CN121144148A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of resource monitoring technology, and in particular to a resource monitoring method, apparatus, equipment, and medium. Background Technology
[0002] Hyperconverged platforms typically provide detailed performance monitoring data, including CPU, memory, disk, and network metrics for each host and VM. They also provide read / write rate metrics for storage pools and traffic monitoring metrics for switches. These metrics can be accessed and viewed graphically within the hyperconverged platform.
[0003] Hyperconverged platforms also provide system and performance alerts. An alert is a notification that occurs in response to selected system events, or when CPU, memory usage, network throughput, storage throughput, or VM disk activity exceeds a specified threshold on the managed host, VM, or storage pool. These alert notifications can be configured on the hyperconverged platform. However, an alert may be issued when a failure has already occurred, potentially causing problems with system operation. Summary of the Invention
[0004] The purpose of this invention is to provide a resource monitoring method, apparatus, equipment, and medium that can provide timely alarms, reduce platform failures, and ensure the reliability of platform operation.
[0005] In a first aspect, a resource monitoring method is provided, comprising: acquiring first resource change data of a monitored virtual machine over a continuous period; determining the virtual machine type of the monitored virtual machine; predicting second resource change data of the monitored virtual machine over a future period using a large model based on the virtual machine type of the monitored virtual machine and the first resource change data; and determining alarm information based on the second resource change data and a preset resource utilization threshold.
[0006] In a preferred embodiment, the present invention may be further configured to include: acquiring historical resource change data of virtual machines corresponding to each virtual machine type of the platform; for each virtual machine type, inputting the historical resource change data of the virtual machine into the large model to be trained to obtain training prediction data; and iteratively training the large model to be trained based on the training prediction data and the actual resource change data to obtain the trained large model.
[0007] In a preferred embodiment, the present invention may be further configured to include: obtaining first configuration information of the platform corresponding to historical resource change data; correspondingly, for each virtual machine type, inputting the historical resource change data of the virtual machine into the large model to be trained to obtain training prediction data, including: for each virtual machine type, inputting the historical resource change data of the virtual machine into the large model to be trained according to the first configuration information to obtain training prediction data.
[0008] In a preferred embodiment, the present invention may be further configured to include: obtaining second configuration information of the current platform; accordingly, based on the virtual machine type of the monitored virtual machine and the first resource change data, using a large model to predict the second resource change data of the monitored virtual machine in a future period; based on the second configuration information, the virtual machine type of the monitored virtual machine and the first resource change data, using a large model to predict the second resource change data of the monitored virtual machine in a future period.
[0009] In a preferred embodiment, the present invention may be further configured such that the first resource change data includes: CPU resource change data over time, memory change data over time, storage change data over time, and network change data over time.
[0010] In a preferred embodiment, the present invention may be further configured to include: obtaining a target time period to be predicted; correspondingly, based on the virtual machine type of the monitored virtual machine and the first resource change data, using a large model to predict the second resource change data of the monitored virtual machine in a future time period, including: based on the target time period, the virtual machine type of the monitored virtual machine and the first resource change data, using a large model to predict the second resource change data of the monitored virtual machine in the target time period.
[0011] In a preferred embodiment, the present invention may be further configured to include: predicting, based on the virtual machine type of the monitored virtual machine and the first resource change data, a third resource change data of the monitored virtual machine for a first time period using a large model; the maximum time of the first time period is less than the minimum time of the target time period; and predicting, based on the virtual machine type of the monitored virtual machine and the third resource change data, a fourth resource change data of the monitored virtual machine for a target time period using a large model.
[0012] Accordingly, alarm information is determined based on the second resource change data and the preset resource utilization threshold, including: determining alarm information based on the second resource change data, the fourth resource change data, and the preset resource utilization threshold.
[0013] Secondly, a resource monitoring device is provided, comprising: an acquisition module for acquiring first resource change data of a monitored virtual machine over a continuous period; a type determination module for determining the virtual machine type of the monitored virtual machine; a prediction module for predicting second resource change data of the monitored virtual machine in a future period using a large model based on the virtual machine type of the monitored virtual machine and the first resource change data; and an alarm module for determining alarm information based on the second resource change data and a preset resource utilization threshold.
[0014] Thirdly, an electronic device is provided, the electronic device including a memory and a processor, the memory storing a computer program, the processor executing the method of any one of the first aspects when running the computer program.
[0015] Fourthly, a computer-readable storage medium is provided, wherein at least one piece of program code is stored therein, the program code being loaded and executed by a processor to implement the resource monitoring method as described in any of the first aspects.
[0016] Fifthly, a computer program product is provided, including a computer program or instructions that, when executed by a processor, implement the resource monitoring method as described in any of the first aspects.
[0017] In summary, the resource monitoring method provided by this invention has the following beneficial technical effects: acquiring first resource change data for a continuous period of time for a monitored virtual machine; determining the virtual machine type of the monitored virtual machine; predicting second resource change data for a future period of the monitored virtual machine using a large model based on the virtual machine type and the first resource change data; and determining alarm information based on the second resource change data and a preset resource utilization threshold. By predicting the relationship between platform resource usage and time using a large model, if the predicted second resource change data exceeds the corresponding utilization threshold, it indicates that an anomaly may occur in the platform at a time when the utilization threshold is exceeded, generating alarm information to alert technical personnel. This timely alert reduces platform failures and ensures the reliability of platform operation.
[0018] In addition, the present invention also provides a resource monitoring device, equipment and medium, all of which have the above-mentioned beneficial technical effects. Attached Figure Description
[0019] To more clearly illustrate the embodiments of the present invention, the accompanying drawings used in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0020] Figure 1 This is a schematic diagram of a resource monitoring method provided in an embodiment of the present invention;
[0021] Figure 2 This is a schematic diagram of another resource monitoring method provided in an embodiment of the present invention;
[0022] Figure 3 This is a schematic diagram of the structure of a resource monitoring device provided in an embodiment of the present invention;
[0023] Figure 4 This is a schematic diagram of the structure of an electronic device provided in an embodiment of the present invention. Detailed Implementation
[0024] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative effort are within the protection scope of the present invention.
[0025] The terms "comprising" and "having," and any variations thereof, in the specification and accompanying drawings of this invention are intended to cover non-exclusive inclusion. For example, a process, method, system, product, or apparatus that includes a series of steps or units is not limited to the steps or units listed, but may include steps or units not listed.
[0026] To enable those skilled in the art to better understand the present invention, the present invention will be further described in detail below with reference to the accompanying drawings and specific embodiments.
[0027] Hyperconverged platforms typically only monitor platform resources in real time or make short-term predictions, lacking sufficient predictive power for the future. If the resource utilization of a hyperconverged platform does exceed a set threshold, it will impact platform performance. If it were possible to predict approximately when the platform's resource utilization will reach the threshold based on existing business needs and notify users in advance, it would provide them with ample time for adjustments and maintenance.
[0028] Therefore, to solve this problem, this invention proposes a method and apparatus for resource monitoring, threshold monitoring, and utilization prediction of hyperconverged platforms based on a large model. This invention achieves the following: 1) By analyzing existing services in the hyperconverged platform, it collects data on the CPU, memory, storage, and network resources used by virtual machines (VMs) during normal business operations over a certain period. 2) By classifying the VMs, it records the actual resource utilization of each type of VM over a certain period. 3) It processes and analyzes the collected VM data for each service type using a large model, outputting a curve showing the resource utilization of the VMs over time. 4) Based on the type and number of VMs currently running on the platform, and considering that hardware resource depletion and residual data can affect the performance of the hyperconverged platform, it predicts when the platform's resource utilization will reach a pre-set threshold under the current business conditions. 5) If the number of VMs is subsequently expanded, only the service type and number of VMs to be expanded need to be input into the large model; this method and apparatus can easily predict when the hyperconverged platform's utilization will reach the threshold.
[0029] This invention provides a resource monitoring method, such as... Figure 1 As shown, the method provided in this embodiment of the invention can be executed by an electronic device, and the method includes:
[0030] S101. Obtain the first resource change data of the monitored virtual machine for a continuous period of time;
[0031] In this embodiment of the invention, the continuous time period is not limited and can be a period of time preceding the current moment. The monitored virtual machine can be a virtual machine specified by the user to be monitored, or any virtual machine on the current platform.
[0032] In some embodiments, the first resource change data includes, but is not limited to: CPU resource change data over time, memory change data over time, storage change data over time, and network change data over time. Specifically, CPU resource change data over time represents the change in CPU utilization over time, memory change data over time represents the change in memory utilization over time, storage change data over time represents the change in storage utilization over time, and network change data over time represents the change in network utilization over time.
[0033] S102. Determine the virtual machine type of the monitored virtual machine;
[0034] In this embodiment of the invention, virtual machine types can be categorized based on their actual usage. For example, virtual machines used only for video processing and editing are classified as type 1; virtual machines used for text data acquisition, processing, and analysis are classified as type 2; and virtual machines used for model training are classified as type 3.
[0035] Specifically, the system pre-stores the processing business types of each virtual machine and the mapping relationship between business types and virtual machine types. Then, after identifying a monitored virtual machine, it matches its corresponding processing business type, and based on the processing business type, determines the appropriate virtual machine type. It is understood that other technologies or algorithms can also be used to determine the virtual machine type of a monitored virtual machine; this is not limited here.
[0036] It is understandable that different virtual machine types handle different services, resulting in significant differences in their resource usage. Therefore, this invention improves the accuracy of predictions by determining the virtual machine type of the monitored virtual machine and then predicting future resource changes.
[0037] S103. Based on the virtual machine type of the monitored virtual machine and the first resource change data, use a large model to predict the second resource change data of the monitored virtual machine in future time periods.
[0038] The virtual machine type and first resource change data of the monitored virtual machine are input into a large model to predict the second resource change data of the monitored virtual machine in future time periods. The future time periods are not limited in this embodiment of the invention and can be set according to actual needs, or several future periods can be randomly determined.
[0039] For large models, the embodiments of the present invention are no longer limited, and can be the current large language model or a model that can learn temporal changes. Users can choose according to their actual needs.
[0040] The second type of resource change data is data on how resource usage changes over time. It can be represented by data or by charts.
[0041] S104. Determine alarm information based on the second resource change data and the preset resource utilization threshold.
[0042] In this embodiment of the invention, a preset resource utilization threshold is set for the resources. Furthermore, if the data in a certain dimension of the predicted second resource change data exceeds the corresponding utilization threshold, it indicates that an anomaly may occur on the platform at a future time when the utilization threshold is exceeded. At this point, an alarm message is generated to alert technical personnel.
[0043] In some embodiments, resource change data includes: CPU resource change data over time, memory change data over time, storage change data over time, and network change data over time.
[0044] Based on this, the following methods are used: 1) Determine whether the CPU resource utilization threshold is exceeded based on the time-varying CPU resource data in the predicted second resource variable data; 2) Determine whether the memory utilization threshold is exceeded based on the time-varying memory data in the predicted second resource variable data; 3) Determine whether the storage utilization threshold is exceeded based on the time-varying storage data in the predicted second resource variable data; 4) Determine whether the network utilization threshold is exceeded based on the time-varying network data in the predicted second resource variable data. If none of these exceed the threshold, it indicates that the predicted resource changes in the future period will not be abnormal, and the alarm information is empty. If one exceeds the threshold, it indicates that the resource exceeding the threshold may experience an anomaly at the corresponding time, and an alarm is generated. The alarm information includes: basic information of the resource exceeding the threshold and the time of the anomaly. If more than one exceeds the threshold, it indicates that the resource exceeding the threshold may experience an anomaly at the corresponding time, and an alarm is generated. The alarm information includes: basic information of each resource exceeding the threshold and the time of the anomaly; and the warning time, which is the earliest anomaly time for the resource exceeding the threshold.
[0045] It is worth noting that if it is necessary to predict the resource usage of various business virtual machines on the hyperconverged platform, after predicting the resource usage of one of the monitored virtual machines, the resource usage of the other virtual machines should be predicted in sequence according to steps S101-S104.
[0046] Understandably, in this embodiment of the invention, a large model is used to train the system on the resource usage of various business virtual machines on the hyperconverged platform to derive the relationship between the resource usage of each type of business virtual machine and time. This large model can then be used to determine the relationship between the resource usage of the hyperconverged platform and time. If the large model predicts that the resource usage of the hyperconverged platform reaches a threshold at a certain point in time, the user is notified in advance, thus implementing an alert.
[0047] As can be seen, in this embodiment of the invention, the following steps are taken: first resource change data for a continuous period of time is acquired from the monitored virtual machine; the virtual machine type of the monitored virtual machine is determined; based on the virtual machine type and the first resource change data, a large model is used to predict the second resource change data for a future period of the monitored virtual machine; and alarm information is determined based on the second resource change data and a preset resource utilization threshold. By predicting the relationship between the platform's resource usage and time using a large model, if the predicted second resource change data exceeds the corresponding utilization threshold, it indicates that an anomaly may occur in the platform at a time when the utilization threshold is exceeded in the future. An alarm is then generated to alert technical personnel, enabling timely alerts, reducing platform failures, and ensuring the reliability of platform operation.
[0048] One possible implementation of this invention further includes: obtaining historical resource change data of virtual machines corresponding to each virtual machine type on the platform; for each virtual machine type, inputting the historical resource change data of the virtual machine into the large model to be trained to obtain training prediction data; and iteratively training the large model to be trained based on the training prediction data and the actual resource change data to obtain the trained large model.
[0049] In this embodiment of the invention, business virtual machines are classified according to virtual machine type. Resource usage data for various virtual machine types is collected. Specifically, the usage of resources such as CPU, memory, storage, and network during normal operation of each type of business virtual machine over a period of time is collected, i.e., historical resource change data. The collected historical resource change data is input into a large model for training. Specifically, by training the large model on the data of each type of business virtual machine, the relationship between virtual machine resource usage and time can be derived. Furthermore, by obtaining actual data of a certain type of business virtual machine on a specific day for verification, the model is continuously trained to improve its accuracy. The above training is performed for each type, completing the data processing for various business virtual machine types.
[0050] Understandably, large models can learn about the changes in resource usage over time for various virtual machine types by learning from the input data.
[0051] For example, historical resource change data could be data from one week, one month, or three months. Furthermore, during model training, this historical resource change data can be automatically segmented and used as training samples and labels for model training. Taking January data as an example, it can be divided into four weeks. The data from the first week can be used as training samples, and the data from the second week as actual data (labels) for model training. Alternatively, the data from each day can be used as training samples, and the data from the next day can be used as actual data (labels) for training, enabling the large model to predict any future period based on the data.
[0052] Furthermore, in one possible implementation, the first resource change data in this invention can be the historical resource change data / a segment of data in the historical resource change data / data from a certain period after the historical resource change data, and this embodiment of the invention is not limited thereto.
[0053] If the first resource change data is the same as the historical resource change data, then the large model can learn about resource changes through the historical resource change data, and then predict resource changes at any future demand moment based on the historical resource change data.
[0054] In this embodiment of the invention, model training is performed for each virtual machine type, so that the final large model can have the function of predicting resources of multiple virtual machine types.
[0055] The large model corresponding to all virtual machine types can be the same or different large models; this invention does not limit this.
[0056] As can be seen, in this embodiment of the invention, for each virtual machine type, the historical resource change data of the virtual machine is input into the large model to be trained to obtain training prediction data; based on the training prediction data and the actual resource change data, the large model to be trained is iteratively trained to obtain a trained large model, so that the large model has the function of prediction.
[0057] One possible implementation of this invention further includes:
[0058] Obtain the platform's first configuration information corresponding to historical resource change data;
[0059] Accordingly, for each virtual machine type, the historical resource change data of the virtual machine is input into the large model to be trained to obtain training prediction data, including:
[0060] For each virtual machine type, based on the first configuration information, the historical resource change data of the virtual machine is input into the large model to be trained to obtain training prediction data.
[0061] In this embodiment of the invention, when training a large model, the platform's first configuration information can be input into the large model, and training can be performed based on the first configuration information. The first configuration information is simply a set of input parameters. Furthermore, if the parameters change during subsequent actual predictions, the large model can adapt accordingly without affecting its functionality. In this embodiment of the invention, the first configuration information includes: the type and number of business virtual machines, and may also include: platform hardware resource consumption, and some other human or environmental factors.
[0062] One possible implementation of this invention further includes: obtaining second configuration information of the current platform; accordingly, using a large model to predict second resource change data of the monitored virtual machine in future periods based on the virtual machine type of the monitored virtual machine and the first resource change data; and using a large model to predict second resource change data of the monitored virtual machine in future periods based on the second configuration information, the virtual machine type of the monitored virtual machine, and the first resource change data.
[0063] Understandably, when using a large model for resource prediction, if the configuration information is the same as that of the platform used for training, predictions can be made directly based on the large model. However, if the configuration information on the platform changes, it may affect the accuracy of the predictions, requiring the new configuration information, i.e., the second configuration information, to be provided to the large model to allow for adaptive changes.
[0064] In one feasible approach, if virtual machine (VM) expansion occurs, since the services running on each type of VM are essentially the same, the first step is to determine the type and number of VMs. Then, the type and number of VMs to be expanded are input into a large model. This model uses collected data to assess and predict the resource utilization of the newly expanded VMs, allowing the large model to adaptively adjust its parameters. It's understandable that the resource consumption of a new VM for service operation differs from that of a VM running for extended periods. Therefore, it's necessary to assess the resource usage of the newly expanded VMs over time to allow the large model to adapt to the current situation and output more accurate predictions.
[0065] Therefore, it can also be determined whether the monitored virtual machine is an expanded virtual machine. If so, the information of the expanded virtual machine and the second configuration information are input into the large model so that the large model can make accurate predictions based on the actual situation after the expansion.
[0066] Furthermore, resource monitoring methods can also include: after business expansion, the type and number of expanded business virtual machines can be input into the large model, which then performs resource monitoring and prediction for the expanded platform.
[0067] As can be seen, in this embodiment of the invention, based on the platform's second configuration information, the second configuration information, the virtual machine type of the monitored virtual machine, and the first resource change data can be used to predict the second resource change data of the monitored virtual machine in future periods using a large model. This allows the large model to make targeted predictions based on the changes, thereby improving the accuracy of the predictions.
[0068] One possible implementation of this invention further includes: obtaining the target time period to be predicted; correspondingly, based on the virtual machine type of the monitored virtual machine and the first resource change data, using a large model to predict the second resource change data of the monitored virtual machine for a future time period, including: based on the target time period, the virtual machine type of the monitored virtual machine, and the first resource change data, using a large model to predict the second resource change data of the monitored virtual machine for the target time period. In this embodiment of the invention, the user can also choose the target time period to be predicted to optimize the user experience.
[0069] One possible implementation of this invention further includes: predicting third resource change data of the monitored virtual machine in a first time period using a large model based on the virtual machine type of the monitored virtual machine and the first resource change data; the maximum time of the first time period is less than the minimum time of the target time period; predicting fourth resource change data of the monitored virtual machine in the target time period using a large model based on the virtual machine type of the monitored virtual machine and the third resource change data; correspondingly, determining alarm information based on second resource change data and a preset resource utilization threshold, including: determining alarm information based on second resource change data, fourth resource change data and a preset resource utilization threshold.
[0070] Specifically, the virtual machine type and the first resource change data are input into the large model. Based on the patterns and rules learned during its training, the large model predicts the resource usage of the monitored virtual machines in the first time period and outputs the third resource change data. Using the large model, the virtual machine type and the third resource change data are used as input to predict the resource usage of the monitored virtual machines in the target time period, resulting in the fourth resource change data.
[0071] In one feasible approach, the second resource change data and the fourth resource change data are compared with preset resource utilization thresholds, respectively. If any resource indicator in the second resource change data or the fourth resource change data exceeds the preset threshold, a corresponding alarm message is generated.
[0072] In another possible approach, the second and fourth resource change data are averaged, and the average data is compared with a preset resource utilization threshold to generate corresponding alarm information.
[0073] As can be seen, in this embodiment of the invention, the change data of the first time period predicted based on the first resource change data is used as a new input for prediction again to obtain the fourth resource change data; and the alarm information is determined by combining the second resource change data and the fourth resource change data, which improves the accuracy.
[0074] One possible implementation of this invention further includes: predicting target time period change data using a large model based on the virtual machine type of the monitored virtual machine and the first half of the resource change data in the first resource change data; predicting target time period change data using a large model based on the virtual machine type of the monitored virtual machine and the second half of the resource change data in the first resource change data; averaging the two change data to obtain average change data; comparing the average change data and the second resource change data; if the similarity between the two reaches a preset threshold, then directly determining alarm information based on the second resource change data and a preset resource utilization threshold; otherwise, determining alarm information based on the average data of the average change data and the average of the second resource change data and a preset resource utilization threshold, or re-entering new first resource change data.
[0075] Based on any of the above embodiments, the present invention provides a specific monitoring method, referencing... Figure 2 ,include:
[0076] (1) Divide the business virtual machines into: business virtual machine 1, business virtual machine 2, and business virtual machine 3;
[0077] (2) Data collection on resource usage of various types of business virtual machines. Collect data on the usage of resources such as CPU, memory, storage, and network of various types of business virtual machines during normal operation over a period of time.
[0078] (3) Input the collected data into the large model for training. By training the large model on the data of each type of business virtual machine, the relationship between the resource usage of the virtual machine and the time over each day can be obtained. By obtaining the actual data of a certain type of business virtual machine on a certain day for verification, the large model is continuously trained to improve its accuracy.
[0079] During training, a custom deep learning model is built based on the dataset and then trained until the accuracy reaches over 95%. After training, the large model training module in this invention can continuously update the model based on actual user feedback. For example, if the usage rate output by the large model differs significantly from the actual usage rate, the user can interact with the large model and provide feedback on the data collected at that moment. The large model then trains based on this feedback. Because the large model has limitations in its analysis of this scenario, the weights of the causes of the problem are increased during training. This process enables continuous updating and optimization of the large model.
[0080] (4) Repeat step (3) to complete the data processing of business virtual machines of various business types. Output the relationship between the actual resource usage of various types of business virtual machines and time under the current platform each day.
[0081] (5) Alarm notification when the utilization rate of hyperconverged platform resources approaches the threshold. Since the performance of hardware resources on the platform is affected by the type and number of business virtual machines, platform hardware resource consumption, and some other human or environmental factors, this method predicts the performance and utilization rate of the platform based on the collected data. This method can predict for a relatively long period of time in the future. Once the risk of reaching the threshold is detected, the user will be notified to take action.
[0082] (6) If there is a business virtual machine expansion, for subsequent business expansion, you only need to input the type and number of business virtual machines to the large model. The large model will then monitor and predict resources for the expanded platform.
[0083] Specifically, since the services running on each type of business virtual machine are essentially the same, the first step is to determine the type and number of business virtual machines. Then, the type and number of the expanded virtual machines are input into the large model. This model will assess and predict the resource utilization of the newly expanded virtual machines based on the collected data. This is because of resource consumption; the resources consumed by a new virtual machine for business operation differ from those of a virtual machine running for a long time. Therefore, it is necessary to assess the resource usage of the newly expanded virtual machines over time.
[0084] As can be seen, in this embodiment of the invention, by classifying business virtual machines and collecting resource usage data of virtual machines of various business types as datasets, and inputting them into a large model, the relationship between resource usage of virtual machines of each business type and time can be obtained, thereby obtaining the relationship between resource usage of the hyperconverged platform and time. If subsequent expansion of business virtual machines is required, only the type and number of business virtual machines to be expanded need to be input into the large model to obtain the relationship between resource usage of the expanded hyperconverged platform and time. After adaptive adjustment, the large model can predict the resource usage of the current platform.
[0085] The following describes a resource monitoring device provided by an embodiment of the present invention. The device described below can be referred to in correspondence with the method described above. The device in this embodiment is installed in an electronic device. Figure 3 , Figure 3 This is a structural block diagram of a resource monitoring device according to one embodiment of the present invention, including: an acquisition module 210, used to acquire first resource change data of a monitored virtual machine over a continuous period; a type determination module 220, used to determine the virtual machine type of the monitored virtual machine; a prediction module 230, used to predict second resource change data of the monitored virtual machine in a future period using a large model based on the virtual machine type of the monitored virtual machine and the first resource change data; and an alarm module 240, used to determine alarm information based on the second resource change data and a preset resource utilization threshold.
[0086] In one possible implementation, the system further includes a training module, which is used to: acquire historical resource change data of virtual machines corresponding to each virtual machine type on the platform; input the historical resource change data of the virtual machine into the large model to be trained for each virtual machine type to obtain training prediction data; and iteratively train the large model to be trained based on the training prediction data and the actual resource change data to obtain the trained large model.
[0087] In one possible implementation, the system further includes: a first configuration information acquisition module, used to acquire the first configuration information of the platform corresponding to the historical resource change data; and a corresponding training module, used to: for each virtual machine type, input the historical resource change data of the virtual machine into the large model to be trained according to the first configuration information to obtain training prediction data.
[0088] In one possible implementation, the system further includes: a second configuration information acquisition module for acquiring the second configuration information of the current platform; and correspondingly, a prediction module 230 for: predicting the second resource change data of the monitored virtual machine in future time periods using a large model based on the second configuration information, the virtual machine type of the monitored virtual machine, and the first resource change data.
[0089] In one possible implementation, the first resource change data includes: CPU resource change data over time, memory change data over time, storage change data over time, and network change data over time.
[0090] In one possible implementation, the system further includes: a target time period acquisition module for acquiring the target time period to be predicted; and correspondingly, a prediction module 230 for: predicting the second resource change data of the monitored virtual machine during the target time period using a large model based on the target time period, the virtual machine type of the monitored virtual machine, and the first resource change data.
[0091] In one possible implementation, the prediction module 230 is further configured to predict the third resource change data of the monitored virtual machine in the first time period using a large model based on the virtual machine type of the monitored virtual machine and the first resource change data; the maximum time of the first time period is less than the minimum time of the target time period; and predict the fourth resource change data of the monitored virtual machine in the target time period using a large model based on the virtual machine type of the monitored virtual machine and the third resource change data; correspondingly, the alarm module 240 is configured to determine alarm information based on the second resource change data, the fourth resource change data and a preset resource utilization threshold.
[0092] Figure 4 A structural diagram of an electronic device provided in an embodiment of the present invention, such as... Figure 4 As shown, the electronic device includes: a memory 60 for storing computer programs;
[0093] The processor 61 is configured to implement the steps of the resource monitoring method as described in the above embodiments when executing a computer program.
[0094] The processor 61 may include one or more processing cores, such as a quad-core processor or an octa-core processor. The processor 61 may be implemented using at least one hardware form selected from Digital Signal Processing (DSP), Field-Programmable Gate Array (FPGA), and Programmable Logic Array (PLA). The processor 61 may also include a main processor and a coprocessor. The main processor, also known as the Central Processing Unit (CPU), is used to process data in the wake-up state; the coprocessor is a low-power processor used to process data in the standby state. In some embodiments, the processor 61 may integrate a Graphics Processing Unit (GPU), which is responsible for rendering and drawing the content to be displayed on the screen. In some embodiments, the processor 61 may also include an Artificial Intelligence (AI) processor, which handles computational operations related to machine learning.
[0095] The memory 60 may include one or more computer-readable storage media, which may be non-transitory. The memory 60 may also include high-speed random access memory and non-volatile memory, such as one or more disk storage devices or flash memory devices. In this embodiment, the memory 60 is used to store at least the following computer program 601, which, after being loaded and executed by the processor 61, is capable of implementing the relevant steps of the resource monitoring method disclosed in any of the foregoing embodiments. In addition, the resources stored in the memory 60 may also include an operating system 602 and data 603, etc., and the storage method may be temporary storage or permanent storage. The operating system 602 may include Windows, Unix, Linux, etc.
[0096] In some embodiments, the electronic device may further include a display screen 62, an input / output interface 63, a communication interface 64, a power supply 65, and a communication bus 66.
[0097] Those skilled in the art will understand that Figure 4 The structures shown do not constitute a limitation on electronic devices and may include more or fewer components than those shown.
[0098] It is understood that if the resource monitoring method in the above embodiments is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, in essence, or the part that contributes to the current technology, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and executes all or part of the steps of the methods in the various embodiments of the present invention. The aforementioned storage medium includes: USB flash drive, mobile hard drive, read-only memory (ROM), random access memory (RAM), electrically erasable programmable ROM, register, hard disk, removable disk, CD-ROM, magnetic disk, or optical disk, and other media capable of storing program code.
[0099] Based on this, embodiments of the present invention also provide a computer-readable storage medium storing a computer program, which, when executed by a processor, implements the steps of the resource monitoring method described above.
[0100] Based on this, embodiments of the present invention also provide a computer program product, including a computer program / instruction, which, when executed by a processor, implements the steps of the above-described resource monitoring method.
[0101] The resource monitoring method, apparatus, device, and medium provided by the embodiments of the present invention have been described in detail above. The various embodiments in the specification are described in a progressive manner, with each embodiment focusing on the differences from other embodiments. Similar or identical parts between embodiments can be referred to interchangeably. For the apparatus disclosed in the embodiments, since it corresponds to the method disclosed in the embodiments, the description is relatively simple; relevant parts can be referred to in the method section.
[0102] Those skilled in the art will further recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of both. To clearly illustrate the interchangeability of hardware and software, the components and steps of the various examples have been generally described in terms of functionality in the foregoing description. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementations should not be considered beyond the scope of this invention.
[0103] The resource monitoring method, apparatus, device, and medium provided by the present invention have been described in detail above. Specific examples have been used to illustrate the principles and implementation methods of the present invention. The descriptions of the embodiments above are only for the purpose of helping to understand the method and core ideas of the present invention. It should be noted that those skilled in the art can make various improvements and modifications to the present invention without departing from the principles of the invention, and these improvements and modifications also fall within the protection scope of the claims of the present invention.
Claims
1. A resource monitoring method, characterized in that, include: Obtain the first resource change data for the monitored virtual machine within a continuous time period; Determine the virtual machine type of the monitored virtual machine; Based on the virtual machine type of the monitored virtual machine and the first resource change data, a large model is used to predict the second resource change data of the monitored virtual machine in future time periods. Alarm information is determined based on the second resource change data and the preset resource utilization threshold.
2. The resource monitoring method according to claim 1, characterized in that, Also includes: Obtain historical resource change data for virtual machines corresponding to each virtual machine type on the platform; For each virtual machine type, the historical resource change data of the virtual machine is input into the large model to be trained to obtain training prediction data; based on the training prediction data and the actual resource change data, the large model to be trained is iteratively trained to obtain the trained large model.
3. The resource monitoring method according to claim 2, characterized in that, Also includes: Obtain the platform's first configuration information corresponding to historical resource change data; Accordingly, for each virtual machine type, the historical resource change data of the virtual machine is input into the large model to be trained to obtain training prediction data, including: For each virtual machine type, based on the first configuration information, the historical resource change data of the virtual machine is input into the large model to be trained to obtain training prediction data.
4. The resource monitoring method according to claim 3, characterized in that, Also includes: Obtain the second configuration information for the current platform; Accordingly, based on the virtual machine type of the monitored virtual machine and the first resource change data, a large model is used to predict the second resource change data of the monitored virtual machine in future time periods. Based on the second configuration information, the virtual machine type of the monitored virtual machine, and the first resource change data, a large model is used to predict the second resource change data of the monitored virtual machine in future time periods.
5. The resource monitoring method according to claim 1, characterized in that, The first resource change data includes: CPU resource change data over time, memory change data over time, storage change data over time, and network change data over time.
6. The resource monitoring method according to any one of claims 1 to 5, characterized in that, Also includes: Obtain the target time period that needs to be predicted; Accordingly, based on the virtual machine type of the monitored virtual machine and the first resource change data, a large model is used to predict the second resource change data of the monitored virtual machine for future periods, including: Based on the target time period, the virtual machine type of the monitored virtual machine, and the first resource change data, a large model is used to predict the second resource change data of the monitored virtual machine during the target time period.
7. The resource monitoring method according to claim 6, characterized in that, Also includes: Based on the virtual machine type of the monitored virtual machine and the first resource change data, the third resource change data of the monitored virtual machine in the first time period is predicted using a large model. The maximum time of the first time period is less than the minimum time of the target time period; Based on the virtual machine type of the monitored virtual machine and the third resource change data, the fourth resource change data of the monitored virtual machine for the target time period is predicted using a large model. Accordingly, alarm information is determined based on the second resource change data and the preset resource utilization threshold, including: Alarm information is determined based on the second resource change data, the fourth resource change data, and the preset resource utilization threshold.
8. A resource monitoring device, characterized in that, include: The acquisition module is used to acquire the first resource change data of the monitored virtual machine over a continuous period of time. A type determination module is used to determine the virtual machine type of the monitored virtual machine; The prediction module is used to predict the second resource change data of the monitored virtual machine in future time periods based on the virtual machine type and the first resource change data of the monitored virtual machine using a large model. The alarm module is used to determine alarm information based on the second resource change data and the preset resource utilization threshold.
9. An electronic device, characterized in that, include: Memory, used to store computer programs; A processor for executing the computer program to implement the resource monitoring method as described in any one of claims 1 to 7.
10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program that, when executed by a processor, implements the resource monitoring method as described in any one of claims 1 to 7.
