CN116126460A - Virtual machine creation method and device - Google Patents

Virtual machine creation method and device Download PDF

Info

Publication number
CN116126460A
CN116126460A CN202211622170.4A CN202211622170A CN116126460A CN 116126460 A CN116126460 A CN 116126460A CN 202211622170 A CN202211622170 A CN 202211622170A CN 116126460 A CN116126460 A CN 116126460A
Authority
CN
China
Prior art keywords
data
virtual machine
stored
creation
database
Prior art date
Legal status (The legal status 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 status listed.)
Pending
Application number
CN202211622170.4A
Other languages
Chinese (zh)
Inventor
王强
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
China United Network Communications Group Co Ltd
Unicom Digital Technology Co Ltd
Unicom Cloud Data Co Ltd
Original Assignee
China United Network Communications Group Co Ltd
Unicom Digital Technology Co Ltd
Unicom Cloud Data Co Ltd
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 China United Network Communications Group Co Ltd, Unicom Digital Technology Co Ltd, Unicom Cloud Data Co Ltd filed Critical China United Network Communications Group Co Ltd
Priority to CN202211622170.4A priority Critical patent/CN116126460A/en
Publication of CN116126460A publication Critical patent/CN116126460A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/455Emulation; Interpretation; Software simulation, e.g. virtualisation or emulation of application or operating system execution engines
    • G06F9/45533Hypervisors; Virtual machine monitors
    • G06F9/45558Hypervisor-specific management and integration aspects
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/23Updating
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/25Integrating or interfacing systems involving database management systems
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/455Emulation; Interpretation; Software simulation, e.g. virtualisation or emulation of application or operating system execution engines
    • G06F9/45533Hypervisors; Virtual machine monitors
    • G06F9/45558Hypervisor-specific management and integration aspects
    • G06F2009/45562Creating, deleting, cloning virtual machine instances
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Software Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Databases & Information Systems (AREA)
  • Data Mining & Analysis (AREA)
  • Testing And Monitoring For Control Systems (AREA)

Abstract

The application provides a virtual machine creation method and device, relates to the technical field of virtual machines, and can effectively reduce operation and maintenance cost. The method comprises the following steps: obtaining storage data based on input data input by a user and used for creating a target virtual machine; after the storage data are determined to be stored in the database, extracting the execution parameters corresponding to the target virtual machine through the controller; and finally, creating the target virtual machine through an executor based on the execution parameters and the stored data. The embodiment of the application is used in the virtual machine creation process.

Description

