CN113127142A - Method and device for creating virtual machine in physical system - Google Patents

Method and device for creating virtual machine in physical system Download PDF

Info

Publication number
CN113127142A
CN113127142A CN201911422789.9A CN201911422789A CN113127142A CN 113127142 A CN113127142 A CN 113127142A CN 201911422789 A CN201911422789 A CN 201911422789A CN 113127142 A CN113127142 A CN 113127142A
Authority
CN
China
Prior art keywords
virtual machine
physical node
processing resources
target
physical
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
CN201911422789.9A
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.)
Qianxin Technology Group Co Ltd
Secworld Information Technology Beijing Co Ltd
Original Assignee
Qianxin Technology Group Co Ltd
Secworld Information Technology Beijing 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 Qianxin Technology Group Co Ltd, Secworld Information Technology Beijing Co Ltd filed Critical Qianxin Technology Group Co Ltd
Priority to CN201911422789.9A priority Critical patent/CN113127142A/en
Publication of CN113127142A publication Critical patent/CN113127142A/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
    • 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

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Stored Programmes (AREA)

Abstract

The present disclosure provides a method of creating a virtual machine in a physical system, the physical system comprising a plurality of physical nodes, each of the plurality of physical nodes comprising a plurality of processing resources, the method comprising: receiving a creation request for creating a virtual machine, wherein the creation request comprises configuration information of the virtual machine, acquiring allocation information of processing resources of each physical node, determining a target physical node corresponding to the virtual machine based on the allocation information and the configuration information, and creating the virtual machine on the target physical node.

Description

