Virtual machine starting control method and device based on clone cloud disk and electronic equipment

By downloading multiple snapshot copies and forming cloned cloud disks during the virtual machine startup process, the performance degradation caused by cloud disk read hotspots is resolved, achieving more efficient virtual machine startup.

CN119025219AActive Publication Date: 2024-11-26BEIJING VOLCANO ENGINE TECH CO LTD

Patent Information

Application Number
CN202411117910.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-08-14
Publication Date
2024-11-26
Estimated Expiration
2044-08-14

AI Technical Summary

Technical Problem

Cloud disks can easily create read hotspots during the rapid startup of virtual machines, leading to increased pressure on the storage cluster and reduced performance.

Method used

By receiving lazy loading requests, the target snapshot data is obtained and multiple snapshot copies are downloaded to form a cloned cloud disk. Data is loaded using the log files corresponding to multiple sets of snapshot copies to avoid read hotspots.

Benefits of technology

It improved the performance of cloud disks, reduced read hotspot issues, and increased virtual machine startup speed.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119025219A_ABST
    Figure CN119025219A_ABST
Patent Text Reader

Abstract

The embodiment of the invention provides a virtual machine starting control method and device based on a cloned cloud disk and electronic equipment, and the method comprises the steps: receiving a lazy loading request sent by a virtual machine to the cloud disk stored by an elastic block, obtaining target snapshot data, and sending a snapshot downloading request to a mirror image center, so as to download at least two snapshot copies, the cloud disk is used for storing data resources required for starting the virtual machine, the snapshot copy is mirror image data of the data resources required for starting the virtual machine, and the target snapshot data is data resources required for running a target function of the virtual machine; respectively connecting each cloud disk to the corresponding snapshot copy so as to obtain log files respectively corresponding to the at least two snapshot copies; and loading a log file corresponding to the snapshot copy through the cloud disk to form a cloned cloud disk, and starting the virtual machine based on the cloned cloud disk. The performance of the cloud disk is improved by downloading a plurality of snapshot copies from the mirror center during lazy loading.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The embodiments of the present disclosure relate to the field of cloud computing technology, and in particular to a virtual machine startup control method, device, and electronic device based on a cloned cloud disk. Background Art

[0002] Currently, there are a lot of elastic demands in cloud computing services, such as Elastic Compute Service (ECS). The system can quickly start a large number of virtual machines through batch cloning according to user needs. In this process, in order to achieve the rapid start of the virtual machine, the system will use lazy loading technology to download some block data during the virtual machine startup process while downloading the image data and load it to the corresponding cloud disk, thereby achieving the rapid start of the virtual machine. After that, after the image data is downloaded, the data resources are loaded to the cloud disk through the image data to achieve the complete start of the virtual machine.

[0003] In the prior art, when a cloud disk loads data resources through downloaded image data, a read hotspot is easily formed, thereby putting pressure on the storage cluster and reducing the performance of the cloud disk. Summary of the invention

[0004] The embodiments of the present disclosure provide a virtual machine startup control method, device and electronic device based on a cloned cloud disk to overcome the problem that a cloud disk easily forms a read hotspot.

[0005] In a first aspect, an embodiment of the present disclosure provides a virtual machine startup control method based on a cloned cloud disk, comprising:

[0006] Receive a lazy loading request sent by the virtual machine to the cloud disk of the elastic block storage, obtain target snapshot data, and send a snapshot download request to the image center to download at least two snapshot copies, wherein the cloud disk is used to store data resources required to start the virtual machine, the snapshot copy is the image data of the data resources required to start the virtual machine, and the target snapshot data is the data resources required to run the target function of the virtual machine; connect each of the cloud disks to the corresponding snapshot copy to obtain the log files corresponding to the at least two snapshot copies; load the log file corresponding to the snapshot copy through the cloud disk to form a cloned cloud disk, and start the virtual machine based on the cloned cloud disk.

[0007] In a second aspect, an embodiment of the present disclosure provides a virtual machine startup control device based on a cloned cloud disk, comprising:

[0008] a processing module, configured to receive a lazy load request sent by a virtual machine to a cloud disk of elastic block storage, obtain target snapshot data, and send a snapshot download request to an image center to download at least two snapshot copies, wherein the cloud disk is used to store data resources required to start the virtual machine, the snapshot copies are image data of the data resources required to start the virtual machine, and the target snapshot data are data resources required to run a target function of the virtual machine;

[0009] A storage module, used to connect each of the cloud disks to the corresponding snapshot copies, so as to obtain log files corresponding to the at least two snapshot copies respectively;

[0010] The loading module is used to load the log file corresponding to the snapshot copy through the cloud disk to form a clone cloud disk, and start the virtual machine based on the clone cloud disk.

[0011] In a third aspect, an embodiment of the present disclosure provides an electronic device, including: a processor and a memory;

[0012] The memory stores computer-executable instructions;

[0013] The processor executes the computer-executable instructions stored in the memory, so that the at least one processor executes the virtual machine startup control method based on the cloned cloud disk as described in the first aspect and various possible designs of the first aspect.

[0014] In a fourth aspect, an embodiment of the present disclosure provides a computer-readable storage medium, in which computer execution instructions are stored. When a processor executes the computer execution instructions, the virtual machine startup control method based on the cloned cloud disk as described in the first aspect and various possible designs of the first aspect is implemented.

[0015] In a fifth aspect, an embodiment of the present disclosure provides a computer program product, including a computer program, which, when executed by a processor, implements the virtual machine startup control method based on the cloned cloud disk as described in the first aspect and various possible designs of the first aspect.

[0016] The virtual machine startup control method, device and electronic device based on clone cloud disk provided in this embodiment, by receiving a lazy loading request sent by the virtual machine to the cloud disk of elastic block storage, obtains the target snapshot data, and sends a snapshot download request to the mirror center to download at least two snapshot copies, wherein the cloud disk is used to store the data resources required to start the virtual machine, the snapshot copy is the mirror data of the data resources required to start the virtual machine, and the target snapshot data is the data resources required to run the target function of the virtual machine; each of the cloud disks is respectively connected to the corresponding snapshot copy to obtain the log files corresponding to the at least two snapshot copies; the log files corresponding to the snapshot copies are loaded through the cloud disk to form a clone cloud disk, and the virtual machine is started based on the clone cloud disk. By downloading multiple snapshot copies from the mirror center during lazy loading, multiple groups of log files corresponding to the snapshot copies are formed in the file storage system, so that the cloud disk can obtain the required data resources from the multiple groups of log files respectively to form a clone cloud disk, avoid the formation of the cloud disk read hot spot problem, and improve the performance of the cloud disk. BRIEF DESCRIPTION OF THE DRAWINGS

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

[0018] Figure 1 An application scenario diagram of the virtual machine startup control method based on cloned cloud disk provided in the embodiment of the present disclosure;

[0019] Figure 2 A schematic diagram of the process of the virtual machine startup control method based on the cloned cloud disk provided in the embodiment of the present disclosure Figure 1 ;

[0020] Figure 3 for Figure 2 A flowchart of a specific implementation method of step S102 in the illustrated embodiment;