Virtual machine creation method and device
Technical Field
The present disclosure relates to the field of virtual machines, and in particular, to a method and apparatus for creating a virtual machine.
Background
With the development of cloud computing technology, cloud native technology represented by containers and k8s is supported and trusted by more and more users. k8s supports cluster extension scheduling virtual machine resources to extend team-capable, fast containerized applications that have relied on virtual machine-based workloads and to avail themselves of k8s virtualized resources.
At present, although virtual machines can be created in k8s clusters by using kubevirt, virtlet, harvester and the like, part of the services still cannot be containerized, and therefore cannot be migrated into k8s by using kubeevirt. This results in the case where k8s coexist with the virtualization platform, which in turn leads to an increase in the operation and maintenance costs.
Disclosure of Invention
The application provides a virtual machine creation method and device, which can effectively reduce operation and maintenance cost.
In order to achieve the above purpose, the present application adopts the following technical scheme:
in a first aspect, the present application provides a virtual machine creation method, including:
based on input data input by a user for creating a target virtual machine, storage data is obtained.
After the storage data are determined to be stored in the database, the execution parameters corresponding to the target virtual machine are extracted through the controller.
Based on the execution parameters and the stored data, a target virtual machine is created by the executor.
Based on the technical scheme, the virtual machine creation method provided by the application can obtain storage data based on input data input by a user for creating a target virtual machine; after the storage data are determined to be stored in the database, extracting the execution parameters corresponding to the target virtual machine through the controller; and finally, creating the target virtual machine through an executor based on the execution parameters and the stored data. By the method, a virtual machine can be created in the k8s cluster aiming at any service, so that the coexistence of k8s and a virtualization platform can be effectively avoided, and the operation and maintenance cost is effectively reduced.
Optionally, based on input data input by a user for creating the target virtual machine, obtaining the storage data includes:
and acquiring a verification rule and a data format corresponding to the stored input data according to the character which is contained in the input data used for creating the target virtual machine and used for identifying the virtual machine type of the target virtual machine and is input by the user.
And responding to the input data to accord with the verification rule, and carrying out data conversion on the input data through a parser according to the data format to obtain the storage data.
Optionally, the stored data is determined to be stored in the database by:
after detecting that the data stored in the database is subjected to data updating operation, the controller determines that the stored data is stored in the database; or alternatively, the first and second heat exchangers may be,
after receiving the data update notification sent by the database through the controller, determining to store the data in the database.
Optionally, creating, by the executor, the target virtual machine based on the execution parameters and the stored data includes:
and modifying the stored data according to the execution parameters to obtain the created data.
Sending a creation request to an executor through a controller; the creation request includes execution parameters and creation data.
After receiving the creation request through the executor, a target virtual machine is created based on the execution parameters and the creation data.
Optionally, after creating the target virtual machine based on the execution parameters and the creation data, the method further includes:
and updating the storage data stored in the database according to the creation data to obtain updated storage data.
In a second aspect, the present application provides a virtual machine creation apparatus, the apparatus including:
and the processing unit is used for obtaining storage data based on input data input by a user and used for creating the target virtual machine.
And the extraction unit is used for extracting the execution parameters corresponding to the target virtual machine through the controller after the storage data are determined to be stored in the database.
And the creation unit is used for creating the target virtual machine through the executor based on the execution parameters and the storage data.
Optionally, the processing unit is specifically configured to:
and acquiring a verification rule and a data format corresponding to the stored input data according to the character which is contained in the input data used for creating the target virtual machine and used for identifying the virtual machine type of the target virtual machine and is input by the user.
And responding to the input data to accord with the verification rule, and carrying out data conversion on the input data through a parser according to the data format to obtain the storage data.
Optionally, the stored data is determined to be stored in the database by:
after detecting that the data stored in the database is subjected to data updating operation, the controller determines that the stored data is stored in the database; or alternatively, the first and second heat exchangers may be,
after receiving the data update notification sent by the database through the controller, determining to store the data in the database.
Optionally, the creating unit is specifically configured to:
and modifying the stored data according to the execution parameters to obtain the created data.
Sending a creation request to an executor through a controller; the creation request includes execution parameters and creation data.
After receiving the creation request through the executor, a target virtual machine is created based on the execution parameters and the creation data.
Optionally, after the creation of the unit, the apparatus further comprises an updating unit, the updating unit being specifically configured to:
and updating the storage data stored in the database according to the creation data to obtain updated storage data.
In a third aspect, the present application provides a virtual machine creation apparatus, including: a processor and a communication interface; the communication interface is coupled to a processor for running a computer program or instructions to implement the virtual machine creation method as described in the first aspect and any one of the possible implementations of the first aspect.
In a fourth aspect, the present application provides a computer readable storage medium having instructions stored therein which, when run on a terminal, cause the terminal to perform a virtual machine creation method as described in any one of the possible implementations of the first aspect and the first aspect.
In a fifth aspect, embodiments of the present application provide a computer program product comprising instructions that, when run on a virtual machine creation means, cause the virtual machine creation means to perform the virtual machine creation method as described in any of the possible implementations of the first aspect and the first aspect.
In a sixth aspect, embodiments of the present application provide a chip comprising a processor and a communication interface, the communication interface and the processor being coupled, the processor being configured to execute a computer program or instructions to implement a virtual machine creation method as described in any of the possible implementations of the first aspect and the first aspect.
Specifically, the chip provided in the embodiments of the present application further includes a memory, configured to store a computer program or instructions.
Drawings
Fig. 1 is a architecture diagram of a virtual machine creation method provided in an embodiment of the present application;
fig. 2 is a flowchart of a virtual machine creation method provided in an embodiment of the present application;
FIG. 3 is a flowchart of another virtual machine creation method according to an embodiment of the present application;
fig. 4 is a schematic structural diagram of a virtual machine creating apparatus according to an embodiment of the present application;
fig. 5 is a schematic structural diagram of another virtual machine creating apparatus according to an embodiment of the present application.
Detailed Description
The following describes in detail a virtual machine creation method and apparatus provided in an embodiment of the present application with reference to the accompanying drawings.
The term "and/or" is herein merely an association relationship describing an associated object, meaning that there may be three relationships, e.g., a and/or B, may represent: a exists alone, A and B exist together, and B exists alone.
The terms "first" and "second" and the like in the description and in the drawings are used for distinguishing between different objects or for distinguishing between different processes of the same object and not for describing a particular sequential order of objects.
Furthermore, references to the terms "comprising" and "having" and any variations thereof in the description of the present application are intended to cover a non-exclusive inclusion. For example, a process, method, system, article, or apparatus that comprises a list of steps or elements is not limited to only those listed but may optionally include other steps or elements not listed or inherent to such process, method, article, or apparatus.
It should be noted that, in the embodiments of the present application, words such as "exemplary" or "such as" are used to mean serving as an example, instance, or illustration. Any embodiment or design described herein as "exemplary" or "for example" should not be construed as preferred or advantageous over other embodiments or designs. Rather, the use of words such as "exemplary" or "such as" is intended to present related concepts in a concrete fashion.
Some of the terms in the embodiments of the present application are explained below to facilitate understanding by those skilled in the art:
1、K8s:
k8s, collectively known as Kubernetes, is an abbreviation that replaces the 8 characters "ubennee" with 8. Is an open source for managing containerized applications on multiple hosts in a cloud platform, and the goal of Kubernetes is to make deploying containerized applications simple and efficient, kubernetes provides a mechanism for application deployment, planning, updating, and maintenance.
2. Cluster
A cluster is a computer system that is connected by a loosely-integrated set of computer software and/or hardware to perform computing work in a highly-tight, coordinated manner. Individual computers in a clustered computer system are often referred to as nodes, and the individual nodes are typically connected by a local area network, although other connection arrangements are possible. Clustered computer systems are commonly used to improve the computational speed and/or reliability of individual computers.
3. Metadata
Metadata, also called intermediate data and relay data, is data describing data, mainly describing data attribute information, and is used to support functions such as indicating storage location, history data, resource searching, file recording, etc.
Fig. 1 is a schematic diagram of a virtual machine creation method according to an embodiment of the present application, where, as shown in fig. 1, the schematic diagram may include a parser 101, a controller 102, an executor 103, a data synchronizer 104, and a database 105.
Wherein the parser 101 may format-convert input data input by a user for creating a target virtual machine. The controller 102 may also be an orchestration controller, where the controller 102 may detect data stored in the database, and may extract execution parameters corresponding to the target virtual machine according to a virtual machine type corresponding to stored data stored in the database for creating the target virtual machine. The executor 103 may create a target virtual machine based on the execution parameters and the stored data. The data synchronizer 104 may update the data already stored in the database. Database 105 may be used to store data.
Specifically, after receiving input data for creating a target virtual machine input by a user, the parser 101 may perform data conversion on the input data after the input data conforms to a verification rule, to obtain stored data; and stores the stored data into database 105. After determining that the stored data is stored in the database, the controller 102 may extract the type of the executor and the corresponding execution parameters corresponding to the target virtual machine, and send a creation request to the executor 103, where after receiving the creation request, the executor 103 may create the target virtual machine according to the data carried in the creation request. After the target virtual machine is created, the controller 102 may invoke the data synchronizer 104 to synchronize the creation data of the creation target virtual machine into the database 105.
With the development of cloud computing technology, cloud native technology represented by containers and k8s is supported and trusted by more and more users. k8s supports cluster extension scheduling virtual machine resources to extend team-capable, fast containerized applications that have relied on virtual machine-based workloads and to avail themselves of k8s virtualized resources. At present, although virtual machines can be created in k8s clusters by using kubevirt, virtlet, harvester and the like, part of the services still cannot be containerized, and therefore cannot be migrated into k8s by using kubeevirt. This results in the case where k8s coexist with the virtualization platform, which in turn leads to an increase in the operation and maintenance costs.
In order to solve the technical problem, the application provides a virtual machine creation method, which can obtain storage data based on input data input by a user for creating a target virtual machine; after the storage data are determined to be stored in the database, extracting the execution parameters corresponding to the target virtual machine through the controller; and finally, creating the target virtual machine through an executor based on the execution parameters and the stored data. By the method, a virtual machine can be created in the k8s cluster aiming at any service, so that the coexistence of k8s and a virtualization platform can be effectively avoided, and the operation and maintenance cost is effectively reduced.
Fig. 2 is a flowchart of a virtual machine creation method according to an embodiment of the present application, as shown in fig. 2, where the method includes the following steps:
step S201, based on input data for creating the target virtual machine input by the user, storage data is obtained.
Specifically, after receiving input data input by a user and used for creating a target virtual machine, according to characters contained in the input data input by the user and used for identifying the type of the virtual machine of the target virtual machine, a corresponding check rule and a corresponding data format when the input data are stored can be obtained; if the input data is determined to accord with the verification rule, according to the data format, carrying out data conversion on the input data through a parser to obtain storage data.
In the embodiment of the present application, the parser may include, but is not limited to, an apiServer parser, which is not limited in this application.
In the embodiment of the present application, when the input data of the target virtual machine is stored, the corresponding verification rule and the data format may be stored in the K8s cluster in advance.
In this embodiment of the present application, the virtual machine type may be a vmware type, an OpenStack type, or other virtual machine types corresponding to various cloud vendors, which is not limited in this application.
Step S202, after determining that the stored data are stored in the database, extracting the execution parameters corresponding to the target virtual machine through the controller.
After the storage data is obtained in step S201, the storage data may be stored in the database, and after it is determined that the storage data is stored in the database, the controller may obtain the execution parameters corresponding to the target virtual machine based on the character for identifying the virtual machine type of the target virtual machine included in the storage data.
In the present embodiment, the database may include, but is not limited to, an etcd database, which is not limited in this application.
In embodiments of the present application, the controller may include, but is not limited to, a crd controller, which is not limited in this application.
Step S203, creating, by the executor, a target virtual machine based on the execution parameters and the stored data.
After determining the execution parameters and the storage data according to step S201 and step S202, the target virtual machine may be created by an executor.
By the method, corresponding virtual machines can be created in the k8s cluster aiming at any service, so that the coexistence of k8s and a virtualization platform can be effectively avoided, and the operation and maintenance cost is effectively reduced.
Fig. 3 is a flowchart of another virtual machine creation method according to an embodiment of the present application, as shown in fig. 3, where the method includes the following steps:
step S301, according to characters which are contained in input data which are input by a user and used for creating a target virtual machine and used for identifying the type of the virtual machine of the target virtual machine, a check rule and a data format which correspond to the stored input data are obtained.
Illustratively, in one embodiment, assuming that the user intends to create a vm type virtual machine, the user needs to input a CR (Custom Resource) object, i.e., input data, corresponding to the virtual machine for creating the vm type virtual machine, where the input data may include data such as a virtual machine name, a CPU (Central Processing Unit) size, a memory size, and a provider string. Wherein the provider string may be used to identify the virtual machine type of the target virtual machine.
After receiving input data input by a user and used for creating a target virtual machine, the virtual machine type of the target virtual machine can be determined according to a provider character string (namely, a character used for identifying the virtual machine type of the target virtual machine) contained in the input data, and then a verification rule and a data format corresponding to the stored input data are obtained from metadata corresponding to the virtual machine type of the target virtual machine stored in advance.
In the embodiment of the present application, metadata corresponding to different virtual machine types may be stored in a configmap form into a K8s cluster, which is not limited in this application.
Step S302, if the input data is determined to be in accordance with the verification rule, the data is converted by the parser according to the data format, so as to obtain the stored data.
After the verification rule and the data format corresponding to the stored input data are obtained in step S301, the input data can be verified according to the verification rule, and after the verification is passed, the input data are converted by a parser according to the data format, so as to obtain the stored data.
For example, assuming that the target virtual machine is a vmware type virtual machine, if the obtained verification rule corresponding to the input data of the virtual machine storing the vmware type is that the character length contained in the virtual machine name is greater than 8, the input data can be verified according to the verification rule, and if the input data is determined to conform to the verification rule, the data conversion is performed on the input data through a parser according to the data format corresponding to the input data of the virtual machine storing the vmware type, so as to obtain the stored data.
In one embodiment, the name of the vmware type virtual machine input by the user is assumed to be asdfghasd and is larger than 8 characters, so that according to a data format corresponding to input data of the vmware type virtual machine, the input data can be subjected to data conversion through a parser to obtain storage data.
In another embodiment, assuming that the vmware type virtual machine name input by the user is as, less than 8 characters, the verification rule is not met, so verification failure information may be returned to enable the user to reenter the corresponding input data.
Step S303, after determining that the stored data is stored in the database, extracting the execution parameters corresponding to the target virtual machine through the controller.
In an alternative embodiment, the storage of the stored data into the database may be determined by:
mode one: after detecting that the data stored in the database is subjected to data updating operation, the controller determines that the stored data is stored in the database;
mode two: after receiving the data update notification sent by the database through the controller, determining to store the data in the database.
After the stored data is determined to be stored in the database in any mode, the execution parameters corresponding to the target virtual machine can be extracted through the controller.
In an embodiment, assuming that the target virtual machine is a vmware type virtual machine, the character for identifying the virtual machine type of the target virtual machine is a provider string, the controller may determine the virtual machine type (vmware type) of the target virtual machine according to the provider string included in the stored data, and then obtain, from metadata corresponding to the pre-stored vmware type virtual machine, an actuator type corresponding to the vmware type virtual machine and a corresponding execution parameter.
In the embodiment of the present application, the actuator type may be an http type or a shell type, which is not limited in this application.
In the embodiment of the present application, the execution parameters may include url (uniform resource locator ) parameters, or may include body parameters, which is not limited in this application.
Step S304, the stored data is modified according to the execution parameters to obtain the created data.
After the execution parameters corresponding to the target virtual machine are extracted in step S303, the stored data may be modified based on the execution parameters, so as to obtain modified stored data, and the modified stored data is used as the creation data.
For example, in one embodiment, assuming that the target virtual machine is a vmware type virtual machine, in step S303, the body parameter included in the execution parameter corresponding to the vmware type virtual machine (target virtual machine) is extracted to include information such as a virtual machine name, a CPU size, and a memory size; wherein, the CPU size is 4 cores, and the memory size is 8G. Assume that the CPU size contained in the stored data is 4 cores and the memory size is 4G. The execution parameters are inconsistent with the stored data, so the stored data can be modified according to the execution parameters, i.e. the memory size contained in the stored data is modified from 4G to 8G.
Step S305, a creation request is sent to the actuator by the controller.
After the stored data is modified in step S304 to obtain the created data, a create request may be sent to the executor through the controller, where the create request may include an execution parameter and a create parameter.
In step S306, after receiving the creation request by the executor, the target virtual machine is created based on the execution parameters and the creation data.
After receiving the creation request through the executor, a target virtual machine may be created based on the execution parameters and the creation parameters.
In this embodiment of the present application, the executor may be an http client tool, and may be a linux shell executor, which is not limited in this application. For example, when the type of the executor included in the metadata corresponding to the virtual machine type of the target virtual machine stored in advance is an http type, the executor is an http client tool; if the type of the executor contained in the metadata corresponding to the virtual machine type of the pre-stored target virtual machine is the shell type, the executor is a linux shell executor; when the target virtual machine is a virtual machine of the virtualization platform, an http client tool can be used for calling a RestApi interface of the virtualization platform for creation; when the target virtual machine is a virtual machine corresponding to KubeVirt, the target virtual machine can be created by calling a kubectl command through a linux shell executor.
In an alternative embodiment, after the target virtual machine is created by the virtual machine creation method in fig. 2 or fig. 3, the storage data stored in the database may be updated according to the creation data, so as to obtain updated storage data.
Specifically, the controller may call the data synchronizer, extract each information when the target virtual machine is created from the creation data of the target virtual machine, and update the storage data stored in the database according to each extracted information, so as to obtain updated storage data, so that the storage data in the database is consistent with the construction data for constructing the target virtual machine.
Fig. 4 is a schematic structural diagram of a virtual machine creating apparatus according to an embodiment of the present application, as shown in fig. 4, where the apparatus includes:
the processing unit 401 is configured to obtain storage data based on input data input by a user for creating a target virtual machine.
And the extracting unit 402 is configured to extract, by the controller, an execution parameter corresponding to the target virtual machine after determining that the stored data is stored in the database.
A creating unit 403 for creating a target virtual machine by an actuator based on the execution parameters and the stored data.
Optionally, the processing unit 401 is specifically configured to:
and acquiring a verification rule and a data format corresponding to the stored input data according to the character which is contained in the input data used for creating the target virtual machine and used for identifying the virtual machine type of the target virtual machine and is input by the user.
And responding to the input data to accord with the verification rule, and carrying out data conversion on the input data through a parser according to the data format to obtain the storage data.
Optionally, the stored data is determined to be stored in the database by:
after detecting that the data stored in the database is subjected to data updating operation, the controller determines that the stored data is stored in the database; or alternatively, the first and second heat exchangers may be,
after receiving the data update notification sent by the database through the controller, determining to store the data in the database.
Optionally, the creating unit 403 is specifically configured to:
and modifying the stored data according to the execution parameters to obtain the created data.
Sending a creation request to an executor through a controller; the creation request includes execution parameters and creation data.
After receiving the creation request through the executor, a target virtual machine is created based on the execution parameters and the creation data.
Optionally, after creating the unit 403, the apparatus further comprises an updating unit, which is specifically configured to:
and updating the storage data stored in the database according to the creation data to obtain updated storage data.
Fig. 5 shows still another possible structural diagram of the virtual machine creating apparatus involved in the above-described embodiment. The virtual machine creation device includes: a processor 501 and a communication interface 502. The processor 501 is configured to control and manage actions of the virtual machine creating apparatus, and the communication interface 502 is configured to support communication between the virtual machine creating apparatus and other network entities. The virtual machine creation means may further comprise a memory 503 and a bus 504, the memory 503 being for storing program codes and data of the virtual machine creation means.
Wherein the memory 503 may be a memory in the virtual machine creation means, etc., which may include a volatile memory, such as a random access memory; the memory may also include non-volatile memory, such as read-only memory, flash memory, hard disk or solid state disk; the memory may also comprise a combination of the above types of memories.
The processor 501 may be implemented or executed with the various exemplary logic blocks, modules and circuits described in connection with the present disclosure. The processor may be a central processing unit, a general purpose processor, a digital signal processor, an application specific integrated circuit, a field programmable gate array or other programmable logic device, a transistor logic device, a hardware component, or any combination thereof. Which may implement or perform the various exemplary logic blocks, modules, and circuits described in connection with this disclosure. The processor may also be a combination that performs the function of a computation, e.g., a combination comprising one or more microprocessors, a combination of a DSP and a microprocessor, etc.
Bus 504 may be an extended industry standard architecture (Extended Industry Standard Architecture, EISA) bus or the like. The bus 504 may be divided into an address bus, a data bus, a control bus, and the like. For ease of illustration, only one thick line is shown in fig. 5, but not only one bus or one type of bus.
From the foregoing description of the embodiments, it will be apparent to those skilled in the art that, for convenience and brevity of description, only the above-described division of functional modules is illustrated, and in practical application, the above-described functional allocation may be implemented by different functional modules according to needs, i.e. the internal structure of the apparatus is divided into different functional modules to implement all or part of the functions described above. The specific working processes of the above-described systems, devices and units may refer to the corresponding processes in the foregoing method embodiments, which are not described herein.
Embodiments of the present application provide a computer program product comprising instructions which, when run on a computer, cause the computer to perform the virtual machine creation method of the method embodiments described above.
The embodiment of the application also provides a computer readable storage medium, in which instructions are stored, which when executed on a computer, cause the computer to execute the virtual machine creating method in the method flow shown in the method embodiment.
The computer readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or a combination of any of the foregoing. More specific examples (a non-exhaustive list) of the computer-readable storage medium would include the following: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a random access Memory (Random Access Memory, RAM), a Read-Only Memory (ROM), an erasable programmable Read-Only Memory (Erasable Programmable Read Only Memory, EPROM), a register, a hard disk, an optical fiber, a portable compact disc Read-Only Memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing, or any other form of computer readable storage medium known in the art. An exemplary storage medium is coupled to the processor such the processor can read information from, and write information to, the storage medium. In the alternative, the storage medium may be integral to the processor. The processor and the storage medium may reside in an application specific integrated circuit (Application Specific Integrated Circuit, ASIC). In the context of the present application, a computer-readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device.
Embodiments of the present invention provide a computer program product comprising instructions which, when run on a computer, cause the computer to perform the virtual machine creation method described in the embodiments of the present application.
Since the virtual machine creating apparatus, the computer readable storage medium, and the computer program product in the embodiments of the present invention can be applied to the above-mentioned method, the technical effects that can be obtained by the method can also refer to the above-mentioned method embodiments, and the embodiments of the present invention are not described herein again.
In the several embodiments provided in this application, it should be understood that the disclosed systems, devices, and methods may be implemented in other ways. For example, the above-described apparatus embodiments are merely illustrative, and for example, the division of the units is merely a logical function division, and there may be additional divisions when actually implemented, for example, multiple units or components may be combined or integrated into another system, or some features may be omitted or not performed. Alternatively, the coupling or direct coupling or communication connection shown or discussed with each other may be through some interface, indirect coupling or communication connection of devices or units, electrical, mechanical, or other form.
The units described as separate units may or may not be physically separate, and units shown as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
In addition, each functional unit in each embodiment of the present application may be integrated in one processing unit, or each unit may exist alone physically, or two or more units may be integrated in one unit.
The foregoing is merely a specific embodiment of the present application, but the protection scope of the present application is not limited thereto, and any changes or substitutions within the technical scope of the present disclosure should be covered in the protection scope of the present application. Therefore, the protection scope of the present application shall be subject to the protection scope of the claims.