Method and device for creating virtual machine in physical system
Technical Field
The present disclosure relates to the field of computer technology, and more particularly, to a method, an apparatus, a computer system, and a computer-readable storage medium for creating a virtual machine in a physical system.
Background
In a virtual machine system created based on kvm (kernel-based virtual machine) -qemu (virtual machine simulator) technology, a qemu process is run for each virtual machine instance. For virtual machines configured in different CPU specifications, threads with the same specification number are created inside qemu to simulate the VCPU (virtual CPU) of the virtual machine.
For the existing multi-core platform, the qemu VCPU threads corresponding to the virtual machine can share the resources of the physical CPU under normal conditions, that is, the qemu VCPU threads are scheduled by the operating system on different cores of the random physical CPU and compete with other business processes for the CPU resources. However, such contention may cause frequent switching of CPU contexts, resulting in frequent swapping in and out of memory, which reduces the overall performance of the virtual machine.
Disclosure of Invention
In view of the above, the present disclosure provides a method and apparatus for creating a virtual machine in a physical system.
One aspect of the present disclosure provides a method of creating a virtual machine in a physical system, the physical system including a plurality of physical nodes, each of the plurality of physical nodes including a plurality of processing resources, the method comprising: receiving a creation request for creating a virtual machine, wherein the creation request comprises configuration information of the virtual machine, acquiring allocation information of processing resources of each physical node, determining a target physical node corresponding to the virtual machine based on the allocation information and the configuration information, and creating the virtual machine on the target physical node.
According to an embodiment of the present disclosure, the method further comprises: and determining a target processing resource in the target physical node corresponding to the virtual machine based on the allocation information and the configuration information, and binding the virtual machine and the target processing resource.
According to an embodiment of the present disclosure, the method further comprises: and under the condition that other virtual machines are bound on the target physical node in a sharing binding mode, migrating the other virtual machines to other non-exclusively bound processing resources in the target physical node.
According to an embodiment of the present disclosure, the configuration information includes: the virtual machine needs to occupy N processing resources and be exclusively bound to the N processing resources, wherein N is an integer greater than 1. At least M processing resources exist in the plurality of processing resources in the target physical node and are distributed as non-exclusive binding processing resources, wherein M is an integer greater than or equal to N.
According to an embodiment of the present disclosure, in a case that at least one processing resource of the M processing resources is in a shared binding state, the M is greater than N.
Another aspect of the present disclosure provides an apparatus for creating a virtual machine in a physical system, the physical system including a plurality of physical nodes, each of the plurality of physical nodes including a plurality of processing resources, the apparatus including a receiving module, an obtaining module, a first determining module, and a creating module. The receiving module is used for receiving a creation request for creating a virtual machine, wherein the creation request comprises configuration information of the virtual machine. The obtaining module is used for obtaining the allocation information of the processing resources of each physical node. The first determining module is used for determining a target physical node corresponding to the virtual machine based on the allocation information and the configuration information. The creation module is to create the virtual machine on the target physical node.
According to an embodiment of the present disclosure, the apparatus further includes a second determining module and a binding module. The second determining module is configured to determine a target processing resource in the target physical node corresponding to the virtual machine based on the allocation information and the configuration information. And the binding module is used for binding the virtual machine with the target processing resource.
According to an embodiment of the present disclosure, the apparatus further comprises: and the migration module is used for migrating the other virtual machines to other non-exclusively-bound processing resources in the target physical node under the condition that the other virtual machines are bound on the target physical node in a sharing binding mode.
According to an embodiment of the present disclosure, the configuration information includes: the virtual machine needs to occupy N processing resources and be exclusively bound to the N processing resources, wherein N is an integer greater than 1. At least M processing resources exist in the plurality of processing resources in the target physical node and are distributed as non-exclusive binding processing resources, wherein M is an integer greater than or equal to N.
According to an embodiment of the present disclosure, in a case that at least one processing resource of the M processing resources is in a shared binding state, the M is greater than N.
Another aspect of the present disclosure provides a computer system comprising: one or more processors, and a computer readable storage medium storing one or more programs, which when executed by the one or more processors, cause the one or more processors to implement the method as described above.
Another aspect of the disclosure provides a non-volatile storage medium storing computer-executable instructions for implementing the method as described above when executed.
Another aspect of the disclosure provides a computer program comprising computer executable instructions for implementing the method as described above when executed.
Drawings
The above and other objects, features and advantages of the present disclosure will become more apparent from the following description of embodiments of the present disclosure with reference to the accompanying drawings, in which:
fig. 1 schematically illustrates an application scenario of a method and apparatus for creating a virtual machine in a physical system according to an embodiment of the present disclosure;
FIG. 2 schematically illustrates a flow diagram of a method of creating a virtual machine in a physical system, according to an embodiment of the disclosure;
FIG. 3 schematically illustrates a block diagram of an apparatus for creating a virtual machine in a physical system, in accordance with an embodiment of the present disclosure; and
FIG. 4 schematically illustrates a block diagram of a computer system suitable for a method of creating a virtual machine in a physical system according to an embodiment of the disclosure.
Detailed Description
Hereinafter, embodiments of the present disclosure will be described with reference to the accompanying drawings. It should be understood that the description is illustrative only and is not intended to limit the scope of the present disclosure. Moreover, in the following description, descriptions of well-known structures and techniques are omitted so as to not unnecessarily obscure the concepts of the present disclosure.
The terminology used herein is for the purpose of describing particular embodiments only and is not intended to be limiting of the disclosure. The terms "comprises," "comprising," and the like, as used herein, specify the presence of stated features, steps, operations, and/or components, but do not preclude the presence or addition of one or more other features, steps, operations, or components.
All terms (including technical and scientific terms) used herein have the same meaning as commonly understood by one of ordinary skill in the art unless otherwise defined. It is noted that the terms used herein should be interpreted as having a meaning that is consistent with the context of this specification and should not be interpreted in an idealized or overly formal sense.
Where a convention analogous to "at least one of A, B and C, etc." is used, in general such a construction is intended in the sense one having skill in the art would understand the convention (e.g., "a system having at least one of A, B and C" would include but not be limited to systems that have a alone, B alone, C alone, a and B together, a and C together, B and C together, and/or A, B, C together, etc.). Where a convention analogous to "A, B or at least one of C, etc." is used, in general such a construction is intended in the sense one having skill in the art would understand the convention (e.g., "a system having at least one of A, B or C" would include but not be limited to systems that have a alone, B alone, C alone, a and B together, a and C together, B and C together, and/or A, B, C together, etc.). It will be further understood by those within the art that virtually any disjunctive word and/or phrase presenting two or more alternative terms, whether in the description, claims, or drawings, should be understood to contemplate the possibilities of including one of the terms, either of the terms, or both terms. For example, the phrase "a or B" should be understood to include the possibility of "a" or "B", or "a and B".
Embodiments of the present disclosure provide a method of creating a virtual machine in a physical system, the physical system including a plurality of physical nodes, each of the plurality of physical nodes including a plurality of processing resources. The method comprises the following steps: receiving a creation request for creating a virtual machine, the creation request including configuration information of the virtual machine, acquiring allocation information of processing resources of each physical node, determining a target physical node corresponding to the virtual machine based on the allocation information and the configuration information, and creating the virtual machine on the target physical node.
Fig. 1 schematically illustrates an application scenario 100 of a method and apparatus for creating a virtual machine in a physical system according to an embodiment of the present disclosure.
It should be noted that fig. 1 is only an example of an application scenario in which the embodiments of the present disclosure may be applied to help those skilled in the art understand the technical content of the present disclosure, but does not mean that the embodiments of the present disclosure may not be applied to other devices, systems, environments or scenarios.
As shown in fig. 1, a physical system in an application scenario 100 according to an embodiment of the present disclosure may include a first physical node 110 and a second physical node 120. The physical system in the embodiments of the present disclosure may be, for example, a system of a non-uniform memory access (NUMA) architecture.
The first physical node 110 may include a processing resource pool 111, and the processing resource pool 111 may include a plurality of processing resources therein. The processing resource may be, for example, a CPU core (CPU core) of the physical node. For example, if the CPU of the first physical node 110 has 8 cores, then there are 8 processing resources in the processing resource pool 111 of the first physical node 110.
The second physical node 120 may include a processing resource pool 121, and the processing resource pool 121 may include a plurality of processing resources therein. The processing resource may be, for example, a CPU core (CPU core) of the physical node. For example, if the CPU of the second physical node 120 has 8 cores, then there are 8 processing resources in the processing resource pool 121 of the second physical node 120.
The disclosed embodiments may establish virtual machines in a physical system, for example, virtual machine VNF1 and virtual machine VNF2 are established in first physical node 110. The second physical node 120 has established therein a virtual machine VNF3 and a virtual machine VNF 4. Where each virtual machine has two VCPUs (for example only), each VCPU may be bound to a CPU core in the physical node so that the physical node may provide the computing resources of the CPU for the virtual machine.
Each physical node resource in the physical system of the disclosed embodiments is isolated. That is, the VCPUs of the virtual machines may all be bound to the CPU core of the physical node where the virtual machine is located, and no inter-physical node binding is performed. For example, Vcpu 0 of virtual machine VNF3 may bind with CPU core2 in the second physical node, but be prohibited from binding with CPU core in the first physical node. The scheme for forbidding cross-node binding in the embodiment of the disclosure can avoid the problem of poor memory access performance caused by cross-node.
According to embodiments of the present disclosure, one or more CPU cores in the processing resource pool (e.g., core1 in processing resource pool 111) may provide computing resources for the virtualization platform, and the portion of the CPU cores may not be bound to any virtual machine. Other CPU cores in the processing resource pool (e.g., cores 2-8 in the processing resource pool 111) may provide computing resources for the created virtual machine, and the CPU core may be exclusively owned by a virtual machine or shared by multiple virtual machines.
It should be understood that the number of physical nodes, virtual machines, and processing resources (CPU core) in FIG. 1 is merely illustrative. There may be any number of physical nodes, virtual machines, and processing resources (CPU cores), as desired for an implementation.
FIG. 2 schematically illustrates a flow diagram of a method of creating a virtual machine in a physical system, according to an embodiment of the disclosure.
According to embodiments of the present disclosure, a physical system may include a plurality of physical nodes, each of which may include a plurality of processing resources. For example, a physical node with a CPU having 8 cores may include 8 processing resources, and a physical node with a CPU having 4 cores may include 4 processing resources.
As shown in fig. 2, the method includes operations S201 to S204.
In operation S201, a creation request for creating a virtual machine is received, where the creation request includes configuration information of the virtual machine.
According to an embodiment of the present disclosure, the configuration information may be, for example, a configuration specification of the virtual machine. For example, configuration specifications for CPU, memory, disk, etc.
For example, the configuration information may further include the amount of processing resources of the physical node that the virtual machine needs to occupy and the binding relationship with the processing resources. For example, a virtual machine needs to occupy and bind exclusively with N processing resources, where N is an integer greater than 1. For example, a virtual machine needs to configure 2 VCPUs, each VCPU needs to have processing resources of one physical node bound exclusively.
In operation S202, allocation information of processing resources of each physical node is acquired.
According to an embodiment of the present disclosure, acquiring allocation information of processing resources of each physical node includes: and acquiring the quantity of the processing resources of the physical node, which can be used for binding with the virtual machine, and the current binding state of the processing resources. For example, the number of processing resources available for binding with the virtual machine in the physical node 1 is 4 (CPU core1 to CPU core6), where the current binding state of the CPU core1 is exclusive binding with other virtual machines, the current binding state of the CPU core2 is shared binding with other virtual machines, the current binding state of the CPU core3 is shared binding with other virtual machines, and the current binding state of the CPU core4 is idle.
In operation S203, a target physical node corresponding to the virtual machine is determined based on the allocation information and the configuration information.
According to the embodiment of the disclosure, a plurality of physical nodes in a physical system can be traversed in sequence, whether the current physical node meets the requirement for creating the virtual machine is determined, if yes, the current physical node is determined to be a target physical node, otherwise, whether the next physical node meets the requirement is continuously determined until all the physical nodes in the physical system are traversed.
In the embodiment of the present disclosure, when a virtual machine needs to be exclusively bound to N processing resources, a target physical node that meets a creation requirement needs to have at least M processing resources that are not configured as non-exclusive bound processing resources, where M is an integer greater than or equal to N.
For example, if the virtual machine needs to be bound exclusively with 2 processing resources, at least 2 processing resources in the target physical node are in a non-exclusive bound state.
According to an embodiment of the present disclosure, M is greater than N in a case where at least one of the M processing resources is in a shared bonded state.
For example, the virtual machine needs to be exclusively bound to 2 processing resources, and at least one processing resource in the physical node is in the shared bound state, so that the virtual machine can become the target physical node only when at least 3 processing resources in the physical node are in the non-exclusive bound state. Because, at least one processing resource in the physical node needs to be in a shared bound state to provide computing resources for the shared bound virtual machine.
According to the embodiment of the disclosure, the target processing resource in the target physical node corresponding to the virtual machine can be determined based on the allocation information and the configuration information.
For example, the configuration information is that the virtual machine needs to be bound exclusively with 2 processing resources. The allocation information includes: the physical node 1 includes a CPU core1 in a shared bound state and a CPU core2 in an idle state, and the physical node 2 includes a CPU core1 in an exclusive bound state, a CPU core2 and a CPU core3 in a shared bound state, and a CPU core4 in an idle state. It may be determined that the target physical node corresponding to the virtual machine is physical node 2 and the target processing resources corresponding to the virtual machine are CPU core3 and CPU core4 of physical node 2.
In operation S204, a virtual machine is created on the target physical node.
According to the embodiment of the disclosure, a virtual machine can be created on the determined target physical node, and the virtual machine is bound with the target processing resource, so as to provide the computing resource for the virtual machine.
In the embodiment of the present disclosure, when other virtual machines have been bound to the target physical node in a shared binding manner, the other virtual machines are migrated to other non-exclusively bound processing resources in the target physical node.
For example, continuing the above example, the configuration information is that the virtual machine needs to be bound exclusively with 2 processing resources. The allocation information includes the CPU core1 in the exclusive bound state, the CPU cores 2 and 3 in the shared bound state, and the CPU core4 in the idle state in the physical node 2. It may be determined that the target physical node corresponding to the virtual machine is physical node 2 and the target processing resources corresponding to the virtual machine are CPU core3 and CPU core4 of physical node 2. If the CPU core3 is already in the shared binding state with other virtual machines, the other virtual machines sharing the CPU core3 may be migrated to the CPU core2 of the physical node 2, so that the other virtual machines share the CPU core2, and the CPU core2 provides computing resources for the other virtual machines.
The embodiment of the disclosure can evenly schedule the virtual machine to be created to run on which physical node through the processing resource allocation information of each physical node and the configuration information of the virtual machine. The scheduling in advance can avoid that the virtual machine is failed to be created and the resources are rolled back to cause unnecessary resource waste because the physical nodes do not have enough bound processing resources during the creation.
In the embodiment of the disclosure, the processing resources in each physical node are isolated, and the virtual machine does not need to bind the processing resources across the nodes, so that the problem of poor memory access performance caused by node crossing can be avoided.
The embodiment of the disclosure can allow the virtual machine to exclusively or share the binding processing resource, and can provide more choices for the tenant, the exclusive binding processing resource can improve the processing performance of the virtual machine, and the shared binding processing resource can improve the number of the created virtual machines.
Fig. 3 schematically illustrates a block diagram of an apparatus 300 for creating a virtual machine in a physical system according to an embodiment of the present disclosure.
As shown in fig. 3, the apparatus 300 includes a receiving module 310, an obtaining module 320, a first determining module 330, and a creating module 340.
The receiving module 310 is configured to receive a creation request for creating a virtual machine, where the creation request includes configuration information of the virtual machine.
The obtaining module 320 is configured to obtain allocation information of processing resources of each physical node.
The first determining module 330 is configured to determine a target physical node corresponding to the virtual machine based on the allocation information and the configuration information.
The creation module 340 is used to create a virtual machine on a target physical node.
According to an embodiment of the present disclosure, the apparatus 300 further comprises: and the second determining module is used for determining target processing resources in the target physical node corresponding to the virtual machine based on the allocation information and the configuration information.
According to an embodiment of the present disclosure, the apparatus 300 further comprises: and the binding module is used for binding the virtual machine with the target processing resource.
According to an embodiment of the present disclosure, the apparatus 300 further comprises: and the migration module is used for migrating other virtual machines to other non-exclusively-bound processing resources in the target physical node under the condition that other virtual machines are bound on the target physical node in a sharing binding mode.
According to an embodiment of the present disclosure, the configuration information includes: the virtual machine needs to occupy N processing resources and be exclusively bound to the N processing resources, where N is an integer greater than 1. At least M processing resources exist in the plurality of processing resources in the target physical node and are distributed as non-exclusive binding processing resources, wherein M is an integer which is larger than or equal to N.
According to an embodiment of the present disclosure, M is greater than N in a case where at least one of the M processing resources is in a shared bonded state.
It should be noted that the implementation, solved technical problems, implemented functions, and achieved technical effects of each module/unit/subunit and the like in the apparatus part embodiment are respectively the same as or similar to the implementation, solved technical problems, implemented functions, and achieved technical effects of each corresponding step in the method part embodiment, and are not described herein again.
Any number of modules, sub-modules, units, sub-units, or at least part of the functionality of any number thereof according to embodiments of the present disclosure may be implemented in one module. Any one or more of the modules, sub-modules, units, and sub-units according to the embodiments of the present disclosure may be implemented by being split into a plurality of modules. Any one or more of the modules, sub-modules, units, sub-units according to embodiments of the present disclosure may be implemented at least in part as a hardware circuit, such as a Field Programmable Gate Array (FPGA), a Programmable Logic Array (PLA), a system on a chip, a system on a substrate, a system on a package, an Application Specific Integrated Circuit (ASIC), or may be implemented in any other reasonable manner of hardware or firmware by integrating or packaging a circuit, or in any one of or a suitable combination of software, hardware, and firmware implementations. Alternatively, one or more of the modules, sub-modules, units, sub-units according to embodiments of the disclosure may be at least partially implemented as a computer program module, which when executed may perform the corresponding functions.
FIG. 4 schematically illustrates a block diagram of a computer system suitable for a method of creating a virtual machine in a physical system according to an embodiment of the disclosure. The computer system illustrated in FIG. 4 is only one example and should not impose any limitations on the scope of use or functionality of embodiments of the disclosure.
As shown in fig. 4, a computer system 400 according to an embodiment of the present disclosure includes a processor 401 that can perform various appropriate actions and processes according to a program stored in a Read Only Memory (ROM)402 or a program loaded from a storage section 408 into a Random Access Memory (RAM) 403. Processor 401 may include, for example, a general purpose microprocessor (e.g., a CPU), an instruction set processor and/or associated chipset, and/or a special purpose microprocessor (e.g., an Application Specific Integrated Circuit (ASIC)), among others. The processor 401 may also include onboard memory for caching purposes. Processor 401 may include a single processing unit or multiple processing units for performing the different actions of the method flows described with reference to fig. 2 in accordance with embodiments of the present disclosure.
In the RAM 403, various programs and data necessary for the operation of the system 400 are stored. The processor 401, ROM 402 and RAM 403 are connected to each other by a bus 404. The processor 401 performs various operations described above with reference to fig. 2 by executing programs in the ROM 402 and/or the RAM 403. Note that the programs may also be stored in one or more memories other than the ROM 402 and RAM 403. The processor 401 may also perform the various operations described above with reference to fig. 2 by executing programs stored in the one or more memories.
According to an embodiment of the present disclosure, system 400 may also include an input/output (I/O) interface 405, input/output (I/O) interface 405 also connected to bus 404. The system 400 may also include one or more of the following components connected to the I/O interface 405: an input section 406 including a keyboard, a mouse, and the like; an output section 407 including a display device such as a Cathode Ray Tube (CRT), a Liquid Crystal Display (LCD), and the like, and a speaker; a storage section 408 including a hard disk and the like; and a communication section 409 including a network interface card such as a LAN card, a modem, or the like. The communication section 409 performs communication processing via a network such as the internet. A driver 410 is also connected to the I/O interface 405 as needed. A removable medium 411 such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, or the like is mounted on the drive 410 as necessary, so that a computer program read out therefrom is mounted into the storage section 408 as necessary.
According to an embodiment of the present disclosure, the method described above with reference to the flow chart may be implemented as a computer software program. For example, embodiments of the present disclosure include a computer program product comprising a computer program embodied on a computer readable medium, the computer program comprising program code for performing the method illustrated in the flow chart. In such an embodiment, the computer program may be downloaded and installed from a network through the communication section 409, and/or installed from the removable medium 411. The computer program, when executed by the processor 401, performs the above-described functions defined in the system of the embodiments of the present disclosure. The systems, devices, apparatuses, modules, units, etc. described above may be implemented by computer program modules according to embodiments of the present disclosure.
It should be noted that the computer readable media shown in the present disclosure may be computer readable signal media or computer readable storage media or any combination of the two. A 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 any combination of the foregoing. More specific examples of the computer readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In the present disclosure, 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. In contrast, in the present disclosure, a computer-readable signal medium may include a propagated data signal with computer-readable program code embodied therein, for example, in baseband or as part of a carrier wave. Such a propagated data signal may take many forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A computer readable signal medium may also be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device. Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to: wireless, wire, fiber optic cable, RF, etc., or any suitable combination of the foregoing. According to embodiments of the present disclosure, a computer-readable medium may include the ROM 402 and/or RAM 403 and/or one or more memories other than the ROM 402 and RAM 403 described above.
The flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present disclosure. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams or flowchart illustration, and combinations of blocks in the block diagrams or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
As another aspect, the present disclosure also provides a computer-readable medium, which may be contained in the apparatus described in the above embodiments; or may be separate and not incorporated into the device. The computer readable medium carries one or more programs which, when executed by a device, cause the device to perform the method as described above.
The embodiments of the present disclosure have been described above. However, these examples are for illustrative purposes only and are not intended to limit the scope of the present disclosure. Although the embodiments are described separately above, this does not mean that the measures in the embodiments cannot be used in advantageous combination. The scope of the disclosure is defined by the appended claims and equivalents thereof. Various alternatives and modifications can be devised by those skilled in the art without departing from the scope of the present disclosure, and such alternatives and modifications are intended to be within the scope of the present disclosure.