[0021] Figure 4 A schematic diagram of a process of connecting a cloud disk to multiple snapshot copies provided by an embodiment of the present disclosure;

[0022] Figure 5 A schematic diagram of the process of the virtual machine startup control method based on the cloned cloud disk provided in the embodiment of the present disclosure Figure 2 ;

[0023] Figure 6 for Figure 5A flowchart of a specific implementation method of step S204 in the illustrated embodiment;

[0024] Figure 7 for Figure 6 A flowchart of a specific implementation method of step S2042 in the illustrated embodiment;

[0025] Figure 8 for Figure 5 A flowchart of a specific implementation method of step S208 in the illustrated embodiment;

[0026] Fig. 9 A structural block diagram of a virtual machine startup control device based on a cloned cloud disk provided in an embodiment of the present disclosure;

[0027] Fig.10 A schematic diagram of the structure of an electronic device provided in an embodiment of the present disclosure;

[0028] Fig.11 A schematic diagram of the hardware structure of an electronic device provided in an embodiment of the present disclosure. DETAILED DESCRIPTION

[0029] In order to make the purpose, technical solution and advantages of the embodiments of the present disclosure clearer, the technical solution in the embodiments of the present disclosure will be clearly and completely described below in conjunction with the drawings in the embodiments of the present disclosure. Obviously, the described embodiments are part of the embodiments of the present disclosure, not all of the embodiments. Based on the embodiments in the present disclosure, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present disclosure.

[0030] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in this disclosure are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of relevant data must comply with the relevant laws, regulations and standards of relevant countries and regions, and provide corresponding operation entrances for users to choose to authorize or refuse.

[0031] First, the existing technical terms in this field are introduced:

[0032] Virtual Machine (VM): refers to a complete computer system with complete hardware system functions simulated by software and running in a completely isolated environment. It is provided by cloud service providers to cloud tenants.

[0033] Elastic Computing Service (ECS): A service provided by a cloud service that is used to dynamically expand and shrink computing resources (such as memory, bandwidth, infrastructure, etc.).

[0034] Elastic Block Storage (EBS): A service provided by a cloud service that is used to dynamically expand and shrink storage resources.

[0035] Node: a service machine in ECS and EBS

[0036] Cluster: In ECS and EBS, a management unit consisting of multiple nodes

[0037] Availability Zone (AZ): A management unit for independent power and network resources in cloud computing, including multiple clusters

[0038] Region: A single regional management unit in cloud computing, including multiple availability zones.

[0039] Cloud disk (BlockDevice): A virtual block device provided by EBS, including empty disks and snapshot clone cloud disks.

[0040] Cloud disk segment (DeviceSegment): The cloud disk is divided into segments according to a fixed size, for example: 32GB.

[0041] Snapshot: A value-added service of EBS that saves instantaneous data snapshots of cloud disks on object storage.

[0042] SnapshotCopy: The storage format of snapshot data after it is downloaded to the EBS cluster.

[0043] Snapshot Segment: The snapshot copy is divided into segments according to a fixed size, for example: 4GB.

[0044] Strip: Packet strip size (e.g. 32KB), number of stripes (e.g. 64).

[0045] Image: A single snapshot or a group of snapshots used to start a VM. Data is stored in the format of snapshots.

[0046] Image Center: The module in ECS responsible for managing images.

[0047] Batch cloning: Create cloud disks in batches through an image, and run virtual machine instances in batches based on the cloud disks.

[0048] Lazy loading: When creating a virtual machine through an image and starting it, the virtual machine can be started directly without waiting for the image data to be loaded into the cloud disk.

[0049] The application scenarios of the embodiments of the present disclosure are explained below:

[0050] Figure 1 This is an application scenario diagram of the virtual machine startup control method based on the cloned cloud disk provided in the embodiment of the present disclosure. The virtual machine startup control method based on the cloned cloud disk provided in the embodiment of the present disclosure can be applied to the application scenario of batch cloning and starting virtual machines. The execution subject of this embodiment can be a physical machine or server that provides elastic computing services or elastic computing services, as well as electronic devices that perform similar functions.

[0051] Among them, in some embodiments, the above-mentioned physical machines, servers and other devices can implement the virtual machine startup control method based on cloned cloud disk provided in the embodiment of the present application by running various computer executable instructions or computer programs. For example, computer executable instructions can be program-level commands, machine instructions or software instructions. The computer program can be a native program or software module in the operating system; it can be a local application, that is, a program that needs to be installed in the operating system to run, or it can be a program that runs based on a browser environment. In summary, the above-mentioned computer executable instructions can be instructions in any form, and the above-mentioned computer programs can be applications, modules or plug-ins in any form, and the specific implementation form can be configured as needed. Further, in some embodiments, the physical machine and server can be an independent physical server, or a server cluster or distributed system composed of multiple physical servers, or a cloud server that provides cloud services, cloud storage, cloud communications, cloud databases, cloud computing, cloud functions, network services, middleware services, domain name services, security services, content delivery networks (Content Delivery Network, CDN), and basic cloud computing services such as big data and artificial intelligence platforms.

[0052] refer to Figure 1As shown in , in the application scenario of batch cloning virtual machines, lazy loading technology is used to quickly clone cloud disks and start virtual machines. The specific process is: after the VM in the ECS cluster sends a lazy loading request to the cloud disk in the EBS cluster, on the one hand, the cloud disk in the EBS cluster sends a data read request to the object storage unit to obtain the corresponding block data and write it to the cloud disk; on the other hand, the cloud disk in the EBS cluster sends a request from the image center (object storage unit) to download the snapshot copy. After the snapshot copy is downloaded, the data sharing of the snapshot copy is realized by generating a log file in the distributed file system. The cloud disk sends a file read request for the log file of the snapshot copy to the distributed file system, so as to write the above log file to the cloud disk, and finally realizes the cloning of the cloud disk and completes the startup process of the virtual machine.

[0053] In the prior art, in the cloud disk batch cloning scenario, after the snapshot copy is downloaded, it will be shared with a large number of cloud disks at the same time. When these cloud disks initiate data read requests at the same time, the log data corresponding to the snapshot copy is likely to form a read hotspot, thereby putting pressure on the storage cluster and reducing the performance of the cloud disk.

[0054] The disclosed embodiment provides a virtual machine startup control method based on a cloned cloud disk to solve the above problem.

[0055] refer to Figure 2 , Figure 2 A schematic diagram of the process of the virtual machine startup control method based on the cloned cloud disk provided in the embodiment of the present disclosure Figure 1 The method of this embodiment can be applied in a server. The virtual machine startup control method based on a cloned cloud disk includes:

[0056] Step S101: Receive a lazy loading request sent by the virtual machine to the cloud disk of the elastic block storage, obtain the target snapshot data, and send a snapshot download request to the image center to download at least two snapshot copies, wherein the cloud disk is used to store the data resources required to start the virtual machine, the snapshot copy is the mirror data of the data resources required to start the virtual machine, and the target snapshot data is the data resources required to run the target function of the virtual machine.

[0057] Step S102: Connect each cloud disk to the corresponding snapshot copy to obtain log files corresponding to at least two snapshot copies.