Claims (12)

1. A method of virtual machine creation, the method comprising:
obtaining storage data based on input data input by a user and used for creating a target virtual machine;
after the stored data are determined to be stored in a database, extracting the execution parameters corresponding to the target virtual machine through a controller;
the target virtual machine is created by an actuator based on the execution parameters and the stored data.
2. The method of claim 1, wherein the obtaining the stored data based on the input data entered by the user for creating the target virtual machine comprises:
acquiring a verification rule and a data format corresponding to the input data according to characters which are contained in the input data used for creating the target virtual machine and used for identifying the virtual machine type of the target virtual machine and are input by the user;
and responding to the input data to accord with the verification rule, and carrying out data conversion on the input data through a parser according to the data format to obtain the storage data.
3. The method of claim 1, wherein the stored data is determined to be stored in a database by:
after detecting that the data stored in the database is subjected to data updating operation through the controller, determining that the stored data is stored in the database; or alternatively, the first and second heat exchangers may be,
and after receiving the data updating notification sent by the database through the controller, determining that the stored data is stored in the database.
4. The method of claim 1, wherein the creating, by an executor, the target virtual machine based on the execution parameters and the stored data comprises:
modifying the stored data according to the execution parameters to obtain creation data;
sending, by the controller, a create request to the executor; the creation request comprises the execution parameters and the creation data;
and after receiving the creation request through the executor, creating the target virtual machine based on the execution parameters and the creation data.
5. The method of claim 4, wherein after creating the target virtual machine based on the execution parameters and the creation data, the method further comprises:
and updating the storage data stored in the database according to the creation data to obtain updated storage data.
6. A virtual machine creation apparatus, the apparatus comprising:
the processing unit is used for obtaining storage data based on input data input by a user and used for creating a target virtual machine;
the extraction unit is used for extracting the execution parameters corresponding to the target virtual machine through the controller after the storage data are determined to be stored in the database;
and the creation unit is used for creating the target virtual machine through an executor based on the execution parameters and the stored data.
7. The apparatus according to claim 6, wherein the processing unit is specifically configured to:
acquiring a verification rule and a data format corresponding to the input data according to characters which are contained in the input data used for creating the target virtual machine and used for identifying the virtual machine type of the target virtual machine and are input by the user;
and responding to the input data to accord with the verification rule, and carrying out data conversion on the input data through a parser according to the data format to obtain the storage data.
8. The apparatus of claim 6, wherein the stored data is determined to be stored in the database by:
after detecting that the data stored in the database is subjected to data updating operation through the controller, determining that the stored data is stored in the database; or alternatively, the first and second heat exchangers may be,
and after receiving the data updating notification sent by the database through the controller, determining that the stored data is stored in the database.
9. The apparatus according to claim 7, wherein the creation unit is specifically configured to:
modifying the stored data according to the execution parameters to obtain creation data;
sending, by the controller, a create request to the executor; the creation request comprises the execution parameters and the creation data;
and after receiving the creation request through the executor, creating the target virtual machine based on the execution parameters and the creation data.
10. The apparatus according to claim 9, characterized in that after the creation unit, the apparatus further comprises an update unit, in particular for:
and updating the storage data stored in the database according to the creation data to obtain updated storage data.
11. A virtual machine creation apparatus, comprising: a processor and a communication interface; the communication interface is coupled to the processor for running a computer program or instructions to implement the virtual machine creation method as defined in any of claims 1-5.
12. A computer readable storage medium having instructions stored therein, characterized in that when executed by a computer, the computer performs the virtual machine creation method of any of the above claims 1-5.
CN202211622170.4A 2022-12-16 2022-12-16 Virtual machine creation method and device Pending CN116126460A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202211622170.4A CN116126460A (en) 2022-12-16 2022-12-16 Virtual machine creation method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202211622170.4A CN116126460A (en) 2022-12-16 2022-12-16 Virtual machine creation method and device