Claims (11)

1. A method of creating a virtual machine in a physical system, the physical system comprising a plurality of physical nodes, each physical node of the plurality of physical nodes comprising a plurality of processing resources; the method comprises the following steps:
receiving a creating request for creating a virtual machine, wherein the creating request comprises configuration information of the virtual machine;
acquiring the allocation information of the processing resources of each physical node;
determining a target physical node corresponding to the virtual machine based on the allocation information and the configuration information; and
creating the virtual machine on the target physical node.
2. The method of claim 1, further comprising:
determining a target processing resource in the target physical node corresponding to the virtual machine based on the allocation information and the configuration information;
and binding the virtual machine with a target processing resource.
3. The method of claim 2, further comprising:
and under the condition that other virtual machines are bound on the target physical node in a sharing binding mode, migrating the other virtual machines to other non-exclusively bound processing resources in the target physical node.
4. The method of claim 1, wherein:
the configuration information includes: the virtual machine needs to occupy N processing resources and is exclusively bound with the N processing resources, wherein N is an integer greater than 1;
at least M processing resources exist in the plurality of processing resources in the target physical node and are distributed as non-exclusive binding processing resources, wherein M is an integer greater than or equal to N.
5. The method of claim 4, wherein M is greater than N if at least one of the M processing resources is in a shared binding state.
6. An apparatus for creating a virtual machine in a physical system, the physical system comprising a plurality of physical nodes, each physical node of the plurality of physical nodes comprising a plurality of processing resources; the device comprises:
a receiving module, configured to receive a creation request for creating a virtual machine, where the creation request includes configuration information of the virtual machine;
an obtaining module, configured to obtain allocation information of processing resources of each physical node;
a first determining module, configured to determine, based on the allocation information and the configuration information, a target physical node corresponding to the virtual machine; and
a creation module to create the virtual machine on the target physical node.
7. The apparatus of claim 6, further comprising:
a second determining module, configured to determine, based on the allocation information and the configuration information, a target processing resource in the target physical node corresponding to the virtual machine;
and the binding module is used for binding the virtual machine with the target processing resource.
8. The apparatus of claim 7, further comprising:
and the migration module is used for migrating the other virtual machines to other non-exclusively-bound processing resources in the target physical node under the condition that the other virtual machines are bound on the target physical node in a sharing binding mode.
9. A computer system, comprising:
one or more processors;
a computer-readable storage medium for storing one or more programs,
wherein the one or more programs, when executed by the one or more processors, cause the one or more processors to implement the method of any of claims 1-5.
10. A computer readable storage medium having stored thereon executable instructions which, when executed by a processor, cause the processor to carry out the method of any one of claims 1 to 5.
11. A computer program product comprising computer readable instructions, wherein the computer readable instructions, when executed, are for performing the method of any of claims 1-5.
CN201911422789.9A 2019-12-30 2019-12-30 Method and device for creating virtual machine in physical system Pending CN113127142A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201911422789.9A CN113127142A (en) 2019-12-30 2019-12-30 Method and device for creating virtual machine in physical system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201911422789.9A CN113127142A (en) 2019-12-30 2019-12-30 Method and device for creating virtual machine in physical system

Publications (1)

Publication Number Publication Date
CN113127142A true CN113127142A (en) 2021-07-16

Family

ID=76770688

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201911422789.9A Pending CN113127142A (en) 2019-12-30 2019-12-30 Method and device for creating virtual machine in physical system

Country Status (1)

Country Link
CN (1) CN113127142A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113608833A (en) * 2021-07-19 2021-11-05 曙光信息产业(北京)有限公司 Virtual machine creation method and device, computer equipment and storage medium

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113608833A (en) * 2021-07-19 2021-11-05 曙光信息产业(北京)有限公司 Virtual machine creation method and device, computer equipment and storage medium

Similar Documents

Publication Publication Date Title
EP3039540B1 (en) Virtual machine monitor configured to support latency sensitive virtual machines
US10372493B2 (en) Thread and/or virtual machine scheduling for cores with diverse capabilities
WO2018119951A1 (en) Gpu virtualization method, device, system, and electronic apparatus, and computer program product
US11157302B2 (en) Idle processor management in virtualized systems via paravirtualization
US9501137B2 (en) Virtual machine switching based on processor power states
US9176787B2 (en) Preserving, from resource management adjustment, portions of an overcommitted resource managed by a hypervisor
US10002016B2 (en) Configuration of virtual machines in view of response time constraints
US8881166B2 (en) Method, data processing program, and computer program product to compensate for coupling overhead in a distributed computing system, and corresponding overhead calculator for a distributed computing system and corresponding computer system
CN114691300A (en) Hot migration method of virtual machine instance
US10318343B2 (en) Migration methods and apparatuses for migrating virtual machine including locally stored and shared data
CN111209080A (en) Transparent transmission method for graphic processor
CN115495228A (en) Method, apparatus and computer program product for resource scheduling
US8938608B2 (en) Enabling portions of programs to be executed on system z integrated information processor (zIIP) without requiring programs to be entirely restructured
US10235202B2 (en) Thread interrupt offload re-prioritization
US11392512B2 (en) USB method and apparatus in a virtualization environment with multi-VM
CN113127142A (en) Method and device for creating virtual machine in physical system
US9703614B2 (en) Managing a free list of resources to decrease control complexity and reduce power consumption
US9766948B2 (en) Selecting processor micro-threading mode
CN113127134A (en) Container cluster, multi-tenant deployment method based on container cluster and electronic equipment
US10810032B2 (en) System and method for dynamic guest-controlled halt polling using a CPU governor
US10318278B2 (en) Power management data package provision method and apparatus
US9524193B1 (en) Transparent virtualized operating system
WO2020028509A1 (en) Method and apparatus for software isolation and security utilizing multi-soc orchestration
CN114595061A (en) Resource allocation method and device, electronic equipment and computer readable storage medium
CN110413349B (en) Service calling method and device, electronic 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