[0058] Step S103: Load the log file corresponding to the snapshot copy through the cloud disk to form a cloned cloud disk, and start the virtual machine based on the cloned cloud disk.

[0059] For example, reference Figure 1In the application scenario diagram shown, the cloud disk is a functional unit for storing data resources required to start the virtual machine, where the data resources include, for example, operating systems, applications, configuration files and other data required to run the virtual machine. The cloud disk is located in the elastic block storage and can be flexibly added or deleted as needed. When the virtual machine in the elastic computing service cluster is started, it needs to load the corresponding resource data into the cloud disk, so it will send a data loading request to the cloud disk located in the elastic block storage to instruct the cloud disk to load the resource data. In the scenario where the virtual machine is started based on the lazy loading technology, the virtual machine will send a lazy loading request to the cloud disk located in the elastic block storage. After receiving the lazy loading request, the cloud disk will obtain the corresponding block data required to run the target function of the virtual machine from the external object storage unit according to the current startup state and stage of the virtual machine, that is, the target snapshot data. The specific implementation method is, for example: sending a data read request for the target snapshot data to the object storage unit, receiving the target snapshot data returned by the object storage unit, and writing the target snapshot data to the cloud disk at the same time, so as to start the target function of the virtual machine based on the target snapshot data in the cloud disk. On the other hand, the cloud disk will send a snapshot download request to the mirror center to download at least two snapshot copies. The snapshot copy is a snapshot data format, which is the mirror data of the data resources required to start the virtual machine. The snapshot copy is a necessary resource required to clone the cloud disk. Its specific implementation method is the existing technology and will not be repeated here.

[0060] It should be noted that in the steps of this embodiment, the snapshot download request from the cloud disk to the mirror center will download at least two snapshot copies from the mirror center. At the same time, each cloud disk is connected to the corresponding snapshot copy to obtain the log file corresponding to the snapshot copy. The log file is another data storage format of the snapshot copy, which is stored in a distributed file storage system, and then the log sentence is distributed through the file storage system to realize the sharing of the snapshot copy. In one possible implementation, Figure 3 As shown, the specific implementation of step S102 includes:

[0061] Step S1021: Sending a mirror data read request to the distributed file storage system via the cloud disk;

[0062] Step S1022: Obtain the log file corresponding to the snapshot copy through the file storage system, and send it to the corresponding cloud disk.

[0063] Exemplarily, the file storage system may be a distributed file storage server, which is arranged inside or outside the device that is the execution subject of this embodiment. After sending a mirror data read request to the file storage system through the cloud disk, the file storage system retrieves the corresponding snapshot copy, and returns it to the corresponding cloud disk based on the data transmission strategy of the distributed system, so that the cloud disk obtains the connected snapshot copy log file.

[0064] Afterwards, the cloud disk loads the log file to form a clone cloud disk. The clone cloud disk is a virtual block device formed by loading the data resources corresponding to the snapshot copy. The content it carries is a "clone" of the data provided by the snapshot service, ultimately achieving the purpose of cloning and starting the virtual machine.

[0065] Based on the above introduction, it can be known that after receiving the lazy loading request, the cloud disk can be divided into two execution stages from the focus of driving the virtual machine to start. The first execution stage is before the snapshot copy is downloaded. It is the process of driving the operation and startup of some functions of the virtual machine by obtaining the target snapshot data from the object storage unit and writing the target snapshot data to the cloud disk, that is, the lazy loading stage. The second execution stage is after the snapshot copy is downloaded. The cloud disk sends a data request to the file storage system to obtain the log file corresponding to the snapshot copy, and forms a clone cloud disk by loading the log file.

[0066] Among them, the read traffic control during the first execution stage is different from the read traffic control after the snapshot copy is downloaded in the second execution stage, because the main read in the lazy loading stage is to read from the memory cache or from the object storage. Therefore, the traffic is only related to the number of nodes in the cluster, and the traffic dispersion in the lazy loading stage can be completely dispersed on all nodes, and all cloud disks in the lazy loading stage share the same bandwidth. In the second execution stage after the snapshot copy is downloaded, although it can be dispersed on all nodes, the traffic of a single data block will still be limited by the service thread and the hard disk bandwidth, thereby affecting the read performance of the cloud disk. In this embodiment, since multiple snapshot copies are stored in the elastic block storage, correspondingly, log files corresponding to multiple snapshot copies will be formed in the file storage system, which is equivalent to increasing the total bandwidth resource supply, so that when the cloud disk accesses the above log files, the impact of bandwidth resource limitations on data transmission performance will be reduced, thereby improving the performance of the cloud disk.

[0067] Figure 4 A schematic diagram of a process of connecting a cloud disk to multiple snapshot copies provided by an embodiment of the present disclosure is shown in FIG. Figure 4As shown, exemplarily, after the cloud disk sends a download request to the mirror center, multiple snapshot backups are downloaded in the elastic block storage (EBS cluster), and the snapshot backups are stored in the distributed file storage system in the form of log files. In the process of continuously creating cloud disks in the elastic block storage (shown as Device in the figure), each cloud disk is connected to the corresponding snapshot backup, and the corresponding log file is obtained through the distributed file storage system, so that each cloud disk can load the above log file with a large read flow, so as to quickly complete the cloud disk cloning and improve the performance of the cloud disk.

[0068] In this embodiment, after receiving a lazy loading request sent by a virtual machine in an elastic computing service cluster to a cloud disk located in an elastic block storage, the target snapshot data is obtained, and a snapshot download request is sent to a mirror center to download at least two snapshot copies, wherein the cloud disk is used to store the data resources required to start the virtual machine, the snapshot copy is the mirror data of the data resources required to start the virtual machine, and the target snapshot data is the data resources required to run the target function of the virtual machine; each cloud disk is connected to the corresponding snapshot copy to obtain the log file corresponding to the snapshot copy; the log file corresponding to the snapshot copy is loaded through the cloud disk to form a clone cloud disk, and the virtual machine is started based on the clone cloud disk. By downloading multiple snapshot copies from the mirror center during lazy loading, multiple groups of log files corresponding to the snapshot copies are formed in the file storage system, so that the cloud disk can obtain the required data resources from the multiple groups of log files respectively to form a clone cloud disk, avoid the formation of a read hot spot problem of the cloud disk, and improve the performance of the cloud disk.

[0069] refer to Figure 5 , Figure 5 A schematic diagram of the process of the virtual machine startup control method based on the cloned cloud disk provided in the embodiment of the present disclosure Figure 2 In this embodiment Figure 2 On the basis of the illustrated embodiment, the steps of determining the number of snapshot copies and setting the upper limit of the traffic of the cloud disk are further added. The virtual machine startup control method based on the cloned cloud disk includes:

[0070] Step S201: receiving a lazy loading request sent by a virtual machine in an elastic computing service cluster to a cloud disk in an elastic block storage.

[0071] Step S202: Obtain target snapshot data through the object storage unit, and start the target function of the virtual machine based on the target snapshot data in the cloud disk. The target snapshot data is the data resource required to run the target function of the virtual machine.

[0072] Step S203: Obtain the traffic data and delay data of the cloud disk.

[0073] Step S204: Determine the target number of snapshot copies based on the traffic data and latency data of the cloud disk.

[0074] Exemplarily, in this embodiment, before sending a snapshot download request to the image center, the number of snapshot copies downloaded is first determined. Since the number of cloud disks created by the user / virtual machine (the number of created disks) is uncertain, how to determine the appropriate number of snapshot copies will directly affect the performance of the final cloud disk. Specifically, the traffic data is data that characterizes the current real-time traffic of the cloud disk, such as 30 megabits per second (Mb / s). The delay data is data that characterizes the delay duration of the cloud disk, such as 39 microseconds (μs). A possible implementation method can directly determine the target number of snapshot copies by comparing the traffic data and delay data of the cloud disk with the corresponding traffic threshold and delay threshold. For example, when the traffic data of the cloud disk exceeds the traffic threshold by a larger amount (i.e., the traffic is too large), the target number of snapshot copies is more, or the increase based on the current number of snapshot copies is more; and / or, when the delay data of the cloud disk exceeds the delay threshold by a larger amount (i.e., the delay is too large), the target number of snapshot copies is more, or the increase based on the current number of snapshot copies is more.

[0075] In one possible implementation, Figure 6 As shown, the specific implementation of step S204 includes:

[0076] Step S2041: Obtain the number of cloud disks in the elastic block storage.

[0077] Step S2042: Determine the target number of snapshot copies according to the number of cloud disks, the traffic data of each cloud disk, and the delay data of each cloud disk.

[0078] For example, in another possible implementation, the number of cloud disks currently in the elastic block storage, that is, the number of created disks, and the traffic data and latency data of each disk can be combined to comprehensively calculate an optimized target number to make the number of snapshot copies more reasonable. For example, based on the traffic data and latency data, the average traffic required by a single cloud disk is evaluated respectively, and then the total traffic required by the cloud disk is obtained in combination with the number of cloud disks; then, the number of snapshot copies is obtained based on the ratio of the total traffic required by the cloud disk to the traffic that can be provided by a single snapshot copy.

[0079] Furthermore, in another possible implementation, as Figure 7 As shown, the specific implementation of step S2042 includes:

[0080] Step S2042A: Determine the delay ratio based on the delay data of each cloud disk and the cloud disk delay threshold.

[0081] Step S2042B: According to the delay ratio and the current flow limit value of each cloud disk, the average flow of a single cloud disk is obtained.

[0082] Step S2052C: According to the ratio of the flow rate provided by the single snapshot copy to the average flow rate, the number of cloud disk connections to which the single snapshot copy can be connected is obtained.

[0083] Step S2052D: Obtain the target number according to the number of cloud disks and the number of cloud disks to which a single snapshot copy can be connected.

[0084] For example, after the lazy loading request is sent, if multiple snapshots are created at the same time, multiple snapshots and multiple disks will share the lazy loading bandwidth. In this scenario, the cloud disk bandwidth of a single snapshot copy may not trigger the traffic threshold for expanding the copy, but the actual traffic required by the cloud disk is still large. Therefore, when the traffic is scattered during lazy loading, consider that the lazy loading traffic is distributed to each cloud disk during lazy loading to ensure the smoothness of the traffic, and the delay can be converted accordingly based on the traffic limiting. Specifically, when the flow limit is not enough to support the traffic of the cloud disk, the corresponding average delay increases. We can reverse the delay to determine how much traffic the cloud disk needs to support the decision of how many copies are needed. Assuming that the current flow limit is 30MB / s, the average delay of the cloud disk that does not trigger the flow limit is 400us. When the flow limit occurs, the average delay rises to 800us, and IO is in the queue, the expected required traffic needs to be about 60MB / s.

[0085] Based on the above example, we can infer how much traffic is needed based on lazy load flow limiting and cloud disk latency, and then determine the number of replicas. Specifically, formula (1) is used to calculate the number of cloud disk connections that a single snapshot replica can connect to, M. T , as shown in formula (1):

[0086] M T =Z*S / ((∑ 0<j<n Y / X*V j ) / n) (1)

[0087] Where X is the average delay without triggering current limiting;

[0088] Y is the average latency of a single cloud disk at present;

[0089] V is the current limit of a single cloud disk;

[0090] S is the traffic that a single replica can provide;

[0091] Z is the flow utilization coefficient;

[0092] T is the time;

[0093] n is the number of cloud disks.

[0094] First, the delay ratio, i.e., Y / X, is obtained based on the ratio of the delay data of each cloud disk to the delay threshold of the cloud disk when the flow limit is not triggered. Then, the average flow of a single cloud disk is obtained based on the cumulative value of the product of the delay ratio and the current flow limit value of each cloud disk, that is, the product of the delay ratio and the flow limit V of a single cloud disk is calculated, and the cumulative sum is obtained for all cloud disks. Then, the cumulative sum is divided by the number of cloud disks n to obtain the cumulative value of the product of the delay ratio and the current flow limit value of each cloud disk for each cloud disk, and the average flow of the cloud disk when it is running stably is obtained. Then, the product of the flow S that a single replica can provide and the usage coefficient Z is calculated. For example, Z is 0.8, which represents the actual usage rate, and the actual flow that a single replica can provide is obtained. Then, the ratio of the actual flow to the average flow is calculated to obtain the number of connections M. T . Finally, the target number is obtained based on the ratio of the number of cloud disks to the number of cloud disks that a single snapshot copy can connect to. For example, if the actual flow that a single copy can provide is 1000Mb / S and the average flow of a single cloud disk is 50Mb / S, then the number of cloud disks that a single snapshot copy can connect to is 20. If the current number of cloud disks is 100, then the target number is 5 based on the ratio of the current number of cloud disks 100 to the number of connections 20.

[0095] Furthermore, in a possible implementation, it is also necessary to control the number of connections M. T Within an appropriate range, that is, less than the maximum number of connections and greater than the minimum number of connections. The maximum number of connections can be determined by the minimum set flow value of a single cloud disk; and the minimum number of connections can be determined by the maximum set flow value of a single cloud disk, which will not be repeated here.

[0096] Step S205: Send a first snapshot download request to the mirror center to download a target number of snapshot copies from the mirror center.

[0097] It should be noted that the step of sending the first snapshot download request to the mirror center in the steps of this embodiment can be repeated multiple times, that is, the process of executing lazy loading in the cloud disk will determine the real-time target number of snapshot copies based on the number of cloud disks in the current cloud disk, the traffic data of each cloud disk and the delay data of each cloud disk, thereby realizing dynamic adjustment of the snapshot copies.

[0098] Step S206: Connect each cloud disk to the corresponding snapshot copy to obtain the log file corresponding to the snapshot copy.

[0099] Step S207: Load the log file corresponding to the snapshot copy through the cloud disk to form a cloned cloud disk, and start the virtual machine based on the cloned cloud disk.

[0100] Optionally, this embodiment also includes:

[0101] Step S208: Set the traffic limit of the cloud disk according to the traffic data and delay data of the cloud disk.

[0102] In a possible implementation, while dynamically setting the snapshot copy, the upper limit of the cloud disk traffic can be dynamically set based on the traffic data and delay data of the cloud disk, thereby avoiding the problem of excessive or insufficient traffic on a single cloud disk and improving the utilization of the cloud disk bandwidth. For example, the traffic data of the cloud disk is S and the delay data is D. Specifically:

[0103] When S = traffic limit and D>X, increase the traffic limit of the cloud disk;

[0104] When S<the upper limit of traffic flow and D=X, the upper limit of traffic flow of the cloud disk is reduced;

[0105] When S<traffic limit and D>X, the traffic limit of the cloud disk will not be adjusted.

[0106] Where X is the cloud disk delay threshold. Through the above method, the flow limit can be adjusted.

[0107] For example, Figure 8 As shown, the specific implementation of step S208 includes:

[0108] Step S2081: Obtain the current traffic limit of each cloud disk.

[0109] Step S2082: Determine the target cloud disk based on the relationship between the traffic data of the cloud disk and the preset current limit value, and the relationship between the delay data and the delay threshold.

[0110] Step S2083: Update the current traffic limit of the target cloud disk according to the mean square error of the delay data of the target cloud disk.

[0111] For example, first, the delay data of the cloud disk is represented as X. After obtaining the current traffic limit of each cloud disk, the cloud disk whose traffic limit needs to be increased and the cloud disk whose traffic limit needs to be reduced can be determined as the target cloud disk in the manner described in the above example. This process will not be described in detail. After that, the mean square error is calculated for the delay of all target cloud disks. If the mean square error is less than the mean square error threshold, no adjustment is made; if the mean square error is greater than the mean square error threshold, an adjustment is made. The specific implementation of the mean square error threshold can be set according to business needs and is not limited here.

[0112] Furthermore, it also includes:

[0113] S2080A: Obtain a basic business coefficient, where the basic business coefficient is used to characterize a business level corresponding to the virtual machine.

[0114] S2080B: Obtain a delay threshold according to the business basic coefficient and the average delay of each cloud disk.

[0115] Furthermore, in order to consider the user's priority dimension, in the steps of this embodiment, the cloud disk delay threshold can be adjusted by further increasing the weight coefficient. The higher the user priority, the lower the weight coefficient, so that important users and businesses can obtain a greater elasticity coefficient. Among them, exemplarily, the priority includes three levels, namely: high: basic coefficient 0.8, Mid: basic coefficient 0.9, Low: basic coefficient 1.0. By calculating the basic coefficient * average delay, the cloud disk delay threshold combined with the business level is defined. Thereby improving the performance of the cloud disk corresponding to important users and businesses.

[0116] In this embodiment, the implementation method of step S201 and step S202 is the same as that of the present disclosure. Figure 2 The implementation methods of step S101 and step S102 in the illustrated embodiment are the same and will not be described in detail here.

[0117] Corresponding to the virtual machine startup control method based on cloned cloud disk in the above embodiment, Fig. 9 A structural block diagram of a virtual machine startup control device based on a cloned cloud disk provided in an embodiment of the present disclosure. The method described in the above embodiment can be executed by the virtual machine startup control device based on a cloned cloud disk, which can be implemented by software and / or hardware, and can be integrated in an electronic device with certain data processing functions. Among them, the electronic device can include but is not limited to mobile terminals with big data processing capabilities, as well as fixed terminals with big data processing capabilities such as desktop computers and supercomputers.

[0118] For the sake of convenience, only the parts related to the embodiments of the present disclosure are shown. Fig. 9 , the virtual machine startup control device 3 based on the cloned cloud disk includes:

[0119] The processing module 31 is used to obtain target snapshot data after receiving a lazy load request sent by a virtual machine in the elastic computing service cluster to a cloud disk located in the elastic block storage, and send a snapshot download request to the image center to download at least two snapshot copies, wherein the cloud disk is used to store data resources required to start the virtual machine, the snapshot copy is the image data of the data resources required to start the virtual machine, and the target snapshot data is the data resources required to run the target function of the virtual machine;

[0120] The storage module 32 is used to connect each cloud disk to the corresponding snapshot copy to obtain the log file corresponding to the snapshot copy;

[0121] The loading module 33 is used to load the log file corresponding to the snapshot copy through the cloud disk to form a cloned cloud disk, and start the virtual machine based on the cloned cloud disk.

[0122] According to one or more embodiments of the present disclosure, when acquiring target snapshot data, the processing module 31 is specifically used to: send a data read request for the target snapshot data to the object storage unit; receive the target snapshot data, and write the target snapshot data to the cloud disk; the method also includes: based on the target snapshot data in the cloud disk, starting the target function of the virtual machine.

[0123] According to one or more embodiments of the present disclosure, after obtaining the target snapshot data, the processing module 31 is further used to: obtain the traffic data and delay data of the cloud disk; determine the target number of snapshot copies based on the traffic data and delay data of the cloud disk; when the processing module 31 sends a snapshot download request to the mirror center, it is specifically used to: send a first snapshot download request to the mirror center to download the target number of snapshot copies from the mirror center.

[0124] According to one or more embodiments of the present disclosure, when determining the target number of snapshot copies based on the traffic data and delay data of the cloud disk, the processing module 31 is specifically used to: obtain the number of cloud disks located in the elastic block storage; determine the target number of snapshot copies based on the number of cloud disks, the traffic data of each cloud disk, and the delay data of each cloud disk.

[0125] According to one or more embodiments of the present disclosure, when the processing module 31 determines the target number of snapshot copies based on the number of cloud disks, the traffic data of each cloud disk and the delay data of each cloud disk, it is specifically used to: determine the delay ratio based on the delay data of each cloud disk and the cloud disk delay threshold; obtain the average traffic of a single cloud disk based on the cumulative value of the product of the delay ratio and the current flow limit value of each cloud disk; obtain the number of connections of cloud disks that a single snapshot copy can connect to based on the ratio of the traffic provided by a single snapshot copy to the average traffic; obtain the target number based on the number of cloud disks and the number of connections of cloud disks that a single snapshot copy can connect to.

[0126] According to one or more embodiments of the present disclosure, the storage module 32 is specifically used to: send a mirror data read request to the distributed file storage system through the cloud disk; obtain the log file corresponding to the snapshot copy through the file storage system, and send it to the corresponding cloud disk.

[0127] According to one or more embodiments of the present disclosure, before connecting each cloud disk to the corresponding snapshot copy to obtain the log file corresponding to the snapshot copy, the processing module 31 is also used to: obtain the traffic data and delay data of the cloud disk; and set the traffic upper limit of the cloud disk according to the traffic data and delay data of the cloud disk.

[0128] According to one or more embodiments of the present disclosure, when the processing module 31 sets the traffic upper limit of the cloud disk according to the traffic data and delay data of the cloud disk, it is specifically used to: obtain the current traffic upper limit of each cloud disk; determine the target cloud disk according to the size relationship between the traffic data of the cloud disk and the preset current limiting value, and the size relationship between the delay data and the delay threshold, and set the current traffic upper limit of the target cloud disk.

[0129] According to one or more embodiments of the present disclosure, the processing module 31 is further used to: obtain a business basic coefficient, where the business basic coefficient is used to characterize a business level corresponding to the virtual machine; and obtain a delay threshold according to the business basic coefficient.