Publications (1)

Publication Number Publication Date
CN116126460A true CN116126460A (en) 2023-05-16

Family

ID=86303630

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202211622170.4A Pending CN116126460A (en) 2022-12-16 2022-12-16 Virtual machine creation method and device

Country Status (1)

Country Link
CN (1) CN116126460A (en)

Similar Documents

Publication Publication Date Title
US10977086B2 (en) Workload placement and balancing within a containerized infrastructure
JP5758995B2 (en) System, method and computer-readable storage medium for sharing analysis results between virtual machines
CN109445861B (en) System starting method, device, computer device and storage medium
CN109634718B (en) Method and system for creating mirror image by cloud platform
WO2020238245A1 (en) Function jump implementation method, device, and computer storage medium
CN101271409A (en) Live migration of a logical partition, method and product thereof
CN111506386A (en) Virtual machine online migration method, device, equipment and computer readable storage medium
US20240111549A1 (en) Method and apparatus for constructing android running environment
CN109417488A (en) The method and apparatus of virtual network function resource management
EP3432132B1 (en) Data storage method and device
US11886898B2 (en) GPU-remoting latency aware virtual machine migration
US11245762B1 (en) Data request servicing using smart network interface cards
CN115988218A (en) Virtualized video coding and decoding system, electronic equipment and storage medium
CN112930532A (en) Controlling store access for merge operations
CN113010265A (en) Pod scheduling method, scheduler, memory plug-in and system
US10831503B2 (en) Saving and restoring machine state between multiple executions of an instruction
JP6385471B2 (en) Migration and remote runtime integration
CN113687779A (en) Data migration method and device, electronic equipment and readable storage medium
US20070033371A1 (en) Method and apparatus for establishing a cache footprint for shared processor logical partitions
EP3877842B1 (en) Migration of partially completed instructions
CN109614242B (en) Computing capacity sharing method, device, equipment and medium
CN114816665B (en) Hybrid arrangement system and virtual machine container resource hybrid arrangement method under super-fusion architecture
CN116126460A (en) Virtual machine creation method and device
CN113791873B (en) Virtual machine creating method, computing device and storage medium
CN110290172B (en) Container application cloning method and device, computer equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination