WO2024131959A1 - Virtual unit startup method and device, and cloud computing system - Google Patents

Virtual unit startup method and device, and cloud computing system Download PDF

Info

Publication number
WO2024131959A1
WO2024131959A1 PCT/CN2023/141129 CN2023141129W WO2024131959A1 WO 2024131959 A1 WO2024131959 A1 WO 2024131959A1 CN 2023141129 W CN2023141129 W CN 2023141129W WO 2024131959 A1 WO2024131959 A1 WO 2024131959A1
Authority
WO
WIPO (PCT)
Prior art keywords
startup
pool
application
virtual unit
memory
Prior art date
Application number
PCT/CN2023/141129
Other languages
French (fr)
Chinese (zh)
Inventor
张嘉伟
张永明
黄毽
Original Assignee
华为云计算技术有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 华为云计算技术有限公司 filed Critical 华为云计算技术有限公司
Publication of WO2024131959A1 publication Critical patent/WO2024131959A1/en

Links

Definitions

  • Intensive cloud computing systems include multiple intensive resource pools that are interconnected at high speeds, and each intensive resource pool centrally distributes one type of resource among computing resources, memory resources, or external storage resources.
  • Non-intensive cloud computing systems include multiple independent non-intensive resource pools, and the ratio of computing resources, memory resources, and external storage resources in each non-intensive resource pool is comparable.
  • the present application provides a virtual unit startup method and device, and a cloud computing system.
  • the technical solution of the present application is as follows.
  • the first startup scheme is a startup scheme of the first application, the startup performance of the first startup scheme matches the startup demand of the first application, and the startup performance of the first startup scheme meets the startup demand of the first application.
  • the management platform determines the first startup scheme according to the startup demand of the first application and the at least one set of startup measurement information, that is, the management platform determines the first startup scheme according to the startup demand and the startup performance of the at least one startup scheme corresponding to the at least one set of startup measurement information.
  • the technical solution provided by the present application is that the management platform in the intensive cloud computing system determines the first startup solution according to the startup demand of the first application and the startup performance of at least one startup solution, and starts the virtual unit of the first application in the first computing pool in the intensive cloud computing system according to the first startup solution. Therefore, the virtual unit startup solution has good performance when implemented in the intensive cloud computing system, can realize the extremely fast startup of the first application, and can make full use of low-cost resources. Since the management platform automatically selects the startup solution according to the startup demand of the first application, the availability of the solution can be improved.
  • the method before starting the first virtual unit in the first computing pool according to the first starting scheme, the method further includes:
  • the benchmark memory snapshot of the benchmark virtual unit is obtained; and the benchmark memory snapshot is stored in the first storage pool.
  • the method before starting the first virtual unit in the first computing pool according to the first starting scheme, the method further includes:
  • a first virtual unit is created in the first computing pool according to the application image of the first application, that is, the first virtual unit is preheated.
  • the technical solution provided by the present application is that the management platform preheats the first virtual unit, which can increase the speed at which the management platform subsequently starts the first virtual unit, thereby increasing the startup speed of the first application, for example, achieving extremely fast startup of the first application.
  • the first startup plan includes a cold start plan based on the first storage pool, in which a baseline unit snapshot is stored, and the baseline unit snapshot is obtained by taking a snapshot of the baseline virtual unit of the first application; starting the first virtual unit of the first application in the first computing pool according to the first startup plan includes: creating and starting the first virtual unit in the first computing pool according to the baseline unit snapshot.
  • the method before starting the first virtual unit in the first computing pool according to the first starting scheme, the method further includes:
  • a reference unit snapshot of the reference virtual unit is obtained; and the reference unit snapshot is stored in the first storage pool.
  • the technical solution provided by the present application is that the management platform obtains a baseline unit snapshot and stores the baseline unit snapshot in a first storage pool, which can facilitate the management unit to subsequently create a first virtual unit and start the first virtual unit based on the baseline unit snapshot, thereby improving the speed at which the management platform starts the first virtual unit, thereby improving the startup speed of the first application.
  • the benchmark virtual unit runs in a first computing pool.
  • the first startup scheme includes a cold start scheme based on the second computing pool, a second virtual unit is running in the second computing pool, and the configuration of the second virtual unit is the same as the configuration of the first virtual unit; starting the first virtual unit of the first application in the first computing pool according to the first startup scheme includes: creating and starting the first virtual unit in the first computing pool according to the second virtual unit.
  • the configuration of the second virtual unit is the same as the configuration of the first virtual unit, including: the metadata of the second virtual unit is the same as the metadata of the first virtual unit, and the description of the second virtual unit is the same as the description of the first virtual unit.
  • the attributes of the second virtual unit are the same as the attributes of the first virtual unit
  • the application image corresponding to the second virtual unit is the same as the application image corresponding to the first virtual unit
  • another markup language (yet another markup language, YAML) file of the second virtual unit is the same as the YAML file of the first virtual unit.
  • an application image is a form of file storage, which is a lightweight and independently executable software package of an application.
  • the application image of any application contains all the content required to run the application, including code, system tools, libraries, environment variables and configuration files, etc.
  • the application image of any application contains all the content required to start the virtual unit of the application, including code, system tools, libraries, environment variables and configuration files, etc.
  • starting the first virtual unit according to the second virtual unit includes: creating a second memory branch in the first computing pool according to the memory of the second virtual unit, the second memory branch being used to store memory data that has changed relative to the memory of the second virtual unit during the operation of the first virtual unit, and the memory data of the first virtual unit is determined based on the memory data of the second virtual unit (that is, the data in the memory of the second virtual unit) and the memory data stored in the second memory branch.
  • starting the first virtual unit according to the second virtual unit includes: creating a second read-write layer in the first computing pool according to the file system of the second virtual unit, the second read-write layer being used to store file data that has changed relative to the file system of the second virtual unit during the operation of the first virtual unit, the file system of the first virtual unit being determined based on the file data in the file system of the second virtual unit and the memory data stored in the second memory branch.
  • the intensive cloud computing system further includes a first storage pool, the first storage pool being interconnected with the first computing pool; the first storage pool being used to store at least one of the following information of the first application: a snapshot of the memory of the virtual unit of the first application; a snapshot of the virtual unit of the first application; The storage location of the at least one information of the first application in the first storage pool is determined according to at least one of the following indicators of the first application: importance, usage frequency, and startup demand.
  • the intensive cloud computing system further includes an image warehouse, which is used to store the correspondence between the indication information of the application image and the storage location of the application image in the first storage pool.
  • the technical solution provided by the present application is that the application image is stored in the first storage pool, and the image warehouse is used to store the correspondence between the indication information of the application image and the storage location of the application image. Therefore, when the management platform creates a virtual unit of an application, the management platform obtains the storage location of the application image from the image warehouse according to the indication information of the application image of the application, and then obtains the application image from the first storage pool according to the storage location of the application image. Therefore, the present application stores the application image in the first storage pool in a distributed manner, and the image warehouse only records the storage location of the application image, which can improve the speed of obtaining the application image, reduce the delay in creating the virtual unit, and avoid the bandwidth bottleneck of the centralized image warehouse.
  • the first storage pool includes at least one of a memory pool and an external memory pool.
  • the memory pool and the external memory pool satisfy at least one of the following: the memory pool includes at least two first storage media, and the at least two first storage media are of different types; the external memory pool includes at least two second storage media, and the at least two second storage media are of different types.
  • the first storage medium and the second storage medium store data based on a differential algorithm respectively.
  • the technical solution provided by the present application is that since the first storage medium and the second storage medium store data based on a differential algorithm respectively, for any data block, it is only necessary to store the difference between the data block and the reference data block in the first storage medium or the second storage medium, and only one copy of the same data block is stored, which can save storage resources and reduce storage costs.
  • the target application matches the first application, including at least one of the following: the target application is the first application; the scale of the target application matches the scale of the first application; the size of the application image of the target application matches the size of the application image of the first application; the type of the target application matches the type of the first application.
  • the startup requirement of the first application includes at least one of a startup duration requirement and a startup cost requirement; and the startup measurement information includes at least one of a measured startup duration and a measured startup cost.
  • obtaining at least one set of startup measurement information corresponding to the target application includes: performing a startup test on the target application in the intensive cloud computing system according to each startup scheme in the at least one startup scheme to obtain a set of startup measurement information corresponding to each startup scheme.
  • the management platform is deployed in the first computing pool.
  • the first computing pool is called a local computing pool
  • the second computing pool is called a remote computing pool
  • the first storage pool is called a remote storage pool.
  • the first virtual unit is a container or a virtual machine.
  • a virtual unit startup device comprising at least one module, the at least one module being used to execute the method provided in the first aspect or any optional manner of the first aspect.
  • the at least one module can be implemented based on software, hardware, or a combination of software and hardware, and the at least one module can be arbitrarily combined or divided based on a specific implementation.
  • a virtual unit startup device comprising a memory and a processor; the memory is used to store a computer program; the processor is used to execute the computer program stored in the memory so that the virtual unit startup device performs a method provided in the first aspect or any optional method of the first aspect.
  • a cloud computing system comprising the virtual unit startup device provided in the second aspect or the third aspect.
  • the cloud computing system includes a computing pool and a storage pool, the computing pool is interconnected with the storage pool, and the computing pool includes a virtual unit startup device as provided in the second aspect or the third aspect.
  • the computing pool includes a management platform, and the management platform includes a virtual unit startup device as provided in the second aspect or the third aspect.
  • the storage pool includes a memory pool and an external memory pool, and the memory pool and the external memory pool are interconnected with the computing pool respectively.
  • a computer-readable storage medium in which a computer program is stored.
  • the computer program is executed, the method provided in the first aspect or any optional manner of the first aspect is implemented.
  • a computer program product which includes a program or code, and when the program or code is executed, it implements the method provided in the first aspect or any optional manner of the first aspect.
  • FIG1 is a schematic diagram of an intensive cloud computing system provided in an embodiment of the present application.
  • FIG2 is a schematic diagram of another intensive cloud computing system provided in an embodiment of the present application.
  • FIG3 is a flow chart of a method for starting a virtual unit provided in an embodiment of the present application.
  • FIG4 is a schematic diagram of starting a first virtual unit provided by an embodiment of the present application.
  • FIG5 is a schematic diagram of another method of starting a first virtual unit provided by an embodiment of the present application.
  • FIG6 is a schematic diagram of another method of starting a first virtual unit provided in an embodiment of the present application.
  • FIG7 is a schematic diagram of a virtual unit startup device provided in an embodiment of the present application.
  • FIG8 is a schematic diagram of another virtual unit starting device provided in an embodiment of the present application.
  • cloud computing systems can deploy applications in containers to achieve resource isolation of different applications based on containers.
  • the applications deployed in the containers can be serverless applications or other applications.
  • starting an application includes starting a container of the application.
  • the container of an application may be a container in which the application is deployed (i.e., the application has been deployed in the container), a container in which the application is to be deployed (i.e., the application is to be deployed in the container), a container created for the application (e.g., a container created based on the application image of the application), or other containers that can ultimately be used to run the application.
  • Current container startup solutions include hot startup solutions and cold startup solutions.
  • the cloud computing system pre-creates (i.e., pre-heats) a certain number of containers.
  • the cloud computing system allocates containers for the application in the pre-created containers according to the container startup request and starts these containers.
  • the cloud computing system pre-prepares at least some of the components (e.g., container snapshots) required to create a container for the application.
  • the cloud computing system creates containers for the application based on the pre-prepared components according to the container startup request and starts these containers.
  • an intensive cloud computing system includes a high-speed interconnected computing pool, a memory pool, and an external memory pool.
  • the computing pool, the memory pool, and the external memory pool are all intensive resource pools.
  • the computing resources are concentrated in the computing pool, the memory resources are concentrated in the memory pool, and the external memory resources are concentrated in the external memory pool.
  • the computing pool also includes a small amount of memory resources and/or external memory resources
  • the memory pool also includes a small amount of computing resources and/or external memory resources
  • the external memory pool also includes a small amount of computing resources and/or memory resources.
  • a host equipped with a large amount of memory is a memory pool
  • a host based on a central processing unit (CPU) is a computing pool
  • a host equipped with a large amount of memory is connected to a host based on a CPU via a remote direct memory access (RDMA) network.
  • RDMA remote direct memory access
  • the characteristic of a non-intensive cloud computing system is that the ratio of different types of resources in each resource pool is equal.
  • the resource pool in a non-intensive cloud computing system is also called a non-intensive resource pool.
  • a non-intensive cloud computing system includes multiple independent non-intensive resource pools, each of which includes computing resources, memory resources, and external storage resources, and the ratio of computing resources, memory resources, and external storage resources in each non-intensive resource
  • the current container startup solution is designed for non-intensive cloud computing systems. Since the characteristics of intensive cloud computing systems are different from those of non-intensive cloud computing systems, directly implementing the current container startup solution in intensive cloud computing systems is likely to lead to problems such as poor application startup performance and poor performance of intensive cloud computing systems.
  • the current hot start solution is directly implemented in an intensive cloud computing system, since it is impossible to preheat many containers in a computing pool with a small memory allocation, when the intensive cloud computing system receives a container startup request corresponding to an application, and the container startup request is used to start multiple containers, the number of preheated containers may be insufficient (for example, the user requests to start 10 containers, but only 7 containers are preheated), affecting the startup speed of the application, which is unbearable for serverless applications (serverless applications require extremely fast startup of containers).
  • the intensive cloud computing system will store the container snapshot in the computing pool (when the current container startup solution starts the container based on the container snapshot, the container snapshot and the container are in the same non-intensive resource pool), but will not store the container snapshot in the storage pool (memory pool or external memory pool) that is interconnected with the computing pool at a high speed.
  • the storage resources in the computing pool are more expensive, which results in an inability to utilize low-cost storage resources, and in turn results in higher operating costs for the intensive cloud computing system.
  • the embodiment of the present application provides a virtual unit startup scheme, which is applied to a management platform in an intensive cloud computing system, and the intensive cloud computing system also includes a first computing pool.
  • the management platform determines the first startup scheme according to the startup demand of the first application and at least one set of startup measurement information corresponding to the target application, and starts the virtual unit of the first application in the first computing pool according to the first startup scheme.
  • the at least one set of startup measurement information corresponds to at least one startup scheme, and each set of startup measurement information is used to characterize the startup performance of starting the target application in the intensive cloud computing system based on the corresponding startup scheme.
  • the target application matches the first application, and the at least one startup scheme includes the first startup scheme.
  • the management platform determines the first startup scheme according to the startup demand of the first application and the at least one set of startup measurement information, that is, the management platform determines the first startup scheme according to the startup demand and the startup performance of the at least one startup scheme. Since the management platform in the intensive cloud computing system determines the first startup scheme according to the startup demand of the first application and the startup performance of at least one startup scheme corresponding to the target application, and starts the virtual unit of the first application in the first computing pool in the intensive cloud computing system according to the first startup scheme, the virtual unit startup scheme provided in the embodiment of the present application has good performance in the intensive cloud computing system, can achieve extremely fast startup of the first application, and can make full use of low-cost resources to reduce the operating cost of the intensive cloud computing system.
  • the virtual unit is a container, a virtual machine (VM) or other unit for resource isolation, and all "virtual units" in this article can be replaced by "containers" or "virtual machines”.
  • the application scenario of the embodiment of the present application provides an intensive cloud computing system, which includes multiple intensive resource pools, and the multiple intensive resource pools are interconnected, for example, the multiple intensive resource pools are interconnected through a high-speed network, and the multiple intensive resource pools can communicate through an application program interface (API), and each of the multiple intensive resource pools mainly includes a type of resource.
  • the multiple intensive resource pools include at least one computing pool and at least one storage pool, and the at least one storage pool includes a memory pool and/or an external memory pool.
  • the computing pool mainly includes computing resources
  • the memory pool mainly includes memory resources
  • the external memory pool mainly includes external memory resources.
  • the computing pool also includes a small amount of memory resources and/or external memory resources, the memory pool also includes a small amount of computing resources and/or external memory resources, and the external memory pool also includes a small amount of computing resources and/or memory resources.
  • the intensive cloud computing system is also called a separated data center
  • the computing pool is also called a computing resource pool
  • the memory pool is also called a memory resource pool or an internal storage resource pool
  • the external memory pool is also called an external memory resource pool or an external storage resource pool.
  • External memory resources are usually disk resources, so the external memory pool is also called a disk pool, a disk resource pool, etc.
  • a computing pool is a host or server mainly based on computing resources
  • a memory pool is a host or server mainly based on memory resources
  • an external memory pool is a host or server mainly based on external memory resources, which is not limited in the embodiments of the present application.
  • the at least one storage pool includes a memory pool and an external memory pool.
  • the memory pool may be a heterogeneous memory pool, which includes at least two first storage media, which are storage media that provide memory resources, and the types of the at least two first storage media are different, for example, the at least two first storage media include dynamic random access memory (DRAM) and storage class memory (SCM).
  • the external memory pool may be a heterogeneous external memory pool, which includes at least two second storage media, which are storage media that provide external memory resources, and the types of the at least two second storage media are different, for example, the at least two second storage media include solid state drives (SSD) and hard disk drives (HDD).
  • SSD solid state drives
  • HDD hard disk drives
  • both the memory pool and the external memory pool support data storage based on a differential algorithm.
  • the differential algorithm refers to storing the difference (difference, diff) between data blocks. For example, for any data block, the difference between the any data block and the reference data block is stored. For example, data is stored based on a differential algorithm in the same storage medium.
  • each storage medium corresponds to a reference data block
  • the difference between the any data block and the reference data block corresponding to the storage medium is stored in the any storage medium.
  • both the memory pool and the external memory pool store data based on a differential algorithm, which can save storage resources and reduce storage costs.
  • a virtual unit can be created in an intensive cloud computing system (for example, a virtual unit can be created for an application), and the application can be deployed in the virtual unit to implement resource isolation of different applications based on the virtual unit.
  • the virtual unit is a computing unit that can run independently, and the virtual unit has its own computing resources, memory resources, and file system.
  • the computing resources of the virtual unit are the computing resources in the computing pool, and a virtual unit occupies part of the computing resources in a computing pool;
  • the memory resources of the virtual unit are the memory resources in the memory pool, and a virtual unit occupies part of the memory resources in a memory pool;
  • the file system of the virtual unit can be located in an external memory pool, and the file system of a virtual unit occupies part of the external memory resources in an external memory pool.
  • the virtual unit is a logical concept, and the different resources of a virtual unit are distributed on the same network.
  • multiple intensive resource pools connected Among them, multiple virtual units of an application can share the same memory resources in the memory pool and/or the same external memory resources in the external memory pool.
  • the intensive cloud computing system also includes a management platform, which is located in the computing pool or independently set up.
  • the management platform is used to manage virtual units.
  • the management platform creates virtual units in the intensive cloud computing system, deploys applications in virtual units, and starts virtual units.
  • the management platform is also called a virtual unit management platform.
  • the virtual unit is a container, a virtual machine, or other unit for resource isolation.
  • the virtual unit is a container, and the corresponding management platform is called a container management platform.
  • the virtual unit is a virtual machine, and the corresponding management platform is called a virtual machine management platform.
  • a storage pool can be used to store various information required to create a virtual unit of an application, including but not limited to a snapshot of the memory of the base virtual unit of the application, a snapshot of the base virtual unit of the application, an application image of the application, etc.
  • the storage strategy corresponding to the application is determined according to indicators such as the importance, frequency of use, and startup requirements (such as startup time, startup cost, etc.) of the application (for example, determining whether to store the information corresponding to the application in the memory pool or in the external memory pool, and which storage medium of the memory pool is specifically stored or which storage medium of the memory pool is specifically stored), and the information corresponding to the application is stored in the storage pool according to the storage strategy corresponding to the application.
  • the information corresponding to the application is stored in the storage pool according to a preset storage strategy or a storage strategy specified by the intensive cloud computing system.
  • different information corresponding to the same application is stored in the same storage pool or different storage pools, and different information corresponding to the same application is stored in the same storage medium or different storage media.
  • an application image is a form of file storage, which is a lightweight and independently executable software package of an application.
  • the application image of any application contains all the content required to run the application.
  • the application image of any application contains all the content required to start the virtual unit of the application, which includes code, system tools, libraries, environment variables, and configuration files.
  • the storage pool is used to store specific application images, and the specific application images meet at least one of the following: the most frequently used application image (for example, an application image with a usage frequency greater than a preset frequency), the most recently used application image (for example, the time difference between the moment when the application image was last used and the current moment is less than a preset time difference), and the application image of an important customer.
  • the storage index of a specific application image meets the preset storage index, and the storage index of any application image is obtained by weighted calculation based on the usage frequency of the application image, the most recent usage time of the application image, and the customer importance level corresponding to the application image.
  • the storage pool includes a memory pool and/or an external memory pool, and the memory pool and/or the external memory pool include at least two storage media, application images of different applications can be stored in the same storage medium or different storage media, and thus, the embodiment of the present application can store application images in a distributed manner in the storage pool.
  • the intensive cloud computing system also includes an image warehouse, which can be a distributed image warehouse, and the image warehouse is used to store the corresponding relationship between the indication information of the application image and the storage location of the application image in the storage pool (hereinafter referred to as the storage location of the application image), for example, the corresponding relationship is called the first corresponding relationship.
  • the management platform creates a virtual unit of a certain application
  • the management platform determines the storage location of the application image according to the indication information of the application image of the application and the first corresponding relationship stored in the image warehouse, and the management platform obtains the application image from the storage pool according to the storage location of the application image, and creates a virtual unit based on the application image.
  • the management platform sends an image acquisition request to the image warehouse, and the image acquisition request carries the indication information of the application image of the application.
  • the image warehouse determines the storage location of the application image according to the indication information of the application image carried in the image acquisition request and the first corresponding relationship, and sends the storage location of the application image to the management platform, and the management platform obtains the application image from the storage pool according to the storage location of the application image.
  • the image repository may be deployed in a computing pool or a storage pool, or may be deployed independently of the computing pool and the storage pool, for example, the image repository may be deployed in an independent server.
  • the indication information of the application image may be an identification of the application image, for example, the identification of a certain application may be used as the identification of the application image of the application.
  • the image warehouse in the related art is used to centrally store application images (that is, different application images are centrally stored in the image warehouse).
  • This image warehouse is also called a centralized image warehouse.
  • the embodiment of the present application stores application images in a distributed manner in a storage pool, and sets a correspondence between the indication information of the image warehouse storing application images and the storage location of the application images.
  • the management platform When the management platform creates a virtual unit of a certain application, the management platform obtains the storage location of the application image from the image warehouse according to the indication information of the application image of the application, and then obtains the application image from the distributed storage pool according to the storage location of the application image.
  • the speed of obtaining application images can be improved and the delay of creating virtual units can be reduced.
  • the distributed storage method of application images in the embodiment of the present application can well solve the problem that the centralized image warehouse has a slow speed of obtaining application images and a large delay in creating virtual units when creating virtual units with high concurrency.
  • FIG1 is a schematic diagram of an intensive cloud computing system 100 provided in an embodiment of the present application.
  • the intensive cloud computing system 100 includes a first computing pool 101, a second computing pool 102 and a third computing pool 104.
  • the second computing pool 102 and the first storage pool 103, the first storage pool 103 includes a memory pool 31 and an external memory pool 32, and the first computing pool 101, the second computing pool 102 and the first storage pool 103 are interconnected through a high-speed network.
  • the first computing pool 101 and the second computing pool 102 are both intensive resource pools based on computing resources
  • the memory pool 31 is an intensive resource pool based on memory resources
  • the external memory pool 32 is an intensive resource pool based on external memory resources.
  • the first computing pool 101 and the second computing pool 102 are both hosts or servers based on computing resources
  • the memory pool 31 is a host or server based on memory resources
  • the external memory pool 32 is a host or server based on external memory resources.
  • the memory pool 31 includes m first storage media 311-31m, and the types of the first storage media 311-31m are different.
  • the first storage medium can store snapshots, application images and other information corresponding to at least one application based on a differential algorithm.
  • the external memory pool 32 includes n second storage media 321-32n, and the types of the second storage media 321-32n are different.
  • the second storage media can store snapshots, application images and other information corresponding to at least one application based on a differential algorithm.
  • the first computing pool 101 includes a management platform 11, and the management platform 11 creates a virtual unit in the intensive cloud computing system 100, deploys applications in the virtual unit, starts the virtual unit, etc.
  • the management platform 11 creates a virtual unit of the first application in the first computing pool 101, the computing resources of the virtual unit are the computing resources in the first computing pool 101, the memory resources of the virtual unit include the memory resources in the memory pool 31, and the file system part of the virtual unit is located in the external memory pool 32.
  • the management platform 11 is in the first computing pool 101, from the perspective of the management platform 11, the first computing pool 101 is called a local computing pool, the second computing pool 102 is called a remote computing pool, the memory pool 31 is called a remote memory pool, and the external memory pool 32 is called a remote external memory pool.
  • the first computing pool 101 and the second computing pool 102 are hosts that mainly use computing resources.
  • the first computing pool 101 is called a local host, and the second computing pool 102 is called a remote host.
  • FIG2 is a schematic diagram of another intensive cloud computing system 100 provided in an embodiment of the present application.
  • the intensive cloud computing system 100 also includes an image warehouse 104.
  • the image warehouse 104 can be deployed in the first computing pool 101, the second computing pool 102 or the first storage pool 103, or it can be deployed independently of the first computing pool 101, the second computing pool 102 and the first storage pool 103.
  • FIG2 takes the deployment of the image warehouse 104 independently of the first computing pool 101, the second computing pool 102 and the first storage pool 103 as an example.
  • the first storage pool 103 is used to store various information required to create a virtual unit of an application, and this information can be distributed in different storage media.
  • the first storage pool 103 is used to store application images
  • the image warehouse 104 is a distributed image warehouse.
  • the image warehouse 104 is used to store the indication information of the application image and the corresponding relationship (for example, referred to as the first corresponding relationship) of the storage location of the application image in the first storage pool 103.
  • the management platform 11 creates a virtual unit of an application
  • the management platform 11 determines the storage location of the application image based on the indication information of the application image of the application and the first correspondence stored in the image repository 104.
  • the management platform 11 obtains the application image from the first storage pool 103 based on the storage location of the application image, and creates a virtual unit based on the application image.
  • the intensive cloud computing system shown in Figures 1 and 2 is only used as an example and is not used to limit the technical solution of the embodiment of the present application.
  • the number of computing pools and storage pools in the intensive cloud computing system can be configured as needed, and the number and type of storage media in the storage pool can be configured as needed, which is not limited in the embodiment of the present application.
  • the virtual unit startup method provided in the embodiment of the present application is applied to the management platform in the intensive cloud computing system, and the virtual unit startup method is executed by the management platform.
  • the intensive cloud computing system also includes a first computing pool, and the management platform can be deployed in the first computing pool.
  • the intensive cloud computing system also includes a first storage pool and a second computing pool, and the first storage pool includes at least one of a memory pool and an external memory pool, and the memory pool and the external memory pool can both be heterogeneous storage pools.
  • the first computing pool, the second computing pool and the first storage pool are interconnected, and the first storage pool is used to store a snapshot of the memory of the virtual unit of the first application, a snapshot of the virtual unit of the first application, and an application image of the first application, and the storage location of these information of the first application in the first storage pool is determined according to the importance, frequency of use, startup requirements, etc. of the first application.
  • the intensive cloud computing system may also include an image warehouse, which is used to store the corresponding relationship between the indication information of the application image and the storage location of the application image in the first storage pool.
  • the intensive cloud computing system is shown in Figure 1 or Figure 2, and the virtual unit startup method is executed by the management platform 11. As shown in Figure 3, the method includes the following steps S301 to S304.
  • the first application is a variety of possible applications that implement resource isolation based on virtual units, for example, the first application is a serverless application, and the first application is a video application, an audio application, an email application, a web application, or a microblog application, etc.
  • the virtual unit can be a computing unit implemented based on virtualization technology, such as a container or a virtual machine.
  • the startup demand of the first application includes at least one of a startup time demand and a startup cost demand.
  • the startup time demand may be that the startup time of the first application (that is, the time required to start the first application) is less than a preset time.
  • the startup cost demand may be that the startup cost of the first application (that is, the cost required to start the first application) is less than a preset cost.
  • the startup time of the first application is related to the startup time of the virtual unit of the first application, and the startup cost of the first application is related to the startup cost of the virtual unit of the first application.
  • the virtual unit of an application The startup of the virtual unit means the startup of the application, so the startup time of the first application is generally the startup time of the virtual unit of the first application, and the startup cost of the first application is generally the startup cost of the virtual unit of the first application.
  • the startup time and startup cost of the virtual unit of the first application are related to the startup method of the virtual unit of the first application, the storage location of snapshots, application images and other related information, etc.
  • a certain storage medium A stores the baseline unit snapshot C0 of the first application (that is, the snapshot of the baseline virtual unit of the first application).
  • the startup time of the first virtual unit depends on the time to create the first virtual unit, the time to pull the baseline unit snapshot C0 from the storage medium A, etc., and the startup cost of the first virtual unit depends on the cost of storing the baseline unit snapshot C0 in the storage medium A.
  • the startup demand of the first application may be input to the management platform by a management user (e.g., a developer user of the first application, a management user of an intensive cloud computing system), or may be determined by the management platform based on the attribute information of the first application.
  • the management platform is provided with a user interface, through which the management user interacts with the management platform, the management user inputs startup demand information to the management platform through the user interface, and the management platform obtains the startup demand information input by the management user, the startup demand information includes the startup demand of the first application, wherein the user interface may be a user interface (UI) interface.
  • UI user interface
  • the management platform obtains attribute information such as the importance, frequency of use, and type of the first application, and the management platform determines the startup demand of the first application based on the attribute information of the first application. For example, the startup time of applications with higher importance and applications with higher frequency of use needs to be shorter.
  • the management platform can obtain at least one set of startup measurement information corresponding to the target application, and the at least one set of startup measurement information corresponds to at least one startup scheme.
  • Each set of startup measurement information is obtained by performing a startup test on the target application in an intensive cloud computing system (for example, the intensive cloud computing system 100 shown in Figure 1 or Figure 2) according to the corresponding startup scheme.
  • Each set of startup measurement information is used to characterize the startup performance of starting the target application in the intensive cloud computing system based on the corresponding startup scheme.
  • Each set of startup measurement information includes at least one of measuring startup duration and measuring startup cost.
  • the at least one startup scheme is pre-formulated, for example, it is pre-formulated by the management platform or manually formulated and input into the management platform.
  • the management platform can provide a user interface, and the user can input the startup scheme into the management platform through the user interface.
  • Each startup scheme in the at least one startup scheme includes a startup mode and a storage strategy.
  • the startup mode can be a hot start or a cold start.
  • the storage strategy is used to store snapshots, file systems, application images, etc. required to start the virtual unit.
  • the storage strategy includes which storage media each information in the snapshot, file system, application image, etc.
  • the at least one startup scheme includes at least one of the following: a hot start scheme based on the first storage pool, a cold start scheme based on the first storage pool, and a cold start scheme based on the second computing pool.
  • the first computing pool, the second computing pool and the first storage pool are interconnected, and the first storage pool includes at least one of a memory pool and an external memory pool.
  • the measured startup time and the measured startup cost of the target application are related to the startup method of the target application, the storage medium where the snapshots and application images related to the target application are located, the storage location of the information related to the target application in the first storage pool, etc.
  • the hot startup solution based on the first storage pool is a startup solution based on the memory snapshot stored in the first storage pool (for example, the snapshot of the memory of the virtual unit), and the startup time and startup cost of the hot startup solution vary depending on the storage medium where the memory snapshot is located;
  • the cold startup solution based on the first storage pool is a startup solution based on the virtual unit snapshot stored in the first storage pool (that is, the snapshot of the virtual unit), and the startup time and startup cost of the cold startup solution vary depending on the storage medium where the virtual unit snapshot is located;
  • the cold startup solution based on the second computing pool is a startup solution based on the virtual unit running in the second computing pool.
  • the management platform performs a startup test on the target application in the intensive cloud computing system according to each startup scheme in the at least one startup scheme, and obtains a set of startup measurement information corresponding to each startup scheme, thereby obtaining at least one set of startup measurement information corresponding to the at least one startup scheme.
  • the management platform performs a startup test on the target application in the intensive cloud computing system according to each startup scheme.
  • the management platform counts the startup time and startup cost of the target application, obtains the measured startup time and measured startup cost corresponding to each startup scheme, that is, obtains a set of startup measurement information corresponding to each startup scheme.
  • Startup scheme 1 can be: a hot startup scheme based on the memory snapshot stored in the first storage medium 311 and the file system stored in the second storage medium 321.
  • Startup solution 2 may be a hot start solution based on the memory snapshot stored in the first storage medium 312 and the file system stored in the second storage medium 321.
  • Startup solution 3 may be a hot start solution based on the memory snapshot stored in the first storage medium 313 and the file system stored in the second storage medium 322.
  • Startup scheme 4 may be: a cold start scheme based on a virtual unit snapshot of the file system stored in the second storage medium 321.
  • Startup scheme 5 may be a cold start scheme based on a virtual unit running in the second computing pool 102.
  • any combination of startup methods and any storage policies may constitute a startup scheme.
  • the management platform 11 performs a startup test on the target application in the intensive cloud computing system 100 according to startup scheme 1, and obtains a set of startup measurement information 1 corresponding to startup scheme 1.
  • the management platform 11 performs a startup test on the target application in the intensive cloud computing system 100 according to startup scheme 2, and obtains a set of startup measurement information 2 corresponding to startup scheme 2.
  • the management platform 11 performs a startup test on the target application in the intensive cloud computing system 100 according to startup scheme k, and obtains a set of startup measurement information k corresponding to startup scheme k.
  • the management platform 11 obtains startup measurement information 1 to k corresponding to startup schemes 1 to k by performing startup tests on the target application.
  • Each set of startup measurement information in the startup measurement information 1 to k includes at least one of measuring startup duration and measuring startup cost.
  • the target application matches the first application, including at least one of the following: the target application is the first application, the scale of the target application matches the scale of the first application, the size of the application image of the target application matches the size of the application image of the first application, and the type of the target application matches the type of the first application.
  • the scale of the target application matches the scale of the first application, including: the scale of the sub-function of the target application is comparable to the scale of the sub-function of the first application (for example, the difference between the number of sub-functions of the target application and the number of sub-functions of the first application is less than a preset number), and the architecture of the target application is comparable to the architecture of the first application.
  • the architecture of any application is, for example, which main functions (or first-level functions) the application includes, which second-level functions each main function includes, which third-level functions each second-level function includes, and so on.
  • the size of the application image of the target application matches the size of the application image of the first application, including: the difference between the size of the application image of the target application and the size of the application image of the first application is less than a preset difference.
  • the type of the target application matches the type of the first application, including: the type of the target application is the same as the type of the first application, for example, the target application and the first application are both video applications.
  • the first application is allowed to be run on a trial basis, and the management platform uses the first application as a target application (the target application is the first application).
  • the management platform performs a startup test on the first application in the intensive cloud computing system according to each startup scheme in at least one startup scheme, and obtains a set of startup measurement information corresponding to each startup scheme.
  • the first application is not allowed to be run on a trial basis, and the management platform determines a target application that matches the first application according to the scale of the first application, the size of the application image of the first application, the type of the first application, etc.
  • the management platform performs a startup test on the target application in the intensive cloud computing system according to each startup scheme in at least one startup scheme, and obtains a set of startup measurement information corresponding to each startup scheme.
  • S303 Determine a first startup solution according to the startup requirement of the first application and the at least one set of startup measurement information, where the at least one startup solution includes the first startup solution.
  • the first startup scheme is a startup scheme in which the startup performance matches the startup demand of the first application among the at least one startup scheme, and the startup performance of the first startup scheme meets the startup demand of the first application.
  • the startup demand of the first application includes at least one of a startup duration demand and a startup cost demand
  • the startup duration demand is that the startup duration of the first application is less than a preset duration
  • the startup cost demand is that the startup cost of the first application is less than a preset cost.
  • the startup performance of the first startup scheme meets the startup demand of the first application, including at least one of the following: the measured startup duration corresponding to the first startup scheme is less than the preset duration, and the measured startup cost corresponding to the first startup scheme is less than the preset cost.
  • the at least one set of startup measurement information corresponds to at least one startup scheme one by one, and each set of startup measurement information is used to characterize the startup performance of starting the target application in the intensive cloud computing system based on the corresponding startup scheme.
  • the management platform determines the startup scheme whose startup performance meets the startup requirements of the first application in the at least one startup scheme according to the at least one set of startup measurement information, and the management platform determines the first startup scheme in the startup scheme whose startup performance meets the startup requirements of the first application.
  • there is only one startup scheme in the at least one startup scheme whose startup performance meets the startup requirements of the first application and the management platform determines the one startup scheme as the first startup scheme.
  • the management platform determines one startup scheme in the multiple startup schemes as the first startup scheme. For example, the management platform determines any one of the multiple startup schemes as the first startup scheme, or the management platform determines the startup scheme with the best startup performance in the multiple startup schemes as the first startup scheme. Among them, the startup scheme with the best startup performance satisfies at least one of the following items: the minimum measured startup duration and the minimum measured startup cost. For example, the management platform determines the startup scheme with the shortest measured startup time and the shortest measured startup cost among the multiple startup schemes as the first startup scheme.
  • the at least one startup scheme includes at least one of a hot startup scheme based on the first storage pool, a cold startup scheme based on the first storage pool, and a cold startup scheme based on the second computing pool, so the first startup scheme includes any one of the following: a hot startup scheme based on the first storage pool, a cold startup scheme based on the first storage pool, and a cold startup scheme based on the second computing pool.
  • the management platform 11 obtains the startup measurement information 1-k corresponding to the startup schemes 1-k.
  • the management platform 11 determines the startup scheme whose startup performance meets the startup requirement of the first application in the startup schemes 1-k according to the startup measurement information 1-k.
  • the startup The startup performance of startup scheme 1 meets the startup requirements of the first application, and the startup performance of startup schemes 2 to k do not meet the startup requirements of the first application, and the management platform 11 determines startup scheme 1 as the first startup scheme.
  • the startup performance of startup schemes 1 to 3 all meet the startup requirements of the first application, and the startup performance of startup schemes 4 to k do not meet the startup requirements of the first application; the management platform 11 determines any startup scheme among startup schemes 1 to 3 (for example, startup scheme 1) as the first startup scheme; or, among startup schemes 1 to 3, startup scheme 1 has the best startup performance, and the management platform 11 determines startup scheme 1 (that is, the startup scheme with the best startup performance) as the first startup scheme.
  • startup scheme 1 for example, startup scheme 1
  • startup scheme 1 has the best startup performance
  • startup scheme 1 that is, the startup scheme with the best startup performance
  • the first virtual unit is a computing unit implemented based on virtualization technology, such as a container or a virtual machine.
  • the management platform deploys the first startup scheme in the intensive cloud computing system according to the first application. For example, the management platform stores snapshots, application images and other information required for starting the virtual unit of the first application based on the first startup scheme in the intensive cloud computing system.
  • the management platform receives a startup request for starting the first application (or a startup request for starting the virtual unit of the first application)
  • the management unit starts the first virtual unit of the first application in the first computing pool according to the first startup scheme.
  • the first startup scheme includes any one of the following: a hot startup scheme based on the first storage pool, a cold startup scheme based on the first storage pool, and a cold startup scheme based on the second computing pool.
  • the implementation method of the management platform starting the first virtual unit is different.
  • the following takes the first startup scheme as an example, which is a hot startup scheme based on the first storage pool, a cold startup scheme based on the first storage pool, or a cold startup scheme based on the second computing pool, and introduces the implementation method of the management platform starting the first virtual unit according to the first startup scheme in three embodiments.
  • the first startup scheme is a hot startup scheme based on the first storage pool.
  • the first storage pool stores a baseline memory snapshot and a baseline file system.
  • the baseline memory snapshot is obtained by taking a snapshot of the memory of the baseline virtual unit of the first application.
  • the baseline file system is the file system of the baseline virtual unit.
  • the data in the baseline memory snapshot and the data in the baseline file system are read-only data. Both the baseline memory snapshot and the baseline file system are only allowed to be read but not written (i.e., modification is not allowed).
  • the first computing pool includes the first virtual unit.
  • the memory of the first virtual unit has a mapping relationship with the baseline memory snapshot (or the memory of the first virtual unit is associated with the baseline memory snapshot), and the file system of the first virtual unit has a mapping relationship with the baseline file system (or the file system of the first virtual unit is associated with the baseline file system).
  • the management platform starts the first virtual unit in the first computing pool according to the first startup scheme, including: the management platform creates a first memory branch in the first computing pool according to the baseline memory snapshot, and the management platform creates a first read-write layer in the first computing pool according to the baseline file system.
  • the first computing pool includes a memory space and an external memory space, the management platform creates a first memory branch in the memory space, and the management platform creates a first read-write layer in the external memory space.
  • the first memory branch is used to store memory data that has changed relative to the baseline memory snapshot during the operation of the first virtual unit (that is, memory data in the memory of the first virtual unit that has changed relative to the baseline memory snapshot), and the memory data of the first virtual unit (that is, data in the memory of the first virtual unit) can be determined based on the data in the baseline memory snapshot and the memory data stored in the first memory branch.
  • the first read-write layer is used to store file data that has changed relative to the baseline file system during the operation of the first virtual unit (that is, file data in the file system of the first virtual unit that has changed relative to the baseline file system), and the file system of the first virtual unit is determined based on the file data in the baseline file system and the file data stored in the first read-write layer.
  • the baseline virtual unit of the first application is a virtual unit that has been deployed with the first application and has been started, and the baseline memory snapshot of the baseline virtual unit is obtained by taking a snapshot of the memory of the baseline virtual unit at a certain time after the baseline virtual unit is started.
  • the first storage pool may include a memory pool and an external memory pool, the baseline memory snapshot may be stored in the memory pool, and the baseline file system may be stored in the external memory pool.
  • the mapping relationship between the memory of the first virtual unit and the reference memory snapshot may include: the storage address of the reference memory snapshot is stored in the first virtual unit, for example, the storage address of the reference memory snapshot is stored in the memory of the first virtual unit.
  • mapping relationship between the memory of the first virtual unit and the reference memory snapshot exists, when accessing the memory of the first virtual unit, the reference memory snapshot can be accessed according to the storage address of the reference memory snapshot, that is, the process of accessing the memory of the first virtual unit includes accessing the reference memory snapshot.
  • the mapping relationship between the file system of the first virtual unit and the reference file system may include: the storage address of the reference file system is stored in the first virtual unit, for example, the storage address of the reference file system is stored in the memory of the first virtual unit.
  • the reference file system can be accessed according to the storage address of the reference file system, that is, accessing the file system of the first virtual unit actually includes accessing the reference file system.
  • FIG4 is a method of starting the first computing pool 101 according to the first startup solution (a hot startup solution based on the first storage pool 103) provided in the embodiment of the present application.
  • the base virtual unit U0 of the first application runs in the first computing pool 101
  • the first storage pool 103 includes a memory pool 31 and an external memory pool 32
  • the memory pool 31 stores a base memory snapshot P0
  • the external memory pool 32 stores a base file system F0
  • the first computing pool 101 includes the first virtual unit U1
  • the memory M1 of the first virtual unit U1 has a mapping relationship with the base memory snapshot P0
  • the file system F1 of the first virtual unit U1 has a mapping relationship with the base file system F0.
  • the management platform 11 When the management platform 11 receives a start request for starting the first application, the management platform 11 creates a first memory branch B1 in the memory space in the first computing pool 101 according to the base memory snapshot P0, and the management platform 11 creates a first read-write layer R1 in the external memory space in the first computing pool 101 according to the base file system F0.
  • the management platform 11 calls the memory M1 and the file system F1 of the first virtual unit U1 by creating the first memory branch B1 and the first read-write layer R1, thereby starting the first virtual unit U1.
  • the first memory branch B1 is used to store memory data that has changed in the memory M1 of the first virtual unit U1 relative to the baseline memory snapshot P0 during the operation of the first virtual unit U1 after the first virtual unit U1 is started, the data in the memory M1 of the first virtual unit U1 is determined based on the data in the baseline memory snapshot P0 and the memory data stored in the first memory branch B1, and accessing the memory M1 of the first virtual unit U1 includes accessing the baseline memory snapshot P0 and the first memory branch B1.
  • the first read-write layer R1 is used to store file data that has changed in the file system F1 of the first virtual unit U1 relative to the baseline file system F0 during the operation of the first virtual unit U1 after the first virtual unit U1 is started, the file system F1 of the first virtual unit U1 is determined based on the file data in the baseline file system F0 and the file data stored in the first read-write layer R1, and accessing the file system F1 of the first virtual unit U1 includes accessing the baseline file system F0 and the first read-write layer R1.
  • the reference virtual unit U0 is a virtual unit that has been deployed with the first application and has been started
  • the reference memory snapshot P0 is obtained by taking a snapshot of the memory of the reference virtual unit U0 at a certain time after the reference virtual unit U0 is started
  • the reference file system F0 is the file system of the reference virtual unit U0.
  • the data in the reference memory snapshot P0 and the data in the reference file system F0 are both read-only data, and both the reference memory snapshot P0 and the reference file system F0 are only allowed to be read but not modified.
  • the memory space in the first computing pool 101 may also include a reference memory branch B0 (not shown in FIG.
  • the external memory space in the first computing pool 101 may also include a reference read-write layer R0 (not shown in FIG. 4).
  • the reference memory branch B0 is used to store memory data that has changed in the memory of the reference virtual unit U0 relative to the reference memory snapshot P0 during the operation of the reference virtual unit U0
  • the reference read-write layer R0 is used to store file data that has changed in the file system of the reference virtual unit U0 relative to the reference file system F0 during the operation of the reference virtual unit U0, and the embodiment of the present application does not limit this.
  • FIG4 only shows the part of the intensive cloud computing system 100 related to the first embodiment.
  • the second computing pool 103 is not shown in FIG4.
  • FIG4 only shows that the baseline memory snapshot P0 is stored in the memory pool 31 and the baseline file system F0 is stored in the external memory pool 32. It does not show in which storage medium in the memory pool 31 the baseline memory snapshot P0 is specifically stored, and in which storage medium in the external memory pool 32 the baseline file system F0 is specifically stored.
  • the specific storage medium where the baseline memory snapshot P0 and the baseline file system F0 are located is determined according to the first startup scheme. For other parts not shown in FIG4, please refer to FIG1 and FIG2, and no further description is given here.
  • the baseline memory snapshot of the baseline virtual unit of the first application is stored in the first storage pool in advance.
  • the baseline memory snapshot can be stored in the first storage pool by the management platform, or by other devices.
  • the baseline virtual unit runs in the first computing pool, and the management platform obtains the baseline memory snapshot of the baseline virtual unit during the operation of the baseline virtual unit, and stores the baseline memory snapshot in the first storage pool.
  • the first application is a commonly used application. After the baseline virtual unit of the first application is started normally, the management platform takes a snapshot of the memory of the baseline virtual unit to obtain the baseline memory snapshot of the baseline virtual unit.
  • the first startup scheme may include a storage policy for the baseline memory snapshot (that is, in which storage medium of the first storage pool the baseline memory snapshot is stored), and the management platform stores the baseline memory snapshot in the first storage pool according to the storage policy.
  • a plurality of applications are deployed in an intensive cloud computing system, and a first application is one of the plurality of applications.
  • the management platform obtains a baseline memory snapshot of the baseline virtual unit after the baseline virtual unit of each commonly used application is normally started, and stores the baseline memory snapshot in a first storage pool. Whether any application is a commonly used application can be determined based on the frequency of use of the application.
  • the first virtual unit before the management platform starts the first virtual unit in the first computing pool according to the first startup scheme, the first virtual unit is pre-created in the first computing pool.
  • the first virtual unit can be created in the first computing pool by the management platform, or by other devices.
  • the management platform obtains an application image of the first application, and the management platform creates the first virtual unit in the first computing pool according to the application image of the first application.
  • the intensive cloud computing system provided in the embodiment of the present application includes an image warehouse, and the application image of the first application is stored in a first storage pool.
  • the image warehouse stores a correspondence between indication information of the application image and the storage location of the application image (that is, the storage location of the application image in the first storage pool).
  • the management platform determines the storage location of the application image from the image warehouse according to the indication information of the application image of the first application.
  • the management platform obtains the application image from the first storage pool according to the storage location of the application image, and creates the first virtual unit in the first computing pool according to the application image.
  • the management After the platform creates the first virtual unit in the first computing pool, the management platform establishes a mapping relationship between the memory of the first virtual unit and the baseline memory snapshot of the baseline virtual unit of the first application, and the management platform establishes a mapping relationship between the file system of the first virtual unit and the baseline file system.
  • the management platform prepares in advance the relevant components required to create the virtual unit of the first application, and the management platform creates the first virtual unit based on these relevant components. Since the management platform has prepared in advance the relevant components required to create the virtual unit, the management platform can directly use these relevant components when creating the first virtual unit, which helps to increase the speed of creating the first virtual unit.
  • these relevant components include control groups (cgroups), namespaces, etc.
  • the management platform 11 Before the management platform 11 creates the first virtual unit U1 in the first computing pool 101, the management platform 11 prepares in advance the relevant components required to create the virtual unit of the first application. As shown in FIG4, the application image 1 of the first application is stored in the external memory pool 32, and the corresponding relationship between the indication information of the application image 1 and the storage location of the application image 1 is stored in the image warehouse 104 (not shown in FIG4).
  • the management platform 11 When the management platform 11 creates the virtual unit of the first application (for example, the first virtual unit U1), the management platform 11 determines the storage location of the application image 1 from the image warehouse 104 according to the indication information of the application image 1, and the management platform 11 obtains the application image 1 from the external memory pool 32 according to the storage location of the application image 1. The management platform 11 creates the first virtual unit U1 in the first computing pool 101 according to the application image 1. After the management platform 11 creates the first virtual unit U1, the management platform 11 associates the memory M1 of the first virtual unit U1 with the baseline memory snapshot P0.
  • the baseline memory snapshot P0 can be accessed according to the storage address of the baseline memory snapshot P0, that is, the process of accessing the memory M1 of the first virtual unit U1 includes accessing the baseline memory snapshot P0.
  • the first startup scheme is a cold startup scheme based on the first storage pool, and the first storage pool stores a reference unit snapshot, which is obtained by taking a snapshot of the reference virtual unit of the first application.
  • the management platform starts the first virtual unit in the first computing pool according to the first startup scheme, including: the management platform creates the first virtual unit in the first computing pool according to the reference unit snapshot and starts the first virtual unit.
  • the management platform creates the first virtual unit in the first computing pool according to the reference unit snapshot based on the checkpoint/restore in userspace (CRIU) technology in user space.
  • the first virtual unit is a container, and the management platform creates and starts the container based on the CRIU technology.
  • the implementation process of the management platform creating the first virtual unit according to the reference unit snapshot and starting the first virtual unit can refer to the implementation process of creating a container according to a container snapshot in the relevant technology, which will not be repeated here.
  • the base virtual unit of the first application is a virtual unit deployed with the first application and started, the base unit snapshot is obtained by taking a snapshot of the base virtual unit at a certain time after the base virtual unit is started, and the base unit snapshot includes the memory data of the base virtual unit and the data in the file system of the base unit snapshot.
  • the first storage pool may include a memory pool and an external memory pool, the base unit snapshot is stored in the memory pool or the external memory pool, the base unit snapshot is stored in the memory pool or the external memory pool, and in which storage medium in the memory pool or in which storage medium in the external memory pool the base unit snapshot is specifically stored, all of which are determined according to the first startup scheme.
  • FIG5 is a schematic diagram of another method of starting the first virtual unit U1 in the first computing pool 101 according to the first startup scheme (cold startup scheme based on the first storage pool 103) provided in an embodiment of the present application.
  • the reference virtual unit U0 of the first application runs in the first computing pool 101
  • the first storage pool 103 includes a memory pool 31 and an external memory pool 32
  • the memory pool 31 stores the reference unit snapshot C0.
  • the management platform 11 receives a startup request for starting the first application, the management platform 11 creates the first virtual unit U1 in the first computing pool 101 according to the reference unit snapshot C0 and starts the first virtual unit U1.
  • the reference unit snapshot C0 is obtained by taking a snapshot of the reference virtual unit U0 at a certain moment after the reference virtual unit U0 is started, and the reference unit snapshot C0 includes the memory data of the reference virtual unit U0 and the data in the file system of the reference virtual unit U0, which is not limited in the embodiment of the present application.
  • FIG. 5 only shows the part of the intensive cloud computing system 100 related to the second embodiment, for example, the second computing pool 103 is not shown in FIG.
  • FIG. 5 only shows that the reference unit snapshot C0 is stored in the memory pool 31, and does not show in which storage medium in the memory pool 31 the reference unit snapshot C0 is specifically stored.
  • the specific storage medium where the reference unit snapshot C0 is located is determined according to the first startup scheme. For other parts not shown in FIG. 5, reference can be made to FIG. 1 and FIG. 2, and no further description is given here.
  • the baseline unit snapshot of the baseline virtual unit of the first application is stored in the first storage pool in advance.
  • the baseline unit snapshot of the baseline virtual unit may be stored in the first storage pool by the management platform, or by other devices.
  • the baseline virtual unit runs in the first computing pool, and the management platform obtains the baseline unit snapshot of the baseline virtual unit during the operation of the baseline virtual unit, and stores the baseline unit snapshot in the first storage pool.
  • the first application is a commonly used application. After the baseline virtual unit of the first application is started normally, the management platform takes a snapshot of the baseline virtual unit based on the CRIU technology to obtain a baseline unit snapshot.
  • the first startup scheme may include a storage policy for the baseline unit snapshot, and the management platform stores the baseline unit snapshot in the first storage pool according to the storage policy.
  • multiple applications are deployed in the intensive cloud computing system, and the first application is one of the multiple applications.
  • the management platform obtains the baseline internal unit snapshot of the baseline virtual unit after the baseline virtual unit of each commonly used application is normally started, and stores the baseline memory snapshot in the first storage pool. This embodiment of the present application does not limit this.
  • the first startup scheme is a cold start scheme based on the second computing pool, the second computing pool runs a second virtual unit, the configuration of the second virtual unit is the same as the configuration of the first virtual unit, and the management platform starts the first virtual unit in the first computing pool according to the first startup scheme, including: the management platform creates the first virtual unit in the first computing pool according to the second virtual unit and starts the first virtual unit.
  • the management platform creates the first virtual unit in the first computing pool according to the configuration of the second virtual unit, for example, the management platform creates the first virtual unit according to the cgroups, namespace, etc. of the second virtual unit, including creating the basic components of the first virtual unit and creating the main process of the first virtual unit.
  • the management platform creates a second memory branch in the first computing pool according to the memory of the second virtual unit, and the management platform creates a second read-write layer in the first computing pool according to the file system of the second virtual unit to start the first virtual unit.
  • the first computing pool includes memory space and external memory space
  • the management platform creates a second memory branch in the memory space
  • the management platform creates a second read-write layer in the external memory space.
  • the second memory branch is used to store memory data that has changed relative to the memory of the second virtual unit during the operation of the first virtual unit (that is, data that has changed in the memory of the first virtual unit relative to the memory of the second virtual unit), and the memory data of the first virtual unit can be determined based on the memory data of the second virtual unit and the memory data stored in the second memory branch.
  • the second read-write layer is used to store file data that has changed relative to the file system of the second virtual unit during the operation of the first virtual unit (that is, file data that has changed in the file system of the first virtual unit relative to the file system of the second virtual unit), and the file system of the first virtual unit is determined based on the file system of the second virtual unit and the file data stored in the second read-write layer.
  • the second virtual unit can be a virtual unit started in the second computing pool based on the first embodiment or the second embodiment above, and the configuration of the second virtual unit is the same as the configuration of the first virtual unit, including: the metadata of the second virtual unit is the same as the metadata of the first virtual unit, and the description of the second virtual unit is the same as the description of the first virtual unit.
  • the attributes of the second virtual unit are the same as the attributes of the first virtual unit, for example, the application image corresponding to the second virtual unit is the same as the application image corresponding to the first virtual unit (for example, the application image corresponding to the second virtual unit and the application image corresponding to the first virtual unit are both application images of the first application).
  • the YAML file of the second virtual unit is the same as the YAML file of the first virtual unit.
  • FIG. 6 is a schematic diagram of starting the first virtual unit U1 in the first computing pool 101 according to another first startup scheme (cold start scheme based on the second computing pool 102) provided in an embodiment of the present application.
  • a second virtual unit U2 is running in the second computing pool 102, and the configuration of the second virtual unit U2 is the same as that of the first virtual unit U1.
  • the management platform 11 When the management platform 11 receives a startup request for starting the first application, the management platform 11 creates the first virtual unit U1 in the first computing pool 101 according to the second virtual unit U2, the management platform 11 creates a second memory branch B2 in the memory space in the first computing pool 101 according to the memory M2 of the second virtual unit U2, and the management platform 11 creates a second read-write layer R2 in the external memory space in the first computing pool 101 according to the file system F2 of the second virtual unit U2.
  • the management platform 11 calls the memory M1 of the first virtual unit U1 and the file system F1 of the first virtual unit U1 by creating the second memory branch B2 and the second read-write layer R2, thereby starting the first virtual unit U1.
  • the second memory branch B2 is used to store memory data that has changed in the memory M1 of the first virtual unit U1 relative to the memory M2 of the second virtual unit U2 during the operation of the first virtual unit U1 after the first virtual unit U1 is started.
  • the data in the memory M1 of the first virtual unit U1 is determined based on the data in the memory M2 of the second virtual unit U2 and the memory data stored in the second memory branch B2.
  • Accessing the memory M1 of the first virtual unit U1 includes accessing the memory M2 of the second virtual unit U2 and the second memory branch B2.
  • the second read-write layer R2 is used to store file data that has changed in the file system F1 of the first virtual unit U1 relative to the file system F2 of the second virtual unit U2 during the operation of the first virtual unit U1 after the first virtual unit U1 is started.
  • the file system F1 of the first virtual unit U1 is determined based on the file data stored in the file system F2 of the second virtual unit U2 and the second read-write layer R2.
  • Accessing the file system F1 of the first virtual unit U1 includes accessing the file system F2 and the second read-write layer R2 of the second virtual unit U2.
  • FIG6 only shows the parts of the intensive cloud computing system 100 related to the third embodiment.
  • the first storage pool 102 and the image warehouse 104 are not shown in FIG6.
  • the management platform runs in the first computing pool. From the perspective of the management platform, the first computing pool can be called a local computing pool, the second computing pool can be called a remote computing pool, and the first storage pool can be called a remote storage pool.
  • the above-mentioned hot start solution based on the first storage pool can be called a hot start solution based on a remote storage pool
  • the above-mentioned cold start solution based on the first storage pool can be called a cold start solution based on a remote storage pool
  • the above-mentioned cold start solution based on the second computing pool can be called a cold start solution based on a remote computing pool.
  • This application implements This example does not limit this.
  • the technical solution provided by the embodiment of the present application is that at least one set of startup measurement information corresponds to at least one startup scheme, and each set of startup measurement information is used to characterize the startup performance of starting the target application in the intensive cloud computing system based on the corresponding startup scheme.
  • the management platform in the intensive cloud computing system determines the first startup scheme according to the startup demand of the first application and the at least one set of startup measurement information (that is, the management platform determines the first startup scheme according to the startup demand of the first application and the startup performance of the at least one startup scheme), and starts the virtual unit of the first application in the first computing pool according to the first startup scheme.
  • the virtual unit startup scheme provided by the embodiment of the present application has good performance in the intensive cloud computing system, can achieve extremely fast startup of the first application, and can make full use of low-cost resources to reduce the operating cost of the intensive cloud computing system. Since the management platform automatically selects the startup scheme according to the startup demand of the first application, the availability of the virtual unit startup scheme can be improved.
  • the above is an introduction to the method embodiment of the present application.
  • the following is an introduction to the device embodiment of the present application.
  • the device of the present application can be used to execute the method of the present application.
  • FIG 7 shows a schematic diagram of a virtual unit startup device 700 provided in an embodiment of the present application.
  • the virtual unit startup device 700 is applied to a management platform in an intensive cloud computing system.
  • the virtual unit startup device 700 is the management platform or a functional component in the management platform.
  • the virtual unit startup device 700 is used to execute all or part of the steps in the method embodiment shown in Figure 3.
  • the intensive cloud computing system also includes a first computing pool.
  • the virtual unit startup device 700 includes an acquisition module 710, a determination module 720 and a startup module 730.
  • the acquisition module 710 is used to acquire the startup demand of the first application, and to acquire at least one set of startup measurement information corresponding to the target application, wherein the at least one set of startup measurement information corresponds to at least one startup scheme, and each set of startup measurement information in the at least one set of startup measurement information is used to characterize the startup performance of starting the target application in the intensive cloud computing system based on the corresponding startup scheme, and the target application matches the first application;
  • a determination module 720 configured to determine a first startup scheme according to the startup demand of the first application and the at least one set of startup measurement information, wherein the at least one startup scheme includes the first startup scheme;
  • the startup module 730 is configured to start a first virtual unit of a first application in a first computing pool according to a first startup scheme.
  • the first startup scheme includes any one of the following: a hot startup scheme based on the first storage pool; a cold startup scheme based on the first storage pool; a cold startup scheme based on the second computing pool.
  • the first storage pool and the second computing pool are interconnected with the first computing pool respectively.
  • the function of the startup module 730 is different, which is described in three embodiments below.
  • the first startup scheme includes a hot startup scheme based on a first storage pool, wherein a baseline memory snapshot is stored in the first storage pool, and the baseline memory snapshot is obtained by taking a snapshot of the memory of a baseline virtual unit of a first application, and the first computing pool includes a first virtual unit; a startup module 730 is used to create a first memory branch in the first computing pool according to the baseline memory snapshot, and the first memory branch is used to store memory data that has changed relative to the baseline memory snapshot during the operation of the first virtual unit.
  • a benchmark file system is also stored in the first storage pool, and the benchmark file system is the file system of the benchmark virtual unit; the startup module 730 is also used to create a first read-write layer in the first computing pool according to the benchmark file system, and the first read-write layer is used to store file data that has changed relative to the benchmark file system during the operation of the first virtual unit.
  • the acquisition module 710 is also used to obtain a baseline memory snapshot of the baseline virtual unit during the operation of the baseline virtual unit before the startup module 730 starts the first virtual unit in the first computing pool according to the first startup scheme; please continue to refer to Figure 7, the virtual unit startup device 700 also includes: a storage module 740, used to store the baseline memory snapshot in the first storage pool.
  • the virtual unit startup device 700 also includes: a creation module 750, which is used to create a first virtual unit in the first computing pool according to the application image of the first application before the startup module 730 starts the first virtual unit in the first computing pool according to the first startup plan.
  • a creation module 750 which is used to create a first virtual unit in the first computing pool according to the application image of the first application before the startup module 730 starts the first virtual unit in the first computing pool according to the first startup plan.
  • the first startup plan includes a cold start plan based on the first storage pool, in which a baseline unit snapshot is stored, and the baseline unit snapshot is obtained by taking a snapshot of the baseline virtual unit of the first application; a startup module 730 is used to create and start the first virtual unit in the first computing pool according to the baseline unit snapshot.
  • the acquisition module 710 is further configured to acquire a reference unit snapshot of the reference virtual unit during the operation of the reference virtual unit before the startup module 730 starts the first virtual unit in the first computing pool according to the first startup scheme;
  • the virtual unit startup device 700 further includes: a storage module 740 , which is used to store the baseline unit snapshot in the first storage pool.
  • the benchmark virtual unit runs in a first computing pool.
  • the first startup plan includes a cold start plan based on a second computing pool, in which a second virtual unit runs, and the configuration of the second virtual unit is the same as that of the first virtual unit; a startup module 730 is used to create and start the first virtual unit in the first computing pool according to the second virtual unit.
  • the startup module 730 is used to create a second memory branch in the first computing pool according to the memory of the second virtual unit, and the second memory branch is used to store memory data that changes relative to the memory of the second virtual unit during the operation of the first virtual unit.
  • the startup module 730 is used to create a second read-write layer in the first computing pool according to the file system of the second virtual unit, and the second read-write layer is used to store file data that changes relative to the file system of the second virtual unit during the operation of the first virtual unit.
  • the intensive cloud computing system also includes a first storage pool, which is interconnected with the first computing pool; the first storage pool is used to store at least one of the following information of the first application: a snapshot of the memory of the virtual unit of the first application; a snapshot of the virtual unit of the first application; and an application image of the first application.
  • the storage location of the at least one information of the first application in the first storage pool is determined according to at least one of the following indicators of the first application: importance, usage frequency, and startup appeal.
  • the intensive cloud computing system further includes an image warehouse, which is used to store the correspondence between the indication information of the application image and the storage location of the application image in the first storage pool.
  • the first storage pool includes at least one of a memory pool and an external memory pool.
  • the memory pool and external memory pool meet at least one of the following requirements:
  • the memory pool includes at least two first storage media, and the at least two first storage media are of different types;
  • the external storage pool includes at least two second storage media, and the at least two second storage media are of different types.
  • the first storage medium and the second storage medium store data based on a differential algorithm respectively.
  • the target application matches the first application, including at least one of the following: the target application is the first application; the scale of the target application matches the scale of the first application; the size of the application image of the target application matches the size of the application image of the first application; the type of the target application matches the type of the first application.
  • the startup requirement of the first application includes at least one of a startup duration requirement and a startup cost requirement; and the startup measurement information includes at least one of a measured startup duration and a measured startup cost.
  • the acquisition module 710 is configured to perform a startup test on the target application in the intensive cloud computing system according to each startup scheme of at least one startup scheme, and obtain a set of startup measurement information corresponding to each startup scheme.
  • the management platform is deployed in the first computing pool.
  • the first virtual unit is a container or a virtual machine.
  • the acquisition module 710 can be used to execute the relevant steps in S301, S302 and S304 above.
  • the functional implementation of the acquisition module 710 can refer to the relevant descriptions in S301, S302 and S304.
  • the determination module 720 can be used to execute the above S303.
  • the functional implementation of the determination module 720 can refer to the relevant description in S303.
  • the startup module 730, the storage module 740 and the creation module 750 can be used to execute the relevant steps in S304 above.
  • the functional implementation of the startup module 730, the storage module 740 and the creation module 750 can refer to the relevant description in S304.
  • the acquisition module 710, the determination module 720, the startup module 730, the storage module 740 and the creation module 750 can all be implemented by software, or can be implemented by hardware.
  • the acquisition module 710 is taken as an example.
  • the implementation of the determination module 720, the startup module 730, the storage module 740 and the creation module 750 can refer to the implementation of the acquisition module 710.
  • the acquisition module 710 may include code running on a computing instance.
  • the computing instance may include at least one of a physical host, a virtual machine, and a container. Furthermore, the computing instance may be one or more.
  • the acquisition module 710 may include code running on multiple hosts/virtual machines/containers. It should be noted that the multiple hosts/virtual machines/containers used to run the code may be distributed in the same region or in different regions. Furthermore, the multiple hosts/virtual machines/containers used to run the code may be distributed in the same availability zone (AZ) or in different AZs, each AZ including one data center or multiple data centers with close geographical locations. Generally, a region may include multiple AZs.
  • AZ availability zone
  • VPC virtual private cloud
  • multiple hosts/virtual machines/containers used to run the code can be distributed in the same virtual private cloud (VPC) or in multiple VPCs.
  • VPC virtual private cloud
  • a VPC is set in a region, and the distance between two VPCs in the same region is
  • a communication gateway must be set up in each VPC to achieve interconnection between VPCs through the communication gateway.
  • the acquisition module 710 may include at least one computing device, or the acquisition module 710 may be a device implemented by an application-specific integrated circuit (ASIC) or a programmable logic device (PLD).
  • the PLD may be a complex programmable logical device (CPLD), a field-programmable gate array (FPGA), a generic array logic (GAL) or any combination thereof.
  • the multiple computing devices included in the acquisition module 710 can be distributed in the same region or in different regions.
  • the multiple computing devices included in the acquisition module 710 can be distributed in the same AZ or in different AZs.
  • the multiple computing devices included in the acquisition module 710 can be distributed in the same VPC or in multiple VPCs.
  • the multiple computing devices can be any combination of computing devices such as ASIC, PLD, CPLD, FPGA, and GAL.
  • the technical solution provided by the embodiment of the present application corresponds to at least one startup scheme
  • each group of startup measurement information is used to characterize the startup performance of starting the target application in the intensive cloud computing system based on the corresponding startup scheme
  • the management platform in the intensive cloud computing system determines the first startup scheme according to the startup demand of the first application and the at least one group of startup measurement information (that is, the management platform determines the first startup scheme according to the startup demand of the first application and the startup performance of the at least one startup scheme), and starts the virtual unit of the first application in the first computing pool according to the first startup scheme
  • the virtual unit startup scheme provided by the embodiment of the present application has good performance in the intensive cloud computing system, can realize the extremely fast startup of the first application, and can make full use of low-cost resources to reduce the operating cost of the intensive cloud computing system. Since the management platform automatically selects the startup scheme according to the startup demand of the first application, the availability of the virtual unit startup scheme can be
  • An embodiment of the present application also provides a virtual unit startup device, including a memory and a processor; the memory is used to store a computer program; the processor is used to execute the computer program stored in the memory so that the virtual unit startup device performs all or part of the steps of the virtual unit startup method provided in the above embodiment.
  • FIG 8 shows a schematic diagram of another virtual unit startup device 800 provided in an embodiment of the present application.
  • the virtual unit startup device 800 can be a management platform in an intensive cloud computing system or a functional component in the management platform.
  • the virtual unit startup device 800 includes a bus 802, a processor 804, a memory 806, and a communication interface 808.
  • the processor 804, the memory 806, and the communication interface 808 communicate through the bus 802. It should be understood that the embodiment of the present application does not limit the number of processors and memories in the virtual unit startup device 800.
  • the bus 802 may be a peripheral component interconnect (PCI) bus or an extended industry standard architecture (EISA) bus, etc.
  • the bus may be divided into an address bus, a data bus, a control bus, etc.
  • FIG8 is represented by only one line, but it does not mean that there is only one bus or one type of bus.
  • the bus 802 may include a path for transmitting information between various components of the virtual unit startup device 800 (e.g., the memory 806, the processor 804, and the communication interface 808).
  • Processor 804 may include any one or more of a central processing unit (CPU), a graphics processing unit (GPU), a microprocessor (MP), or a digital signal processor (DSP).
  • CPU central processing unit
  • GPU graphics processing unit
  • MP microprocessor
  • DSP digital signal processor
  • the memory 806 may include a volatile memory, such as a random access memory (RAM).
  • the processor 804 may also include a non-volatile memory, such as a read-only memory (ROM), a flash memory, a hard disk drive (HDD), or a solid state drive (SSD).
  • ROM read-only memory
  • HDD hard disk drive
  • SSD solid state drive
  • the memory 806 stores executable program codes, and the processor 804 executes the executable program codes to respectively implement the functions of the aforementioned acquisition module 710, determination module 720, startup module 730, storage module 740, and creation module 750, thereby implementing at least some steps of the aforementioned virtual unit startup method. That is, the memory 806 stores instructions for executing the aforementioned virtual unit startup method.
  • the communication interface 808 uses a transceiver module such as, but not limited to, a network interface card or a transceiver to implement communication between the virtual unit startup device 800 and other devices or communication networks.
  • a transceiver module such as, but not limited to, a network interface card or a transceiver to implement communication between the virtual unit startup device 800 and other devices or communication networks.
  • the embodiment of the present application also provides a cloud computing system, which includes a computing pool and a storage pool, the computing pool is interconnected with the storage pool, and the computing pool includes a virtual unit startup device as shown in Figure 7 or Figure 8.
  • the computing pool includes a management platform, and the management platform includes a virtual unit startup device as shown in Figure 7 or Figure 8.
  • the cloud computing system is the intensive cloud computing system 100 as shown in FIG. 1 or FIG. 2 .
  • An embodiment of the present application provides a computer-readable storage medium, which stores a computer program.
  • the computer program is executed (for example, executed by a virtual unit startup device, a management platform, one or more processors, etc.), all or part of the steps of the method provided in the above method embodiment are implemented.
  • An embodiment of the present application provides a computer program product, which includes a program or code.
  • the program or code When executed (for example, executed by a virtual unit startup device, a management platform, one or more processors, etc.), it implements all or part of the steps of the method provided in the above method embodiment.
  • An embodiment of the present application provides a chip, which includes a programmable logic circuit and/or program instructions. When the chip is running, it is used to implement all or part of the steps of the method provided in the above method embodiment.
  • the “virtual unit” described in the embodiments of the present application may be a container or a virtual machine, and the “virtual units” in the above embodiments may all be replaced by “containers” or all be replaced by “virtual machines”. After the replacement, the technical solutions described in the above embodiments still hold true.
  • the above embodiments it can be implemented in whole or in part by software, hardware, firmware or any combination thereof.
  • software it can be implemented in whole or in part in the form of a computer program product, and the computer program product includes one or more computer instructions.
  • the computer program instructions When the computer program instructions are loaded and executed on a computer, the process or function described in the embodiment of the present application is generated in whole or in part.
  • the computer may be a general-purpose computer, a computer network, or other programmable device.
  • the computer instructions may be stored in a computer-readable storage medium, or transmitted from one computer-readable storage medium to another computer-readable storage medium, for example, the computer instructions may be transmitted from a website site, computer, server or data center by wired (e.g., coaxial cable, optical fiber, digital subscriber line) or wireless (e.g., infrared, wireless, microwave, etc.) mode to another website site, computer, server or data center.
  • the computer-readable storage medium may be any available medium that a computer can access or a data storage device such as a server, data center, etc. that contains one or more available media integrated.
  • the available medium may be a magnetic medium (e.g., a floppy disk, a hard disk, a tape), an optical medium, or a semiconductor medium (e.g., a solid-state hard disk), etc.
  • the term “at least one” in this application refers to one or more, and “multiple” refers to two or more.
  • the term “and/or” in this application is merely a description of the association relationship of associated objects, indicating that three relationships may exist. For example, A and/or B may represent: A exists alone, A and B exist at the same time, and B exists alone.
  • the words “first”, “second”, “third” and the like are used to distinguish between identical or similar items with substantially the same functions and effects. Those skilled in the art will understand that the words “first”, “second”, “third” and the like do not limit the quantity and execution order.
  • the disclosed devices and the like can be implemented by other configuration methods.
  • the device embodiments described above are only illustrative, for example, the division of modules is only a logical function division, and there may be other division methods in actual implementation, for example, multiple modules or components can be combined or integrated into another system, or some features can be ignored or not executed.
  • modules described as separate components may or may not be physically separated, and the components described as modules may or may not be physical modules, and may be located in one place or distributed on multiple devices. Some or all of the modules may be selected according to actual needs to achieve the purpose of the present embodiment.

Abstract

A virtual unit startup method and device, and a cloud computing system, relating to the technical field of cloud computers. The method is applied to a management platform in an intensive cloud computing system, and the intensive cloud computing system further comprises a first computing pool. The method comprises: acquiring a startup demand of a first application and at least one set of startup measurement information corresponding to a target application, wherein the at least one set of startup measurement information corresponds to at least one startup scheme, each set of startup measurement information is used for representing the startup performance of starting the target application in an intensive cloud computing system on the basis of the corresponding startup scheme, and the target application is matched with the first application; determining a first startup scheme according to the startup demand of the first application and the at least one set of startup measurement information; and starting a first virtual unit of the first application in a first computing pool according to the first startup scheme. The virtual unit startup scheme provided by the present application has better implementation performance in the intensive cloud computing system.

Description

虚拟单元启动方法及装置、云计算***Virtual unit startup method and device, cloud computing system
本申请要求申请日为2022年12月23日,申请号为202211663651.X,申请名称为“容器启动方法及装置、云计算***”的中国专利申请的优先权,以及,要求申请日为2023年03月31日,申请号为202310340580.8,申请名称为“虚拟单元启动方法及装置、云计算***”的中国专利申请的优先权,这两件专利申请的全部内容通过引用结合在本申请中。This application claims priority to a Chinese patent application filed on December 23, 2022, with application number 202211663651.X, and application name “CONTAINER STARTUP METHOD AND DEVICE, AND CLOUD COMPUTING SYSTEM”, and claims priority to a Chinese patent application filed on March 31, 2023, with application number 202310340580.8, and application name “VIRTUAL UNIT STARTUP METHOD AND DEVICE, AND CLOUD COMPUTING SYSTEM”. The entire contents of these two patent applications are incorporated into this application by reference.
技术领域Technical Field
本申请涉及云算机技术领域,特别涉及一种虚拟单元启动方法及装置、云计算***。The present application relates to the field of cloud computing technology, and in particular to a virtual unit startup method and device, and a cloud computing system.
背景技术Background technique
随着虚拟化技术的发展,云计算***可以将应用(application)部署在容器(container)中,以基于容器实现不同应用的资源隔离。通常,启动某一应用包括启动该应用的容器(也即部署该应用的容器)。With the development of virtualization technology, cloud computing systems can deploy applications in containers to achieve resource isolation of different applications based on containers. Generally, starting an application includes starting the container of the application (ie, the container in which the application is deployed).
目前的容器启动方案是针对非集约化云计算***设计的,在集约化云计算***中实施的性能较差。其中,集约化云计算***包括高速互联的多个集约化资源池,每个集约化资源池中集中分布计算资源、内存资源或外存资源中的一类资源。非集约化云计算***包括独立的多个非集约化资源池,每个非集约化资源池中的计算资源、内存资源和外存资源的配比相当。The current container startup scheme is designed for non-intensive cloud computing systems, and its performance is poor when implemented in intensive cloud computing systems. Intensive cloud computing systems include multiple intensive resource pools that are interconnected at high speeds, and each intensive resource pool centrally distributes one type of resource among computing resources, memory resources, or external storage resources. Non-intensive cloud computing systems include multiple independent non-intensive resource pools, and the ratio of computing resources, memory resources, and external storage resources in each non-intensive resource pool is comparable.
发明内容Summary of the invention
本申请提供了一种虚拟单元启动方法及装置、云计算***。本申请的技术方案如下。The present application provides a virtual unit startup method and device, and a cloud computing system. The technical solution of the present application is as follows.
第一方面,提供了一种虚拟单元启动方法,应用于集约化云计算***中的管理平台,该集约化云计算***还包括第一计算池,该方法包括:获取第一应用的启动诉求;获取目标应用对应的至少一组启动测量信息,该至少一组启动测量信息对应至少一个启动方案,该至少一组启动测量信息中的每组启动测量信息用于表征基于对应的启动方案在该集约化云计算***中启动目标应用的启动性能,目标应用与第一应用匹配;根据第一应用的启动诉求和该至少一组启动测量信息确定第一启动方案,该至少一个启动方案包括第一启动方案;根据第一启动方案在第一计算池中启动第一应用的第一虚拟单元。In a first aspect, a virtual unit startup method is provided, which is applied to a management platform in an intensive cloud computing system, wherein the intensive cloud computing system also includes a first computing pool, and the method includes: obtaining a startup demand of a first application; obtaining at least one set of startup measurement information corresponding to a target application, wherein the at least one set of startup measurement information corresponds to at least one startup scheme, wherein each set of startup measurement information in the at least one set of startup measurement information is used to characterize startup performance of starting the target application in the intensive cloud computing system based on the corresponding startup scheme, and the target application matches the first application; determining a first startup scheme according to the startup demand of the first application and the at least one set of startup measurement information, wherein the at least one startup scheme includes a first startup scheme; and starting a first virtual unit of the first application in the first computing pool according to the first startup scheme.
其中,第一启动方案是第一应用的启动方案,第一启动方案的启动性能与第一应用的启动诉求匹配,第一启动方案的启动性能满足第一应用的启动诉求。管理平台根据第一应用的启动诉求和该至少一组启动测量信息确定第一启动方案也即是该管理平台根据该启动诉求和该至少一组启动测量信息对应的该至少一个启动方案的启动性能确定第一启动方案。The first startup scheme is a startup scheme of the first application, the startup performance of the first startup scheme matches the startup demand of the first application, and the startup performance of the first startup scheme meets the startup demand of the first application. The management platform determines the first startup scheme according to the startup demand of the first application and the at least one set of startup measurement information, that is, the management platform determines the first startup scheme according to the startup demand and the startup performance of the at least one startup scheme corresponding to the at least one set of startup measurement information.
本申请提供的技术方案,由于集约化云计算***中的管理平台根据第一应用的启动诉求和至少一个启动方案的启动性能确定第一启动方案,并根据第一启动方案在该集约化云计算***中的第一计算池中启动第一应用的虚拟单元,因此,该虚拟单元启动方案在集约化云计算***中实施的性能较好,可以实现第一应用的极速启动,且可以充分利用低成本的资源。由于管理平台根据第一应用的启动诉求自动选择启动方案,因此能够提升方案的可用性。The technical solution provided by the present application is that the management platform in the intensive cloud computing system determines the first startup solution according to the startup demand of the first application and the startup performance of at least one startup solution, and starts the virtual unit of the first application in the first computing pool in the intensive cloud computing system according to the first startup solution. Therefore, the virtual unit startup solution has good performance when implemented in the intensive cloud computing system, can realize the extremely fast startup of the first application, and can make full use of low-cost resources. Since the management platform automatically selects the startup solution according to the startup demand of the first application, the availability of the solution can be improved.
可选的,第一启动方案包括以下任意一个:基于第一存储池的热启动方案;基于第一存储池的冷启动方案;基于第二计算池的冷启动方案;其中,第一存储池和第二计算池分别与第一计算池互联。例如,基于第一存储池的热启动方案是基于第一存储池中存储的内存快照的热启动方案,基于第一存储池的冷启动方案是基于第一存储池中存储的虚拟单元快照的冷启动方案,基于第二计算池的冷启动方案是基于第二计算池中运行的虚拟单元的冷启动方案。Optionally, the first startup solution includes any one of the following: a hot startup solution based on the first storage pool; a cold startup solution based on the first storage pool; a cold startup solution based on the second computing pool; wherein the first storage pool and the second computing pool are interconnected with the first computing pool, respectively. For example, the hot startup solution based on the first storage pool is a hot startup solution based on a memory snapshot stored in the first storage pool, the cold startup solution based on the first storage pool is a cold startup solution based on a virtual unit snapshot stored in the first storage pool, and the cold startup solution based on the second computing pool is a cold startup solution based on a virtual unit running in the second computing pool.
可选的,第一启动方案包括基于第一存储池的热启动方案,第一存储池中存储有基准内存快照,该基准内存快照是对第一应用的基准虚拟单元的内存进行快照得到的,第一计算池中包括第一虚拟单元;根据第一启动方案在第一计算池中启动第一应用的第一虚拟单元,包括:根据该基准内存快照在第一计算池中创建第一内存分支,第一内存分支用于存储第一虚拟单元运行过程中相对于该基准内存快照发生变化的内存数据,第一虚拟单元的内存数据(也即第一虚拟单元的内存中的数据)根据该基准内存快照中的数据和 第一内存分支中存储的内存数据确定。其中,第一应用的基准虚拟单元是部署有第一应用且已启动的虚拟单元。Optionally, the first startup scheme includes a hot startup scheme based on the first storage pool, the first storage pool stores a baseline memory snapshot, the baseline memory snapshot is obtained by taking a snapshot of the memory of the baseline virtual unit of the first application, and the first computing pool includes the first virtual unit; starting the first virtual unit of the first application in the first computing pool according to the first startup scheme includes: creating a first memory branch in the first computing pool according to the baseline memory snapshot, the first memory branch is used to store memory data that has changed relative to the baseline memory snapshot during the operation of the first virtual unit, and the memory data of the first virtual unit (that is, the data in the memory of the first virtual unit) is based on the data in the baseline memory snapshot and The memory data stored in the first memory branch is determined. The base virtual unit of the first application is a virtual unit in which the first application is deployed and started.
可选的,第一存储池中还存储有基准文件***,该基准文件***是该基准虚拟单元的文件***;根据第一启动方案在第一计算池中启动第一应用的第一虚拟单元,还包括:根据该基准文件***在第一计算池中创建第一读写层,第一读写层用于存储第一虚拟单元运行过程中相对于该基准文件***发生变化的文件数据,第一虚拟单元的文件***根据该基准文件***中的文件数据和第一读写层中存储的文件数据确定。Optionally, a benchmark file system is also stored in the first storage pool, and the benchmark file system is the file system of the benchmark virtual unit; starting the first virtual unit of the first application in the first computing pool according to the first startup plan also includes: creating a first read-write layer in the first computing pool according to the benchmark file system, the first read-write layer is used to store file data that changes relative to the benchmark file system during the operation of the first virtual unit, and the file system of the first virtual unit is determined based on the file data in the benchmark file system and the file data stored in the first read-write layer.
可选的,在根据第一启动方案在第一计算池中启动第一虚拟单元之前,该方法还包括:Optionally, before starting the first virtual unit in the first computing pool according to the first starting scheme, the method further includes:
在该基准虚拟单元运行的过程中,获取该基准虚拟单元的该基准内存快照;将该基准内存快照存储至第一存储池中。During the operation of the benchmark virtual unit, the benchmark memory snapshot of the benchmark virtual unit is obtained; and the benchmark memory snapshot is stored in the first storage pool.
本申请提供的技术方案,管理平台获取基准内存快照,并将该基准内存快照存储至第一存储池中,可以便于该管理单元后续根据该基准内存快照创建第一内存分支以启动第一虚拟单元,提高该管理平台启动第一虚拟单元的速度,从而提高第一应用的启动速度。The technical solution provided by the present application is that the management platform obtains a baseline memory snapshot and stores the baseline memory snapshot in a first storage pool, which can facilitate the management unit to subsequently create a first memory branch based on the baseline memory snapshot to start the first virtual unit, thereby improving the speed at which the management platform starts the first virtual unit, thereby improving the startup speed of the first application.
可选的,在根据第一启动方案在第一计算池中启动第一虚拟单元之前,该方法还包括:Optionally, before starting the first virtual unit in the first computing pool according to the first starting scheme, the method further includes:
根据第一应用的应用镜像在第一计算池中创建第一虚拟单元。也即,在预热第一虚拟单元。A first virtual unit is created in the first computing pool according to the application image of the first application, that is, the first virtual unit is preheated.
本申请提供的技术方案,管理平台预热第一虚拟单元,可以提高该管理平台后续启动第一虚拟单元的速度,从而提高第一应用的启动速度,例如实现第一应用的极速启动。The technical solution provided by the present application is that the management platform preheats the first virtual unit, which can increase the speed at which the management platform subsequently starts the first virtual unit, thereby increasing the startup speed of the first application, for example, achieving extremely fast startup of the first application.
可选的,第一启动方案包括基于第一存储池的冷启动方案,第一存储池中存储有基准单元快照,该基准单元快照是对第一应用的基准虚拟单元进行快照得到的;根据第一启动方案在第一计算池中启动第一应用的第一虚拟单元,包括:根据该基准单元快照在第一计算池中创建并启动第一虚拟单元。Optionally, the first startup plan includes a cold start plan based on the first storage pool, in which a baseline unit snapshot is stored, and the baseline unit snapshot is obtained by taking a snapshot of the baseline virtual unit of the first application; starting the first virtual unit of the first application in the first computing pool according to the first startup plan includes: creating and starting the first virtual unit in the first computing pool according to the baseline unit snapshot.
可选的,在根据第一启动方案在第一计算池中启动第一虚拟单元之前,该方法还包括:Optionally, before starting the first virtual unit in the first computing pool according to the first starting scheme, the method further includes:
在该基准虚拟单元运行的过程中,获取该基准虚拟单元的该基准单元快照;将该基准单元快照存储至该第一存储池中。During the operation of the reference virtual unit, a reference unit snapshot of the reference virtual unit is obtained; and the reference unit snapshot is stored in the first storage pool.
本申请提供的技术方案,管理平台获取基准单元快照,并将该基准单元快照存储至第一存储池中,可以便于该管理单元后续根据该基准单元快照创建第一虚拟单元并启动第一虚拟单元,提高该管理平台启动第一虚拟单元的速度,从而提高第一应用的启动速度。The technical solution provided by the present application is that the management platform obtains a baseline unit snapshot and stores the baseline unit snapshot in a first storage pool, which can facilitate the management unit to subsequently create a first virtual unit and start the first virtual unit based on the baseline unit snapshot, thereby improving the speed at which the management platform starts the first virtual unit, thereby improving the startup speed of the first application.
可选的,该基准虚拟单元运行在第一计算池中。Optionally, the benchmark virtual unit runs in a first computing pool.
可选的,第一启动方案包括基于第二计算池的冷启动方案,第二计算池中运行有第二虚拟单元,第二虚拟单元的配置与第一虚拟单元的配置相同;根据第一启动方案在第一计算池中启动第一应用的第一虚拟单元,包括:根据第二虚拟单元在第一计算池中创建并启动第一虚拟单元。其中,第二虚拟单元的配置与第一虚拟单元的配置相同包括:第二虚拟单元的元数据与第一虚拟单元的元数据相同,第二虚拟单元的描述与第一虚拟单元的描述相同。例如,第二虚拟单元的属性与第一虚拟单元的属性相同,第二虚拟单元对应的应用镜像与第一虚拟单元对应的应用镜像相同(例如第二虚拟单元对应的应用镜像和第一虚拟单元对应的应用镜像都是第一应用的应用镜像)。示例的,第二虚拟单元的另一种标记语言(yet another markup language,YAML)文件与第一虚拟单元的YAML文件相同。其中,应用镜像是一种文件存储形式,是一个应用轻量级且独立可执行的软件包,任一应用的应用镜像包含运行该应用所需的所有内容,包含代码、***工具、库、环境变量和配置文件等,例如,任一应用的应用镜像包含启动该应用的虚拟单元所需的所有内容,包含代码、***工具、库、环境变量和配置文件等。Optionally, the first startup scheme includes a cold start scheme based on the second computing pool, a second virtual unit is running in the second computing pool, and the configuration of the second virtual unit is the same as the configuration of the first virtual unit; starting the first virtual unit of the first application in the first computing pool according to the first startup scheme includes: creating and starting the first virtual unit in the first computing pool according to the second virtual unit. Among them, the configuration of the second virtual unit is the same as the configuration of the first virtual unit, including: the metadata of the second virtual unit is the same as the metadata of the first virtual unit, and the description of the second virtual unit is the same as the description of the first virtual unit. For example, the attributes of the second virtual unit are the same as the attributes of the first virtual unit, and the application image corresponding to the second virtual unit is the same as the application image corresponding to the first virtual unit (for example, the application image corresponding to the second virtual unit and the application image corresponding to the first virtual unit are both application images of the first application). For example, another markup language (yet another markup language, YAML) file of the second virtual unit is the same as the YAML file of the first virtual unit. Among them, an application image is a form of file storage, which is a lightweight and independently executable software package of an application. The application image of any application contains all the content required to run the application, including code, system tools, libraries, environment variables and configuration files, etc. For example, the application image of any application contains all the content required to start the virtual unit of the application, including code, system tools, libraries, environment variables and configuration files, etc.
可选的,根据第二虚拟单元启动第一虚拟单元,包括:根据第二虚拟单元的内存在第一计算池中创建第二内存分支,第二内存分支用于存储第一虚拟单元运行过程中相对于第二虚拟单元的内存发生变化的内存数据,第一虚拟单元的内存数据根据第二虚拟单元的内存数据(也即第二虚拟单元的内存中的数据)和第二内存分支中存储的内存数据确定。Optionally, starting the first virtual unit according to the second virtual unit includes: creating a second memory branch in the first computing pool according to the memory of the second virtual unit, the second memory branch being used to store memory data that has changed relative to the memory of the second virtual unit during the operation of the first virtual unit, and the memory data of the first virtual unit is determined based on the memory data of the second virtual unit (that is, the data in the memory of the second virtual unit) and the memory data stored in the second memory branch.
可选的,根据第二虚拟单元启动第一虚拟单元,包括:根据第二虚拟单元的文件***在第一计算池中创建第二读写层,第二读写层用于存储第一虚拟单元运行过程中相对于第二虚拟单元的文件***发生变化的文件数据,第一虚拟单元的文件***根据第二虚拟单元的文件***中的文件数据和第二内存分支中存储的内存数据确定。Optionally, starting the first virtual unit according to the second virtual unit includes: creating a second read-write layer in the first computing pool according to the file system of the second virtual unit, the second read-write layer being used to store file data that has changed relative to the file system of the second virtual unit during the operation of the first virtual unit, the file system of the first virtual unit being determined based on the file data in the file system of the second virtual unit and the memory data stored in the second memory branch.
可选的,该集约化云计算***还包括第一存储池,第一存储池与第一计算池互联;第一存储池用于存储第一应用的以下至少一个信息:第一应用的虚拟单元的内存的快照;第一应用的虚拟单元的快照;第一 应用的应用镜像。第一应用的该至少一个信息在第一存储池中的存储位置根据第一应用的以下至少一个指标确定:重要性、使用频率、启动诉求。Optionally, the intensive cloud computing system further includes a first storage pool, the first storage pool being interconnected with the first computing pool; the first storage pool being used to store at least one of the following information of the first application: a snapshot of the memory of the virtual unit of the first application; a snapshot of the virtual unit of the first application; The storage location of the at least one information of the first application in the first storage pool is determined according to at least one of the following indicators of the first application: importance, usage frequency, and startup demand.
本申请提供的技术方案,根据第一应用的重要性、使用频率、启动诉求等指标确定第一应用的虚拟单元的内存的快照、第一应用的虚拟单元的快照、第一应用的应用镜像等信息在第一存储池中的存储位置,因此可以将重要性较高、使用频率较大、启动诉求较为严格的应用的信息存储在性能较好的存储介质中,保障这些应用的启动性能。The technical solution provided in the present application determines the storage location of information such as a snapshot of the memory of the virtual unit of the first application, a snapshot of the virtual unit of the first application, and an application image of the first application in the first storage pool according to indicators such as the importance, usage frequency, and startup requirements of the first application. Therefore, information of applications with higher importance, higher usage frequency, and stricter startup requirements can be stored in a storage medium with better performance, thereby ensuring the startup performance of these applications.
可选的,该集约化云计算***还包括镜像仓库,该镜像仓库用于存储应用镜像的指示信息与该应用镜像在第一存储池中的存储位置的对应关系。Optionally, the intensive cloud computing system further includes an image warehouse, which is used to store the correspondence between the indication information of the application image and the storage location of the application image in the first storage pool.
本申请提供的技术方案,应用镜像存储在第一存储池中,镜像仓库用于存储应用镜像的指示信息与该应用镜像的存储位置的对应关系,因此,管理平台创建某一应用的虚拟单元时,该管理平台根据该应用的应用镜像的指示信息从该镜像仓库中获取该应用镜像的存储位置,进而根据该应用镜像的存储位置从第一存储池中获取该应用镜像,由此,本申请将应用镜像分布式存储在第一存储池中,镜像仓库仅记录应用镜像的存储位置,可以提升获取应用镜像的速度,减小创建虚拟单元的时延,避免集中式镜像仓库的带宽瓶颈。The technical solution provided by the present application is that the application image is stored in the first storage pool, and the image warehouse is used to store the correspondence between the indication information of the application image and the storage location of the application image. Therefore, when the management platform creates a virtual unit of an application, the management platform obtains the storage location of the application image from the image warehouse according to the indication information of the application image of the application, and then obtains the application image from the first storage pool according to the storage location of the application image. Therefore, the present application stores the application image in the first storage pool in a distributed manner, and the image warehouse only records the storage location of the application image, which can improve the speed of obtaining the application image, reduce the delay in creating the virtual unit, and avoid the bandwidth bottleneck of the centralized image warehouse.
可选的,第一存储池包括内存池和外存池中的至少一个。Optionally, the first storage pool includes at least one of a memory pool and an external memory pool.
可选的,该内存池和该外存池满足以下至少一项:该内存池包括至少两个第一存储介质,该至少两个第一存储介质的类型不同;该外存池包括至少两个第二存储介质,该至少两个第二存储介质的类型不同。其中,第一存储介质和第二存储介质分别基于差分算法存储数据。Optionally, the memory pool and the external memory pool satisfy at least one of the following: the memory pool includes at least two first storage media, and the at least two first storage media are of different types; the external memory pool includes at least two second storage media, and the at least two second storage media are of different types. The first storage medium and the second storage medium store data based on a differential algorithm respectively.
本申请提供的技术方案,由于第一存储介质和第二存储介质分别基于差分算法存储数据,因此对于任一数据块,仅需在第一存储介质或第二存储介质中存储该任一数据块与参考数据块之间的差异,相同的数据块仅存储一份,可以节省存储资源,降低存储成本。The technical solution provided by the present application is that since the first storage medium and the second storage medium store data based on a differential algorithm respectively, for any data block, it is only necessary to store the difference between the data block and the reference data block in the first storage medium or the second storage medium, and only one copy of the same data block is stored, which can save storage resources and reduce storage costs.
可选的,目标应用与第一应用匹配包括以下至少一项:目标应用是第一应用;目标应用的规模与第一应用的规模匹配;目标应用的应用镜像的大小与第一应用的应用镜像的大小匹配;目标应用的类型与第一应用的类型匹配。Optionally, the target application matches the first application, including at least one of the following: the target application is the first application; the scale of the target application matches the scale of the first application; the size of the application image of the target application matches the size of the application image of the first application; the type of the target application matches the type of the first application.
可选的,第一应用的启动诉求包括启动时长诉求和启动成本诉求中的至少一个;启动测量信息包括测量启动时长和测量启动成本中的至少一个。Optionally, the startup requirement of the first application includes at least one of a startup duration requirement and a startup cost requirement; and the startup measurement information includes at least one of a measured startup duration and a measured startup cost.
可选的,获取目标应用对应的至少一组启动测量信息,包括:根据该至少一个启动方案中的每个启动方案在该集约化云计算***中对目标应用进行启动测试,得到该每个启动方案对应的一组启动测量信息。Optionally, obtaining at least one set of startup measurement information corresponding to the target application includes: performing a startup test on the target application in the intensive cloud computing system according to each startup scheme in the at least one startup scheme to obtain a set of startup measurement information corresponding to each startup scheme.
可选的,所述管理平台部署在第一计算池中。从管理平台的角度来讲,第一计算池称为本地计算池、第二计算池称为远端(remote)计算池,第一存储池称为远端存储池。Optionally, the management platform is deployed in the first computing pool. From the perspective of the management platform, the first computing pool is called a local computing pool, the second computing pool is called a remote computing pool, and the first storage pool is called a remote storage pool.
可选的,第一虚拟单元是容器或虚拟机。Optionally, the first virtual unit is a container or a virtual machine.
第二方面,提供了一种虚拟单元启动装置,包括至少一个模块,该至少一个模块用于执行如上述第一方面或第一方面的任一可选方式所提供的方法。该至少一个模块可以基于软件、硬件或软件和硬件的结合实现,该至少一个模块可以基于具体实现进行任意组合或分割。In a second aspect, a virtual unit startup device is provided, comprising at least one module, the at least one module being used to execute the method provided in the first aspect or any optional manner of the first aspect. The at least one module can be implemented based on software, hardware, or a combination of software and hardware, and the at least one module can be arbitrarily combined or divided based on a specific implementation.
第三方面,提供了一种虚拟单元启动装置,包括存储器和处理器;该存储器用于存储计算机程序;该处理器用于执行该存储器中存储的计算机程序以使得该虚拟单元启动装置执行如上述第一方面或第一方面的任一可选方式所提供的方法。In a third aspect, a virtual unit startup device is provided, comprising a memory and a processor; the memory is used to store a computer program; the processor is used to execute the computer program stored in the memory so that the virtual unit startup device performs a method provided in the first aspect or any optional method of the first aspect.
第四方面,提供了一种云计算***,包括如上述第二方面或第三方面所提供的虚拟单元启动装置。In a fourth aspect, a cloud computing system is provided, comprising the virtual unit startup device provided in the second aspect or the third aspect.
可选的,该云计算***包括计算池和存储池,该计算池与该存储池互联,该计算池包括如上述第二方面或第三方面所提供的虚拟单元启动装置。例如,该计算池包括管理平台,该管理平台包括如上述第二方面或第三方面所提供的虚拟单元启动装置。Optionally, the cloud computing system includes a computing pool and a storage pool, the computing pool is interconnected with the storage pool, and the computing pool includes a virtual unit startup device as provided in the second aspect or the third aspect. For example, the computing pool includes a management platform, and the management platform includes a virtual unit startup device as provided in the second aspect or the third aspect.
可选的,该存储池包括内存池和外存池,该内存池和该外存池分别与该计算池互联。Optionally, the storage pool includes a memory pool and an external memory pool, and the memory pool and the external memory pool are interconnected with the computing pool respectively.
第五方面,提供了一种计算机可读存储介质,该计算机可读存储介质中存储有计算机程序,该计算机程序被执行时实现如上述第一方面或第一方面的任一可选方式所提供的方法。In a fifth aspect, a computer-readable storage medium is provided, in which a computer program is stored. When the computer program is executed, the method provided in the first aspect or any optional manner of the first aspect is implemented.
第六方面,提供了一种计算机程序产品,该计算机程序产品包括程序或代码,该程序或代码被执行时实现如上述第一方面或第一方面的任一可选方式所提供的方法。In a sixth aspect, a computer program product is provided, which includes a program or code, and when the program or code is executed, it implements the method provided in the first aspect or any optional manner of the first aspect.
上述第二方面至第六方面的技术效果可以参考第一方面的技术效果,这里不做赘述。 The technical effects of the second to sixth aspects mentioned above can refer to the technical effects of the first aspect and will not be elaborated here.
附图说明BRIEF DESCRIPTION OF THE DRAWINGS
图1是本申请实施例提供的一种集约化云计算***的示意图;FIG1 is a schematic diagram of an intensive cloud computing system provided in an embodiment of the present application;
图2是本申请实施例提供的另一种集约化云计算***的示意图;FIG2 is a schematic diagram of another intensive cloud computing system provided in an embodiment of the present application;
图3是本申请实施例提供的一种虚拟单元启动方法的流程图;FIG3 is a flow chart of a method for starting a virtual unit provided in an embodiment of the present application;
图4是本申请实施例提供的一种启动第一虚拟单元的示意图;FIG4 is a schematic diagram of starting a first virtual unit provided by an embodiment of the present application;
图5是本申请实施例提供的另一种启动第一虚拟单元的示意图;FIG5 is a schematic diagram of another method of starting a first virtual unit provided by an embodiment of the present application;
图6是本申请实施例提供的再一种启动第一虚拟单元的示意图;FIG6 is a schematic diagram of another method of starting a first virtual unit provided in an embodiment of the present application;
图7是本申请实施例提供的一种虚拟单元启动装置的示意图;FIG7 is a schematic diagram of a virtual unit startup device provided in an embodiment of the present application;
图8是本申请实施例提供的另一种虚拟单元启动装置的示意图。FIG8 is a schematic diagram of another virtual unit starting device provided in an embodiment of the present application.
具体实施方式Detailed ways
下面将结合附图对本申请实施方式作进一步地描述。The implementation methods of the present application will be further described below in conjunction with the accompanying drawings.
随着虚拟化技术的发展,云计算***可以将应用部署在容器中,以基于容器实现不同应用的资源隔离。其中,部署在容器中的应用可以是无服务器(serverless)应用或其他应用。With the development of virtualization technology, cloud computing systems can deploy applications in containers to achieve resource isolation of different applications based on containers. Among them, the applications deployed in the containers can be serverless applications or other applications.
在基于容器的应用隔离方案中,一般情况下,启动某一应用包括启动该应用的容器。其中,某一应用的容器可以是部署有该应用的容器(也即是该应用已经部署在该容器中)、即将部署该应用的容器(也即是即将在该容器中部署该应用)、针对该应用创建的容器(例如根据该应用的应用镜像创建的容器)等最终可用于该应用运行的容器。In a container-based application isolation solution, generally speaking, starting an application includes starting a container of the application. The container of an application may be a container in which the application is deployed (i.e., the application has been deployed in the container), a container in which the application is to be deployed (i.e., the application is to be deployed in the container), a container created for the application (e.g., a container created based on the application image of the application), or other containers that can ultimately be used to run the application.
目前的容器启动方案包括热启动方案和冷启动方案。在热启动方案中,云计算***预先创建(也即预热)一定数量的容器,当云计算***接收到对应于某一应用的容器启动请求时,该云计算***根据该容器启动请求在预先创建好的容器中为该应用分配容器并启动这些容器。在冷启动方案中,对于某一应用,云计算***预先准备创建该应用的容器所需的至少部分组件(例如容器快照),当云计算***接收到对应于该应用的容器启动请求时,该云计算***根据该容器启动请求基于预先准备好的组件创建该应用的容器并启动这些容器。Current container startup solutions include hot startup solutions and cold startup solutions. In the hot startup solution, the cloud computing system pre-creates (i.e., pre-heats) a certain number of containers. When the cloud computing system receives a container startup request corresponding to a certain application, the cloud computing system allocates containers for the application in the pre-created containers according to the container startup request and starts these containers. In the cold startup solution, for a certain application, the cloud computing system pre-prepares at least some of the components (e.g., container snapshots) required to create a container for the application. When the cloud computing system receives a container startup request corresponding to the application, the cloud computing system creates containers for the application based on the pre-prepared components according to the container startup request and starts these containers.
云原生技术的不断发展驱动底层硬件基础设施向资源集约化高速互联的资源池演进,这使得集约化云计算***应运而生。集约化云计算***也称为也称为分离式数据中心(disaggregated data center),其特点是每类资源都集中分布在对应的资源池中,各资源池通过高速网络互联,集约化云计算***中的资源池也称为集约化资源池。例如,集约化云计算***包括高速互联的计算池、内存池和外存池,计算池、内存池和外存池都是集约化资源池,计算资源集中分布在计算池中,内存资源集中分布在内存池中,外存资源集中分布在外存池中。此外,计算池中还包括少量的内存资源和/或外存资源,内存池中还包括少量的计算资源和/或外存资源,外存池中还包括少量的计算资源和/或内存资源。示例的,装配有大量内存的主机是一个内存池,以中央处理单元(central processing unit,CPU)为主的主机是一个计算池,装配有大量内存的主机通过远程直接内存存取(remote direct memory access,RDMA)网络连接到以CPU为主的主机上。非集约化云计算***的特点是每个资源池中不同类资源的配比相当,非集约化云计算***中的资源池也称为非集约化资源池,例如,非集约化云计算***包括独立的多个非集约化资源池,每个非集约化资源池中包括计算资源、内存资源和外存资源,且每个非集约化资源池中的计算资源、内存资源和外存资源的配比相当。The continuous development of cloud-native technology drives the evolution of the underlying hardware infrastructure to a resource pool with intensive and high-speed interconnection, which has led to the emergence of intensive cloud computing systems. Intensive cloud computing systems are also called disaggregated data centers. Their characteristics are that each type of resource is concentrated in the corresponding resource pool, and each resource pool is interconnected through a high-speed network. The resource pool in the intensive cloud computing system is also called an intensive resource pool. For example, an intensive cloud computing system includes a high-speed interconnected computing pool, a memory pool, and an external memory pool. The computing pool, the memory pool, and the external memory pool are all intensive resource pools. The computing resources are concentrated in the computing pool, the memory resources are concentrated in the memory pool, and the external memory resources are concentrated in the external memory pool. In addition, the computing pool also includes a small amount of memory resources and/or external memory resources, the memory pool also includes a small amount of computing resources and/or external memory resources, and the external memory pool also includes a small amount of computing resources and/or memory resources. For example, a host equipped with a large amount of memory is a memory pool, a host based on a central processing unit (CPU) is a computing pool, and a host equipped with a large amount of memory is connected to a host based on a CPU via a remote direct memory access (RDMA) network. The characteristic of a non-intensive cloud computing system is that the ratio of different types of resources in each resource pool is equal. The resource pool in a non-intensive cloud computing system is also called a non-intensive resource pool. For example, a non-intensive cloud computing system includes multiple independent non-intensive resource pools, each of which includes computing resources, memory resources, and external storage resources, and the ratio of computing resources, memory resources, and external storage resources in each non-intensive resource pool is equal.
目前的容器启动方案是针对非集约化云计算***设计的,由于集约化云计算***的特点与非集约化云计算***的特点不同,因此在集约化云计算***中直接实施目前的容器启动方案容易导致应用启动性能较差,集约化云计算***的性能较差等问题。例如,若在集约化云计算***中直接实施目前的热启动方案,由于在内存配比较小的计算池中无法预热很多容器,当集约化云计算***接收到对应于某一应用的容器启动请求,且该容器启动请求用于启动多个容器时,预热的容器的数量可能不足(例如用户请求启动10个容器,仅预热7个容器),影响该应用的启动速度,这对于serverless应用是难以忍受的(serverless应用对容器的启动诉求是极速启动)。再例如,若在集约化云计算***中直接实施目前的冷启动方案,集约化云计算***会在计算池中存储容器快照(目前的容器启动方案基于容器快照启动容器时,容器快照和容器在同一非集约化资源池中),而不会在与该计算池高速互联的存储池(内存池或外存池)中存储容器快照, 相比于该存储池中的存储资源,该计算池中的存储资源的成本较高,这导致无法利用低成本的存储资源,进而导致集约化云计算***运营成本较高。The current container startup solution is designed for non-intensive cloud computing systems. Since the characteristics of intensive cloud computing systems are different from those of non-intensive cloud computing systems, directly implementing the current container startup solution in intensive cloud computing systems is likely to lead to problems such as poor application startup performance and poor performance of intensive cloud computing systems. For example, if the current hot start solution is directly implemented in an intensive cloud computing system, since it is impossible to preheat many containers in a computing pool with a small memory allocation, when the intensive cloud computing system receives a container startup request corresponding to an application, and the container startup request is used to start multiple containers, the number of preheated containers may be insufficient (for example, the user requests to start 10 containers, but only 7 containers are preheated), affecting the startup speed of the application, which is unbearable for serverless applications (serverless applications require extremely fast startup of containers). For another example, if the current cold start solution is directly implemented in an intensive cloud computing system, the intensive cloud computing system will store the container snapshot in the computing pool (when the current container startup solution starts the container based on the container snapshot, the container snapshot and the container are in the same non-intensive resource pool), but will not store the container snapshot in the storage pool (memory pool or external memory pool) that is interconnected with the computing pool at a high speed. Compared with the storage resources in the storage pool, the storage resources in the computing pool are more expensive, which results in an inability to utilize low-cost storage resources, and in turn results in higher operating costs for the intensive cloud computing system.
本申请实施例提供了一种虚拟单元启动方案,该虚拟单元启动方案应用于集约化云计算***中的管理平台,该集约化云计算***还包括第一计算池。该管理平台根据第一应用的启动诉求和目标应用对应的至少一组启动测量信息确定第一启动方案,并根据第一启动方案在第一计算池中启动第一应用的虚拟单元。其中,该至少一组启动测量信息对应至少一个启动方案,每组启动测量信息用于表征基于对应的启动方案在该集约化云计算***中启动目标应用的启动性能,目标应用与第一应用匹配,该至少一个启动方案包括第一启动方案,该管理平台根据第一应用的启动诉求和该至少一组启动测量信息确定第一启动方案也即是该管理平台根据该启动诉求和该至少一个启动方案的启动性能确定第一启动方案。由于集约化云计算***中的管理平台根据第一应用的启动诉求和目标应用对应的至少一个启动方案的启动性能确定第一启动方案,并根据第一启动方案在该集约化云计算***中的第一计算池中启动第一应用的虚拟单元,因此,本申请实施例提供的虚拟单元启动方案在集约化云计算***中实施的性能较好,可以实现第一应用的极速启动,且可以充分利用低成本的资源,降低集约化云计算***的运营成本。其中,虚拟单元是容器、虚拟机(virtual machine,VM)或其他用于资源隔离的单元,本文中的所有“虚拟单元”均可以替换为“容器”或“虚拟机”。The embodiment of the present application provides a virtual unit startup scheme, which is applied to a management platform in an intensive cloud computing system, and the intensive cloud computing system also includes a first computing pool. The management platform determines the first startup scheme according to the startup demand of the first application and at least one set of startup measurement information corresponding to the target application, and starts the virtual unit of the first application in the first computing pool according to the first startup scheme. Among them, the at least one set of startup measurement information corresponds to at least one startup scheme, and each set of startup measurement information is used to characterize the startup performance of starting the target application in the intensive cloud computing system based on the corresponding startup scheme. The target application matches the first application, and the at least one startup scheme includes the first startup scheme. The management platform determines the first startup scheme according to the startup demand of the first application and the at least one set of startup measurement information, that is, the management platform determines the first startup scheme according to the startup demand and the startup performance of the at least one startup scheme. Since the management platform in the intensive cloud computing system determines the first startup scheme according to the startup demand of the first application and the startup performance of at least one startup scheme corresponding to the target application, and starts the virtual unit of the first application in the first computing pool in the intensive cloud computing system according to the first startup scheme, the virtual unit startup scheme provided in the embodiment of the present application has good performance in the intensive cloud computing system, can achieve extremely fast startup of the first application, and can make full use of low-cost resources to reduce the operating cost of the intensive cloud computing system. Wherein, the virtual unit is a container, a virtual machine (VM) or other unit for resource isolation, and all "virtual units" in this article can be replaced by "containers" or "virtual machines".
下面介绍本申请实施例的技术方案,首先介绍本申请实施例的应用场景。The technical solution of the embodiment of the present application is introduced below, and the application scenario of the embodiment of the present application is first introduced.
本申请实施例的应用场景提供一种集约化云计算***,该集约化云计算***包括多个集约化资源池,该多个集约化资源池互联,例如该多个集约化资源池通过高速网络互联,该多个集约化资源池可以通过应用程序接口(application program interface,API)通信,该多个集约化资源池中的每个集约化资源池中主要包括一类资源。示例的,该多个集约化资源池包括至少一个计算池和至少一个存储池,该至少一个存储池包括内存池和/或外存池,计算池中主要包括计算资源,内存池中主要包括内存资源,外存池中主要包括外存资源。计算池中还包括少量的内存资源和/或外存资源,内存池中还包括少量的计算资源和/或外存资源,外存池中还包括少量的计算资源和/或内存资源。其中,集约化云计算***也称为分离式数据中心,计算池也称为计算资源池,内存池也称为内存资源池或内部存储资源池,外存池也称为外存资源池或外部存储资源池。外存资源通常为磁盘资源,从而外存池也称为磁盘池、磁盘资源池等。示例的,计算池是以计算资源为主的主机或服务器,内存池是以内存资源为主的主机或服务器,外存池是以外存资源为主的主机或服务器,本申请实施例对此不做限定。The application scenario of the embodiment of the present application provides an intensive cloud computing system, which includes multiple intensive resource pools, and the multiple intensive resource pools are interconnected, for example, the multiple intensive resource pools are interconnected through a high-speed network, and the multiple intensive resource pools can communicate through an application program interface (API), and each of the multiple intensive resource pools mainly includes a type of resource. For example, the multiple intensive resource pools include at least one computing pool and at least one storage pool, and the at least one storage pool includes a memory pool and/or an external memory pool. The computing pool mainly includes computing resources, the memory pool mainly includes memory resources, and the external memory pool mainly includes external memory resources. The computing pool also includes a small amount of memory resources and/or external memory resources, the memory pool also includes a small amount of computing resources and/or external memory resources, and the external memory pool also includes a small amount of computing resources and/or memory resources. Among them, the intensive cloud computing system is also called a separated data center, the computing pool is also called a computing resource pool, the memory pool is also called a memory resource pool or an internal storage resource pool, and the external memory pool is also called an external memory resource pool or an external storage resource pool. External memory resources are usually disk resources, so the external memory pool is also called a disk pool, a disk resource pool, etc. For example, a computing pool is a host or server mainly based on computing resources, a memory pool is a host or server mainly based on memory resources, and an external memory pool is a host or server mainly based on external memory resources, which is not limited in the embodiments of the present application.
可选的实施例中,该至少一个存储池包括内存池和外存池。该内存池可以是异构内存池,该内存池中包括至少两个第一存储介质,该至少两个第一存储介质都是提供内存资源的存储介质,该至少两个第一存储介质的类型不同,例如该至少两个第一存储介质包括动态随机存取内存(dynamic random access memory,DRAM)和存储级内存(storage class memory,SCM)。该外存池可以是异构外存池,该外存池中包括至少两个第二存储介质,该至少两个第二存储介质都是提供外存资源的存储介质,该至少两个第二存储介质的类型不同,例如该至少两个第二存储介质包括固态硬盘(solid state drives,SSD)和硬盘驱动器(hard disk drive,HDD)。由于不同类型的存储介质的性能(例如速度)、成本等不同,因此,以上至少两个第一存储介质的性能、成本等不同,以上至少两个第二存储介质的性能、成本等不同。可选的,该内存池和该外存池均支持基于差分算法存储数据。差分算法指的是存储数据块之间的差异(difference,diff),例如,对于任一数据块,存储该任一数据块与参考数据块的差异。示例的,同一个存储介质中基于差分算法存储数据,例如,每个存储介质对应一个参考数据块,对于将要在任一存储介质中存储的任一数据块,在该任一存储介质中存储该任一数据块与该存储介质对应的参考数据块之间的差异。本申请实施例中,内存池和该外存池均基于差分算法存储数据,可以节省存储资源,降低存储成本。In an optional embodiment, the at least one storage pool includes a memory pool and an external memory pool. The memory pool may be a heterogeneous memory pool, which includes at least two first storage media, which are storage media that provide memory resources, and the types of the at least two first storage media are different, for example, the at least two first storage media include dynamic random access memory (DRAM) and storage class memory (SCM). The external memory pool may be a heterogeneous external memory pool, which includes at least two second storage media, which are storage media that provide external memory resources, and the types of the at least two second storage media are different, for example, the at least two second storage media include solid state drives (SSD) and hard disk drives (HDD). Since different types of storage media have different performance (such as speed), cost, etc., the performance, cost, etc. of the above at least two first storage media are different, and the performance, cost, etc. of the above at least two second storage media are different. Optionally, both the memory pool and the external memory pool support data storage based on a differential algorithm. The differential algorithm refers to storing the difference (difference, diff) between data blocks. For example, for any data block, the difference between the any data block and the reference data block is stored. For example, data is stored based on a differential algorithm in the same storage medium. For example, each storage medium corresponds to a reference data block, and for any data block to be stored in any storage medium, the difference between the any data block and the reference data block corresponding to the storage medium is stored in the any storage medium. In an embodiment of the present application, both the memory pool and the external memory pool store data based on a differential algorithm, which can save storage resources and reduce storage costs.
在本申请实施例中,可以在集约化云计算***中创建虚拟单元(例如针对应用创建虚拟单元),并在虚拟单元中部署应用,以基于虚拟单元实现不同应用的资源隔离。其中,虚拟单元是可以独立运行的计算单元,虚拟单元具有自己的计算资源、内存资源和文件***。虚拟单元的计算资源是计算池中的计算资源,一个虚拟单元占用一个计算池中的部分计算资源;虚拟单元的内存资源是内存池中的内存资源,一个虚拟单元占用一个内存池中的部分内存资源;虚拟单元的文件***可以位于外存池中,一个虚拟单元的文件***占用一个外存池中的部分外存资源。也即,虚拟单元是个逻辑概念,一个虚拟单元的不同资源分布在互 联的多个集约化资源池中。其中,一个应用的多个虚拟单元可以共用内存池中的相同内存资源和/或外存池中的相同外存资源。例如,内存池中存储有某一应用的基准虚拟单元(例如已创建的某一虚拟单元)的内存的快照,该应用的所有虚拟单元可以共用该基准虚拟单元的内存的快照。可选的,该集约化云计算***中还包括管理平台,该管理平台位于计算池或独立设置,该管理平台用于管理虚拟单元,由该管理平台在该集约化云计算***中创建虚拟单元、在虚拟单元中部署应用,以及启动虚拟单元等。该管理平台也称为虚拟单元管理平台。其中,虚拟单元是容器、虚拟机或其他用于资源隔离的单元。例如,虚拟单元是容器,该管理平台对应的称为容器管理平台。再例如,虚拟单元是虚拟机,该管理平台对应的称为虚拟机管理平台。In an embodiment of the present application, a virtual unit can be created in an intensive cloud computing system (for example, a virtual unit can be created for an application), and the application can be deployed in the virtual unit to implement resource isolation of different applications based on the virtual unit. Among them, the virtual unit is a computing unit that can run independently, and the virtual unit has its own computing resources, memory resources, and file system. The computing resources of the virtual unit are the computing resources in the computing pool, and a virtual unit occupies part of the computing resources in a computing pool; the memory resources of the virtual unit are the memory resources in the memory pool, and a virtual unit occupies part of the memory resources in a memory pool; the file system of the virtual unit can be located in an external memory pool, and the file system of a virtual unit occupies part of the external memory resources in an external memory pool. In other words, the virtual unit is a logical concept, and the different resources of a virtual unit are distributed on the same network. In multiple intensive resource pools connected. Among them, multiple virtual units of an application can share the same memory resources in the memory pool and/or the same external memory resources in the external memory pool. For example, a snapshot of the memory of a baseline virtual unit of an application (for example, a virtual unit that has been created) is stored in the memory pool, and all virtual units of the application can share the snapshot of the memory of the baseline virtual unit. Optionally, the intensive cloud computing system also includes a management platform, which is located in the computing pool or independently set up. The management platform is used to manage virtual units. The management platform creates virtual units in the intensive cloud computing system, deploys applications in virtual units, and starts virtual units. The management platform is also called a virtual unit management platform. Among them, the virtual unit is a container, a virtual machine, or other unit for resource isolation. For example, the virtual unit is a container, and the corresponding management platform is called a container management platform. For another example, the virtual unit is a virtual machine, and the corresponding management platform is called a virtual machine management platform.
在本申请实施例中,存储池可以用于存储创建应用的虚拟单元所需的各种信息,这些信息包括但不限于该应用的基准虚拟单元的内存的快照、该应用的基准虚拟单元的快照、该应用的应用镜像等。一个实施例中,根据应用的重要性、使用频率、启动诉求(例如启动时长、启动成本等)等指标确定该应用对应的存储策略(例如确定将该应用对应的这些信息存储在内存池中还是存储在外存池中,以及具体存储在内存池的哪个存储介质中或具体存储在内存池的哪个存储介质中),并根据该应用对应的存储策略在存储池中存储该应用对应的信息。另一个实施例中,根据预设存储策略或该集约化云计算***的规定的存储策略在存储池中存储应用对应的信息。可选的,同一个应用对应的不同信息存储在同一存储池或不同存储池中,同一个应用对应的不同信息存储在同一存储介质或不同存储介质中。其中,应用镜像是一种文件存储形式,是一个应用轻量级且独立可执行的软件包,任一应用的应用镜像包含运行该应用所需的所有内容,例如,任一应用的应用镜像包含启动该应用的虚拟单元所需的所有内容,这些内容包含代码、***工具、库、环境变量和配置文件等。In an embodiment of the present application, a storage pool can be used to store various information required to create a virtual unit of an application, including but not limited to a snapshot of the memory of the base virtual unit of the application, a snapshot of the base virtual unit of the application, an application image of the application, etc. In one embodiment, the storage strategy corresponding to the application is determined according to indicators such as the importance, frequency of use, and startup requirements (such as startup time, startup cost, etc.) of the application (for example, determining whether to store the information corresponding to the application in the memory pool or in the external memory pool, and which storage medium of the memory pool is specifically stored or which storage medium of the memory pool is specifically stored), and the information corresponding to the application is stored in the storage pool according to the storage strategy corresponding to the application. In another embodiment, the information corresponding to the application is stored in the storage pool according to a preset storage strategy or a storage strategy specified by the intensive cloud computing system. Optionally, different information corresponding to the same application is stored in the same storage pool or different storage pools, and different information corresponding to the same application is stored in the same storage medium or different storage media. Among them, an application image is a form of file storage, which is a lightweight and independently executable software package of an application. The application image of any application contains all the content required to run the application. For example, the application image of any application contains all the content required to start the virtual unit of the application, which includes code, system tools, libraries, environment variables, and configuration files.
可选的实施例中,存储池用于存储特定应用镜像,特定应用镜像满足以下至少一种:最常使用的应用镜像(例如使用频率大于预设频率的应用镜像)、最近使用的应用镜像(例如最近一次使用该应用镜像的时刻与当前时刻之间的时间差小于预设时间差)、重要客户的应用镜像。示例的,特定应用镜像的存储指标满足预设存储指标,任一应用镜像的存储指标根据该应用镜像的使用频率、该应用镜像的最近使用时间以及该应用镜像对应的客户重要等级加权计算获得。在本申请实施例中,由于存储池包括内存池和/或外存池,且内存池和/或外存池中包括至少两个存储介质,因此,不同应用的应用镜像可以存储在同一存储介质或不同存储介质中,从而,本申请实施例可以将应用镜像分布式存储在存储池中。In an optional embodiment, the storage pool is used to store specific application images, and the specific application images meet at least one of the following: the most frequently used application image (for example, an application image with a usage frequency greater than a preset frequency), the most recently used application image (for example, the time difference between the moment when the application image was last used and the current moment is less than a preset time difference), and the application image of an important customer. For example, the storage index of a specific application image meets the preset storage index, and the storage index of any application image is obtained by weighted calculation based on the usage frequency of the application image, the most recent usage time of the application image, and the customer importance level corresponding to the application image. In an embodiment of the present application, since the storage pool includes a memory pool and/or an external memory pool, and the memory pool and/or the external memory pool include at least two storage media, application images of different applications can be stored in the same storage medium or different storage media, and thus, the embodiment of the present application can store application images in a distributed manner in the storage pool.
可选的实施例中,集约化云计算***中还包括镜像仓库,该镜像仓库可以是分布式镜像仓库,该镜像仓库用于存储应用镜像的指示信息与该应用镜像在存储池中的存储位置(简称为应用镜像的存储位置)的对应关系,例如该对应关系称为第一对应关系。管理平台创建某一应用的虚拟单元时,该管理平台根据该应用的应用镜像的指示信息和该镜像仓库中存储的第一对应关系确定该应用镜像的存储位置,该管理平台根据该应用镜像的存储位置从该存储池中获取该应用镜像,并基于该应用镜像创建虚拟单元。示例的,该管理平台向该镜像仓库发送镜像获取请求,该镜像获取请求携带该应用的应用镜像的指示信息,该镜像仓库根据该镜像获取请求携带的应用镜像的指示信息和第一对应关系确定该应用镜像的存储位置,并向该管理平台发送该应用镜像的存储位置,该管理平台根据该应用镜像的存储位置从存储池中获取该应用镜像。其中,该镜像仓库可以部署在计算池或存储池中,可以独立于计算池和存储池部署,例如该镜像仓库部署在一***立的服务器中。应用镜像的指示信息可以是应用镜像的标识等,例如将某一应用的标识作为该应用的应用镜像的标识。In an optional embodiment, the intensive cloud computing system also includes an image warehouse, which can be a distributed image warehouse, and the image warehouse is used to store the corresponding relationship between the indication information of the application image and the storage location of the application image in the storage pool (hereinafter referred to as the storage location of the application image), for example, the corresponding relationship is called the first corresponding relationship. When the management platform creates a virtual unit of a certain application, the management platform determines the storage location of the application image according to the indication information of the application image of the application and the first corresponding relationship stored in the image warehouse, and the management platform obtains the application image from the storage pool according to the storage location of the application image, and creates a virtual unit based on the application image. For example, the management platform sends an image acquisition request to the image warehouse, and the image acquisition request carries the indication information of the application image of the application. The image warehouse determines the storage location of the application image according to the indication information of the application image carried in the image acquisition request and the first corresponding relationship, and sends the storage location of the application image to the management platform, and the management platform obtains the application image from the storage pool according to the storage location of the application image. The image repository may be deployed in a computing pool or a storage pool, or may be deployed independently of the computing pool and the storage pool, for example, the image repository may be deployed in an independent server. The indication information of the application image may be an identification of the application image, for example, the identification of a certain application may be used as the identification of the application image of the application.
相关技术中的镜像仓库用于集中存储应用镜像(也即不同的应用镜像集中存储在镜像仓库),这种镜像仓库也称为集中式镜像仓库。在高并发创建虚拟单元的情况下,集中式镜像仓库存在带宽瓶颈,导致获取应用镜像的速度较慢,创建虚拟单元的时延较大。本申请实施例将应用镜像分布式存储在存储池中,并设置镜像仓库存储应用镜像的指示信息与应用镜像的存储位置的对应关系,管理平台创建某一应用的虚拟单元时,该管理平台根据该应用的应用镜像的指示信息从镜像仓库中获取该应用镜像的存储位置,进而根据该应用镜像的存储位置从分布式的存储池中获取该应用镜像,由此,可以提升获取应用镜像的速度,减小创建虚拟单元的时延,本申请实施例的应用镜像分布式存储方式能够很好的解决集中式镜像仓库在高并发创建虚拟单元的情况下获取应用镜像的速度慢,创建虚拟单元的时延大的问题。The image warehouse in the related art is used to centrally store application images (that is, different application images are centrally stored in the image warehouse). This image warehouse is also called a centralized image warehouse. In the case of high-concurrency creation of virtual units, there is a bandwidth bottleneck in the centralized image warehouse, resulting in a slow speed of obtaining application images and a large delay in creating virtual units. The embodiment of the present application stores application images in a distributed manner in a storage pool, and sets a correspondence between the indication information of the image warehouse storing application images and the storage location of the application images. When the management platform creates a virtual unit of a certain application, the management platform obtains the storage location of the application image from the image warehouse according to the indication information of the application image of the application, and then obtains the application image from the distributed storage pool according to the storage location of the application image. Thus, the speed of obtaining application images can be improved and the delay of creating virtual units can be reduced. The distributed storage method of application images in the embodiment of the present application can well solve the problem that the centralized image warehouse has a slow speed of obtaining application images and a large delay in creating virtual units when creating virtual units with high concurrency.
以集约化云计算***包括两个计算池、一个内存池和一个外存池为例说明。作为一个示例,图1是本申请实施例提供的一种集约化云计算***100的示意图。集约化云计算***100包括第一计算池101、第 二计算池102和第一存储池103,第一存储池103包括内存池31和外存池32,第一计算池101、第二计算池102和第一存储池103通过高速网络互联。第一计算池101和第二计算池102都是以计算资源为主的集约化资源池,内存池31是以内存资源为主的集约化资源池,外存池32是以外存资源为主的集约化资源池。示例的,第一计算池101和第二计算池102都是以计算资源为主的主机或服务器,内存池31是以内存资源为主的主机或服务器,外存池32是以外存资源为主的主机或服务器。如图1所示,内存池31中包括m个第一存储介质311~31m,第一存储介质311~31m的类型不同,第一存储介质可以基于差分算法存储至少一个应用对应的快照、应用镜像等信息。外存池32中包括n个第二存储介质321~32n,第二存储介质321~32n的类型不同,第二存储介质可以基于差分算法存储至少一个应用对应的快照、应用镜像等信息。第一计算池101中包括管理平台11,由管理平台11在集约化云计算***100中创建虚拟单元、在虚拟单元中部署应用、启动虚拟单元等。示例的,管理平台11在第一计算池101中创建第一应用的虚拟单元,该虚拟单元的计算资源是第一计算池101中的计算资源,该虚拟单元的内存资源包括内存池31中的内存资源,该虚拟单元的文件***部分位于外存池32中。由于管理平台11在第一计算池101中,从管理平台11的角度来讲,第一计算池101称为本地计算池、第二计算池102称为远端计算池,内存池31称为远端内存池,外存池32称为远端外存池。示例的,第一计算池101和第二计算池102都是以计算资源为主的主机,第一计算池101称为本地主机,第二计算池102称为远端主机。Take the example of an intensive cloud computing system including two computing pools, a memory pool and an external memory pool. As an example, FIG1 is a schematic diagram of an intensive cloud computing system 100 provided in an embodiment of the present application. The intensive cloud computing system 100 includes a first computing pool 101, a second computing pool 102 and a third computing pool 104. The second computing pool 102 and the first storage pool 103, the first storage pool 103 includes a memory pool 31 and an external memory pool 32, and the first computing pool 101, the second computing pool 102 and the first storage pool 103 are interconnected through a high-speed network. The first computing pool 101 and the second computing pool 102 are both intensive resource pools based on computing resources, the memory pool 31 is an intensive resource pool based on memory resources, and the external memory pool 32 is an intensive resource pool based on external memory resources. For example, the first computing pool 101 and the second computing pool 102 are both hosts or servers based on computing resources, the memory pool 31 is a host or server based on memory resources, and the external memory pool 32 is a host or server based on external memory resources. As shown in FIG. 1, the memory pool 31 includes m first storage media 311-31m, and the types of the first storage media 311-31m are different. The first storage medium can store snapshots, application images and other information corresponding to at least one application based on a differential algorithm. The external memory pool 32 includes n second storage media 321-32n, and the types of the second storage media 321-32n are different. The second storage media can store snapshots, application images and other information corresponding to at least one application based on a differential algorithm. The first computing pool 101 includes a management platform 11, and the management platform 11 creates a virtual unit in the intensive cloud computing system 100, deploys applications in the virtual unit, starts the virtual unit, etc. For example, the management platform 11 creates a virtual unit of the first application in the first computing pool 101, the computing resources of the virtual unit are the computing resources in the first computing pool 101, the memory resources of the virtual unit include the memory resources in the memory pool 31, and the file system part of the virtual unit is located in the external memory pool 32. Since the management platform 11 is in the first computing pool 101, from the perspective of the management platform 11, the first computing pool 101 is called a local computing pool, the second computing pool 102 is called a remote computing pool, the memory pool 31 is called a remote memory pool, and the external memory pool 32 is called a remote external memory pool. For example, the first computing pool 101 and the second computing pool 102 are hosts that mainly use computing resources. The first computing pool 101 is called a local host, and the second computing pool 102 is called a remote host.
作为另一个示例,图2是本申请实施例提供的另一种集约化云计算***100的示意图。如图2所示,在图1的基础上,集约化云计算***100还包括镜像仓库104。镜像仓库104可以部署在第一计算池101、第二计算池102或第一存储池103中,也可以独立于第一计算池101、第二计算池102和第一存储池103部署,图2以镜像仓库104独立于第一计算池101、第二计算池102和第一存储池103部署为例说明。第一存储池103用于存储创建应用的虚拟单元所需的各种信息,这些信息可以分布在不同存储介质中。可选的,第一存储池103用于存储应用镜像,镜像仓库104是分布式镜像仓库,镜像仓库104用于存储应用镜像的指示信息与该应用镜像在第一存储池103中的存储位置的对应关系(例如称为第一对应关系)。管理平台11创建某一应用的虚拟单元时,管理平台11根据该应用的应用镜像的指示信息和镜像仓库104中存储的第一对应关系确定该应用镜像的存储位置,管理平台11根据该应用镜像的存储位置从第一存储池103中获取该应用镜像,并基于该应用镜像创建虚拟单元。As another example, FIG2 is a schematic diagram of another intensive cloud computing system 100 provided in an embodiment of the present application. As shown in FIG2, on the basis of FIG1, the intensive cloud computing system 100 also includes an image warehouse 104. The image warehouse 104 can be deployed in the first computing pool 101, the second computing pool 102 or the first storage pool 103, or it can be deployed independently of the first computing pool 101, the second computing pool 102 and the first storage pool 103. FIG2 takes the deployment of the image warehouse 104 independently of the first computing pool 101, the second computing pool 102 and the first storage pool 103 as an example. The first storage pool 103 is used to store various information required to create a virtual unit of an application, and this information can be distributed in different storage media. Optionally, the first storage pool 103 is used to store application images, and the image warehouse 104 is a distributed image warehouse. The image warehouse 104 is used to store the indication information of the application image and the corresponding relationship (for example, referred to as the first corresponding relationship) of the storage location of the application image in the first storage pool 103. When the management platform 11 creates a virtual unit of an application, the management platform 11 determines the storage location of the application image based on the indication information of the application image of the application and the first correspondence stored in the image repository 104. The management platform 11 obtains the application image from the first storage pool 103 based on the storage location of the application image, and creates a virtual unit based on the application image.
图1和图2所示的集约化云计算***仅用于举例,并非用于限制本申请实施例的技术方案。在实现过程中,可以根据需要配置集约化云计算***中的计算池和存储池的数量,以及,根据需要配置存储池中的存储介质的数量和类型,本申请实施例对此不做限定。The intensive cloud computing system shown in Figures 1 and 2 is only used as an example and is not used to limit the technical solution of the embodiment of the present application. In the implementation process, the number of computing pools and storage pools in the intensive cloud computing system can be configured as needed, and the number and type of storage media in the storage pool can be configured as needed, which is not limited in the embodiment of the present application.
以上是对本申请应用场景的介绍,下面介绍本申请的虚拟单元启动方法的实施例。The above is an introduction to the application scenarios of the present application. The following is an introduction to an embodiment of the virtual unit startup method of the present application.
本申请实施例提供的虚拟单元启动方法应用于集约化云计算***中的管理平台,该虚拟单元启动方法由该管理平台执行。该集约化云计算***还包括第一计算池,该管理平台可以部署在第一计算池中。可选的,该集约化云计算***还包括第一存储池和第二计算池,第一存储池包括内存池和外存池中的至少一个,该内存池和该外存池均可以是异构存储池。第一计算池、第二计算池和第一存储池互联,第一存储池用于存储第一应用的虚拟单元的内存的快照、第一应用的虚拟单元的快照、第一应用的应用镜像,并且第一应用的这些信息在第一存储池中的存储位置根据第一应用的重要性、使用频率、启动诉求等确定。该集约化云计算***还可以包括镜像仓库,该镜像仓库用于存储应用镜像的指示信息与该应用镜像在第一存储池中的存储位置的对应关系。示例的,该集约化云计算***如图1或图2所示,该虚拟单元启动方法由管理平台11执行。如图3所示,该方法包括如下步骤S301至S304。The virtual unit startup method provided in the embodiment of the present application is applied to the management platform in the intensive cloud computing system, and the virtual unit startup method is executed by the management platform. The intensive cloud computing system also includes a first computing pool, and the management platform can be deployed in the first computing pool. Optionally, the intensive cloud computing system also includes a first storage pool and a second computing pool, and the first storage pool includes at least one of a memory pool and an external memory pool, and the memory pool and the external memory pool can both be heterogeneous storage pools. The first computing pool, the second computing pool and the first storage pool are interconnected, and the first storage pool is used to store a snapshot of the memory of the virtual unit of the first application, a snapshot of the virtual unit of the first application, and an application image of the first application, and the storage location of these information of the first application in the first storage pool is determined according to the importance, frequency of use, startup requirements, etc. of the first application. The intensive cloud computing system may also include an image warehouse, which is used to store the corresponding relationship between the indication information of the application image and the storage location of the application image in the first storage pool. For example, the intensive cloud computing system is shown in Figure 1 or Figure 2, and the virtual unit startup method is executed by the management platform 11. As shown in Figure 3, the method includes the following steps S301 to S304.
S301.获取第一应用的启动诉求。S301. Obtain a startup request of a first application.
其中,第一应用是基于虚拟单元实现资源隔离的各种可能的应用,例如第一应用是serverless应用,且第一应用是视频类应用、音频类应用、邮件类应用、网页类应用或微博类应用等。虚拟单元可以是容器、虚拟机等基于虚拟化技术实现的计算单元。The first application is a variety of possible applications that implement resource isolation based on virtual units, for example, the first application is a serverless application, and the first application is a video application, an audio application, an email application, a web application, or a microblog application, etc. The virtual unit can be a computing unit implemented based on virtualization technology, such as a container or a virtual machine.
其中,第一应用的启动诉求包括启动时长诉求和启动成本诉求中的至少一个。该启动时长诉求可以是第一应用的启动时长(也即启动第一应用所需的时长)小于预设时长。该启动成本诉求可以是第一应用的启动成本(也即启动第一应用所需的成本)小于预设成本。第一应用的启动时长与第一应用的虚拟单元的启动时长相关,第一应用的启动成本与第一应用的虚拟单元的启动成本相关。一般情况下,一个应用的虚 拟单元启动意味着该应用启动,因此第一应用的启动时长一般就是第一应用的虚拟单元的启动时长,第一应用的启动成本一般就是第一应用的虚拟单元的启动成本。第一应用的虚拟单元的启动时长和启动成本均与第一应用的虚拟单元的启动方式,快照、应用镜像等相关信息的存储位置等有关。例如,某一存储介质A中存储有第一应用的基准单元快照C0(也即第一应用的基准虚拟单元的快照),若根据基准单元快照C0冷启动第一应用的一个虚拟单元(例如称为第一虚拟单元),第一虚拟单元的启动时长取决于创建第一虚拟单元的时长、从存储介质A中拉取基准单元快照C0的时长等,第一虚拟单元的启动成本取决于在该存储介质A中存储基准单元快照C0的成本。The startup demand of the first application includes at least one of a startup time demand and a startup cost demand. The startup time demand may be that the startup time of the first application (that is, the time required to start the first application) is less than a preset time. The startup cost demand may be that the startup cost of the first application (that is, the cost required to start the first application) is less than a preset cost. The startup time of the first application is related to the startup time of the virtual unit of the first application, and the startup cost of the first application is related to the startup cost of the virtual unit of the first application. In general, the virtual unit of an application The startup of the virtual unit means the startup of the application, so the startup time of the first application is generally the startup time of the virtual unit of the first application, and the startup cost of the first application is generally the startup cost of the virtual unit of the first application. The startup time and startup cost of the virtual unit of the first application are related to the startup method of the virtual unit of the first application, the storage location of snapshots, application images and other related information, etc. For example, a certain storage medium A stores the baseline unit snapshot C0 of the first application (that is, the snapshot of the baseline virtual unit of the first application). If a virtual unit of the first application (for example, called the first virtual unit) is cold-started according to the baseline unit snapshot C0, the startup time of the first virtual unit depends on the time to create the first virtual unit, the time to pull the baseline unit snapshot C0 from the storage medium A, etc., and the startup cost of the first virtual unit depends on the cost of storing the baseline unit snapshot C0 in the storage medium A.
在本申请实施例中,第一应用的启动诉求可以是管理用户(例如第一应用的开发用户、集约化云计算***的管理用户)向管理平台输入的,也可以是该管理平台根据第一应用的属性信息确定的。一个实施例中,该管理平台提供有用户界面,管理用户通过该用户界面与该管理平台交互,该管理用户通过该用户界面向该管理平台输入启动诉求信息,该管理平台获取该管理用户输入的该启动诉求信息,该启动诉求信息包括第一应用的启动诉求,其中,该用户界面可以是用户接口(user interface,UI)界面。另一个实施例中,管理平台获取第一应用的重要性、使用频率、类型等属性信息,管理平台根据第一应用的属性信息确定第一应用的启动诉求。例如,重要性较高的应用、使用频率较高的应用等的启动时长需要较短。In an embodiment of the present application, the startup demand of the first application may be input to the management platform by a management user (e.g., a developer user of the first application, a management user of an intensive cloud computing system), or may be determined by the management platform based on the attribute information of the first application. In one embodiment, the management platform is provided with a user interface, through which the management user interacts with the management platform, the management user inputs startup demand information to the management platform through the user interface, and the management platform obtains the startup demand information input by the management user, the startup demand information includes the startup demand of the first application, wherein the user interface may be a user interface (UI) interface. In another embodiment, the management platform obtains attribute information such as the importance, frequency of use, and type of the first application, and the management platform determines the startup demand of the first application based on the attribute information of the first application. For example, the startup time of applications with higher importance and applications with higher frequency of use needs to be shorter.
S302.获取目标应用对应的至少一组启动测量信息,该至少一组启动测量信息对应至少一个启动方案,该至少一组启动测量信息中的每组启动测量信息用于表征基于对应的启动方案在集约化云计算***中启动目标应用的启动性能,目标应用与第一应用匹配。S302. Obtain at least one set of startup measurement information corresponding to the target application, the at least one set of startup measurement information corresponding to at least one startup scheme, each set of startup measurement information in the at least one set of startup measurement information is used to characterize the startup performance of starting the target application in the intensive cloud computing system based on the corresponding startup scheme, and the target application matches the first application.
管理平台可以获取目标应用对应的至少一组启动测量信息,该至少一组启动测量信息一一对应至少一个启动方案,每组启动测量信息是根据对应的启动方案在集约化云计算***(例如图1或图2所示的集约化云计算***100)中对目标应用进行启动测试获得的,每组启动测量信息用于表征基于对应的启动方案在集约化云计算***中启动目标应用的启动性能,每组启动测量信息包括测量启动时长和测量启动成本中的至少一个。The management platform can obtain at least one set of startup measurement information corresponding to the target application, and the at least one set of startup measurement information corresponds to at least one startup scheme. Each set of startup measurement information is obtained by performing a startup test on the target application in an intensive cloud computing system (for example, the intensive cloud computing system 100 shown in Figure 1 or Figure 2) according to the corresponding startup scheme. Each set of startup measurement information is used to characterize the startup performance of starting the target application in the intensive cloud computing system based on the corresponding startup scheme. Each set of startup measurement information includes at least one of measuring startup duration and measuring startup cost.
其中,该至少一个启动方案是预先制定的,例如是管理平台预先制定的或者是人工制定好并输入管理平台的,该管理平台可以提供有用户界面,用户可以通过该用户界面向该管理平台输入启动方案。该至少一个启动方案中的每个启动方案包括启动方式和存储策略,该启动方式可以是热启动或冷启动,该存储策略用于存储启动虚拟单元所需的快照、文件***、应用镜像等,例如,存储策略包括将快照、文件***、应用镜像等中的每个信息存储在哪些存储介质中(例如将快照存储在内存池中的哪个存储介质中,将应用镜像存储在外存池中的哪个存储介质中等),任意的启动方式和任意的存储策略的组合都可以构成一个启动方案。可选的,该至少一个启动方案包括以下至少一个:基于第一存储池的热启动方案、基于第一存储池的冷启动方案、基于第二计算池的冷启动方案。第一计算池、第二计算池和第一存储池互联,第一存储池包括内存池和外存池中的至少一种。目标应用的测量启动时长和测量启动成本均与目标应用的启动方式、目标应用相关的快照、应用镜像等信息所在的存储介质、目标应用相关的这些信息在第一存储池中的存储位置等相关。示例的,基于第一存储池的热启动方案是基于第一存储池中存储的内存快照(例如虚拟单元的内存的快照)的启动方案,且根据内存快照所在的存储介质的不同,热启动方案的启动时长和启动成本等不同;基于第一存储池的冷启动方案是基于第一存储池中存储的虚拟单元快照(也即虚拟单元的快照)的启动方案,且根据虚拟单元快照所在的存储介质的不同,冷启动方案的启动时长和启动成本等不同;基于第二计算池的冷启动方案是基于第二计算池中运行的虚拟单元的启动方案。Among them, the at least one startup scheme is pre-formulated, for example, it is pre-formulated by the management platform or manually formulated and input into the management platform. The management platform can provide a user interface, and the user can input the startup scheme into the management platform through the user interface. Each startup scheme in the at least one startup scheme includes a startup mode and a storage strategy. The startup mode can be a hot start or a cold start. The storage strategy is used to store snapshots, file systems, application images, etc. required to start the virtual unit. For example, the storage strategy includes which storage media each information in the snapshot, file system, application image, etc. is stored in (for example, which storage medium in the memory pool is the snapshot stored in, which storage medium in the external memory pool is the application image stored in, etc.), and any combination of startup mode and any storage strategy can constitute a startup scheme. Optionally, the at least one startup scheme includes at least one of the following: a hot start scheme based on the first storage pool, a cold start scheme based on the first storage pool, and a cold start scheme based on the second computing pool. The first computing pool, the second computing pool and the first storage pool are interconnected, and the first storage pool includes at least one of a memory pool and an external memory pool. The measured startup time and the measured startup cost of the target application are related to the startup method of the target application, the storage medium where the snapshots and application images related to the target application are located, the storage location of the information related to the target application in the first storage pool, etc. For example, the hot startup solution based on the first storage pool is a startup solution based on the memory snapshot stored in the first storage pool (for example, the snapshot of the memory of the virtual unit), and the startup time and startup cost of the hot startup solution vary depending on the storage medium where the memory snapshot is located; the cold startup solution based on the first storage pool is a startup solution based on the virtual unit snapshot stored in the first storage pool (that is, the snapshot of the virtual unit), and the startup time and startup cost of the cold startup solution vary depending on the storage medium where the virtual unit snapshot is located; the cold startup solution based on the second computing pool is a startup solution based on the virtual unit running in the second computing pool.
可选的实施例中,管理平台根据该至少一个启动方案中的每个启动方案在集约化云计算***中对目标应用进行启动测试,得到该每个启动方案对应的一组启动测量信息,从而得到该至少一个启动方案一一对应的至少一组启动测量信息。具体的实施例中,对于该至少一个启动方案中的每个启动方案:该管理平台根据该每个启动方案在集约化云计算***中对目标应用进行启动测试,在启动测试过程中,该管理平台统计目标应用的启动时长和启动成本,得到该每个启动方案对应的测量启动时长和测量启动成本,也即得到该每个启动方案对应的一组启动测量信息。以在图1或图2所示的集约化云计算***100中对目标应用进行启动测试为例说明。示例的,管理平台11预先制定k个启动方案1~k,k为正整数。启动方案1可以是:基于第一存储介质311中存储的内存快照和第二存储介质321中存储的文件***的热启动方案。启动方案2可以是:基于第一存储介质312中存储的内存快照和第二存储介质321中存储的文件***的热启动方案。启动方案3可以是:基于第一存储介质313中存储的内存快照和第二存储介质322中存储的文件***的热 启动方案。启动方案4可以是:基于第二存储介质321中存储的文件***的虚拟单元快照的冷启动方案。启动方案5可以是基于第二计算池102中运行的虚拟单元的冷启动方案。依次类推,任意的启动方式和任意的存储策略的组合都可以构成一个启动方案。示例的,管理平台11根据启动方案1在集约化云计算***100中对目标应用进行启动测试,得到启动方案1对应的一组启动测量信息1。管理平台11根据启动方案2在集约化云计算***100中对目标应用进行启动测试,得到启动方案2对应的一组启动测量信息2。依次类推,管理平台11根据启动方案k在集约化云计算***100中对目标应用进行启动测试,得到启动方案k对应的一组启动测量信息k。管理平台11通过对目标应用进行启动测试得到启动方案1~k一一对应的启动测量信息1~k。启动测量信息1~k中的每组启动测量信息包括括测量启动时长和测量启动成本中的至少一个。In an optional embodiment, the management platform performs a startup test on the target application in the intensive cloud computing system according to each startup scheme in the at least one startup scheme, and obtains a set of startup measurement information corresponding to each startup scheme, thereby obtaining at least one set of startup measurement information corresponding to the at least one startup scheme. In a specific embodiment, for each startup scheme in the at least one startup scheme: the management platform performs a startup test on the target application in the intensive cloud computing system according to each startup scheme. During the startup test, the management platform counts the startup time and startup cost of the target application, obtains the measured startup time and measured startup cost corresponding to each startup scheme, that is, obtains a set of startup measurement information corresponding to each startup scheme. Take the startup test of the target application in the intensive cloud computing system 100 shown in Figure 1 or Figure 2 as an example. For example, the management platform 11 pre-formulates k startup schemes 1~k, where k is a positive integer. Startup scheme 1 can be: a hot startup scheme based on the memory snapshot stored in the first storage medium 311 and the file system stored in the second storage medium 321. Startup solution 2 may be a hot start solution based on the memory snapshot stored in the first storage medium 312 and the file system stored in the second storage medium 321. Startup solution 3 may be a hot start solution based on the memory snapshot stored in the first storage medium 313 and the file system stored in the second storage medium 322. Startup scheme. Startup scheme 4 may be: a cold start scheme based on a virtual unit snapshot of the file system stored in the second storage medium 321. Startup scheme 5 may be a cold start scheme based on a virtual unit running in the second computing pool 102. By analogy, any combination of startup methods and any storage policies may constitute a startup scheme. For example, the management platform 11 performs a startup test on the target application in the intensive cloud computing system 100 according to startup scheme 1, and obtains a set of startup measurement information 1 corresponding to startup scheme 1. The management platform 11 performs a startup test on the target application in the intensive cloud computing system 100 according to startup scheme 2, and obtains a set of startup measurement information 2 corresponding to startup scheme 2. By analogy, the management platform 11 performs a startup test on the target application in the intensive cloud computing system 100 according to startup scheme k, and obtains a set of startup measurement information k corresponding to startup scheme k. The management platform 11 obtains startup measurement information 1 to k corresponding to startup schemes 1 to k by performing startup tests on the target application. Each set of startup measurement information in the startup measurement information 1 to k includes at least one of measuring startup duration and measuring startup cost.
在本申请实施例中,目标应用与第一应用匹配包括以下至少一项:目标应用是第一应用、目标应用的规模与第一应用的规模匹配、目标应用的应用镜像的大小与第一应用的应用镜像的大小匹配、目标应用的类型与第一应用的类型匹配。示例的,目标应用的规模与第一应用的规模匹配包括:目标应用的子功能的规模与第一应用的子功能的规模相当(例如目标应用的子功能的数量与第一应用的子功能的数量的差值小于预设数量),目标应用的架构与第一应用的架构相当。任一应用的架构例如:该任一应用包括哪些主功能(或称为一级功能),每个主功能下包括哪些二级功能,每个二级功能下包括哪些三级功能,依次类推。目标应用的应用镜像的大小与第一应用的应用镜像的大小匹配包括:目标应用的应用镜像的大小与第一应用的应用镜像的大小的差值小于预设差值。目标应用的类型与第一应用的类型匹配包括:目标应用的类型与第一应用的类型相同,例如目标应用和第一应用都是视频类应用。一个实施例中,第一应用允许试运行,管理平台将第一应用作为目标应用(目标应用是第一应用),管理平台根据至少一个启动方案中的每个启动方案在集约化云计算***中对第一应用进行启动测试,得到该每个启动方案对应的一组启动测量信息。另一个实施例中,第一应用不允许试运行,管理平台根据第一应用的规模、第一应用的应用镜像的大小、第一应用的类型等,确定与第一应用匹配的目标应用,管理平台根据至少一个启动方案中的每个启动方案在集约化云计算***中对目标应用进行启动测试,得到该每个启动方案对应的一组启动测量信息。In an embodiment of the present application, the target application matches the first application, including at least one of the following: the target application is the first application, the scale of the target application matches the scale of the first application, the size of the application image of the target application matches the size of the application image of the first application, and the type of the target application matches the type of the first application. For example, the scale of the target application matches the scale of the first application, including: the scale of the sub-function of the target application is comparable to the scale of the sub-function of the first application (for example, the difference between the number of sub-functions of the target application and the number of sub-functions of the first application is less than a preset number), and the architecture of the target application is comparable to the architecture of the first application. The architecture of any application is, for example, which main functions (or first-level functions) the application includes, which second-level functions each main function includes, which third-level functions each second-level function includes, and so on. The size of the application image of the target application matches the size of the application image of the first application, including: the difference between the size of the application image of the target application and the size of the application image of the first application is less than a preset difference. The type of the target application matches the type of the first application, including: the type of the target application is the same as the type of the first application, for example, the target application and the first application are both video applications. In one embodiment, the first application is allowed to be run on a trial basis, and the management platform uses the first application as a target application (the target application is the first application). The management platform performs a startup test on the first application in the intensive cloud computing system according to each startup scheme in at least one startup scheme, and obtains a set of startup measurement information corresponding to each startup scheme. In another embodiment, the first application is not allowed to be run on a trial basis, and the management platform determines a target application that matches the first application according to the scale of the first application, the size of the application image of the first application, the type of the first application, etc. The management platform performs a startup test on the target application in the intensive cloud computing system according to each startup scheme in at least one startup scheme, and obtains a set of startup measurement information corresponding to each startup scheme.
S303.根据第一应用的启动诉求和该至少一组启动测量信息确定第一启动方案,该至少一个启动方案包括第一启动方案。S303: Determine a first startup solution according to the startup requirement of the first application and the at least one set of startup measurement information, where the at least one startup solution includes the first startup solution.
其中,第一启动方案是该至少一个启动方案中,启动性能与第一应用的启动诉求匹配的一个启动方案,第一启动方案的启动性能满足第一应用的启动诉求。示例的,第一应用的启动诉求包括启动时长诉求和启动成本诉求中的至少一个,该启动时长诉求是第一应用的启动时长小于预设时长,该启动成本诉求是第一应用的启动成本小于预设成本,对应的,第一启动方案的启动性能满足第一应用的启动诉求包括以下至少一项:第一启动方案对应的测量启动时长小于该预设时长,第一启动方案对应的测量启动成本小于该预设成本。Among them, the first startup scheme is a startup scheme in which the startup performance matches the startup demand of the first application among the at least one startup scheme, and the startup performance of the first startup scheme meets the startup demand of the first application. For example, the startup demand of the first application includes at least one of a startup duration demand and a startup cost demand, the startup duration demand is that the startup duration of the first application is less than a preset duration, and the startup cost demand is that the startup cost of the first application is less than a preset cost. Correspondingly, the startup performance of the first startup scheme meets the startup demand of the first application, including at least one of the following: the measured startup duration corresponding to the first startup scheme is less than the preset duration, and the measured startup cost corresponding to the first startup scheme is less than the preset cost.
可选的实施例中,该至少一组启动测量信息一一对应该至少一个启动方案,每组启动测量信息用于表征基于对应的启动方案在集约化云计算***中启动目标应用的启动性能,管理平台根据该至少一组启动测量信息,在该至少一个启动方案中确定启动性能满足第一应用的启动诉求的启动方案,管理平台在启动性能满足第一应用的启动诉求的启动方案中确定第一启动方案。一个实施例中,该至少一个启动方案中仅存在一个启动方案的启动性能满足第一应用的启动诉求,管理平台将该一个启动方案确定为第一启动方案。另一个实施例中,该至少一个启动方案中存在多个启动方案的启动性能均满足第一应用的启动诉求,管理平台将该多个启动方案中的一个启动方案确定为第一启动方案。例如,管理平台将该多个启动方案中的任一个启动方案确定为第一启动方案,或者,管理平台将该多个启动方案中启动性能最优的启动方案确定为第一启动方案。其中,启动性能最优的启动方案满足以下至少一项:测量启动时长最小、测量启动成本最小。示例的,管理平台将该多个启动方案中测量启动时长最小且测量启动成本最小的启动方案确定为第一启动方案。如前所述,该至少一个启动方案包括基于第一存储池的热启动方案、基于第一存储池的冷启动方案、基于第二计算池的冷启动方案中的至少一个,因此第一启动方案包括以下任意一个:基于第一存储池的热启动方案、基于第一存储池的冷启动方案、基于第二计算池的冷启动方案。In an optional embodiment, the at least one set of startup measurement information corresponds to at least one startup scheme one by one, and each set of startup measurement information is used to characterize the startup performance of starting the target application in the intensive cloud computing system based on the corresponding startup scheme. The management platform determines the startup scheme whose startup performance meets the startup requirements of the first application in the at least one startup scheme according to the at least one set of startup measurement information, and the management platform determines the first startup scheme in the startup scheme whose startup performance meets the startup requirements of the first application. In one embodiment, there is only one startup scheme in the at least one startup scheme whose startup performance meets the startup requirements of the first application, and the management platform determines the one startup scheme as the first startup scheme. In another embodiment, there are multiple startup schemes in the at least one startup scheme whose startup performance meets the startup requirements of the first application, and the management platform determines one startup scheme in the multiple startup schemes as the first startup scheme. For example, the management platform determines any one of the multiple startup schemes as the first startup scheme, or the management platform determines the startup scheme with the best startup performance in the multiple startup schemes as the first startup scheme. Among them, the startup scheme with the best startup performance satisfies at least one of the following items: the minimum measured startup duration and the minimum measured startup cost. For example, the management platform determines the startup scheme with the shortest measured startup time and the shortest measured startup cost among the multiple startup schemes as the first startup scheme. As mentioned above, the at least one startup scheme includes at least one of a hot startup scheme based on the first storage pool, a cold startup scheme based on the first storage pool, and a cold startup scheme based on the second computing pool, so the first startup scheme includes any one of the following: a hot startup scheme based on the first storage pool, a cold startup scheme based on the first storage pool, and a cold startup scheme based on the second computing pool.
作为一个示例,以在图1或图2所示的集约化云计算***100中对目标应用进行启动测试为例说明,在S302中管理平台11得到启动方案1~k一一对应的启动测量信息1~k,在S303中,管理平台11根据启动测量信息1~k,在启动方案1~k确定启动性能满足第一应用的启动诉求的启动方案。一个实施例中,启 动方案1的启动性能满足第一应用的启动诉求,启动方案2~k的启动性能均不满足第一应用的启动诉求,管理平台11将启动方案1确定为第一启动方案。另一个实施例中,启动方案1~3的启动性能均满足第一应用的启动诉求,启动方案4~k的启动性能均不满足第一应用的启动诉求;管理平台11将启动方案1~3中的任一个启动方案(例如启动方案1)确定为第一启动方案;或者,启动方案1~3中,启动方案1的启动性能最优,管理平台11将启动方案1(也即启动性能最优的启动方案)确定为第一启动方案。As an example, taking the startup test of the target application in the intensive cloud computing system 100 shown in FIG. 1 or FIG. 2 as an example, in S302, the management platform 11 obtains the startup measurement information 1-k corresponding to the startup schemes 1-k. In S303, the management platform 11 determines the startup scheme whose startup performance meets the startup requirement of the first application in the startup schemes 1-k according to the startup measurement information 1-k. In one embodiment, the startup The startup performance of startup scheme 1 meets the startup requirements of the first application, and the startup performance of startup schemes 2 to k do not meet the startup requirements of the first application, and the management platform 11 determines startup scheme 1 as the first startup scheme. In another embodiment, the startup performance of startup schemes 1 to 3 all meet the startup requirements of the first application, and the startup performance of startup schemes 4 to k do not meet the startup requirements of the first application; the management platform 11 determines any startup scheme among startup schemes 1 to 3 (for example, startup scheme 1) as the first startup scheme; or, among startup schemes 1 to 3, startup scheme 1 has the best startup performance, and the management platform 11 determines startup scheme 1 (that is, the startup scheme with the best startup performance) as the first startup scheme.
S304.根据第一启动方案在第一计算池中启动第一应用的第一虚拟单元。S304. Start a first virtual unit of a first application in a first computing pool according to a first startup plan.
其中,第一虚拟单元是容器、虚拟机等基于虚拟化技术实现的计算单元。The first virtual unit is a computing unit implemented based on virtualization technology, such as a container or a virtual machine.
管理平台确定第一启动方案之后,该管理平台根据第一应用在集约化云计算***中部署第一启动方案,例如,该管理平台在集约化云计算***中存储基于第一启动方案启动第一应用的虚拟单元所需的快照、应用镜像等信息。该管理平台接收到用于启动第一应用的启动请求(或者说用于启动第一应用的虚拟单元的启动请求)时,该管理单元根据第一启动方案在第一计算池中启动第一应用的第一虚拟单元。其中,第一启动方案包括以下任意一个:基于第一存储池的热启动方案、基于第一存储池的冷启动方案、基于第二计算池的冷启动方案。根据第一启动方案的不同,管理平台启动第一虚拟单元的实现方式不同。下面以第一启动方案是基于第一存储池的热启动方案、基于第一存储池的冷启动方案或基于第二计算池的冷启动方案为例,分三个实施例介绍管理平台根据第一启动方案启动第一虚拟单元的实现方式。After the management platform determines the first startup scheme, the management platform deploys the first startup scheme in the intensive cloud computing system according to the first application. For example, the management platform stores snapshots, application images and other information required for starting the virtual unit of the first application based on the first startup scheme in the intensive cloud computing system. When the management platform receives a startup request for starting the first application (or a startup request for starting the virtual unit of the first application), the management unit starts the first virtual unit of the first application in the first computing pool according to the first startup scheme. Among them, the first startup scheme includes any one of the following: a hot startup scheme based on the first storage pool, a cold startup scheme based on the first storage pool, and a cold startup scheme based on the second computing pool. Depending on the first startup scheme, the implementation method of the management platform starting the first virtual unit is different. The following takes the first startup scheme as an example, which is a hot startup scheme based on the first storage pool, a cold startup scheme based on the first storage pool, or a cold startup scheme based on the second computing pool, and introduces the implementation method of the management platform starting the first virtual unit according to the first startup scheme in three embodiments.
第一个实施例:第一启动方案是基于第一存储池的热启动方案,第一存储池中存储有基准内存快照和基准文件***,该基准内存快照是对第一应用的基准虚拟单元的内存进行快照得到的,该基准文件***是该基准虚拟单元的文件***,该基准内存快照中的数据和该基准文件***中的数据均为只读数据,该基准内存快照和该基准文件***均仅允许读而不允许写(也即不允许修改)。第一计算池中包括第一虚拟单元,第一虚拟单元的内存与该基准内存快照存在映射关系(或者说第一虚拟单元的内存与该基准内存快照关联),第一虚拟单元的文件***与该基准文件***存在映射关系(或者说第一虚拟单元的文件***与该基准文件***关联)。管理平台根据第一启动方案在第一计算池中启动第一虚拟单元,包括:该管理平台根据该基准内存快照在第一计算池中创建第一内存分支,以及,该管理平台根据该基准文件***在第一计算池中创建第一读写层。例如,第一计算池中包括内存空间和外存空间,该管理平台在该内存空间中创建第一内存分支,该管理平台在该外存空间中创建第一读写层。First embodiment: The first startup scheme is a hot startup scheme based on the first storage pool. The first storage pool stores a baseline memory snapshot and a baseline file system. The baseline memory snapshot is obtained by taking a snapshot of the memory of the baseline virtual unit of the first application. The baseline file system is the file system of the baseline virtual unit. The data in the baseline memory snapshot and the data in the baseline file system are read-only data. Both the baseline memory snapshot and the baseline file system are only allowed to be read but not written (i.e., modification is not allowed). The first computing pool includes the first virtual unit. The memory of the first virtual unit has a mapping relationship with the baseline memory snapshot (or the memory of the first virtual unit is associated with the baseline memory snapshot), and the file system of the first virtual unit has a mapping relationship with the baseline file system (or the file system of the first virtual unit is associated with the baseline file system). The management platform starts the first virtual unit in the first computing pool according to the first startup scheme, including: the management platform creates a first memory branch in the first computing pool according to the baseline memory snapshot, and the management platform creates a first read-write layer in the first computing pool according to the baseline file system. For example, the first computing pool includes a memory space and an external memory space, the management platform creates a first memory branch in the memory space, and the management platform creates a first read-write layer in the external memory space.
其中,第一内存分支用于存储第一虚拟单元运行过程中相对于该基准内存快照发生变化的内存数据(也即,第一虚拟单元的内存中相对于该基准内存快照发生变化的内存数据),第一虚拟单元的内存数据(也即第一虚拟单元的内存中的数据)可以根据该基准内存快照中的数据和第一内存分支中存储的内存数据确定。第一读写层用于存储第一虚拟单元运行过程中相对于该基准文件***发生变化的文件数据(也即,第一虚拟单元的文件***中相对于该基准文件***发生变化的文件数据),第一虚拟单元的文件***根据该基准文件***中的文件数据和第一读写层中存储的文件数据确定。第一应用的基准虚拟单元是部署有第一应用且已启动的一个虚拟单元,该基准虚拟单元的基准内存快照是在该基准虚拟单元启动之后的某一时刻对该基准虚拟单元的内存进行快照得到的。第一存储池可以包括内存池和外存池,该基准内存快照可以存储在该内存池中,基准文件***可以存储在该外存池中。该基准内存快照存储在该内存池中还是存储在该外存池中,该基准内存快照具体存储在该内存池中的哪个存储介质中或者存储在该外存池中的哪个存储介质中,该基准文件***存储在该内存池中还是存储在该外存池中,该基准文件***具体存储在该内存池中的哪个存储介质中或者存储在该外存池中的哪个存储介质中,这些都根据第一启动方案确定。此外,第一虚拟单元的内存与该基准内存快照存在映射关系可以包括:第一虚拟单元中存储有该基准内存快照的存储地址,例如,第一虚拟单元的内存中存储有该基准内存快照的存储地址。由于第一虚拟单元的内存与该基准内存快照存在映射关系,因此在访问第一虚拟单元的内存时,可以根据该基准内存快照的存储地址访问该基准内存快照,也即,访问第一虚拟单元的内存的过程包括访问该基准内存快照。同理,第一虚拟单元的文件***与该基准文件***存在映射关系可以包括:第一虚拟单元中存储有该基准文件***的存储地址,例如,第一虚拟单元的内存中存储有该基准文件***的存储地址。由于第一虚拟单元的文件***与该基准文件***存在映射关系,因此在访问第一虚拟单元的文件***时,可以根据该基准文件***的存储地址访问该基准文件***,也即,访问第一虚拟单元的文件***的实际包括访问该基准文件***。The first memory branch is used to store memory data that has changed relative to the baseline memory snapshot during the operation of the first virtual unit (that is, memory data in the memory of the first virtual unit that has changed relative to the baseline memory snapshot), and the memory data of the first virtual unit (that is, data in the memory of the first virtual unit) can be determined based on the data in the baseline memory snapshot and the memory data stored in the first memory branch. The first read-write layer is used to store file data that has changed relative to the baseline file system during the operation of the first virtual unit (that is, file data in the file system of the first virtual unit that has changed relative to the baseline file system), and the file system of the first virtual unit is determined based on the file data in the baseline file system and the file data stored in the first read-write layer. The baseline virtual unit of the first application is a virtual unit that has been deployed with the first application and has been started, and the baseline memory snapshot of the baseline virtual unit is obtained by taking a snapshot of the memory of the baseline virtual unit at a certain time after the baseline virtual unit is started. The first storage pool may include a memory pool and an external memory pool, the baseline memory snapshot may be stored in the memory pool, and the baseline file system may be stored in the external memory pool. Whether the reference memory snapshot is stored in the memory pool or in the external memory pool, in which storage medium in the memory pool or in which storage medium in the external memory pool the reference memory snapshot is specifically stored, whether the reference file system is stored in the memory pool or in the external memory pool, in which storage medium in the memory pool or in which storage medium in the external memory pool the reference file system is specifically stored, are all determined according to the first startup scheme. In addition, the mapping relationship between the memory of the first virtual unit and the reference memory snapshot may include: the storage address of the reference memory snapshot is stored in the first virtual unit, for example, the storage address of the reference memory snapshot is stored in the memory of the first virtual unit. Since the mapping relationship between the memory of the first virtual unit and the reference memory snapshot exists, when accessing the memory of the first virtual unit, the reference memory snapshot can be accessed according to the storage address of the reference memory snapshot, that is, the process of accessing the memory of the first virtual unit includes accessing the reference memory snapshot. Similarly, the mapping relationship between the file system of the first virtual unit and the reference file system may include: the storage address of the reference file system is stored in the first virtual unit, for example, the storage address of the reference file system is stored in the memory of the first virtual unit. Since there is a mapping relationship between the file system of the first virtual unit and the reference file system, when accessing the file system of the first virtual unit, the reference file system can be accessed according to the storage address of the reference file system, that is, accessing the file system of the first virtual unit actually includes accessing the reference file system.
作为一个示例,以在图2所示的集约化云计算***100中启动第一虚拟单元U1为例说明。图4是本申请实施例提供的一种根据第一启动方案(基于第一存储池103的热启动方案)在第一计算池101中启动 第一虚拟单元U1的示意图。如图4所示,第一应用的基准虚拟单元U0运行在第一计算池101中,第一存储池103包括内存池31和外存池32,内存池31中存储有基准内存快照P0,外存池32中存储有基准文件***F0,第一计算池101中包括第一虚拟单元U1,第一虚拟单元U1的内存M1与基准内存快照P0存在映射关系,第一虚拟单元U1的文件***F1与基准文件***F0存在映射关系。管理平台11接收到用于启动第一应用的启动请求时,管理平台11根据基准内存快照P0在第一计算池101中的内存空间中创建第一内存分支B1,以及,管理平台11根据基准文件***F0在第一计算池101中的外存空间中创建第一读写层R1。管理平台11通过创建第一内存分支B1和第一读写层R1调用起第一虚拟单元U1的内存M1和文件***F1,从而启动第一虚拟单元U1。其中,第一内存分支B1用于存储第一虚拟单元U1启动之后,第一虚拟单元U1运行过程中,第一虚拟单元U1的内存M1中相对于基准内存快照P0发生变化的内存数据,第一虚拟单元U1的内存M1中的数据根据基准内存快照P0中的数据和第一内存分支B1中存储的内存数据确定,访问第一虚拟单元U1的内存M1包括访问基准内存快照P0和第一内存分支B1。第一读写层R1用于存储第一虚拟单元U1启动之后,第一虚拟单元U1运行过程中,第一虚拟单元U1的文件***F1中相对于基准文件***F0发生变化的文件数据,第一虚拟单元U1的文件***F1根据基准文件***F0中的文件数据和第一读写层R1中存储的文件数据确定,访问第一虚拟单元U1的文件***F1包括访问基准文件***F0和第一读写层R1。其中,基准虚拟单元U0是部署有第一应用且已启动的一个虚拟单元,基准内存快照P0是在基准虚拟单元U0启动之后的某一时刻对基准虚拟单元U0的内存进行快照得到的,基准文件***F0是基准虚拟单元U0的文件***。可选的,基准内存快照P0中的数据和基准文件***F0中的数据均为只读数据,基准内存快照P0和基准文件***F0均只允许读而不允许修改,第一计算池101中的内存空间中还可以包括基准内存分支B0(图4中未示出),第一计算池101中的外存空间中还可以包括基准读写层R0(图4中未示出),基准内存分支B0用于存储基准虚拟单元U0运行的过程中,基准虚拟单元U0的内存中相对于基准内存快照P0发生变化的内存数据,基准读写层R0用于存储基准虚拟单元U0运行的过程中,基准虚拟单元U0的文件***中相对于基准文件***F0发生变化的文件数据,本申请实施例对此不做限定。As an example, the first virtual unit U1 is started in the intensive cloud computing system 100 shown in FIG2. FIG4 is a method of starting the first computing pool 101 according to the first startup solution (a hot startup solution based on the first storage pool 103) provided in the embodiment of the present application. Schematic diagram of the first virtual unit U1. As shown in FIG4, the base virtual unit U0 of the first application runs in the first computing pool 101, the first storage pool 103 includes a memory pool 31 and an external memory pool 32, the memory pool 31 stores a base memory snapshot P0, the external memory pool 32 stores a base file system F0, the first computing pool 101 includes the first virtual unit U1, the memory M1 of the first virtual unit U1 has a mapping relationship with the base memory snapshot P0, and the file system F1 of the first virtual unit U1 has a mapping relationship with the base file system F0. When the management platform 11 receives a start request for starting the first application, the management platform 11 creates a first memory branch B1 in the memory space in the first computing pool 101 according to the base memory snapshot P0, and the management platform 11 creates a first read-write layer R1 in the external memory space in the first computing pool 101 according to the base file system F0. The management platform 11 calls the memory M1 and the file system F1 of the first virtual unit U1 by creating the first memory branch B1 and the first read-write layer R1, thereby starting the first virtual unit U1. The first memory branch B1 is used to store memory data that has changed in the memory M1 of the first virtual unit U1 relative to the baseline memory snapshot P0 during the operation of the first virtual unit U1 after the first virtual unit U1 is started, the data in the memory M1 of the first virtual unit U1 is determined based on the data in the baseline memory snapshot P0 and the memory data stored in the first memory branch B1, and accessing the memory M1 of the first virtual unit U1 includes accessing the baseline memory snapshot P0 and the first memory branch B1. The first read-write layer R1 is used to store file data that has changed in the file system F1 of the first virtual unit U1 relative to the baseline file system F0 during the operation of the first virtual unit U1 after the first virtual unit U1 is started, the file system F1 of the first virtual unit U1 is determined based on the file data in the baseline file system F0 and the file data stored in the first read-write layer R1, and accessing the file system F1 of the first virtual unit U1 includes accessing the baseline file system F0 and the first read-write layer R1. Among them, the reference virtual unit U0 is a virtual unit that has been deployed with the first application and has been started, the reference memory snapshot P0 is obtained by taking a snapshot of the memory of the reference virtual unit U0 at a certain time after the reference virtual unit U0 is started, and the reference file system F0 is the file system of the reference virtual unit U0. Optionally, the data in the reference memory snapshot P0 and the data in the reference file system F0 are both read-only data, and both the reference memory snapshot P0 and the reference file system F0 are only allowed to be read but not modified. The memory space in the first computing pool 101 may also include a reference memory branch B0 (not shown in FIG. 4), and the external memory space in the first computing pool 101 may also include a reference read-write layer R0 (not shown in FIG. 4). The reference memory branch B0 is used to store memory data that has changed in the memory of the reference virtual unit U0 relative to the reference memory snapshot P0 during the operation of the reference virtual unit U0, and the reference read-write layer R0 is used to store file data that has changed in the file system of the reference virtual unit U0 relative to the reference file system F0 during the operation of the reference virtual unit U0, and the embodiment of the present application does not limit this.
需要说明的是,图4为了简洁仅示出了集约化云计算***100中与该第一个实施例相关的部分,例如图4中未示出第二计算池103。此外,图4为了简洁仅示出基准内存快照P0存储在内存池31中,基准文件***F0存储在外存池32中,并未示出基准内存快照P0具体存储在内存池31中的哪个存储介质中,基准文件***F0具体存储在外存池32中的哪个存储介质中,基准内存快照P0和基准文件***F0具体所在的存储介质根据第一启动方案确定。图4中未示出的其他部分可以参考图1和图2,这里不做赘述。It should be noted that, for the sake of simplicity, FIG4 only shows the part of the intensive cloud computing system 100 related to the first embodiment. For example, the second computing pool 103 is not shown in FIG4. In addition, for the sake of simplicity, FIG4 only shows that the baseline memory snapshot P0 is stored in the memory pool 31 and the baseline file system F0 is stored in the external memory pool 32. It does not show in which storage medium in the memory pool 31 the baseline memory snapshot P0 is specifically stored, and in which storage medium in the external memory pool 32 the baseline file system F0 is specifically stored. The specific storage medium where the baseline memory snapshot P0 and the baseline file system F0 are located is determined according to the first startup scheme. For other parts not shown in FIG4, please refer to FIG1 and FIG2, and no further description is given here.
可选的,在该第一个实施例中,在管理平台根据第一启动方案在第一计算池中启动第一虚拟单元之前,预先在第一存储池中存储第一应用的基准虚拟单元的基准内存快照。可以由该管理平台在第一存储池中存储该基准内存快照,也可以由其他设备在第一存储池中存储该基准内存快照。一个实施例中,该基准虚拟单元运行在第一计算池中,管理平台在该基准虚拟单元运行的过程中获取该基准虚拟单元的基准内存快照,并将该基准内存快照存储至第一存储池中。可选的,第一应用是常用应用,在第一应用的基准虚拟单元正常启动后,该管理平台对该基准虚拟单元的内存打快照,获得该基准虚拟单元的基准内存快照,第一启动方案中可以包括该基准内存快照的存储策略(也即将该基准内存快照存储在第一存储池的哪个存储介质中),该管理平台根据该存储策略将该基准内存快照存储至第一存储池中。一个实施例中,集约化云计算***中部署有多个应用,第一应用是该多个应用中的一个应用,对于该多个应用中的每个常用应用,该管理平台在该每个常用应用的基准虚拟单元正常启动后获取该基准虚拟单元的基准内存快照,并在第一存储池中存储该基准内存快照。其中,可以根据任一应用的使用频率确定该任一应用是否为常用应用。Optionally, in the first embodiment, before the management platform starts the first virtual unit in the first computing pool according to the first startup scheme, the baseline memory snapshot of the baseline virtual unit of the first application is stored in the first storage pool in advance. The baseline memory snapshot can be stored in the first storage pool by the management platform, or by other devices. In one embodiment, the baseline virtual unit runs in the first computing pool, and the management platform obtains the baseline memory snapshot of the baseline virtual unit during the operation of the baseline virtual unit, and stores the baseline memory snapshot in the first storage pool. Optionally, the first application is a commonly used application. After the baseline virtual unit of the first application is started normally, the management platform takes a snapshot of the memory of the baseline virtual unit to obtain the baseline memory snapshot of the baseline virtual unit. The first startup scheme may include a storage policy for the baseline memory snapshot (that is, in which storage medium of the first storage pool the baseline memory snapshot is stored), and the management platform stores the baseline memory snapshot in the first storage pool according to the storage policy. In one embodiment, a plurality of applications are deployed in an intensive cloud computing system, and a first application is one of the plurality of applications. For each commonly used application in the plurality of applications, the management platform obtains a baseline memory snapshot of the baseline virtual unit after the baseline virtual unit of each commonly used application is normally started, and stores the baseline memory snapshot in a first storage pool. Whether any application is a commonly used application can be determined based on the frequency of use of the application.
可选的,在该第一个实施例中,在管理平台根据第一启动方案在第一计算池中启动第一虚拟单元之前,预先在第一计算池中创建第一虚拟单元。可以由该管理平台在第一计算池中创建第一虚拟单元,也可以由其他设备在第一计算池中创建第一虚拟单元。一个实施例中,该管理平台获取第一应用的应用镜像,该管理平台根据第一应用的应用镜像在第一计算池中创建第一虚拟单元。示例的,本申请实施例提供的集约化云计算***包括镜像仓库,第一应用的应用镜像存储在第一存储池中,该镜像仓库中存储有该应用镜像的指示信息与该应用镜像的存储位置(也即该应用镜像在第一存储池中的存储位置)的对应关系,管理平台根据第一应用的应用镜像的指示信息从镜像仓库确定该应用镜像的存储位置,该管理平台根据该应用镜像的存储位置从第一存储池获取该应用镜像,并根据该应用镜像在第一计算池中创建第一虚拟单元。该管理 平台在第一计算池中创建第一虚拟单元之后,该管理平台建立第一虚拟单元的内存与第一应用的基准虚拟单元的基准内存快照的映射关系,以及,该管理平台建立第一虚拟单元的文件***与基准文件***的映射关系。此外,该管理平台在第一计算池中创建第一虚拟单元之前,该管理平台预先准备创建第一应用的虚拟单元所需的相关组件,该管理平台基于这些相关组件创建第一虚拟单元,由于该管理平台预先准备了创建虚拟单元所需的相关组件,该管理平台创建第一虚拟单元时可以直接使用这些相关组件,有助于提高创建第一虚拟单元的速度。示例的,这些相关组件包括控制组(control groups,cgroups)、命名空间(namespace)等。Optionally, in the first embodiment, before the management platform starts the first virtual unit in the first computing pool according to the first startup scheme, the first virtual unit is pre-created in the first computing pool. The first virtual unit can be created in the first computing pool by the management platform, or by other devices. In one embodiment, the management platform obtains an application image of the first application, and the management platform creates the first virtual unit in the first computing pool according to the application image of the first application. By way of example, the intensive cloud computing system provided in the embodiment of the present application includes an image warehouse, and the application image of the first application is stored in a first storage pool. The image warehouse stores a correspondence between indication information of the application image and the storage location of the application image (that is, the storage location of the application image in the first storage pool). The management platform determines the storage location of the application image from the image warehouse according to the indication information of the application image of the first application. The management platform obtains the application image from the first storage pool according to the storage location of the application image, and creates the first virtual unit in the first computing pool according to the application image. The management After the platform creates the first virtual unit in the first computing pool, the management platform establishes a mapping relationship between the memory of the first virtual unit and the baseline memory snapshot of the baseline virtual unit of the first application, and the management platform establishes a mapping relationship between the file system of the first virtual unit and the baseline file system. In addition, before the management platform creates the first virtual unit in the first computing pool, the management platform prepares in advance the relevant components required to create the virtual unit of the first application, and the management platform creates the first virtual unit based on these relevant components. Since the management platform has prepared in advance the relevant components required to create the virtual unit, the management platform can directly use these relevant components when creating the first virtual unit, which helps to increase the speed of creating the first virtual unit. For example, these relevant components include control groups (cgroups), namespaces, etc.
作为一个示例,请继续参考图4,管理平台11在第一计算池101中创建第一虚拟单元U1之前,管理平台11预先准备创建第一应用的虚拟单元所需的相关组件。如图4所示,外存池32中存储有第一应用的应用镜像1,镜像仓库104中存储有应用镜像1的指示信息与应用镜像1的存储位置的对应关系(图4中未示出),管理平台11创建第一应用的虚拟单元(例如第一虚拟单元U1)时,管理平台11根据应用镜像1的指示信息从镜像仓库104确定应用镜像1的存储位置,管理平台11根据应用镜像1的存储位置从外存池32中获取应用镜像1,管理平台11根据应用镜像1在第一计算池101中创建第一虚拟单元U1。管理平台11创建第一虚拟单元U1之后,管理平台11将第一虚拟单元U1的内存M1与基准内存快照P0关联,在访问第一虚拟单元U1的内存时,可以根据该基准内存快照P0的存储地址访问该基准内存快照P0,也即,访问第一虚拟单元U1的内存M1的过程包括访问该基准内存快照P0。As an example, please continue to refer to FIG4. Before the management platform 11 creates the first virtual unit U1 in the first computing pool 101, the management platform 11 prepares in advance the relevant components required to create the virtual unit of the first application. As shown in FIG4, the application image 1 of the first application is stored in the external memory pool 32, and the corresponding relationship between the indication information of the application image 1 and the storage location of the application image 1 is stored in the image warehouse 104 (not shown in FIG4). When the management platform 11 creates the virtual unit of the first application (for example, the first virtual unit U1), the management platform 11 determines the storage location of the application image 1 from the image warehouse 104 according to the indication information of the application image 1, and the management platform 11 obtains the application image 1 from the external memory pool 32 according to the storage location of the application image 1. The management platform 11 creates the first virtual unit U1 in the first computing pool 101 according to the application image 1. After the management platform 11 creates the first virtual unit U1, the management platform 11 associates the memory M1 of the first virtual unit U1 with the baseline memory snapshot P0. When accessing the memory of the first virtual unit U1, the baseline memory snapshot P0 can be accessed according to the storage address of the baseline memory snapshot P0, that is, the process of accessing the memory M1 of the first virtual unit U1 includes accessing the baseline memory snapshot P0.
第二个实施例:第一启动方案是基于第一存储池的冷启动方案,第一存储池中存储有基准单元快照,该基准单元快照是对第一应用的基准虚拟单元进行快照得到的,管理平台根据第一启动方案在第一计算池中启动第一虚拟单元,包括:该管理平台根据该基准单元快照在第一计算池中创建第一虚拟单元并启动第一虚拟单元。示例的,该管理平台基于用户空间的检查点/恢复(checkpoint/restore in userspace,CRIU)技术,根据该基准单元快照在第一计算池中创建第一虚拟单元。一个实施例中,第一虚拟单元是容器,管理平台基于CRIU技术创建容器并启动该容器。该管理平台根据该基准单元快照创建第一虚拟单元并启动第一虚拟单元的实现过程可以参考相关技术中根据容器快照创建容器的实现过程,这里不做赘述。Second embodiment: The first startup scheme is a cold startup scheme based on the first storage pool, and the first storage pool stores a reference unit snapshot, which is obtained by taking a snapshot of the reference virtual unit of the first application. The management platform starts the first virtual unit in the first computing pool according to the first startup scheme, including: the management platform creates the first virtual unit in the first computing pool according to the reference unit snapshot and starts the first virtual unit. For example, the management platform creates the first virtual unit in the first computing pool according to the reference unit snapshot based on the checkpoint/restore in userspace (CRIU) technology in user space. In one embodiment, the first virtual unit is a container, and the management platform creates and starts the container based on the CRIU technology. The implementation process of the management platform creating the first virtual unit according to the reference unit snapshot and starting the first virtual unit can refer to the implementation process of creating a container according to a container snapshot in the relevant technology, which will not be repeated here.
其中,第一应用的基准虚拟单元是部署有第一应用且已启动的一个虚拟单元,该基准单元快照是在该基准虚拟单元启动之后的某一时刻对该基准虚拟单元进行快照得到的,该基准单元快照中包括该基准虚拟单元的内存数据和该基准单元快照的文件***中的数据。第一存储池可以包括内存池和外存池,该基准单元快照存储在该内存池或该外存池中,该基准单元快照存储在该内存池中还是存储在该外存池中,该基准单元快照具体存储在该内存池中的哪个存储介质中或者存储在该外存池中的哪个存储介质中,这些都根据第一启动方案确定。The base virtual unit of the first application is a virtual unit deployed with the first application and started, the base unit snapshot is obtained by taking a snapshot of the base virtual unit at a certain time after the base virtual unit is started, and the base unit snapshot includes the memory data of the base virtual unit and the data in the file system of the base unit snapshot. The first storage pool may include a memory pool and an external memory pool, the base unit snapshot is stored in the memory pool or the external memory pool, the base unit snapshot is stored in the memory pool or the external memory pool, and in which storage medium in the memory pool or in which storage medium in the external memory pool the base unit snapshot is specifically stored, all of which are determined according to the first startup scheme.
作为一个示例,以在图2所示的集约化云计算***100中启动第一虚拟单元U1为例说明。图5是本申请实施例提供的另一种根据第一启动方案(基于第一存储池103的冷启动方案)在第一计算池101中启动第一虚拟单元U1的示意图。如图5所示,第一应用的基准虚拟单元U0运行在第一计算池101中,第一存储池103包括内存池31和外存池32,内存池31中存储有基准单元快照C0。管理平台11接收到用于启动第一应用的启动请求时,管理平台11根据基准单元快照C0在第一计算池101中创建第一虚拟单元U1并启动第一虚拟单元U1。其中,基准单元快照C0是在基准虚拟单元U0启动之后的某一时刻对基准虚拟单元U0进行快照得到的,基准单元快照C0中包括基准虚拟单元U0的内存数据和该基准虚拟单元U0的文件***中的数据,本申请实施例对此不做限定。需要说明的是,图5为了简洁仅示出了集约化云计算***100中与该第二个实施例相关的部分,例如图5中未示出第二计算池103。此外,图5为了简洁仅示出基准单元快照C0存储在内存池31中,并未示出基准单元快照C0具体存储在内存池31中的哪个存储介质中,基准单元快照C0具体所在的存储介质根据第一启动方案确定。图5中未示出的其他部分可以参考图1和图2,这里不做赘述。As an example, the first virtual unit U1 is started in the intensive cloud computing system 100 shown in FIG2. FIG5 is a schematic diagram of another method of starting the first virtual unit U1 in the first computing pool 101 according to the first startup scheme (cold startup scheme based on the first storage pool 103) provided in an embodiment of the present application. As shown in FIG5, the reference virtual unit U0 of the first application runs in the first computing pool 101, and the first storage pool 103 includes a memory pool 31 and an external memory pool 32, and the memory pool 31 stores the reference unit snapshot C0. When the management platform 11 receives a startup request for starting the first application, the management platform 11 creates the first virtual unit U1 in the first computing pool 101 according to the reference unit snapshot C0 and starts the first virtual unit U1. Among them, the reference unit snapshot C0 is obtained by taking a snapshot of the reference virtual unit U0 at a certain moment after the reference virtual unit U0 is started, and the reference unit snapshot C0 includes the memory data of the reference virtual unit U0 and the data in the file system of the reference virtual unit U0, which is not limited in the embodiment of the present application. It should be noted that, for the sake of simplicity, FIG. 5 only shows the part of the intensive cloud computing system 100 related to the second embodiment, for example, the second computing pool 103 is not shown in FIG. In addition, for the sake of simplicity, FIG. 5 only shows that the reference unit snapshot C0 is stored in the memory pool 31, and does not show in which storage medium in the memory pool 31 the reference unit snapshot C0 is specifically stored. The specific storage medium where the reference unit snapshot C0 is located is determined according to the first startup scheme. For other parts not shown in FIG. 5, reference can be made to FIG. 1 and FIG. 2, and no further description is given here.
可选的,在该第二个实施例中,在管理平台根据第一启动方案在第一计算池中启动第一虚拟单元之前,预先在第一存储池中存储第一应用的基准虚拟单元的基准单元快照。可以由该管理平台在第一存储池中存储该基准虚拟单元的基准单元快照,也可以由其他设备在第一存储池中存储该基准虚拟单元的基准单元快照。一个实施例中,该基准虚拟单元运行在第一计算池中,该管理平台在该基准虚拟单元运行的过程中获取该基准虚拟单元的基准单元快照,并将该基准单元快照存储至第一存储池中。可选的,第一应用是常用应用,在第一应用的基准虚拟单元正常启动后,该管理平台基于CRIU技术对该基准虚拟单元打快照,获 得该基准虚拟单元的基准单元快照,第一启动方案中可以包括该基准单元快照的存储策略,该管理平台根据该存储策略将该基准单元快照存储至第一存储池中。一个实施例中,集约化云计算***中部署有多个应用,第一应用是该多个应用中的一个应用,对于该多个应用中的每个常用应用,该管理平台在该每个常用应用的基准虚拟单元正常启动后获取该基准虚拟单元的基准内单元快照,并在第一存储池中存储该基准内存快照,本申请实施例对此不做限定。Optionally, in the second embodiment, before the management platform starts the first virtual unit in the first computing pool according to the first startup scheme, the baseline unit snapshot of the baseline virtual unit of the first application is stored in the first storage pool in advance. The baseline unit snapshot of the baseline virtual unit may be stored in the first storage pool by the management platform, or by other devices. In one embodiment, the baseline virtual unit runs in the first computing pool, and the management platform obtains the baseline unit snapshot of the baseline virtual unit during the operation of the baseline virtual unit, and stores the baseline unit snapshot in the first storage pool. Optionally, the first application is a commonly used application. After the baseline virtual unit of the first application is started normally, the management platform takes a snapshot of the baseline virtual unit based on the CRIU technology to obtain a baseline unit snapshot. The first startup scheme may include a storage policy for the baseline unit snapshot, and the management platform stores the baseline unit snapshot in the first storage pool according to the storage policy. In one embodiment, multiple applications are deployed in the intensive cloud computing system, and the first application is one of the multiple applications. For each commonly used application in the multiple applications, the management platform obtains the baseline internal unit snapshot of the baseline virtual unit after the baseline virtual unit of each commonly used application is normally started, and stores the baseline memory snapshot in the first storage pool. This embodiment of the present application does not limit this.
第三个实施例:第一启动方案是基于第二计算池的冷启动方案,第二计算池中运行有第二虚拟单元,第二虚拟单元的配置与第一虚拟单元的配置相同,管理平台根据第一启动方案在第一计算池中启动第一虚拟单元,包括:该管理平台根据第二虚拟单元在第一计算池中创建第一虚拟单元并启动第一虚拟单元。一个实施例中,该管理平台根据第二虚拟单元的配置在第一计算池中创建第一虚拟单元,例如该管理平台根据第二虚拟单元的cgroups、namespace等创建第一虚拟单元,包括创建第一虚拟单元的基础组件以及创建第一虚拟单元的主进程。该管理平台创建第一虚拟单元之后,该管理平台根据第二虚拟单元的内存在第一计算池中创建第二内存分支,以及,该管理平台根据第二虚拟单元的文件***在第一计算池中创建第二读写层,以启动第一虚拟单元。例如,第一计算池中包括内存空间和外存空间,该管理平台在该内存空间中创建第二内存分支,该管理平台在该外存空间中创建第二读写层。The third embodiment: The first startup scheme is a cold start scheme based on the second computing pool, the second computing pool runs a second virtual unit, the configuration of the second virtual unit is the same as the configuration of the first virtual unit, and the management platform starts the first virtual unit in the first computing pool according to the first startup scheme, including: the management platform creates the first virtual unit in the first computing pool according to the second virtual unit and starts the first virtual unit. In one embodiment, the management platform creates the first virtual unit in the first computing pool according to the configuration of the second virtual unit, for example, the management platform creates the first virtual unit according to the cgroups, namespace, etc. of the second virtual unit, including creating the basic components of the first virtual unit and creating the main process of the first virtual unit. After the management platform creates the first virtual unit, the management platform creates a second memory branch in the first computing pool according to the memory of the second virtual unit, and the management platform creates a second read-write layer in the first computing pool according to the file system of the second virtual unit to start the first virtual unit. For example, the first computing pool includes memory space and external memory space, the management platform creates a second memory branch in the memory space, and the management platform creates a second read-write layer in the external memory space.
其中,第二内存分支用于存储第一虚拟单元运行过程中相对于第二虚拟单元的内存发生变化的内存数据(也即,第一虚拟单元的内存中相对于第二虚拟单元的内存发生变化的数据),第一虚拟单元的内存数据可以根据第二虚拟单元的内存数据和第二内存分支中存储的内存数据确定。第二读写层用于存储第一虚拟单元运行过程中相对于第二虚拟单元的文件***发生变化的文件数据(也即,第一虚拟单元的文件***中相对于第二虚拟单元的文件***发生变化的文件数据),第一虚拟单元的文件***根据第二虚拟单元的文件***和第二读写层中存储的文件数据确定。其中,第二虚拟单元可以是基于上述第一个实施例或第二个实施例在第二计算池中启动的虚拟单元,第二虚拟单元的配置与第一虚拟单元的配置相同包括:第二虚拟单元的元数据(metadata)与第一虚拟单元的元数据相同,第二虚拟单元的描述与第一虚拟单元的描述相同。例如,第二虚拟单元的属性与第一虚拟单元的属性相同,例如第二虚拟单元对应的应用镜像与第一虚拟单元对应的应用镜像相同(比如第二虚拟单元对应的应用镜像和第一虚拟单元对应的应用镜像都是第一应用的应用镜像)。示例的,第二虚拟单元的YAML文件与第一虚拟单元的YAML文件相同。The second memory branch is used to store memory data that has changed relative to the memory of the second virtual unit during the operation of the first virtual unit (that is, data that has changed in the memory of the first virtual unit relative to the memory of the second virtual unit), and the memory data of the first virtual unit can be determined based on the memory data of the second virtual unit and the memory data stored in the second memory branch. The second read-write layer is used to store file data that has changed relative to the file system of the second virtual unit during the operation of the first virtual unit (that is, file data that has changed in the file system of the first virtual unit relative to the file system of the second virtual unit), and the file system of the first virtual unit is determined based on the file system of the second virtual unit and the file data stored in the second read-write layer. The second virtual unit can be a virtual unit started in the second computing pool based on the first embodiment or the second embodiment above, and the configuration of the second virtual unit is the same as the configuration of the first virtual unit, including: the metadata of the second virtual unit is the same as the metadata of the first virtual unit, and the description of the second virtual unit is the same as the description of the first virtual unit. For example, the attributes of the second virtual unit are the same as the attributes of the first virtual unit, for example, the application image corresponding to the second virtual unit is the same as the application image corresponding to the first virtual unit (for example, the application image corresponding to the second virtual unit and the application image corresponding to the first virtual unit are both application images of the first application). For example, the YAML file of the second virtual unit is the same as the YAML file of the first virtual unit.
作为一个示例,以在图1或图2所示的集约化云计算***100中启动第一虚拟单元U1为例说明。图6是本申请实施例提供的再一种根据第一启动方案(基于第二计算池102的冷启动方案)在第一计算池101中启动第一虚拟单元U1的示意图。如图6所示,第二计算池102中运行有第二虚拟单元U2,第二虚拟单元U2的配置与第一虚拟单元U1的配置相同。管理平台11接收到用于启动第一应用的启动请求时,管理平台11根据第二虚拟单元U2在第一计算池101中创建第一虚拟单元U1,管理平台11根据第二虚拟单元U2的内存M2在第一计算池101中中的内存空间中创建第二内存分支B2,以及,管理平台11根据第二虚拟单元U2的文件***F2在第一计算池101中的外存空间中创建第二读写层R2。管理平台11通过创建第二内存分支B2和第二读写层R2调用起第一虚拟单元U1的内存M1和第一虚拟单元U1的文件***F1,从而启动第一虚拟单元U1。其中,第二内存分支B2用于存储第一虚拟单元U1启动之后,第一虚拟单元U1运行过程中,第一虚拟单元U1的内存M1中相对于第二虚拟单元U2的内存M2发生变化的内存数据,第一虚拟单元U1的内存M1中的数据根据第二虚拟单元U2的内存M2中的数据和第二内存分支B2中存储的内存数据确定,访问第一虚拟单元U1的内存M1包括访问第二虚拟单元U2的内存M2和第二内存分支B2。第二读写层R2用于存储第一虚拟单元U1启动之后,第一虚拟单元U1运行过程中,第一虚拟单元U1的文件***F1中相对于第二虚拟单元U2的文件***F2发生变化的文件数据,第一虚拟单元U1的文件***F1根据第二虚拟单元U2的文件***F2和第二读写层R2中存储的文件数据确定,访问第一虚拟单元U1的文件***F1包括访问第二虚拟单元U2的文件***F2和第二读写层R2。需要说明的是,图6为了简洁仅示出了集约化云计算***100中与该第三个实施例相关的部分,例如图6中未示出第一存储池102和镜像仓库104。图6中未示出的其他部分可以参考图1和图2,这里不做赘述。As an example, take starting the first virtual unit U1 in the intensive cloud computing system 100 shown in FIG. 1 or 2 as an example. FIG. 6 is a schematic diagram of starting the first virtual unit U1 in the first computing pool 101 according to another first startup scheme (cold start scheme based on the second computing pool 102) provided in an embodiment of the present application. As shown in FIG. 6, a second virtual unit U2 is running in the second computing pool 102, and the configuration of the second virtual unit U2 is the same as that of the first virtual unit U1. When the management platform 11 receives a startup request for starting the first application, the management platform 11 creates the first virtual unit U1 in the first computing pool 101 according to the second virtual unit U2, the management platform 11 creates a second memory branch B2 in the memory space in the first computing pool 101 according to the memory M2 of the second virtual unit U2, and the management platform 11 creates a second read-write layer R2 in the external memory space in the first computing pool 101 according to the file system F2 of the second virtual unit U2. The management platform 11 calls the memory M1 of the first virtual unit U1 and the file system F1 of the first virtual unit U1 by creating the second memory branch B2 and the second read-write layer R2, thereby starting the first virtual unit U1. The second memory branch B2 is used to store memory data that has changed in the memory M1 of the first virtual unit U1 relative to the memory M2 of the second virtual unit U2 during the operation of the first virtual unit U1 after the first virtual unit U1 is started. The data in the memory M1 of the first virtual unit U1 is determined based on the data in the memory M2 of the second virtual unit U2 and the memory data stored in the second memory branch B2. Accessing the memory M1 of the first virtual unit U1 includes accessing the memory M2 of the second virtual unit U2 and the second memory branch B2. The second read-write layer R2 is used to store file data that has changed in the file system F1 of the first virtual unit U1 relative to the file system F2 of the second virtual unit U2 during the operation of the first virtual unit U1 after the first virtual unit U1 is started. The file system F1 of the first virtual unit U1 is determined based on the file data stored in the file system F2 of the second virtual unit U2 and the second read-write layer R2. Accessing the file system F1 of the first virtual unit U1 includes accessing the file system F2 and the second read-write layer R2 of the second virtual unit U2. It should be noted that, for the sake of simplicity, FIG6 only shows the parts of the intensive cloud computing system 100 related to the third embodiment. For example, the first storage pool 102 and the image warehouse 104 are not shown in FIG6. For other parts not shown in FIG6, please refer to FIG1 and FIG2, and they will not be described here.
可选的实施例中,管理平台运行在第一计算池中,从管理平台的角度来讲,第一计算池可以称为本地计算池、第二计算池可以称为远端计算池,第一存储池可以称为远端存储池。上述基于第一存储池的热启动方案可以称为基于远端存储池的热启动方案,上述基于第一存储池的冷启动方案可以称为基于远端存储池的冷启动方案,上述基于第二计算池的冷启动方案可以称为基于远端计算池的冷启动方案,本申请实施 例对此不做限定。In an optional embodiment, the management platform runs in the first computing pool. From the perspective of the management platform, the first computing pool can be called a local computing pool, the second computing pool can be called a remote computing pool, and the first storage pool can be called a remote storage pool. The above-mentioned hot start solution based on the first storage pool can be called a hot start solution based on a remote storage pool, the above-mentioned cold start solution based on the first storage pool can be called a cold start solution based on a remote storage pool, and the above-mentioned cold start solution based on the second computing pool can be called a cold start solution based on a remote computing pool. This application implements This example does not limit this.
综上所述,本申请实施例提供的技术方案,至少一组启动测量信息对应至少一个启动方案,每组启动测量信息用于表征基于对应的启动方案在集约化云计算***中启动目标应用的启动性能,该集约化云计算***中的管理平台根据第一应用的启动诉求和该至少一组启动测量信息确定第一启动方案(也即,该管理平台根据第一应用的启动诉求和该至少一个启动方案的启动性能确定第一启动方案),并根据第一启动方案在第一计算池中启动第一应用的虚拟单元,因此,本申请实施例提供的虚拟单元启动方案在集约化云计算***中实施的性能较好,可以实现第一应用的极速启动,且可以充分利用低成本的资源,降低集约化云计算***的运营成本。由于管理平台根据第一应用的启动诉求自动选择启动方案,因此能够提升该虚拟单元启动方案的可用性。In summary, the technical solution provided by the embodiment of the present application is that at least one set of startup measurement information corresponds to at least one startup scheme, and each set of startup measurement information is used to characterize the startup performance of starting the target application in the intensive cloud computing system based on the corresponding startup scheme. The management platform in the intensive cloud computing system determines the first startup scheme according to the startup demand of the first application and the at least one set of startup measurement information (that is, the management platform determines the first startup scheme according to the startup demand of the first application and the startup performance of the at least one startup scheme), and starts the virtual unit of the first application in the first computing pool according to the first startup scheme. Therefore, the virtual unit startup scheme provided by the embodiment of the present application has good performance in the intensive cloud computing system, can achieve extremely fast startup of the first application, and can make full use of low-cost resources to reduce the operating cost of the intensive cloud computing system. Since the management platform automatically selects the startup scheme according to the startup demand of the first application, the availability of the virtual unit startup scheme can be improved.
以上是对本申请的方法实施例的介绍,下面介绍本申请的装置实施例。本申请的装置可以用于执行本申请的方法。对于本申请的装置实施例中未披露的细节,请参照方法实施例。The above is an introduction to the method embodiment of the present application. The following is an introduction to the device embodiment of the present application. The device of the present application can be used to execute the method of the present application. For details not disclosed in the device embodiment of the present application, please refer to the method embodiment.
请参考图7,其示出了本申请实施例提供的一种虚拟单元启动装置700的示意图。虚拟单元启动装置700应用于集约化云计算***中的管理平台,例如虚拟单元启动装置700是该管理平台或者是该管理平台中的功能组件。虚拟单元启动装置700用于执行图3所示方法实施例中的全部或部分步骤。其中,该集约化云计算***还包括第一计算池。参见图7,虚拟单元启动装置700包括获取模块710、确定模块720和启动模块730。Please refer to Figure 7, which shows a schematic diagram of a virtual unit startup device 700 provided in an embodiment of the present application. The virtual unit startup device 700 is applied to a management platform in an intensive cloud computing system. For example, the virtual unit startup device 700 is the management platform or a functional component in the management platform. The virtual unit startup device 700 is used to execute all or part of the steps in the method embodiment shown in Figure 3. Among them, the intensive cloud computing system also includes a first computing pool. Referring to Figure 7, the virtual unit startup device 700 includes an acquisition module 710, a determination module 720 and a startup module 730.
获取模块710,用于获取第一应用的启动诉求,以及,获取目标应用对应的至少一组启动测量信息,该至少一组启动测量信息对应至少一个启动方案,该至少一组启动测量信息中的每组启动测量信息用于表征基于对应的启动方案在该集约化云计算***中启动目标应用的启动性能,目标应用与第一应用匹配;The acquisition module 710 is used to acquire the startup demand of the first application, and to acquire at least one set of startup measurement information corresponding to the target application, wherein the at least one set of startup measurement information corresponds to at least one startup scheme, and each set of startup measurement information in the at least one set of startup measurement information is used to characterize the startup performance of starting the target application in the intensive cloud computing system based on the corresponding startup scheme, and the target application matches the first application;
确定模块720,用于根据第一应用的启动诉求和该至少一组启动测量信息确定第一启动方案,该至少一个启动方案包括第一启动方案;A determination module 720, configured to determine a first startup scheme according to the startup demand of the first application and the at least one set of startup measurement information, wherein the at least one startup scheme includes the first startup scheme;
启动模块730,用于根据第一启动方案在第一计算池中启动第一应用的第一虚拟单元。The startup module 730 is configured to start a first virtual unit of a first application in a first computing pool according to a first startup scheme.
可选的,第一启动方案包括以下任意一个:基于第一存储池的热启动方案;基于第一存储池的冷启动方案;基于第二计算池的冷启动方案。第一存储池和第二计算池分别与第一计算池互联。根据第一启动方案的不同,启动模块730的功能不同,下面分三个实施例介绍。Optionally, the first startup scheme includes any one of the following: a hot startup scheme based on the first storage pool; a cold startup scheme based on the first storage pool; a cold startup scheme based on the second computing pool. The first storage pool and the second computing pool are interconnected with the first computing pool respectively. Depending on the first startup scheme, the function of the startup module 730 is different, which is described in three embodiments below.
第一个实施例:第一启动方案包括基于第一存储池的热启动方案,第一存储池中存储有基准内存快照,该基准内存快照是对第一应用的基准虚拟单元的内存进行快照得到的,第一计算池中包括第一虚拟单元;启动模块730,用于根据该基准内存快照在第一计算池中创建第一内存分支,第一内存分支用于存储第一虚拟单元运行过程中相对于该基准内存快照发生变化的内存数据。The first embodiment: The first startup scheme includes a hot startup scheme based on a first storage pool, wherein a baseline memory snapshot is stored in the first storage pool, and the baseline memory snapshot is obtained by taking a snapshot of the memory of a baseline virtual unit of a first application, and the first computing pool includes a first virtual unit; a startup module 730 is used to create a first memory branch in the first computing pool according to the baseline memory snapshot, and the first memory branch is used to store memory data that has changed relative to the baseline memory snapshot during the operation of the first virtual unit.
可选的,在该第一个实施例中,第一存储池中还存储有基准文件***,该基准文件***是该基准虚拟单元的文件***;启动模块730,还用于根据该基准文件***在第一计算池中创建第一读写层,第一读写层用于存储第一虚拟单元运行过程中相对于该基准文件***发生变化的文件数据。Optionally, in the first embodiment, a benchmark file system is also stored in the first storage pool, and the benchmark file system is the file system of the benchmark virtual unit; the startup module 730 is also used to create a first read-write layer in the first computing pool according to the benchmark file system, and the first read-write layer is used to store file data that has changed relative to the benchmark file system during the operation of the first virtual unit.
可选的,在该第一个实施例中,获取模块710,还用于在启动模块730根据第一启动方案在第一计算池中启动第一虚拟单元之前,在该基准虚拟单元运行的过程中,获取该基准虚拟单元的基准内存快照;请继续参考图7,虚拟单元启动装置700还包括:存储模块740,用于将该基准内存快照存储至第一存储池中。Optionally, in the first embodiment, the acquisition module 710 is also used to obtain a baseline memory snapshot of the baseline virtual unit during the operation of the baseline virtual unit before the startup module 730 starts the first virtual unit in the first computing pool according to the first startup scheme; please continue to refer to Figure 7, the virtual unit startup device 700 also includes: a storage module 740, used to store the baseline memory snapshot in the first storage pool.
可选的,请继续参考图7,在第一个实施例中,虚拟单元启动装置700还包括:创建模块750,用于在启动模块730根据第一启动方案在第一计算池中启动第一虚拟单元之前,根据第一应用的应用镜像在第一计算池中创建第一虚拟单元。Optionally, please continue to refer to Figure 7. In the first embodiment, the virtual unit startup device 700 also includes: a creation module 750, which is used to create a first virtual unit in the first computing pool according to the application image of the first application before the startup module 730 starts the first virtual unit in the first computing pool according to the first startup plan.
第二个实施例:第一启动方案包括基于第一存储池的冷启动方案,第一存储池中存储有基准单元快照,该基准单元快照是对第一应用的基准虚拟单元进行快照得到的;启动模块730,用于根据该基准单元快照在第一计算池中创建并启动第一虚拟单元。Second embodiment: The first startup plan includes a cold start plan based on the first storage pool, in which a baseline unit snapshot is stored, and the baseline unit snapshot is obtained by taking a snapshot of the baseline virtual unit of the first application; a startup module 730 is used to create and start the first virtual unit in the first computing pool according to the baseline unit snapshot.
可选的,在第二个实施例中,获取模块710,还用于在启动模块730根据第一启动方案在第一计算池中启动第一虚拟单元之前,在该基准虚拟单元运行的过程中,获取该基准虚拟单元的基准单元快照;Optionally, in the second embodiment, the acquisition module 710 is further configured to acquire a reference unit snapshot of the reference virtual unit during the operation of the reference virtual unit before the startup module 730 starts the first virtual unit in the first computing pool according to the first startup scheme;
请继续参考图7,虚拟单元启动装置700还包括:存储模块740,用于将该基准单元快照存储至第一存储池中。 Please continue to refer to FIG. 7 , the virtual unit startup device 700 further includes: a storage module 740 , which is used to store the baseline unit snapshot in the first storage pool.
可选的,该基准虚拟单元运行在第一计算池中。Optionally, the benchmark virtual unit runs in a first computing pool.
第三个实施例:第一启动方案包括基于第二计算池的冷启动方案,第二计算池中运行有第二虚拟单元,第二虚拟单元的配置与第一虚拟单元的配置相同;启动模块730,用于根据第二虚拟单元在第一计算池中创建并启动第一虚拟单元。A third embodiment: The first startup plan includes a cold start plan based on a second computing pool, in which a second virtual unit runs, and the configuration of the second virtual unit is the same as that of the first virtual unit; a startup module 730 is used to create and start the first virtual unit in the first computing pool according to the second virtual unit.
可选的,在第二个实施例中,启动模块730,用于根据第二虚拟单元的内存在第一计算池中创建第二内存分支,第二内存分支用于存储第一虚拟单元运行过程中相对于第二虚拟单元的内存发生变化的内存数据。Optionally, in a second embodiment, the startup module 730 is used to create a second memory branch in the first computing pool according to the memory of the second virtual unit, and the second memory branch is used to store memory data that changes relative to the memory of the second virtual unit during the operation of the first virtual unit.
可选的,在第二个实施例中,启动模块730,用于根据第二虚拟单元的文件***在第一计算池中创建第二读写层,第二读写层用于存储第一虚拟单元运行过程中相对于第二虚拟单元的文件***发生变化的文件数据。Optionally, in a second embodiment, the startup module 730 is used to create a second read-write layer in the first computing pool according to the file system of the second virtual unit, and the second read-write layer is used to store file data that changes relative to the file system of the second virtual unit during the operation of the first virtual unit.
可选的,该集约化云计算***还包括第一存储池,第一存储池与第一计算池互联;第一存储池用于存储第一应用的以下至少一个信息:第一应用的虚拟单元的内存的快照;第一应用的虚拟单元的快照;第一应用的应用镜像。Optionally, the intensive cloud computing system also includes a first storage pool, which is interconnected with the first computing pool; the first storage pool is used to store at least one of the following information of the first application: a snapshot of the memory of the virtual unit of the first application; a snapshot of the virtual unit of the first application; and an application image of the first application.
可选的,第一应用的该至少一个信息在第一存储池中的存储位置根据第一应用的以下至少一个指标确定:重要性、使用频率、启动诉求。Optionally, the storage location of the at least one information of the first application in the first storage pool is determined according to at least one of the following indicators of the first application: importance, usage frequency, and startup appeal.
可选的,该集约化云计算***还包括镜像仓库,该镜像仓库用于存储应用镜像的指示信息与该应用镜像在第一存储池中的存储位置的对应关系。Optionally, the intensive cloud computing system further includes an image warehouse, which is used to store the correspondence between the indication information of the application image and the storage location of the application image in the first storage pool.
可选的,第一存储池包括内存池和外存池中的至少一个。Optionally, the first storage pool includes at least one of a memory pool and an external memory pool.
可选的,内存池和外存池满足以下至少一项:Optionally, the memory pool and external memory pool meet at least one of the following requirements:
该内存池包括至少两个第一存储介质,该至少两个第一存储介质的类型不同;The memory pool includes at least two first storage media, and the at least two first storage media are of different types;
该外存池包括至少两个第二存储介质,该至少两个第二存储介质的类型不同。The external storage pool includes at least two second storage media, and the at least two second storage media are of different types.
其中,第一存储介质和第二存储介质分别基于差分算法存储数据。The first storage medium and the second storage medium store data based on a differential algorithm respectively.
可选的,目标应用与第一应用匹配包括以下至少一项:目标应用是第一应用;目标应用的规模与第一应用的规模匹配;目标应用的应用镜像的大小与第一应用的应用镜像的大小匹配;目标应用的类型与第一应用的类型匹配。Optionally, the target application matches the first application, including at least one of the following: the target application is the first application; the scale of the target application matches the scale of the first application; the size of the application image of the target application matches the size of the application image of the first application; the type of the target application matches the type of the first application.
可选的,第一应用的启动诉求包括启动时长诉求和启动成本诉求中的至少一个;启动测量信息包括测量启动时长和测量启动成本中的至少一个。Optionally, the startup requirement of the first application includes at least one of a startup duration requirement and a startup cost requirement; and the startup measurement information includes at least one of a measured startup duration and a measured startup cost.
可选的,获取模块710,用于根据至少一个启动方案中的每个启动方案在集约化云计算***中对目标应用进行启动测试,得到该每个启动方案对应的一组启动测量信息。Optionally, the acquisition module 710 is configured to perform a startup test on the target application in the intensive cloud computing system according to each startup scheme of at least one startup scheme, and obtain a set of startup measurement information corresponding to each startup scheme.
可选的,管理平台部署在第一计算池中。Optionally, the management platform is deployed in the first computing pool.
可选的,第一虚拟单元是容器或虚拟机。Optionally, the first virtual unit is a container or a virtual machine.
获取模块710可以用于执行上述S301、S302以及S304中的相关步骤,获取模块710的功能实现可以参考S301、S302以及S304中的相关描述。确定模块720可以用于执行上述S303,确定模块720的功能实现可以参考S303中的相关描述。启动模块730、存储模块740和创建模块750可以用于执行上述S304中的相关步骤,启动模块730、存储模块740和创建模块750的功能实现可以参考S304中的相关描述。The acquisition module 710 can be used to execute the relevant steps in S301, S302 and S304 above. The functional implementation of the acquisition module 710 can refer to the relevant descriptions in S301, S302 and S304. The determination module 720 can be used to execute the above S303. The functional implementation of the determination module 720 can refer to the relevant description in S303. The startup module 730, the storage module 740 and the creation module 750 can be used to execute the relevant steps in S304 above. The functional implementation of the startup module 730, the storage module 740 and the creation module 750 can refer to the relevant description in S304.
获取模块710、确定模块720、启动模块730、存储模块740和创建模块750均可以通过软件实现,或者可以通过硬件实现。接下来以获取模块710为例介绍。类似的,确定模块720、启动模块730、存储模块740和创建模块750的实现方式可以参考获取模块710的实现方式。The acquisition module 710, the determination module 720, the startup module 730, the storage module 740 and the creation module 750 can all be implemented by software, or can be implemented by hardware. Next, the acquisition module 710 is taken as an example. Similarly, the implementation of the determination module 720, the startup module 730, the storage module 740 and the creation module 750 can refer to the implementation of the acquisition module 710.
获取模块710作为软件功能模块的一种举例,获取模块710可以包括运行在计算实例上的代码。其中,计算实例可以包括物理主机、虚拟机、容器中的至少一种。进一步地,上述计算实例可以是一台或者多台。例如,获取模块710可以包括运行在多个主机/虚拟机/容器上的代码。需要说明的是,用于运行该代码的多个主机/虚拟机/容器可以分布在相同的区域(region)中,也可以分布在不同的region中。进一步地,用于运行该代码的多个主机/虚拟机/容器可以分布在相同的可用区(availability zone,AZ)中,也可以分布在不同的AZ中,每个AZ包括一个数据中心或多个地理位置相近的数据中心。其中,通常一个region可以包括多个AZ。As an example of a software functional module, the acquisition module 710 may include code running on a computing instance. The computing instance may include at least one of a physical host, a virtual machine, and a container. Furthermore, the computing instance may be one or more. For example, the acquisition module 710 may include code running on multiple hosts/virtual machines/containers. It should be noted that the multiple hosts/virtual machines/containers used to run the code may be distributed in the same region or in different regions. Furthermore, the multiple hosts/virtual machines/containers used to run the code may be distributed in the same availability zone (AZ) or in different AZs, each AZ including one data center or multiple data centers with close geographical locations. Generally, a region may include multiple AZs.
同样,用于运行该代码的多个主机/虚拟机/容器可以分布在同一个虚拟私有云(virtual private cloud,VPC)中,也可以分布在多个VPC中。其中,通常一个VPC设置在一个region内,同一region内两个VPC之 间,以及不同region的VPC之间跨区通信需在每个VPC内设置通信网关,经通信网关实现VPC之间的互连。Similarly, multiple hosts/virtual machines/containers used to run the code can be distributed in the same virtual private cloud (VPC) or in multiple VPCs. Usually, a VPC is set in a region, and the distance between two VPCs in the same region is For cross-region communication between VPCs, as well as between VPCs in different regions, a communication gateway must be set up in each VPC to achieve interconnection between VPCs through the communication gateway.
获取模块710作为硬件功能单元的一种举例,获取模块710可以包括至少一个计算设备,或者,获取模块710可以是利用专用集成电路(application-specific integrated circuit,ASIC)或可编程逻辑器件(programmable logic device,PLD)实现的设备等。上述PLD可以是复杂程序逻辑器件(complex programmable logical device,CPLD)、现场可编程门阵列(field-programmable gate array,FPGA)、通用阵列逻辑(generic array logic,GAL)或其任意组合实现。As an example of a hardware functional unit, the acquisition module 710 may include at least one computing device, or the acquisition module 710 may be a device implemented by an application-specific integrated circuit (ASIC) or a programmable logic device (PLD). The PLD may be a complex programmable logical device (CPLD), a field-programmable gate array (FPGA), a generic array logic (GAL) or any combination thereof.
获取模块710包括的多个计算设备可以分布在相同的region中,也可以分布在不同的region中。获取模块710包括的多个计算设备可以分布在相同的AZ中,也可以分布在不同的AZ中。同样,获取模块710包括的多个计算设备可以分布在同一个VPC中,也可以分布在多个VPC中。所述多个计算设备可以是ASIC、PLD、CPLD、FPGA和GAL等计算设备的任意组合。The multiple computing devices included in the acquisition module 710 can be distributed in the same region or in different regions. The multiple computing devices included in the acquisition module 710 can be distributed in the same AZ or in different AZs. Similarly, the multiple computing devices included in the acquisition module 710 can be distributed in the same VPC or in multiple VPCs. The multiple computing devices can be any combination of computing devices such as ASIC, PLD, CPLD, FPGA, and GAL.
综上所述,本申请实施例提供的技术方案,本申请实施例提供的技术方案,至少一组启动测量信息对应至少一个启动方案,每组启动测量信息用于表征基于对应的启动方案在集约化云计算***中启动目标应用的启动性能,该集约化云计算***中的管理平台根据第一应用的启动诉求和该至少一组启动测量信息确定第一启动方案(也即,该管理平台根据第一应用的启动诉求和该至少一个启动方案的启动性能确定第一启动方案),并根据第一启动方案在第一计算池中启动第一应用的虚拟单元,因此,本申请实施例提供的虚拟单元启动方案在集约化云计算***中实施的性能较好,可以实现第一应用的极速启动,且可以充分利用低成本的资源,降低集约化云计算***的运营成本。由于管理平台根据第一应用的启动诉求自动选择启动方案,因此能够提升该虚拟单元启动方案的可用性。In summary, the technical solution provided by the embodiment of the present application, the technical solution provided by the embodiment of the present application, at least one group of startup measurement information corresponds to at least one startup scheme, each group of startup measurement information is used to characterize the startup performance of starting the target application in the intensive cloud computing system based on the corresponding startup scheme, the management platform in the intensive cloud computing system determines the first startup scheme according to the startup demand of the first application and the at least one group of startup measurement information (that is, the management platform determines the first startup scheme according to the startup demand of the first application and the startup performance of the at least one startup scheme), and starts the virtual unit of the first application in the first computing pool according to the first startup scheme, therefore, the virtual unit startup scheme provided by the embodiment of the present application has good performance in the intensive cloud computing system, can realize the extremely fast startup of the first application, and can make full use of low-cost resources to reduce the operating cost of the intensive cloud computing system. Since the management platform automatically selects the startup scheme according to the startup demand of the first application, the availability of the virtual unit startup scheme can be improved.
本申请实施例还提供了一种虚拟单元启动装置,包括存储器和处理器;该存储器用于存储计算机程序;该处理器用于执行该存储器中存储的计算机程序以使得该虚拟单元启动装置执行如上述实施例提供的虚拟单元启动方法的全部或部分步骤。An embodiment of the present application also provides a virtual unit startup device, including a memory and a processor; the memory is used to store a computer program; the processor is used to execute the computer program stored in the memory so that the virtual unit startup device performs all or part of the steps of the virtual unit startup method provided in the above embodiment.
作为一个示例,请参考图8,其示出了本申请实施例提供的另一种虚拟单元启动装置800的示意图。虚拟单元启动装置800可以是集约化云计算***中的管理平台或者是该管理平台中的功能组件。如图8所示,虚拟单元启动装置800包括总线802、处理器804、存储器806和通信接口808。处理器804、存储器806和通信接口808之间通过总线802通信。应理解,本申请实施例不限定虚拟单元启动装置800中的处理器、存储器的个数。As an example, please refer to Figure 8, which shows a schematic diagram of another virtual unit startup device 800 provided in an embodiment of the present application. The virtual unit startup device 800 can be a management platform in an intensive cloud computing system or a functional component in the management platform. As shown in Figure 8, the virtual unit startup device 800 includes a bus 802, a processor 804, a memory 806, and a communication interface 808. The processor 804, the memory 806, and the communication interface 808 communicate through the bus 802. It should be understood that the embodiment of the present application does not limit the number of processors and memories in the virtual unit startup device 800.
总线802可以是外设部件互连标准(peripheral component interconnect,PCI)总线或扩展工业标准结构(extended industry standard architecture,EISA)总线等。总线可以分为地址总线、数据总线、控制总线等。为便于表示,图8中仅用一条线表示,但并不表示仅有一根总线或一种类型的总线。总线802可包括在虚拟单元启动装置800各个部件(例如,存储器806、处理器804、通信接口808)之间传送信息的通路。The bus 802 may be a peripheral component interconnect (PCI) bus or an extended industry standard architecture (EISA) bus, etc. The bus may be divided into an address bus, a data bus, a control bus, etc. For ease of representation, FIG8 is represented by only one line, but it does not mean that there is only one bus or one type of bus. The bus 802 may include a path for transmitting information between various components of the virtual unit startup device 800 (e.g., the memory 806, the processor 804, and the communication interface 808).
处理器804可以包括中央处理器(central processing unit,CPU)、图形处理器(graphics processing unit,GPU)、微处理器(micro processor,MP)或者数字信号处理器(digital signal processor,DSP)等处理器中的任意一种或多种。Processor 804 may include any one or more of a central processing unit (CPU), a graphics processing unit (GPU), a microprocessor (MP), or a digital signal processor (DSP).
存储器806可以包括易失性存储器(volatile memory),例如随机存取存储器(random access memory,RAM)。处理器804还可以包括非易失性存储器(non-volatile memory),例如只读存储器(read-only memory,ROM),快闪存储器,机械硬盘(hard disk drive,HDD)或固态硬盘(solid state drive,SSD)等。The memory 806 may include a volatile memory, such as a random access memory (RAM). The processor 804 may also include a non-volatile memory, such as a read-only memory (ROM), a flash memory, a hard disk drive (HDD), or a solid state drive (SSD).
存储器806中存储有可执行的程序代码,处理器804执行该可执行的程序代码以分别实现前述获取模块710、确定模块720、启动模块730、存储模块740和创建模块750的功能,从而实现上述虚拟单元启动方法的至少部分步骤。也即,存储器806上存有用于执行上述虚拟单元启动方法的指令。The memory 806 stores executable program codes, and the processor 804 executes the executable program codes to respectively implement the functions of the aforementioned acquisition module 710, determination module 720, startup module 730, storage module 740, and creation module 750, thereby implementing at least some steps of the aforementioned virtual unit startup method. That is, the memory 806 stores instructions for executing the aforementioned virtual unit startup method.
通信接口808使用例如但不限于网络接口卡、收发器一类的收发模块,来实现虚拟单元启动装置800与其他设备或通信网络之间的通信。The communication interface 808 uses a transceiver module such as, but not limited to, a network interface card or a transceiver to implement communication between the virtual unit startup device 800 and other devices or communication networks.
本申请实施例还提供了一种云计算***,该云计算***包括计算池和存储池,该计算池与该存储池互联,该计算池包括如图7或图8所示的虚拟单元启动装置。例如,该计算池中包括管理平台,该管理平台包括如图7或图8所示的虚拟单元启动装置。The embodiment of the present application also provides a cloud computing system, which includes a computing pool and a storage pool, the computing pool is interconnected with the storage pool, and the computing pool includes a virtual unit startup device as shown in Figure 7 or Figure 8. For example, the computing pool includes a management platform, and the management platform includes a virtual unit startup device as shown in Figure 7 or Figure 8.
示例的,该云计算***是如图1或图2所示的集约化云计算***100。 Illustratively, the cloud computing system is the intensive cloud computing system 100 as shown in FIG. 1 or FIG. 2 .
本申请实施例提供了一种计算机可读存储介质,该计算机可读存储介质中存储有计算机程序,该计算机程序被执行(例如,被虚拟单元启动装置、管理平台、一个或多个处理器等执行)时,实现如上述方法实施例提供的方法的全部或部分步骤。An embodiment of the present application provides a computer-readable storage medium, which stores a computer program. When the computer program is executed (for example, executed by a virtual unit startup device, a management platform, one or more processors, etc.), all or part of the steps of the method provided in the above method embodiment are implemented.
本申请实施例提供了一种计算机程序产品,该计算机程序产品包括程序或代码,该程序或代码被执行(例如,被虚拟单元启动装置、管理平台、一个或多个处理器等执行)时,实现如上述方法实施例提供的方法的全部或部分步骤。An embodiment of the present application provides a computer program product, which includes a program or code. When the program or code is executed (for example, executed by a virtual unit startup device, a management platform, one or more processors, etc.), it implements all or part of the steps of the method provided in the above method embodiment.
本申请实施例提供了一种芯片,该芯片包括可编程逻辑电路和/或程序指令,该芯片运行时用于实现如上述方法实施例提供的方法的全部或部分步骤。An embodiment of the present application provides a chip, which includes a programmable logic circuit and/or program instructions. When the chip is running, it is used to implement all or part of the steps of the method provided in the above method embodiment.
需要说明的是,本申请实施例中所述的“虚拟单元”可以是容器或虚拟机,上述实施例中的“虚拟单元”可以全部替换为“容器”或全部替换为“虚拟机”,替换之后,上述实施例所描述的技术方案仍然成立。It should be noted that the “virtual unit” described in the embodiments of the present application may be a container or a virtual machine, and the “virtual units” in the above embodiments may all be replaced by “containers” or all be replaced by “virtual machines”. After the replacement, the technical solutions described in the above embodiments still hold true.
在上述实施例中,可以全部或部分地通过软件、硬件、固件或者其任意组合来实现。当使用软件实现时,可以全部或部分地以计算机程序产品的形式实现,所述计算机程序产品包括一个或多个计算机指令。在计算机上加载和执行所述计算机程序指令时,全部或部分地产生按照本申请实施例所述的流程或功能。所述计算机可以是通用计算机、计算机网络、或者其他可编程装置。所述计算机指令可以存储在计算机的可读存储介质中,或者从一个计算机可读存储介质向另一个计算机可读存储介质传输,例如,所述计算机指令可以从一个网站站点、计算机、服务器或数据中心通过有线(例如同轴电缆、光纤、数字用户线)或无线(例如红外、无线、微波等)方式向另一个网站站点、计算机、服务器或数据中心传输。所述计算机可读存储介质可以是计算机能够存取的任何可用介质或者包含一个或多个可用介质集成的服务器、数据中心等数据存储装置。所述可用介质可以是磁性介质(例如,软盘、硬盘、磁带)、光介质,或者半导体介质(例如固态硬盘)等。In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented using software, it can be implemented in whole or in part in the form of a computer program product, and the computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the process or function described in the embodiment of the present application is generated in whole or in part. The computer may be a general-purpose computer, a computer network, or other programmable device. The computer instructions may be stored in a computer-readable storage medium, or transmitted from one computer-readable storage medium to another computer-readable storage medium, for example, the computer instructions may be transmitted from a website site, computer, server or data center by wired (e.g., coaxial cable, optical fiber, digital subscriber line) or wireless (e.g., infrared, wireless, microwave, etc.) mode to another website site, computer, server or data center. The computer-readable storage medium may be any available medium that a computer can access or a data storage device such as a server, data center, etc. that contains one or more available media integrated. The available medium may be a magnetic medium (e.g., a floppy disk, a hard disk, a tape), an optical medium, or a semiconductor medium (e.g., a solid-state hard disk), etc.
应当理解的是,本申请中的术语“至少一个”指一个或多个,“多个”指两个或两个以上。本申请中的术语“和/或”仅仅是一种描述关联对象的关联关系,表示可以存在三种关系,例如,A和/或B,可以表示:单独存在A,同时存在A和B,单独存在B这三种情况。另外,为了便于清楚描述,在本申请中,采用了“第一”、“第二”、“第三”等字样对功能和作用基本相同的相同项或相似项进行区分。本领域技术人员可以理解“第一”、“第二”、“第三”等字样并不对数量和执行次序进行限定。It should be understood that the term "at least one" in this application refers to one or more, and "multiple" refers to two or more. The term "and/or" in this application is merely a description of the association relationship of associated objects, indicating that three relationships may exist. For example, A and/or B may represent: A exists alone, A and B exist at the same time, and B exists alone. In addition, in order to facilitate clear description, in this application, the words "first", "second", "third" and the like are used to distinguish between identical or similar items with substantially the same functions and effects. Those skilled in the art will understand that the words "first", "second", "third" and the like do not limit the quantity and execution order.
本申请实施例提供的方法实施例和装置实施例等不同类型的实施例均可以相互参考,本申请实施例对此不做限定。本申请实施例提供的方法实施例操作的先后顺序能够进行适当调整,操作也能够根据情况进行响应增减,任何熟悉本技术领域的技术人员在本申请揭露的技术范围内,可轻易想到变化的方法,都应涵盖在本申请的保护范围之内,因此不再赘述。The different types of embodiments such as the method embodiments and device embodiments provided in the embodiments of the present application can refer to each other, and the embodiments of the present application are not limited thereto. The sequence of operations of the method embodiments provided in the embodiments of the present application can be appropriately adjusted, and the operations can also be increased or decreased in response to the situation. Any technician familiar with the technical field can easily think of the changed methods within the technical scope disclosed in the present application, and they should be included in the protection scope of the present application, so they will not be repeated.
在本申请提供的相应实施例中,应该理解到,所揭露的装置等可以通过其它的构成方式实现。例如,以上所描述的装置实施例仅仅是示意性的,例如,模块的划分仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个模块或组件可以结合或者可以集成到另一个***,或一些特征可以忽略,或不执行。In the corresponding embodiments provided in the present application, it should be understood that the disclosed devices and the like can be implemented by other configuration methods. For example, the device embodiments described above are only illustrative, for example, the division of modules is only a logical function division, and there may be other division methods in actual implementation, for example, multiple modules or components can be combined or integrated into another system, or some features can be ignored or not executed.
作为分离部件说明的模块可以是或者也可以不是物理上分开的,作为模块描述的部件可以是或者也可以不是物理模块,既可以位于一个地方,或者也可以分布到多个设备上。可以根据实际的需要选择其中的部分或者全部模块来实现本实施例方案的目的。The modules described as separate components may or may not be physically separated, and the components described as modules may or may not be physical modules, and may be located in one place or distributed on multiple devices. Some or all of the modules may be selected according to actual needs to achieve the purpose of the present embodiment.
以上所述,仅为本申请的示例性实施方式,但本申请的保护范围并不局限于此,任何熟悉本技术领域的技术人员在本申请揭露的技术范围内,可轻易想到各种等效的修改或替换都应涵盖在本申请的保护范围之内。因此,本申请的保护范围应以权利要求的保护范围为准。 The above is only an exemplary embodiment of the present application, but the protection scope of the present application is not limited thereto. Any technician familiar with the technical field can easily think of various equivalent modifications or replacements within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application shall be based on the protection scope of the claims.

Claims (48)

  1. 一种虚拟单元启动方法,其特征在于,应用于集约化云计算***中的管理平台,所述集约化云计算***还包括第一计算池,所述方法包括:A virtual unit startup method, characterized in that it is applied to a management platform in an intensive cloud computing system, wherein the intensive cloud computing system further includes a first computing pool, and the method includes:
    获取第一应用的启动诉求;Get the startup request of the first application;
    获取目标应用对应的至少一组启动测量信息,所述至少一组启动测量信息对应至少一个启动方案,所述至少一组启动测量信息中的每组启动测量信息用于表征基于对应的启动方案在所述集约化云计算***中启动所述目标应用的启动性能,所述目标应用与所述第一应用匹配;Acquire at least one set of startup measurement information corresponding to the target application, the at least one set of startup measurement information corresponding to at least one startup scheme, each set of startup measurement information in the at least one set of startup measurement information being used to characterize startup performance of the target application in the intensive cloud computing system based on the corresponding startup scheme, and the target application matches the first application;
    根据所述第一应用的启动诉求和所述至少一组启动测量信息确定第一启动方案,所述至少一个启动方案包括所述第一启动方案;Determine a first startup scheme according to the startup demand of the first application and the at least one set of startup measurement information, wherein the at least one startup scheme includes the first startup scheme;
    根据所述第一启动方案在所述第一计算池中启动所述第一应用的第一虚拟单元。A first virtual unit of the first application is started in the first computing pool according to the first starting scheme.
  2. 根据权利要求1所述的方法,其特征在于,所述第一启动方案包括以下任意一个:The method according to claim 1, characterized in that the first startup scheme includes any one of the following:
    基于第一存储池的热启动方案;A hot start solution based on the first storage pool;
    基于所述第一存储池的冷启动方案;A cold start solution based on the first storage pool;
    基于第二计算池的冷启动方案;Cold start solution based on the second computing pool;
    其中,所述第一存储池和所述第二计算池分别与所述第一计算池互联。The first storage pool and the second computing pool are interconnected with the first computing pool respectively.
  3. 根据权利要求2所述的方法,其特征在于,所述第一启动方案包括基于所述第一存储池的热启动方案,所述第一存储池中存储有基准内存快照,所述基准内存快照是对所述第一应用的基准虚拟单元的内存进行快照得到的,所述第一计算池中包括所述第一虚拟单元;The method according to claim 2 is characterized in that the first startup scheme includes a hot startup scheme based on the first storage pool, the first storage pool stores a baseline memory snapshot, the baseline memory snapshot is obtained by taking a snapshot of the memory of the baseline virtual unit of the first application, and the first computing pool includes the first virtual unit;
    所述根据所述第一启动方案在所述第一计算池中启动所述第一应用的第一虚拟单元,包括:根据所述基准内存快照在所述第一计算池中创建第一内存分支,所述第一内存分支用于存储所述第一虚拟单元运行过程中相对于所述基准内存快照发生变化的内存数据。Starting the first virtual unit of the first application in the first computing pool according to the first startup scheme includes: creating a first memory branch in the first computing pool according to the baseline memory snapshot, the first memory branch being used to store memory data that has changed relative to the baseline memory snapshot during the operation of the first virtual unit.
  4. 根据权利要求3所述的方法,其特征在于,所述第一存储池中还存储有基准文件***,所述基准文件***是所述基准虚拟单元的文件***;The method according to claim 3, characterized in that a reference file system is also stored in the first storage pool, and the reference file system is a file system of the reference virtual unit;
    所述根据所述第一启动方案在所述第一计算池中启动所述第一应用的第一虚拟单元,还包括:根据所述基准文件***在所述第一计算池中创建第一读写层,所述第一读写层用于存储所述第一虚拟单元运行过程中相对于所述基准文件***发生变化的文件数据。Starting the first virtual unit of the first application in the first computing pool according to the first startup scheme also includes: creating a first read-write layer in the first computing pool according to the benchmark file system, the first read-write layer being used to store file data that changes relative to the benchmark file system during the operation of the first virtual unit.
  5. 根据权利要求3或4所述的方法,其特征在于,在根据所述第一启动方案在所述第一计算池中启动所述第一虚拟单元之前,所述方法还包括:The method according to claim 3 or 4, characterized in that before starting the first virtual unit in the first computing pool according to the first startup scheme, the method further comprises:
    在所述基准虚拟单元运行的过程中,获取所述基准虚拟单元的所述基准内存快照;During the operation of the benchmark virtual unit, obtaining the benchmark memory snapshot of the benchmark virtual unit;
    将所述基准内存快照存储至所述第一存储池中。The baseline memory snapshot is stored in the first storage pool.
  6. 根据权利要求3至5任一项所述的方法,其特征在于,在根据所述第一启动方案在所述第一计算池中启动所述第一虚拟单元之前,所述方法还包括:The method according to any one of claims 3 to 5, characterized in that before starting the first virtual unit in the first computing pool according to the first startup scheme, the method further comprises:
    根据所述第一应用的应用镜像在所述第一计算池中创建所述第一虚拟单元。The first virtual unit is created in the first computing pool according to the application image of the first application.
  7. 根据权利要求2所述的方法,其特征在于,所述第一启动方案包括基于所述第一存储池的冷启动方案,所述第一存储池中存储有基准单元快照,所述基准单元快照是对所述第一应用的基准虚拟单元进行快照得到的;The method according to claim 2, characterized in that the first startup scheme comprises a cold startup scheme based on the first storage pool, the first storage pool stores a reference unit snapshot, and the reference unit snapshot is obtained by taking a snapshot of the reference virtual unit of the first application;
    所述根据所述第一启动方案在所述第一计算池中启动所述第一应用的第一虚拟单元,包括:根据所述基准单元快照在所述第一计算池中创建并启动所述第一虚拟单元。Starting the first virtual unit of the first application in the first computing pool according to the first starting scheme includes: creating and starting the first virtual unit in the first computing pool according to the benchmark unit snapshot.
  8. 根据权利要求7所述的方法,其特征在于,在根据所述第一启动方案在所述第一计算池中启动所述 第一虚拟单元之前,所述方法还包括:The method according to claim 7, characterized in that, in starting the first computing pool according to the first startup scheme, Before the first virtual unit, the method further comprises:
    在所述基准虚拟单元运行的过程中,获取所述基准虚拟单元的所述基准单元快照;During the operation of the reference virtual unit, obtaining the reference unit snapshot of the reference virtual unit;
    将所述基准单元快照存储至所述第一存储池中。The benchmark unit snapshot is stored in the first storage pool.
  9. 根据权利要求3至8任一项所述的方法,其特征在于,The method according to any one of claims 3 to 8, characterized in that
    所述基准虚拟单元运行在所述第一计算池中。The benchmark virtual unit runs in the first computing pool.
  10. 根据权利要求2所述的方法,其特征在于,所述第一启动方案包括基于所述第二计算池的冷启动方案,所述第二计算池中运行有第二虚拟单元,所述第二虚拟单元的配置与所述第一虚拟单元的配置相同;The method according to claim 2, characterized in that the first startup scheme includes a cold start scheme based on the second computing pool, a second virtual unit runs in the second computing pool, and a configuration of the second virtual unit is the same as a configuration of the first virtual unit;
    所述根据所述第一启动方案在所述第一计算池中启动所述第一应用的第一虚拟单元,包括:根据所述第二虚拟单元在所述第一计算池中创建并启动所述第一虚拟单元。Starting the first virtual unit of the first application in the first computing pool according to the first starting scheme includes: creating and starting the first virtual unit in the first computing pool according to the second virtual unit.
  11. 根据权利要求10所述的方法,其特征在于,根据所述第二虚拟单元启动所述第一虚拟单元,包括:根据所述第二虚拟单元的内存在所述第一计算池中创建第二内存分支,所述第二内存分支用于存储所述第一虚拟单元运行过程中相对于所述第二虚拟单元的内存发生变化的内存数据。The method according to claim 10 is characterized in that starting the first virtual unit according to the second virtual unit includes: creating a second memory branch in the first computing pool according to the memory of the second virtual unit, and the second memory branch is used to store memory data that changes relative to the memory of the second virtual unit during the operation of the first virtual unit.
  12. 根据权利要求10或11所述的方法,其特征在于,根据所述第二虚拟单元启动所述第一虚拟单元,包括:根据所述第二虚拟单元的文件***在所述第一计算池中创建第二读写层,所述第二读写层用于存储所述第一虚拟单元运行过程中相对于所述第二虚拟单元的文件***发生变化的文件数据。The method according to claim 10 or 11 is characterized in that starting the first virtual unit according to the second virtual unit includes: creating a second read-write layer in the first computing pool according to the file system of the second virtual unit, and the second read-write layer is used to store file data that changes relative to the file system of the second virtual unit during the operation of the first virtual unit.
  13. 根据权利要求1至12任一项所述的方法,其特征在于,所述集约化云计算***还包括第一存储池,所述第一存储池与所述第一计算池互联;The method according to any one of claims 1 to 12, characterized in that the intensive cloud computing system further comprises a first storage pool, and the first storage pool is interconnected with the first computing pool;
    所述第一存储池用于存储所述第一应用的以下至少一个信息:The first storage pool is used to store at least one of the following information of the first application:
    所述第一应用的虚拟单元的内存的快照;a snapshot of the memory of the virtual unit of the first application;
    所述第一应用的虚拟单元的快照;a snapshot of a virtual unit of the first application;
    所述第一应用的应用镜像。The application image of the first application.
  14. 根据权利要求13所述的方法,其特征在于,The method according to claim 13, characterized in that
    所述第一应用的所述至少一个信息在所述第一存储池中的存储位置根据所述第一应用的以下至少一个指标确定:重要性、使用频率、启动诉求。The storage location of the at least one information of the first application in the first storage pool is determined according to at least one of the following indicators of the first application: importance, usage frequency, and startup appeal.
  15. 根据权利要求13或14所述的方法,其特征在于,The method according to claim 13 or 14, characterized in that
    所述集约化云计算***还包括镜像仓库,所述镜像仓库用于存储所述应用镜像的指示信息与所述应用镜像在所述第一存储池中的存储位置的对应关系。The intensive cloud computing system further includes an image warehouse, and the image warehouse is used to store the correspondence between the indication information of the application image and the storage location of the application image in the first storage pool.
  16. 根据权利要求13至15任一项所述的方法,其特征在于,The method according to any one of claims 13 to 15, characterized in that
    所述第一存储池包括内存池和外存池中的至少一个。The first storage pool includes at least one of a memory pool and an external memory pool.
  17. 根据权利要求16所述的方法,其特征在于,The method according to claim 16, characterized in that
    所述内存池和所述外存池满足以下至少一项:The memory pool and the external memory pool satisfy at least one of the following:
    所述内存池包括至少两个第一存储介质,所述至少两个第一存储介质的类型不同;The memory pool includes at least two first storage media, and the at least two first storage media are of different types;
    所述外存池包括至少两个第二存储介质,所述至少两个第二存储介质的类型不同;The external storage pool includes at least two second storage media, and the at least two second storage media are of different types;
    其中,所述第一存储介质和所述第二存储介质分别基于差分算法存储数据。The first storage medium and the second storage medium store data based on a differential algorithm respectively.
  18. 根据权利要求1至17任一项所述的方法,其特征在于,The method according to any one of claims 1 to 17, characterized in that
    所述目标应用与所述第一应用匹配包括以下至少一项:The target application matches the first application, including at least one of the following:
    所述目标应用是所述第一应用; The target application is the first application;
    所述目标应用的规模与所述第一应用的规模匹配;The scale of the target application matches the scale of the first application;
    所述目标应用的应用镜像的大小与所述第一应用的应用镜像的大小匹配;The size of the application image of the target application matches the size of the application image of the first application;
    所述目标应用的类型与所述第一应用的类型匹配。The type of the target application matches the type of the first application.
  19. 根据权利要求1至18任一项所述的方法,其特征在于,The method according to any one of claims 1 to 18, characterized in that
    所述启动诉求包括启动时长诉求和启动成本诉求中的至少一个;The startup demands include at least one of a startup time demand and a startup cost demand;
    所述启动测量信息包括测量启动时长和测量启动成本中的至少一个。The startup measurement information includes at least one of a measured startup duration and a measured startup cost.
  20. 根据权利要求1至19任一项所述的方法,其特征在于,所述获取目标应用对应的至少一组启动测量信息,包括:根据所述至少一个启动方案中的每个启动方案在所述集约化云计算***中对所述目标应用进行启动测试,得到所述每个启动方案对应的一组启动测量信息。The method according to any one of claims 1 to 19 is characterized in that the obtaining of at least one set of startup measurement information corresponding to the target application comprises: performing a startup test on the target application in the intensive cloud computing system according to each startup scheme in the at least one startup scheme to obtain a set of startup measurement information corresponding to each startup scheme.
  21. 根据权利要求1至20任一项所述的方法,其特征在于,The method according to any one of claims 1 to 20, characterized in that
    所述管理平台部署在所述第一计算池中。The management platform is deployed in the first computing pool.
  22. 根据权利要求1至21任一项所述的方法,其特征在于,The method according to any one of claims 1 to 21, characterized in that
    所述第一虚拟单元是容器或虚拟机。The first virtual unit is a container or a virtual machine.
  23. 一种虚拟单元启动装置,其特征在于,应用于集约化云计算***中的管理平台,所述集约化云计算***还包括第一计算池,所述装置包括:A virtual unit startup device, characterized in that it is applied to a management platform in an intensive cloud computing system, wherein the intensive cloud computing system further includes a first computing pool, and the device includes:
    获取模块,用于获取第一应用的启动诉求,以及,获取目标应用对应的至少一组启动测量信息,所述至少一组启动测量信息对应至少一个启动方案,所述至少一组启动测量信息中的每组启动测量信息用于表征基于对应的启动方案在所述集约化云计算***中启动所述目标应用的启动性能,所述目标应用与所述第一应用匹配;an acquisition module, configured to acquire a startup demand of a first application, and to acquire at least one set of startup measurement information corresponding to a target application, wherein the at least one set of startup measurement information corresponds to at least one startup scheme, and each set of startup measurement information in the at least one set of startup measurement information is used to characterize startup performance of the target application in the intensive cloud computing system based on the corresponding startup scheme, and the target application matches the first application;
    确定模块,用于根据所述第一应用的启动诉求和所述至少一组启动测量信息确定第一启动方案,所述至少一个启动方案包括所述第一启动方案;a determining module, configured to determine a first startup scheme according to the startup demand of the first application and the at least one set of startup measurement information, wherein the at least one startup scheme includes the first startup scheme;
    启动模块,用于根据所述第一启动方案在所述第一计算池中启动所述第一应用的第一虚拟单元。A startup module is used to start the first virtual unit of the first application in the first computing pool according to the first startup scheme.
  24. 根据权利要求23所述的装置,其特征在于,所述第一启动方案包括以下任意一个:The device according to claim 23, characterized in that the first startup scheme includes any one of the following:
    基于第一存储池的热启动方案;A hot start solution based on the first storage pool;
    基于所述第一存储池的冷启动方案;A cold start solution based on the first storage pool;
    基于第二计算池的冷启动方案;Cold start solution based on the second computing pool;
    其中,所述第一存储池和所述第二计算池分别与所述第一计算池互联。The first storage pool and the second computing pool are interconnected with the first computing pool respectively.
  25. 根据权利要求24所述的装置,其特征在于,所述第一启动方案包括基于所述第一存储池的热启动方案,所述第一存储池中存储有基准内存快照,所述基准内存快照是对所述第一应用的基准虚拟单元的内存进行快照得到的,所述第一计算池中包括所述第一虚拟单元;The device according to claim 24, characterized in that the first startup scheme includes a hot startup scheme based on the first storage pool, the first storage pool stores a baseline memory snapshot, the baseline memory snapshot is obtained by taking a snapshot of the memory of the baseline virtual unit of the first application, and the first computing pool includes the first virtual unit;
    所述启动模块,用于根据所述基准内存快照在所述第一计算池中创建第一内存分支,所述第一内存分支用于存储所述第一虚拟单元运行过程中相对于所述基准内存快照发生变化的内存数据。The startup module is used to create a first memory branch in the first computing pool according to the baseline memory snapshot, and the first memory branch is used to store memory data that has changed relative to the baseline memory snapshot during the operation of the first virtual unit.
  26. 根据权利要求25所述的装置,其特征在于,所述第一存储池中还存储有基准文件***,所述基准文件***是所述基准虚拟单元的文件***;所述启动模块,还用于根据所述基准文件***在所述第一计算池中创建第一读写层,所述第一读写层用于存储所述第一虚拟单元运行过程中相对于所述基准文件***发生变化的文件数据。The device according to claim 25 is characterized in that a benchmark file system is also stored in the first storage pool, and the benchmark file system is the file system of the benchmark virtual unit; the startup module is also used to create a first read-write layer in the first computing pool according to the benchmark file system, and the first read-write layer is used to store file data that changes relative to the benchmark file system during the operation of the first virtual unit.
  27. 根据权利要求25或26所述的装置,其特征在于,The device according to claim 25 or 26, characterized in that
    所述获取模块,还用于在所述启动模块根据所述第一启动方案在所述第一计算池中启动所述第一虚拟 单元之前,在所述基准虚拟单元运行的过程中,获取所述基准虚拟单元的所述基准内存快照;The acquisition module is further configured to start the first virtual machine in the first computing pool according to the first startup scheme in the startup module. unit, obtaining the benchmark memory snapshot of the benchmark virtual unit during the operation of the benchmark virtual unit;
    所述装置还包括:存储模块,用于将所述基准内存快照存储至所述第一存储池中。The device further includes: a storage module, configured to store the baseline memory snapshot in the first storage pool.
  28. 根据权利要求25至27任一项所述的装置,其特征在于,所述装置还包括:The device according to any one of claims 25 to 27, characterized in that the device further comprises:
    创建模块,用于在所述启动模块根据所述第一启动方案在所述第一计算池中启动所述第一虚拟单元之前,根据所述第一应用的应用镜像在所述第一计算池中创建所述第一虚拟单元。A creation module is used to create the first virtual unit in the first computing pool according to the application image of the first application before the startup module starts the first virtual unit in the first computing pool according to the first startup scheme.
  29. 根据权利要求24所述的装置,其特征在于,所述第一启动方案包括基于所述第一存储池的冷启动方案,所述第一存储池中存储有基准单元快照,所述基准单元快照是对所述第一应用的基准虚拟单元进行快照得到的;所述启动模块,用于根据所述基准单元快照在所述第一计算池中创建并启动所述第一虚拟单元。The device according to claim 24 is characterized in that the first startup scheme includes a cold start scheme based on the first storage pool, a baseline unit snapshot is stored in the first storage pool, and the baseline unit snapshot is obtained by taking a snapshot of the baseline virtual unit of the first application; the startup module is used to create and start the first virtual unit in the first computing pool according to the baseline unit snapshot.
  30. 根据权利要求29所述的装置,其特征在于,The device according to claim 29, characterized in that
    所述获取模块,还用于在所述启动模块根据所述第一启动方案在所述第一计算池中启动所述第一虚拟单元之前,在所述基准虚拟单元运行的过程中,获取所述基准虚拟单元的所述基准单元快照;The acquisition module is further configured to acquire the reference unit snapshot of the reference virtual unit during the operation of the reference virtual unit before the startup module starts the first virtual unit in the first computing pool according to the first startup scheme;
    所述装置还包括:存储模块,用于将所述基准单元快照存储至所述第一存储池中。The device further includes: a storage module, configured to store the benchmark unit snapshot in the first storage pool.
  31. 根据权利要求25至30任一项所述的装置,其特征在于,The device according to any one of claims 25 to 30, characterized in that
    所述基准虚拟单元运行在所述第一计算池中。The benchmark virtual unit runs in the first computing pool.
  32. 根据权利要求24所述的装置,其特征在于,所述第一启动方案包括基于所述第二计算池的冷启动方案,所述第二计算池中运行有第二虚拟单元,所述第二虚拟单元的配置与所述第一虚拟单元的配置相同;所述启动模块,用于根据所述第二虚拟单元在所述第一计算池中创建并启动所述第一虚拟单元。The device according to claim 24 is characterized in that the first startup scheme includes a cold start scheme based on the second computing pool, a second virtual unit runs in the second computing pool, and the configuration of the second virtual unit is the same as the configuration of the first virtual unit; the startup module is used to create and start the first virtual unit in the first computing pool according to the second virtual unit.
  33. 根据权利要求32所述的装置,其特征在于,所述启动模块,用于根据所述第二虚拟单元的内存在所述第一计算池中创建第二内存分支,所述第二内存分支用于存储所述第一虚拟单元运行过程中相对于所述第二虚拟单元的内存发生变化的内存数据。The device according to claim 32 is characterized in that the startup module is used to create a second memory branch in the first computing pool according to the memory of the second virtual unit, and the second memory branch is used to store memory data that changes relative to the memory of the second virtual unit during the operation of the first virtual unit.
  34. 根据权利要求32或33所述的装置,其特征在于,所述启动模块,用于根据所述第二虚拟单元的文件***在所述第一计算池中创建第二读写层,所述第二读写层用于存储所述第一虚拟单元运行过程中相对于所述第二虚拟单元的文件***发生变化的文件数据。The device according to claim 32 or 33 is characterized in that the startup module is used to create a second read-write layer in the first computing pool according to the file system of the second virtual unit, and the second read-write layer is used to store file data that changes relative to the file system of the second virtual unit during the operation of the first virtual unit.
  35. 根据权利要求23至34任一项所述的装置,其特征在于,所述集约化云计算***还包括第一存储池,所述第一存储池与所述第一计算池互联;The device according to any one of claims 23 to 34, characterized in that the intensive cloud computing system further comprises a first storage pool, and the first storage pool is interconnected with the first computing pool;
    所述第一存储池用于存储所述第一应用的以下至少一个信息:The first storage pool is used to store at least one of the following information of the first application:
    所述第一应用的虚拟单元的内存的快照;a snapshot of the memory of the virtual unit of the first application;
    所述第一应用的虚拟单元的快照;a snapshot of a virtual unit of the first application;
    所述第一应用的应用镜像。The application image of the first application.
  36. 根据权利要求35所述的装置,其特征在于,The device according to claim 35, characterized in that
    所述第一应用的所述至少一个信息在所述第一存储池中的存储位置根据所述第一应用的以下至少一个指标确定:重要性、使用频率、启动诉求。The storage location of the at least one information of the first application in the first storage pool is determined according to at least one of the following indicators of the first application: importance, usage frequency, and startup appeal.
  37. 根据权利要求35或36所述的装置,其特征在于,The device according to claim 35 or 36, characterized in that
    所述集约化云计算***还包括镜像仓库,所述镜像仓库用于存储所述应用镜像的指示信息与所述应用镜像在所述第一存储池中的存储位置的对应关系。 The intensive cloud computing system further includes an image warehouse, and the image warehouse is used to store the correspondence between the indication information of the application image and the storage location of the application image in the first storage pool.
  38. 根据权利要求35至37任一项所述的装置,其特征在于,The device according to any one of claims 35 to 37, characterized in that
    所述第一存储池包括内存池和外存池中的至少一个。The first storage pool includes at least one of a memory pool and an external memory pool.
  39. 根据权利要求38所述的装置,其特征在于,The device according to claim 38, characterized in that
    所述内存池和所述外存池满足以下至少一项:The memory pool and the external memory pool satisfy at least one of the following:
    所述内存池包括至少两个第一存储介质,所述至少两个第一存储介质的类型不同;The memory pool includes at least two first storage media, and the at least two first storage media are of different types;
    所述外存池包括至少两个第二存储介质,所述至少两个第二存储介质的类型不同;The external storage pool includes at least two second storage media, and the at least two second storage media are of different types;
    其中,所述第一存储介质和所述第二存储介质分别基于差分算法存储数据。The first storage medium and the second storage medium store data based on a differential algorithm respectively.
  40. 根据权利要求23至39任一项所述的装置,其特征在于,The device according to any one of claims 23 to 39, characterized in that
    所述目标应用与所述第一应用匹配包括以下至少一项:The target application matches the first application, including at least one of the following:
    所述目标应用是所述第一应用;The target application is the first application;
    所述目标应用的规模与所述第一应用的规模匹配;The scale of the target application matches the scale of the first application;
    所述目标应用的应用镜像的大小与所述第一应用的应用镜像的大小匹配;The size of the application image of the target application matches the size of the application image of the first application;
    所述目标应用的类型与所述第一应用的类型匹配。The type of the target application matches the type of the first application.
  41. 根据权利要求23至40任一项所述的装置,其特征在于,The device according to any one of claims 23 to 40, characterized in that
    所述启动诉求包括启动时长诉求和启动成本诉求中的至少一个;The startup demands include at least one of a startup time demand and a startup cost demand;
    所述启动测量信息包括测量启动时长和测量启动成本中的至少一个。The startup measurement information includes at least one of a measured startup duration and a measured startup cost.
  42. 根据权利要求23至41任一项所述的装置,其特征在于,所述获取模块,用于根据所述至少一个启动方案中的每个启动方案在所述集约化云计算***中对所述目标应用进行启动测试,得到所述每个启动方案对应的一组启动测量信息。The device according to any one of claims 23 to 41 is characterized in that the acquisition module is used to perform a startup test on the target application in the intensive cloud computing system according to each startup scheme of the at least one startup scheme to obtain a set of startup measurement information corresponding to each startup scheme.
  43. 根据权利要求23至42任一项所述的装置,其特征在于,The device according to any one of claims 23 to 42, characterized in that
    所述管理平台部署在所述第一计算池中。The management platform is deployed in the first computing pool.
  44. 根据权利要求23至43任一项所述的装置,其特征在于,The device according to any one of claims 23 to 43, characterized in that
    所述第一虚拟单元是容器或虚拟机。The first virtual unit is a container or a virtual machine.
  45. 一种虚拟单元启动装置,其特征在于,包括存储器和处理器;A virtual unit startup device, characterized by comprising a memory and a processor;
    所述存储器用于存储计算机程序;The memory is used to store computer programs;
    所述处理器用于执行所述存储器中存储的计算机程序以使得所述虚拟单元启动装置执行如权利要求1至22任一项所述的方法。The processor is configured to execute the computer program stored in the memory so that the virtual unit startup device executes the method according to any one of claims 1 to 22.
  46. 一种云计算***,其特征在于,包括计算池和存储池,所述存储池与所述计算池互联,所述计算池包括如权利要求23至45任一项所述的虚拟单元启动装置。A cloud computing system, characterized in that it includes a computing pool and a storage pool, the storage pool is interconnected with the computing pool, and the computing pool includes a virtual unit startup device as described in any one of claims 23 to 45.
  47. 一种计算机可读存储介质,其特征在于,所述计算机可读存储介质中存储有计算机程序,所述计算机程序被执行时实现如权利要求1至22任一项所述的方法。A computer-readable storage medium, characterized in that a computer program is stored in the computer-readable storage medium, and when the computer program is executed, the method according to any one of claims 1 to 22 is implemented.
  48. 一种计算机程序产品,其特征在于,所述计算机程序产品包括程序或代码,所述程序或代码被执行时实现如权利要求1至22任一项所述的方法。 A computer program product, characterized in that the computer program product comprises a program or code, and when the program or code is executed, it implements the method according to any one of claims 1 to 22.
PCT/CN2023/141129 2022-12-23 2023-12-22 Virtual unit startup method and device, and cloud computing system WO2024131959A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202211663651.X 2022-12-23
CN202310340580.8 2023-03-31

Publications (1)

Publication Number Publication Date
WO2024131959A1 true WO2024131959A1 (en) 2024-06-27

Family

ID=

Similar Documents

Publication Publication Date Title
US20110078681A1 (en) Method and system for running virtual machine image
US20130091183A1 (en) Volume Management
US20120011513A1 (en) Implementing a versioned virtualized application runtime environment
AU2016247150B2 (en) Data defined infrastructure
US20180189311A1 (en) File system warnings for moves of shared content items
US20200320189A1 (en) Processing method for container security policy and related apparatus
US10992746B2 (en) Automatic system response to external field-replaceable unit (FRU) process
US11500822B2 (en) Virtualized append-only interface
US9442860B2 (en) Providing record level sharing (RLS) to individual catalogs
US11681653B2 (en) Namespace representation and enhanced browsability for replicated file systems
US20220138023A1 (en) Managing alert messages for applications and access permissions
WO2021226822A1 (en) Log write method and apparatus, electronic device, and storage medium
WO2024131959A1 (en) Virtual unit startup method and device, and cloud computing system
US10831794B2 (en) Dynamic alternate keys for use in file systems utilizing a keyed index
WO2021232860A1 (en) Communication method, apparatus and system
CN113553314A (en) Service processing method, device, equipment and medium of super-convergence system
CN118277025A (en) Virtual unit starting method and device and cloud computing system
US9348859B2 (en) Providing record-level sharing (RLS) to local data sets
US12020053B2 (en) Exposing untrusted devices to virtual machines
WO2024067479A1 (en) Container escape detection method, electronic device, and system
CN113254415B (en) Method and device for processing read request of distributed file system
US20220308909A1 (en) Exposing untrusted devices to virtual machines
US11971848B2 (en) Efficient transparent switchover of file system consolidation migrations
US11709665B2 (en) Hybrid approach to performing a lazy pull of container images
US11385816B2 (en) Systems and methods for implementing improved links between paths of one or more file systems