[0130] The processing module 31, storage module 32 and loading module 33 are connected in sequence. The virtual machine startup control device 3 based on the cloned cloud disk provided in this embodiment can execute the technical solution of the above method embodiment, and its implementation principle and technical effect are similar, which will not be repeated in this embodiment.

[0131] Fig.10 A schematic diagram of the structure of an electronic device provided by an embodiment of the present disclosure is shown in FIG. Fig.10 As shown, the electronic device 4 includes:

[0132] A processor 41, and a memory 42 communicatively connected to the processor 41;

[0133] The memory 42 stores computer executable instructions;

[0134] The processor 41 executes the computer execution instructions stored in the memory 42 to implement the following Figure 2-Figure 8 The virtual machine startup control method based on cloned cloud disk in the illustrated embodiment.

[0135] Optionally, the processor 41 and the memory 42 are connected via a bus 43 .

[0136] For related instructions, please refer to Figure 2-Figure 8 The relevant descriptions and effects corresponding to the steps in the corresponding embodiments can be understood, and no further elaboration is made here.

[0137] The present invention provides a computer-readable storage medium, wherein the computer-readable storage medium stores computer-executable instructions, which are used to implement the present invention when executed by a processor. Figure 2-Figure 8 A virtual machine startup control method based on a cloned cloud disk is provided in any one of the corresponding embodiments.

[0138] The present invention provides a computer program product, including a computer program. When the computer program is executed by a processor, the present invention is realized. Figure 2-Figure 8 A virtual machine startup control method based on a cloned cloud disk is provided in any one of the corresponding embodiments.

[0139] In order to implement the above embodiment, the embodiment of the present disclosure also provides an electronic device.

[0140] refer to Fig.11 , which shows a schematic diagram of the structure of an electronic device 900 suitable for implementing the embodiment of the present disclosure, and the electronic device 900 may be a terminal device or a server. The terminal device may include but is not limited to mobile terminals such as mobile phones, notebook computers, digital broadcast receivers, personal digital assistants (PDAs), tablet computers (Portable Android Devices, PADs), portable multimedia players (PMPs), vehicle terminals (such as vehicle navigation terminals), etc., and fixed terminals such as digital TVs, desktop computers, etc. Fig.11 The electronic device shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present disclosure.

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

[0142] Typically, the following devices may be connected to the I / O interface 905: input devices 906 including, for example, a touch screen, a touch pad, a keyboard, a mouse, a camera, a microphone, an accelerometer, a gyroscope, etc.; output devices 907 including, for example, a liquid crystal display (LCD), a speaker, a vibrator, etc.; storage devices 908 including, for example, a magnetic tape, a hard disk, etc.; and communication devices 909. The communication device 909 may allow the electronic device 900 to communicate with other devices wirelessly or by wire to exchange data. Although Fig.11 The electronic device 900 is shown with various devices, but it should be understood that it is not required to implement or possess all the devices shown. More or fewer devices may be implemented or possessed instead.

[0143] In particular, according to an embodiment of the present disclosure, the process described above with reference to the flowchart can be implemented as a computer software program. For example, an embodiment of the present disclosure includes a computer program product, which includes a computer program carried on a computer-readable medium, and the computer program contains program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from a network through a communication device 909, or installed from a storage device 908, or installed from a ROM 902. When the computer program is executed by the processing device 901, the above-mentioned functions defined in the method of the embodiment of the present disclosure are executed.

[0144] It should be noted that the computer-readable medium disclosed above may be a computer-readable signal medium or a computer-readable storage medium or any combination of the above two. The computer-readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples of computer-readable storage media may include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present disclosure, a computer-readable storage medium may be any tangible medium containing or storing a program that may be used by or in combination with an instruction execution system, device or device. In the present disclosure, a computer-readable signal medium may include a data signal propagated in a baseband or as part of a carrier wave, in which a computer-readable program code is carried. This propagated data signal may take a variety of forms, including but not limited to an electromagnetic signal, an optical signal, or any suitable combination of the above. The computer readable signal medium may also be any computer readable medium other than a computer readable storage medium, which may send, propagate or transmit a program for use by or in conjunction with an instruction execution system, apparatus or device. The program code contained on the computer readable medium may be transmitted using any suitable medium, including but not limited to: wires, optical cables, RF (radio frequency), etc., or any suitable combination of the above.

[0145] The computer-readable medium may be included in the electronic device, or may exist independently without being incorporated into the electronic device.

[0146] The computer-readable medium carries one or more programs. When the one or more programs are executed by the electronic device, the electronic device executes the method shown in the above embodiment.

[0147] Computer program code for performing the operations of the present disclosure may be written in one or more programming languages ​​or a combination thereof, including object-oriented programming languages, such as Java, Smalltalk, C++, and conventional procedural programming languages, such as "C" or similar programming languages. The program code may be executed entirely on the user's computer, partially on the user's computer, as an independent software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer via any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., via the Internet using an Internet service provider).

[0148] The flow chart and block diagram in the accompanying drawings illustrate the possible architecture, function and operation of the system, method and computer program product according to various embodiments of the present disclosure. In this regard, each square box in the flow chart or block diagram can represent a module, a program segment or a part of a code, and the module, the program segment or a part of the code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some implementations as replacements, the functions marked in the square box can also occur in a sequence different from that marked in the accompanying drawings. For example, two square boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each square box in the block diagram and / or flow chart, and the combination of the square boxes in the block diagram and / or flow chart can be implemented with a dedicated hardware-based system that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.

[0149] The units or modules involved in the embodiments described in the present disclosure may be implemented by software or hardware, wherein the name of a unit or module does not, in some cases, constitute a limitation on the unit itself.

[0150] The functions described above herein may be performed at least in part by one or more hardware logic components. For example, without limitation, exemplary types of hardware logic components that may be used include: field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chips (SOCs), complex programmable logic devices (CPLDs), and the like.

[0151] In the context of the present disclosure, a machine-readable medium may be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, device, or equipment. A machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, device, or equipment, or any suitable combination of the foregoing. A more specific example of a machine-readable storage medium may include an electrical connection based on one or more lines, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.

[0152] In a first aspect, according to one or more embodiments of the present disclosure, a method for controlling virtual machine startup based on a cloned cloud disk is provided, comprising:

[0153] After receiving a lazy loading request sent by a virtual machine in an elastic computing service cluster to a cloud disk located in an elastic block storage, the target snapshot data is obtained, and a snapshot download request is sent to an image center to download at least two snapshot copies, wherein the cloud disk is used to store data resources required to start the virtual machine, the snapshot copy is the image data of the data resources required to start the virtual machine, and the target snapshot data is the data resources required to run the target function of the virtual machine; each cloud disk is connected to the corresponding snapshot copy to obtain log files corresponding to at least two snapshot copies; the log files corresponding to the snapshot copies are loaded through the cloud disk to form a cloned cloud disk, and the virtual machine is started based on the cloned cloud disk.

[0154] According to one or more embodiments of the present disclosure, obtaining target snapshot data includes: sending a data read request for the target snapshot data to an object storage unit; receiving the target snapshot data, and writing the target snapshot data to a cloud disk; the method also includes: starting a target function of the virtual machine based on the target snapshot data in the cloud disk.

