Perform this task to create a VM on a host or in a cluster. To use a VM, you must install an operating system for it.
A VM labels the first added disk as vda or hda depending on the disk type. The operation system can be installed only on disk vda or hda. Make sure the size of disk vda is different from that of disk vdb, or you might mix them up and fail to install the OS correctly.
From the left navigation pane, select Data Center >Virtualization > Cluster name or Data Center >Virtualization > Cluster name > Host name.
Click the VMs tab.
Click Add VM and configure related VM parameters to create a VM.
Click OK.
Basic info:
Alias: Enter a VM name displayed on Space Console. The alias is configurable. The system automatically generates a name for identification when this VM is created. The generated name do not change with the modification of the alias.
Operating System: Select the operating system installed on the VM. X86 hosts support only Windows, Linux, and BSD operating systems. ARM hosts support only Kylin operating systems and Unity Operating System.
Version: Select the operation system version to create the VM. You might fail to install an operation system if its version is not the same as the selected version.
Host: Select a host for VM deployment.
Auto Migration: To have the VM automatically migrate in the cluster after the DRS policies take effect, enable auto migration.
Auto Driver Upgrade: Enable the VM to upgrade its driver when the driver version is lower than that of the current management platform. This feature is not supported by Kylin OS.
CPU parameters:
CPUs: Set the number of CPUs for the VM, The number of vCPUs of a VM cannot exceed the number of the CPUs on the host. To improve the processing performance of Windows 7 OS that supports a maximum of only 2 CPUs, you can set multiple cores for each vCPU.
CPU Cores: Specify the number of CPU cores. The number of CPU cores of a VM cannot exceed that of the host.
Operating Mode: Select a CPU operating mode.
Compatible—Virtualizes physical CPUs of different models into vCPUs of the same model. This mode features good migration compatibility.
Host Matching—Virtualizes physical CPUs of different models into vCPUs of different models. This mode features bad compatibility but provides better performance for OSs of VMs than the Compatible mode.
Passthrough—Enables the VM to access the physical CPUs directly. This mode features bad compatibility but provides better performance for OSs of VMs than the Compatible and Host Matching modes. To migrate a VM that uses the passthrough CPU operating mode, the source and destination hosts must use CPUs of the same model. ARM hosts do not support this parameter.
Simulate Physical Host: Enable physical host simulation, which allows applications to identify the VM as a physical host. This parameter is available only in host matching mode. ARM hosts do not support this parameter.
Architecture: Select a CPU architecture. This parameter is available only when you select Compatible as the CPU operating mode. The 32-bit architecture supports only 32-bit operating systems. If you select the 32-bit architecture for a VM using a 64-bit operating system, the VM cannot be started after being shut down. ARM hosts do not support this parameter.
Scheduling Priority: Select a priority for the processes on the VM to preempt physical CPU resources. You can modify the scheduling priority for an online VM. Options include Low, Medium, and High. The default priority is medium.
Reserve: Enter the number of CPUs that the host reserves for the VM.
Limit: Enter the maximum host CPU frequency that a single CPU core of the VM can use.
Overall CPU Limit: Select whether to enable overall CPU limit. For example, if you set maximum host CPU frequency that a single CPU core can use to 2000 MHz and enable overall CPU limit for a VM has 4 CPU cores, the maximum host CPU frequency is 8000 MHz for both the VM and a single CPU core of the VM.
Online Scale Down: Select whether to enable online CPU scale-down. Whether a VM supports online CPU scale-down depends on its operating system. If the OS does not support online CPU scale-down, the page will not display this argument. Make sure the hardware version of the VM is 2.7 or later. ARM hosts do not support this parameter.
Online Scale Up: Select whether to enable adding CPUs for online VMs. ARM hosts do not support this parameter.
I/O Priority: Select an I/O priority for the processes on the VM to read/write the disk. Options include Low, Medium, and High. The default priority is medium. ARM hosts do not support this parameter.
Memory parameters:
Memory Size: Specify the memory capacity of the VM. This setting is the memory size of the guest OS. The maximum memory size available for the VM depends on the physical memory size.
Reserve: Enter the memory to be reserved for the VM to the total available memory of the host in percentage. The host allocates specific memory to a VM based on the actual memory usage of the VM. You can reserve memory for a VM in case the VM needs more memory after the host memory is exhausted.
Limit: Enter the maximum host memory size that the VM can use.
Resource Priority: Select the priority for the VM to request memory resources.
Memory Ballooning: Enable or do not enable ballooning. With ballooning enabled, the system dynamically allocates host memory to VMs without shutting down VMs. After you perform memory hot-add for a VM, you cannot configure memory ballooning for the VM directly. To configure memory ballooning for the VM, you must shut down the VM, modify its memory, and starts the VM again.
HugePages: Configure whether the VM can use HugePages memory of the host. You can turn on this option only if the HugePages feature is enabled on the host and the VM is shut down. In addition, this feature is mutually exclusive with memory reservation, memory limit, resource priority, and ballooning.
Network parameters:
Network: Select a virtual switch for the VM.
Port Profile: Specify network parameters for the VM, including its VLAN, ACL, network bandwidth.
Virtual Firewall: Select a virtual firewall for the VM. The incoming and outgoing data packets of the VM will be filtered based on the firewall rules.
NIC Type: Select a NIC type for the VM. Options include Common NIC, High-Speed NIC, and Intel e1000 NIC. The default NIC type is high-speed NIC, which is CVK driven.
IPv4/IPv6 Bound to the NIC: The IP address bound to the MAC address of the VM. For the NIC to communicate correctly, you must make sure the IP address assigned to the NIC is the same as the bound IP address. The IPv6 address is displayed only when VM IPv6 Address Management is enabled.
MAC: Manually specify a MAC address. If you do not specify a MAC address, the system automatically assigns a MAC address to the VM.
Fast Forwarding: Enable fast forwarding to improve the network performance of the VM. This feature is available only for high-speed NICs.
Hot Swappable: Configure whether to enable hot swapping for the NIC or not. This parameter is available for high-speed NICs. ARM hosts do not support this parameter.
MTU: Set the MTU for the VM NIC. The default MTU is 1500.
Disk parameters:
Disk Capacity: Specify the disk size.
Type: Specify a disk type.
New File: For the VM, a file is a disk based on a virtual disk file. This disk type is more manageable than the block device disk type. If you select this option, an empty storage file is created as the disk of the VM.
Create RBD: If you select this option, create an RBD as the disk of the VM in an RBD storage pool.
Existing File: Specify an existing storage volume that is not used by other VMs. You can choose a volume from the local file directory, shared file system, or network file system storage pool as the disk of the VM. This parameter is available only when you create a VM on the host.
Block Device: A block device is also called a raw device that does not have a file system, for example, a storage LUN on an IP SAN or FC SAN. Block devices are typically used in a virtualization environment that requires high performance, for example, databases and high-performance I/O compute. This parameter is available only when you create a VM on a host. You can select a volume from the RBD, iSCSI, FC, or LVM logic storage pool as the disk of the VM.
Storage Pool: Select the storage pool on which the new disk is created.
File Name: Enter the file name of the disk if a new file is used as the disk. Select a disk formatting mode, which can be High Speed and Intelligent. The default mode is intelligent.
Intelligent.: Specify qcow2 disk format.
High Speed: Specify raw disk format. This format has a better I/O performance with a simple structure.
Provision: Storage volume provision mode. Options include Thin,Eager Zeroed, and Lazy Zeroed.
Thin—Allocates only as much storage space as the volume requires for its initial operations when the volume is created. If the volume requires more storage space later, you can allocate as much storage space as the volume requires as long as the maximum storage size is not exceeded.
Lazy Zeroed—Allocates the specified maximum storage size to the volume when the volume is created. Data remaining on the physical device is not erased during creation, but is zeroed out on first write from the VM.
Eager Zeroed—Allocates the specified maximum storage size to the volume when the volume is created. Data remaining on the physical device is zeroed out during creation. It might take a longer time to create volumes in this mode than to create volumes in other modes.
Disk Cluster Size: Set the smallest amount of disk space that can be used to store a file. If a file is larger than a disk cluster, it is stored in multiple disk clusters. If a file is smaller than a disk cluster, it is stored in a dedicated disk cluster. A shared file system is mainly used to store VM image files. As a best practice, set the value of this parameter as large as possible to enhance disk read performance and save disk space. You must configure this parameter when you add an intelligent disk.
Bus Type: Select a bus type. Options include IDE, USB, High-Speed, and High-Speed SCSI. ARM hosts support only the High-Speed SCSI options.
Cache Mode: Select a cache mode for VM storage files. Options include Directsync, Writethrough, Writeback, and None. The default cache mode for intelligent disk format is Directsync. For raw or block (including RBD) device disk format, the default cache mode is None.
Directsync—The system reads data from the physical disk.
Writethrough—The system writes data to the host cache, and then to the physical disk.
Writeback—The system writes data to the VM cache, then to the host cache, and finally to the physical disk.
None—The system writes data to the VM cache, and then to the physical disk.
Hot Swappable: Enable or disable disk hot swapping. This option is available only for the high-speed bus type. ARM hosts do not support this parameter.
Floppy disk parameters:
Floppy Disk: Select a floppy disk image. The system will automatically load the high-speed driver compatible with the selected OS version.
CD Drive parameters:
CD Drive: Select a CD/DVD or image file. To avoid migration failure when the destination host does not have a physical CD-ROM drive, unmount the physical CD-ROM drive from a VM after the VM finishes using that drive.
Connection Mode: Select a connection mode for the CD drive. Options include Install Driver, Image, and CD/DVD.
Install Driver: Load Agenttools. The default CD-ROM drive is /vms/isos/agenttools.iso.
Image: Enable OS installation for the VM by loading the mirroring of the system. Make sure the system mirroring has been uploaded to the management platform before enabling this mode.
CD/DVD: The default CD-ROM drive is /dev/cdrom and is unchangeable. This parameter is supported only when you create a VM in a cluster.
Hardware parameters:
Add Hardware: Select the hardware to add for the VM, including NIC, disk, CD-ROM drive, floppy drive, GPU device, USB device, remote USB device, PCI device, and watchdog. ARM hosts only support NIC, disk, CD-ROM drive, and floppy drive. As a best practice to ensure the startup of a VM, follow these restrictions when you add PCI devices for a VM:
If the memory size of a VM is smaller than 2 GB, the total memory size of PCI devices added to the VM cannot exceed 2 GB.
If the memory size of a VM is larger than 2 GB, the total memory size of PCI devices added to the VM cannot exceed 1 GB.
GPU Device: Select a Graphics Processing Unit (GPU) device. A GPU device acts as a CPU to process images so that the CPU can perform other tasks. A VM that has a GPU or vGPU device mounted does not support the following actions in running state: hibernate, clone as template, convert as template, take a snapshot, clone, migrate to another host without changing the storage, and migrate to another host with storage changed.
Resource Pool: Select a resource pool, which contains all available GPUs in the cluster. If you select a GPU resource pool, the VM accesses the physical GPU resources of the host through GPU passthrough. If you select a vGPU resource pool, the VM accesses the vGPU resources of the host.
Service Template: Select a service template. The service template defines the rule that how VMs use the GPU resources on the host. The host allocates these resources to VMs based on the priorities of the VMs.
Driver Type: Select a driver type for PCI or GPU device..
Exclusive Mode: Select whether the VM can exclusively use the specified GPU/vGPU resources. If you select Yes, the GPU/vGPU resources cannot be used by any other VMs. This feature is available only when the host has available GPU/vGPU resources that have been added to the selected GPU resource pool. To migrate a VM when this feature is enabled, make sure the target host has sufficient GPU/vGPU resources and the VM is powered off.
Resource Count: Set the maximum number of GPU/vGPU resources that can be used by the VM. The value depends on the resource pool type and state of the exclusive mode feature:
If you select a vGPU resource pool, only 1 is available.
If you select a GPU resource pool and exclusive mode is disabled, the value is the maximum number of GPUs on a single host in the resource pool. For example, if the resource pool has three hosts, and the hosts have three, two, and two GPUs, respectively, the value is 3.
If you select a GPU resource pool and exclusive mode is enabled, the value is the number of available GPUs on the host attached to the VM.
USB Hard Disk: Add a USB to the VM. This option is available only if you select a host when you create the VM.
Connection Mode: Set the USB connection standard. Options include USB 1.0, USB 2.0, and USB 3.0 (the default).
Remote USB: Add a remote USB to the VM. If a remote USB is used, the VM can continue to use that USB after it migrates to a new host. This option is available only if you select a host when you create the VM.
Connection Mode: Set the network USB connection standard. Options include USB 1.0, USB 2.0, and USB 3.0 (the default).
PCI Device: Add a PCI device to the VM. This option is available only if you select a host when you create the VM. As a best practice to ensure the startup of a VM, follow these restrictions when you add PCI devices for a VM:
If the memory size of a VM is smaller than 2 GB, the total memory size of PCI devices added to the VM cannot exceed 2 GB.
If the memory size of a VM is larger than 2 GB, the total memory size of PCI devices added to the VM cannot exceed 1 GB.
Driver Type: Set the PCI device driver type. Only VFIO is supported.
Watchdog: Set the timer to monitor the state of the VM and resume the VM.