[0155] According to one or more embodiments of the present disclosure, after obtaining the target snapshot data, the method also includes: obtaining the traffic data and delay data of the cloud disk; determining the target number of snapshot copies based on the traffic data and delay data of the cloud disk; sending a snapshot download request to the mirror center, including: sending a first snapshot download request to the mirror center to download the target number of snapshot copies from the mirror center.

[0156] According to one or more embodiments of the present disclosure, a target number of snapshot copies is determined based on traffic data and delay data of the cloud disk, including: obtaining the number of cloud disks located in the elastic block storage; and determining the target number of snapshot copies based on the number of cloud disks, traffic data of each cloud disk, and delay data of each cloud disk.

[0157] According to one or more embodiments of the present disclosure, the target number of snapshot copies is determined based on the number of cloud disks, the traffic data of each cloud disk and the delay data of each cloud disk, including: determining the delay ratio based on the delay data of each cloud disk and the cloud disk delay threshold; obtaining the average traffic of a single cloud disk based on the delay ratio and the current flow limit value of each cloud disk; obtaining the number of connections to cloud disks that a single snapshot copy can connect to based on the ratio of the traffic provided by a single snapshot copy to the average traffic; and obtaining the target number based on the number of cloud disks and the number of connections to cloud disks that a single snapshot copy can connect to.

[0158] According to one or more embodiments of the present disclosure, each cloud disk is connected to the corresponding snapshot copy to obtain log files corresponding to at least two snapshot copies, including: sending a mirror data read request to the distributed file storage system through the cloud disk; obtaining the log file corresponding to the snapshot copy through the file storage system, and sending it to the corresponding cloud disk.

[0159] According to one or more embodiments of the present disclosure, before connecting each cloud disk to the corresponding snapshot copy to obtain the log files corresponding to at least two snapshot copies, the method also includes: obtaining the traffic data and delay data of the cloud disk; setting the traffic upper limit of the cloud disk according to the traffic data and delay data of the cloud disk.

[0160] According to one or more embodiments of the present disclosure, the traffic upper limit of the cloud disk is set according to the traffic data and delay data of the cloud disk, including: obtaining the current traffic upper limit of each cloud disk; determining the target cloud disk according to the size relationship between the traffic data of the cloud disk and the preset current limiting value, and the size relationship between the delay data and the delay threshold, and setting the current traffic upper limit of the target cloud disk.

[0161] According to one or more embodiments of the present disclosure, the method further includes: obtaining a business basic coefficient, where the business basic coefficient is used to characterize a business level corresponding to the virtual machine; and obtaining a delay threshold according to the business basic coefficient.

[0162] In a second aspect, according to one or more embodiments of the present disclosure, a virtual machine startup control device based on a cloned cloud disk is provided, comprising:

[0163] The processing module is used to obtain target snapshot data after receiving a lazy load request sent by a virtual machine in the elastic computing service cluster to a cloud disk located in the elastic block storage, and send a snapshot download request to the image center to download at least two snapshot copies, wherein the cloud disk is used to store data resources required to start the virtual machine, the snapshot copy is the image data of the data resources required to start the virtual machine, and the target snapshot data is the data resources required to run the target function of the virtual machine;

[0164] A storage module, used to connect each cloud disk to the corresponding snapshot copy, so as to obtain log files corresponding to at least two snapshot copies respectively;

[0165] The loading module is used to load the log file corresponding to the snapshot copy through the cloud disk to form a cloned cloud disk, and start the virtual machine based on the cloned cloud disk.

[0166] According to one or more embodiments of the present disclosure, when obtaining target snapshot data, the processing module is specifically used to: send a data read request for the target snapshot data to the object storage unit; receive the target snapshot data, and write the target snapshot data to the cloud disk; the method also includes: based on the target snapshot data in the cloud disk, starting the target function of the virtual machine.

[0167] According to one or more embodiments of the present disclosure, after obtaining the target snapshot data, the processing module is further used to: obtain the traffic data and delay data of the cloud disk; determine the target number of snapshot copies based on the traffic data and delay data of the cloud disk; when the processing module sends a snapshot download request to the mirror center, it is specifically used to: send a first snapshot download request to the mirror center to download the target number of snapshot copies from the mirror center.

[0168] According to one or more embodiments of the present disclosure, when the processing module determines the target number of snapshot copies based on the traffic data and delay data of the cloud disk, it is specifically used to: obtain the number of cloud disks located in the elastic block storage; determine the target number of snapshot copies based on the number of cloud disks, the traffic data of each cloud disk, and the delay data of each cloud disk.

[0169] According to one or more embodiments of the present disclosure, when the processing module determines the target number of snapshot copies based on the number of cloud disks, the traffic data of each cloud disk and the delay data of each cloud disk, the processing module is specifically used to: determine the delay ratio based on the delay data of each cloud disk and the cloud disk delay threshold; obtain the average traffic of a single cloud disk based on the delay ratio and the current flow limit value of each cloud disk; obtain the number of connections to cloud disks that a single snapshot copy can connect to based on the ratio of the traffic provided by a single snapshot copy to the average traffic; and obtain the target number based on the number of cloud disks and the number of connections to cloud disks that a single snapshot copy can connect to.

[0170] According to one or more embodiments of the present disclosure, the storage module is specifically used to: send a mirror data read request to a distributed file storage system through a cloud disk; obtain a log file corresponding to a snapshot copy through the file storage system, and send it to a corresponding cloud disk.

[0171] According to one or more embodiments of the present disclosure, before connecting each cloud disk to the corresponding snapshot copy to obtain the log files corresponding to at least two snapshot copies, the processing module is also used to: obtain the traffic data and delay data of the cloud disk; and set the traffic upper limit of the cloud disk according to the traffic data and delay data of the cloud disk.

[0172] According to one or more embodiments of the present disclosure, when the processing module sets the traffic upper limit of the cloud disk based on the traffic data and delay data of the cloud disk, it is specifically used to: obtain the current traffic upper limit of each cloud disk; determine the target cloud disk based on the size relationship between the traffic data of the cloud disk and the preset current limiting value, and the size relationship between the delay data and the delay threshold, and set the current traffic upper limit of the target cloud disk.

[0173] According to one or more embodiments of the present disclosure, the processing module is further used to: obtain a business basic coefficient, which is used to characterize a business level corresponding to the virtual machine; and obtain a delay threshold according to the business basic coefficient.

[0174] In a third aspect, according to one or more embodiments of the present disclosure, there is provided an electronic device, comprising: at least one processor and a memory;

[0175] Memory stores computer-executable instructions;

[0176] At least one processor executes the computer-executable instructions stored in the memory, so that the at least one processor executes the virtual machine startup control method based on the cloned cloud disk as described in the first aspect and various possible designs of the first aspect.

[0177] In a fourth aspect, according to one or more embodiments of the present disclosure, a computer-readable storage medium is provided, in which computer execution instructions are stored. When a processor executes the computer execution instructions, the virtual machine startup control method based on the cloned cloud disk as described in the first aspect and various possible designs of the first aspect is implemented.

[0178] In a fifth aspect, according to one or more embodiments of the present disclosure, a computer program product is provided, including a computer program, which, when executed by a processor, implements the virtual machine startup control method based on a cloned cloud disk as described in the first aspect and various possible designs of the first aspect.

[0179] The above description is only a preferred embodiment of the present disclosure and an explanation of the technical principles used. Those skilled in the art should understand that the scope of disclosure involved in the present disclosure is not limited to the technical solutions formed by a specific combination of the above technical features, but should also cover other technical solutions formed by any combination of the above technical features or their equivalent features without departing from the above disclosed concept. For example, the above features are replaced with the technical features with similar functions disclosed in the present disclosure (but not limited to) by each other to form a technical solution.

[0180] In addition, although each operation is described in a specific order, this should not be understood as requiring these operations to be performed in the specific order shown or in a sequential order. Under certain circumstances, multitasking and parallel processing may be advantageous. Similarly, although some specific implementation details are included in the above discussion, these should not be interpreted as limiting the scope of the present disclosure. Some features described in the context of a separate embodiment can also be implemented in a single embodiment in combination. On the contrary, the various features described in the context of a single embodiment can also be implemented in multiple embodiments individually or in any suitable sub-combination mode.

[0181] Although the subject matter has been described in language specific to structural features and / or methodological logical actions, it should be understood that the subject matter defined in the appended claims is not necessarily limited to the specific features or actions described above. On the contrary, the specific features and actions described above are merely example forms of implementing the claims.

Claims

1. A virtual machine startup control method based on cloned cloud disk, It is characterized in that include: Receive a lazy load request sent by the virtual machine to the cloud disk of the elastic block storage, obtain target snapshot data, and send a snapshot download request to the image center to download at least two snapshot copies, wherein the cloud disk is used to store data resources required to start the virtual machine, the snapshot copy is the image data of the data resources required to start the virtual machine, and the target snapshot data is the data resources required to run the target function of the virtual machine; Connecting each of the cloud disks to the corresponding snapshot copies respectively to obtain log files corresponding to the at least two snapshot copies respectively; The log file corresponding to the snapshot copy is loaded through the cloud disk to form a cloned cloud disk, and the virtual machine is started based on the cloned cloud disk.

2. The method according to claim 1, It is characterized in that The obtaining of target snapshot data includes: Sending a data read request for target snapshot data to the object storage unit; Receiving the target snapshot data, and writing the target snapshot data into the cloud disk; The method further includes: starting a target function of the virtual machine based on the target snapshot data in the cloud disk.

3. The method according to claim 1, It is characterized in that After acquiring the target snapshot data, the method further includes: Obtaining traffic data and delay data of the cloud disk; Determining a target number of snapshot copies according to the traffic data and latency data of the cloud disk; The sending of the snapshot download request to the mirror center includes: A first snapshot download request is sent to the mirror center to download the target number of snapshot copies from the mirror center.

4. The method according to claim 3, It is characterized in that The determining the target number of the snapshot copies according to the traffic data and delay data of the cloud disk includes: Get the number of cloud disks in the elastic block storage; The target number of the snapshot copies is determined according to the number of cloud disks, the traffic data of each cloud disk, and the delay data of each cloud disk.

5. The method according to claim 4, It is characterized in that The determining the target number of snapshot copies according to the number of cloud disks, the traffic data of each cloud disk, and the delay data of each cloud disk includes: Determine the delay ratio based on the delay data of each cloud disk and the cloud disk delay threshold; The average flow of a single cloud disk is obtained according to the delay ratio and the current flow limit value of each cloud disk; According to the ratio of the flow provided by the single snapshot copy to the average flow, the number of connections of the cloud disks to which the single snapshot copy can be connected is obtained; The target number is obtained according to the number of cloud disks and the number of cloud disks to which the single snapshot copy can be connected.

6. The method according to claim 1, It is characterized in that The step of connecting each of the cloud disks to the corresponding snapshot copies to obtain log files corresponding to the at least two snapshot copies respectively includes: Sending a mirror data read request to the distributed file storage system via the cloud disk; The log file corresponding to the snapshot copy is obtained through the file storage system and sent to the corresponding cloud disk.

7. The method according to claim 1, It is characterized in that Before connecting each of the cloud disks to the corresponding snapshot copies to obtain the log files corresponding to the at least two snapshot copies, the method further includes: Obtaining traffic data and delay data of the cloud disk; The traffic upper limit of the cloud disk is set according to the traffic data and delay data of the cloud disk.

8. The method according to claim 7, It is characterized in that The step of setting the upper limit of the traffic volume of the cloud disk according to the traffic volume data and the delay data of the cloud disk includes: Obtain the current traffic limit of each of the cloud disks; According to the size relationship between the traffic data of the cloud disk and the preset current limiting value, and the size relationship between the delay data and the delay threshold, the target cloud disk is determined, and the current traffic upper limit of the target cloud disk is set.

9. The method according to claim 8, It is characterized in that The method further comprises: Acquire a business basic coefficient, where the business basic coefficient is used to characterize a business level corresponding to the virtual machine; The delay threshold is obtained according to the business basic coefficient and the average delay of each of the cloud disks.

10. A virtual machine startup control device based on cloned cloud disk, It is characterized in that include: a processing module, configured to receive a lazy load request sent by a virtual machine to a cloud disk of elastic block storage, obtain target snapshot data, and send a snapshot download request to an image center to download at least two snapshot copies, wherein the cloud disk is used to store data resources required to start the virtual machine, the snapshot copies are image data of the data resources required to start the virtual machine, and the target snapshot data are data resources required to run a target function of the virtual machine; A storage module, used to connect each of the cloud disks to the corresponding snapshot copies, so as to obtain log files corresponding to the at least two snapshot copies respectively; The loading module is used to load the log file corresponding to the snapshot copy through the cloud disk to form a clone cloud disk, and start the virtual machine based on the clone cloud disk.

11. An electronic device, It is characterized in that include: Processor and memory; The memory stores computer-executable instructions; The processor executes the computer-executable instructions stored in the memory, so that the processor executes the virtual machine startup control method based on cloned cloud disk according to any one of claims 1 to 9.

12. A computer-readable storage medium, It is characterized in that The computer-readable storage medium stores computer-executable instructions. When the processor executes the computer-executable instructions, the virtual machine startup control method based on the cloned cloud disk as described in any one of claims 1 to 9 is implemented.

13. A computer program product comprising a computer program, It is characterized in that When the computer program is executed by a processor, the virtual machine startup control method based on a cloned cloud disk is implemented as described in any one of claims 1 to 9.

Citation Information

Patent Citations

  • Distributed system data loading method and device

    CN110018878A

  • Dynamic file placement method based on combined prediction in cloud storage system

    CN111258980A

  • Data processing method and device and electronic equipment

    CN114077574A

  • Method, apparatus, and compute program product for determining consistence level of snapshots of virtual machines

    US20190220444A1

Cited By

  • Mirror image storage scheduling method and system based on resource popularity

    CN119814761A

  • Faster initialising vms by copying the virtual disks for each VM from a snapshot copy, each copy having its own log file

    EP4811129A1