Prepare Images, Templates, and VM Specifications

Images, templates, and VM specifications preserve the software media, hardware configuration, and operating system initialization information required for VM deployment. Administrators can prepare image storage, add images, create templates, or create VM specifications before deployment to improve VM provisioning efficiency.

Image storage stores system images, disk images, and template files. VM templates are suitable for reusing virtual machine environments that have already been installed and configured. VM specifications are suitable for automatically configuring operating system parameters when you create virtual machines.

Image Storage Management

Image storage works as a repository for image templates that contain operating systems and for disk images. You can use image storage to share image files across data centers.

Before you create a virtual machine, prepare image storage and then add system images, disk images, or OVA templates to the image storage. The status of image storage affects operations such as image upload, synchronization, migration, and template creation.

Add a Standalone Image Storage

A standalone image storage stores image files as image slices and supports incremental storage.

Procedure

  1. In the navigation pane, choose Inventory > Image and Template.
  2. Right-click the target data center and choose Add Image Storage.
  3. In the Select Image Storage Type dialog, choose Standalone Image Storage.
  4. Click Next.
  5. In the Add Image Storage dialog, configure the following options to complete basic configurations:
    1. Configure basic information.
      Option Description
      Name Image storage name.
      Description Enter a brief description for the image storage.
      Type Displays Standalone Image Storage.
      Data Center Current data center.
    2. Configure image storage information.
      Option Description
      Image Storage IP IP address of the image storage server.
      SSH Port Default port: 22. You can specify an SSH port.
      Username Default user: root. You can specify a regular user.
      Password Password of the user.
  6. Click Next.
    The system tests connectivity to the image storage IP address.
  7. Set the following parameters to complete storage configuration:
    1. Configure disk information.
      Option Description
      Addition Method Supports Free Disk and Local Directory addition methods.
      Free Disk When you select Free Disk, add free disks that are unmounted or unpartitioned on the image storage.
      Note: Configuring a free disk formats the selected disk and permanently removes all partitions, file systems, and data on the disk.
      Mount Path Absolute path of the storage mounted on the image storage.
      Note: Do not use /, /dev/, /proc/, /sys/, /usr/bin, /bin, or other system directories. Otherwise, image storage might work abnormally.
      Retrieve Existing Images Disabled by default. If enabled, the system retrieves existing image files from the mount path of this image storage.
      Image Sync Network Network CIDR used for image synchronization between standalone image repositories under the same management node. If left blank, the management network is used by default. If both the source and target image repositories are configured with this parameter, only the image sync network of the target image storage takes effect.
      Data Network Network CIDR used for data communication between compute nodes and image storage. If left blank, the management network is used by default.
    2. Configure advanced settings.
      Option Description
      Reserved Capacity for Image Storage Default: 1 GB. Capacity reserved for image storage.
      Image Blob Upload Concurrency Default: 1. Concurrency for uploading image blobs when a single image is uploaded. Valid range: 1 to 16.
      Image Blob Download Concurrency Default: 1. Concurrency for downloading image blobs when a single image is downloaded. Valid range: 1 to 16.
  8. Review the configuration and click OK.

Add a Distributed Image Storage

A distributed image storage stores image files on distributed block storage.

Procedure

  1. In the navigation pane, choose Inventory > Image and Template.
  2. Right-click the target data center and choose Add Image Storage.
  3. In the Select Image Storage Type dialog, choose Distributed Image Storage.
  4. Click Next.
  5. In the Add Image Storage dialog, configure the following options:
    1. Configure basic information.
      Option Description
      Name Image storage name.
      Description Enter a brief description for the image storage.
      Type Displays Distributed Image Storage.
      Data Center Current data center.
    2. Configure image storage information.
      Option Description
      Monitor Node To add a monitor node, specify the management IP address, SSH port, username, and password of the monitor node.
      Image Storage Pool You can create a storage pool in the distributed storage cluster in advance and enter the UUID of the pool. If left blank, the system automatically creates an image storage pool.
      Data Network Network CIDR used for data communication between compute nodes and image storage. If left blank, the management network is used by default.
    3. Configure advanced settings.
      Option Description
      Reserved Capacity for Image Storage Default: 1 GB. Capacity reserved for image storage.
      Image Blob Upload Concurrency Default: 1. Concurrency for uploading image blobs when a single image is uploaded. Valid range: 1 to 16.
      Image Blob Download Concurrency Default: 1. Concurrency for downloading image blobs when a single image is downloaded. Valid range: 1 to 16.
  6. Review the configuration and click OK.

Manage Image Storage

You can modify image storage settings, view resource usage, clean up data, or delete image storage as needed.

Common Entries

You can manage image storage from the following entries:

  • In the navigation pane, choose Inventory > Image and Template, and right-click the target image storage.
  • Go to the target image storage page and click Actions.
  • Go to the Image Storage tab of a data center and perform batch operations.

Common Operations

Operation Description
Edit Name and Description Modify the name and description of the image storage.
Modify Configuration Modify the configuration of the image storage.
Update Password Update the password of the image storage. After the password is updated, reconnect the image storage manually for the change to take effect.
View Usage View image storage usage.
Data Cleanup Clean up permanently deleted invalid data and expired temporary data in the image storage.
Note: After an image file is permanently deleted and the virtual machines created from the image are permanently deleted, data cleanup releases the storage space occupied by the image storage. Avoid write operations during data cleanup.
View Monitoring Data View trends of image storage capacity, CPU, memory, disk resource usage, and NIC usage over time.
Delete Image Storage Delete existing image storage. You can also delete image storage in bulk on the Image Storage tab of the data center.

Image Storage Status

Image storage has two status categories: state and status. Each category has a different meaning and supports different operations.

State

State indicates whether image storage is enabled or disabled by an administrator.
  • Enabled: You can add images to this image storage and create virtual machines from the images on this image storage.
  • Disabled: You cannot add new images. Existing images are not affected and can still be used to create virtual machines.

Status

Status indicates the network connection between image storage and the management node, including Connecting, Connected, and Disconnected. When the network is unstable, the image storage status might change. You can reconnect image storage to change its status.

Add an Image

You can add system images or disk images in multiple formats to image storage. When you create a virtual machine for the first time, the system downloads the image to a data storage as an image cache. You can add QCOW2, ISO, RAW, or VMDK image files to image storage by URL or local upload.

Procedure

  1. In the navigation pane, choose Inventory > Image and Template.
  2. Right-click the target image storage and choose Add Image.
  3. In the Add Image dialog, configure the following options:
    Option Description
    Image Storage Current image storage.
    Image Path Add an image by URL or by uploading a local file.
    URL Supports HTTP, HTTPS, FTP, and SFTP URLs, or an absolute path on a standalone image storage.
    Upload File Select an image file that can be accessed by the current browser and matches the selected image format, and upload it directly. Interrupted local file uploads can be resumed.
    Note:
    • The system automatically retries recoverable upload errors. If an upload is paused due to a network interruption and the page remains open, the upload resumes automatically after the network recovers.
    • If the browser retains permission to access the original local file after the page is refreshed or you sign in again, the system automatically resumes an upload that was paused due to an error. If the browser prompts you to allow access to previously selected files or folders, grant access as needed.
    • If the browser does not have permission to access the file or the permission has expired, the upload cannot resume automatically. Click Pending Uploads at the top of the page. In the Pending Upload Tasks panel, locate the task, click Select to Continue, and reselect the same local file.
    • A manually paused task does not resume automatically. In the task details, click Continue.
    • If the local file has been modified, moved, or deleted, the original upload task cannot resume. Start a new upload.
    • If an upload error occurs, the platform automatically retries the upload up to five times. If all five retry attempts fail, the upload task enters the Failed state and cannot be resumed. Start a new upload.
    • Click View Upload History to view local file upload tasks.
    Name Image name.
    Description Enter a brief description for the image.
    Image Type Image type, including system image and disk image.
    Image Format Available image formats vary by image type. Supported formats include .qcow2, .iso, .raw, and .vmdk files.
  4. Review the configuration and click OK.

Synchronize Images

About this task

Under the same management node, you can synchronize one or more images from a standalone image storage to a specified standalone image storage.

Image synchronization between image storage uses the management network by default. You can also configure a separate image synchronization network when you add an image storage or modify image storage configuration to reduce pressure on the management network. If both the source and target image storage are configured with image synchronization networks, only the image synchronization network of the target image storage takes effect during synchronization.

Procedure

  1. In the navigation pane, choose Inventory > Image and Template.
  2. Select the target image storage.
  3. On the image storage details page, click Image.
  4. On the Image tab, select the target image.
  5. Click Actions > Synchronize Image.
  6. In the Synchronize Image dialog, select the target standalone image storage.
  7. Click OK.

Migrate an Image

Before you begin

  • Only migration between distributed image storage is supported.
  • Before you migrate an image, make sure that the monitoring nodes of the two distributed image storage can communicate with each other.
  • If an ISO image is migrated across data centers, virtual machines that use the ISO image must detach the image before they can start properly after the migration.

Procedure

  1. In the navigation pane, choose Inventory > Image and Template.
  2. Right-click the target image and choose Change Image Storage.
  3. In the Change Image Storage dialog, select the target distributed image storage.
  4. Click OK.

What to do next

After migration, the original image data remains in image storage. You can manually clean up the data in the image storage. The cleanup cannot be undone. Proceed with caution.

Delete an Image

Before you begin

Optional: The platform provides an image deletion protection mechanism. You can control deletion behavior by adjusting the deletion policy in system parameters. By default, the image deletion policy is delayed deletion, which keeps deleted resources for three days. Deleted resources are first moved to the recycle bin and then permanently deleted after the retention period expires.

Procedure

  1. In the navigation pane, choose Inventory > Image and Template.
  2. Select the target image.
  3. On the image details page, click Actions > Move to Recycle Bin.
    To delete images in bulk, select target images on the Images tab of the image storage, and then click Bulk Actions > Move to Recycle Bin.
    The delete button name changes according to the Image Deletion Policy setting. If the deletion policy is immediate deletion, the button name is Delete. If the deletion policy is delayed deletion or never deletion, the button name is Move to Recycle Bin.
  4. After you acknowledge the risk information, click OK.

Export an Image

Select an image and export it. The exported image is displayed on the Export List tab of the root node. Exported images cannot be exported again.

Procedure

  1. In the navigation pane, choose Inventory > Image and Template > Image Files.
  2. Right-click the target image file and choose Export Image.
  3. In the Export Image dialog, select an export method and click OK.
    Note:
    • For large image files, select Export Only. After export, you can view and download the file from the Export List page.
    • For small and medium-sized image files, select Export and Download.

Export an OVA Template

Export a virtual machine in .ova format to a standalone image storage in the same data center. The exported OVA template does not include ISO CD-ROMs or GPU devices.

Before you begin

  • The virtual machine is shut down.
  • VM encryption and disk encryption are disabled. An encrypted VM cannot be exported as an OVA template.

Procedure

  1. In the navigation pane, choose Inventory > VM and Host.
  2. Right-click the target virtual machine and choose Template > Export OVA Template.
  3. In the Export OVA Template dialog, select an export method and image storage, and click OK.
    Note:
    • For virtual machines with large files, select Export Only. After export, you can view and download the exported file from the Export List page.
    • For virtual machines with small or medium-sized files, select Export and Download.
  4. After export is complete, click Inventory > Root Node.
  5. Click Export List to view the exported VM OVA template.
    Figure 1. View Exported VM OVA Templates


VM Template Management

A VM template is a set of virtual machine operating system, application, and feature configurations. You can use VM templates to quickly deploy virtual machines with the same attributes in batches, improving efficiency and consistency.

Clone a VM to a Template

Clone a virtual machine to a template. The source virtual machine can continue to be used after it is cloned to a template.

Before you begin

  • The virtual machine power state must be Running, Paused, Stopped, or Crashed.
  • The virtual machine must not have shared disks or RDM disks attached. If any are attached, detach them before cloning the virtual machine to a template.
  • VM encryption and disk encryption must be disabled. An encrypted VM cannot be cloned to a template.

Procedure

  1. In the navigation pane, choose Inventory > VM and Host.
  2. Select the target virtual machine and click Actions > Clone > Clone to Template.
  3. In the Clone Virtual Machine to Template dialog, configure the following options:
    Option Description
    Name Enter a template name.
    Note: The name must be unique and cannot duplicate the names of existing virtual machines or templates.
    Description Enter a brief description for the template.
    Data Storage Location where the template is stored. By default, it is the same as the source virtual machine data storage.
    Tags Attach tags to identify different templates.
    Note: If the virtual machine has GPU, USB, or PCIe devices attached, except PCIe devices automatically attached by SR-IOV NICs, the cloned template does not include these peripheral devices. To keep these devices, you can convert the virtual machine to a template.
  4. Review the configuration and click OK.

What to do next

After you clone the virtual machine to a template, you can use the template to quickly deploy virtual machines with the same attributes.

You can modify the template without affecting normal use of the source virtual machine.

Convert a VM to a Template

Convert a shutdown virtual machine to a template. After the source virtual machine is converted to a template, it can be used only as a template and is removed from the virtual machine navigation tree. The template is displayed in the Image and Template > Template File navigation tree.

Before you begin

  • The virtual machine must be shut down.
  • The virtual machine must not have shared disks or RDM disks attached. If any are attached, detach them before converting the virtual machine to a template.
  • The virtual machine must not be associated with any backup plans. If it is associated with one, disassociate it before converting the virtual machine to a template.
  • VM encryption and disk encryption must be disabled. An encrypted VM cannot be converted to a template.

Procedure

  1. In the navigation pane, choose Inventory > VM and Host.
  2. Select the target virtual machine and click Actions > Template > Convert to Template.
  3. Review the selected target and click OK.

What to do next

After you convert the virtual machine to a template, you can use the template to quickly deploy virtual machines with the same attributes.

Convert a Template to a VM

Convert a template directly to a virtual machine. To edit template configuration or when you no longer need to keep the virtual machine as a deployment template, convert the template to a virtual machine.

Procedure

  1. In the navigation pane, choose Inventory > Image and Template.
  2. In the Template File list, select the target template and click Actions > Convert to Virtual Machine.
  3. In the Convert to Virtual Machine dialog, configure the following options:
    Option Description
    Name Enter a virtual machine name.
    Power Status Choose whether to automatically power on the VM after conversion.
    Location Automatically assigned by default. Select the host or cluster where the virtual machine runs.
    • In local storage scenarios, you cannot specify the VM location. By default, the virtual machine runs on the host where local disks reside.
    • In non-local storage scenarios, you can specify the VM location.
  4. Review the configuration and click OK.

What to do next

After you convert the template to a virtual machine, you can adjust the virtual machine configuration as needed and then convert the virtual machine back to a template.

Create a VM from a Template

Create identical virtual machines from a template. You can customize hardware, software, and configuration for the new virtual machines based on the template.

Before you begin

  • The platform provides VM-related system parameters that globally control default platform behavior. Before creating virtual machines, you can customize VM-related system parameters to control default VM features.
  • Before you create virtual machines from a template, make sure that a VM template already exists in the platform.
  • To enable VM or disk encryption, make sure that an available default key provider is configured. If you use the Native Key Provider, back it up first. For more information, see Encryption Keys and How Encryption Works.

Procedure

  1. In the navigation pane, choose Inventory > VM and Host.
  2. Right-click a valid parent resource of the virtual machine, such as a cluster or host, and choose New Virtual Machine.
  3. In the Select VM Creation Type dialog, select From Template.
  4. Click Next.
  5. In the Select Virtual Machine Template dialog, select the target template and click OK.
  6. In the Create Virtual Machine from Template dialog, configure the following options:
    1. Configure template information.
      Option Description
      Template Select a template and create virtual machines from it.
    2. Configure basic information.
      Option Description
      Name Virtual machine name.
      Quantity Number of virtual machines to create.
      Note: When creating multiple virtual machines from a template, the following configurations will be cleared:
      • Added GPU, USB, and PCIe devices
      • Manually specified IP address
      Group Group to which the virtual machine belongs. If not specified, the default group is used.
      Location Host or cluster where the virtual machine runs.
      OS Virtual machine operating system. Mainstream operating systems are supported, including Linux and Windows.
      HA Mechanism for automatically restarting a virtual machine after an abnormal shutdown. Enabled by default.
      VM Encryption Encrypts runtime data written to disk, such as memory and GPU state, by using a key from the default key provider. Enabling this option automatically enables Disk Encryption for all disks. For more information, see VM Encryption.
      Power Status Whether to automatically power on the virtual machine after creation. Enabled by default.
    3. Configure hardware information.
      Option Description
      CPU Supports adjusting the total number of cores and the number of cores per socket, and configuring CPU hot plug.
      Memory Supports adjusting memory size and configuring memory resource priority.
      Disk

      You can modify the following settings for an existing disk:

      • Adjust the disk cache mode and configure AIO acceleration.
      • Disk Encryption: Encrypts all data stored on the disk by using a key from the default key provider. You can encrypt an individual disk even when VM encryption is disabled. Disk encryption and shared-disk mode are mutually exclusive.

      Click Add Hardware > Disk to add a disk to the VM. You can customize the capacity and features of the new disk.

      NIC Supports adjusting NIC model, port group, multi-queue count, MAC address, IP address, and DNS assignment mode. You can click Add Hardware > NIC to add a new NIC to the virtual machine. You can customize the address and features of the new NIC.
      CD/DVD Drive Supports attaching an ISO image file to the virtual machine so that the virtual machine can boot from the ISO CD-ROM.
      GPU Device 1 Attach a GPU device to the virtual machine. Physical GPU devices and vGPU devices are supported. Click Add Hardware > GPU Device to add a GPU device.
      USB Device 1 Attach a USB device to the virtual machine. Direct connection and forwarding are supported. Click Add Hardware > USB Device to add a USB device. A single virtual machine supports at most one USB device.
      PCIe Device 1 Attach a PCIe device to the virtual machine. PCIe devices switched to passthrough mode on the host are supported. Click Add Hardware > PCIe Device to add a PCIe device.
      Other Hardware The video card, sound card, and motherboard configuration in a template file cannot be modified.
    4. Configure advanced settings.
      General Options
      Option Description
      Description Displays the description recorded in the template by default. You can modify the virtual machine description.
      Tag Displays the VM tags recorded in the template by default. You can modify tags.
      OS Attribute Configures the VM operating system attributes.
      • Do Not Customize: Inherits the hostname, administrator password, workgroup or domain configurations from the template.
      • Apply a Specification: Select an existing VM specification to apply the system configuration specified in the specification.
      • Manually Customize: Customize a new VM specification.
  7. Review the configuration and click OK.

What to do next

Some virtual machine configurations depend on VMTools. After the virtual machine is created, install VMTools to make these configurations take effect. For more information about VMTools, see Install and Use VMTools.

Manage VM Templates

Modify VM templates as needed based on service scenarios, including editing the name and description, modifying configuration, and changing the owner. If you no longer need a template, delete it.

Common Entries

You can manage VM templates from the following entries:

  • Go to the target template page and click Actions.
  • Go to the Image and Template tab of the data center that contains the templates and perform batch operations.

Common Operations

Operation Description
Edit Name and Description Modify the name and description of a template.
Note: The new name must be unique and cannot duplicate the names of existing virtual machines or templates.
Modify Configuration

Modify template basic information, total CPU cores, CPU cores per socket, memory size, or disk capacity.

To make extensive changes to template configuration, convert the template to a virtual machine, adjust the configuration as needed, and then convert the virtual machine back to a template for later use.

Change Owner Specify the owner of a template.
Delete VM Templates Delete a single template, or delete templates in bulk on the Image and Template tab of the data center that contains the templates.
Note: After a template is deleted, its template files, including NIC files, disk files, and database records, cannot be restored. Proceed with caution.

VM Specification Management

You can create and manage customization specifications for Windows or Linux virtual machine operating systems. A VM specification is a file that contains virtual machine operating system configuration.

VM customization specifications help avoid conflicts during batch deployment from templates, such as duplicated hostnames or SIDs.

Create a Windows VM Specification

Save specific Windows VM operating system settings in a customization specification, such as how the virtual machine participate in the network and hostname configuration.

Before you begin

The following operating system versions support customization specification for virtual machines:
  • Windows Server 2012
  • Windows Server 2016
  • Windows Server 2019
  • Windows Server 2022
  • Windows Server 2025
  • Windows 10 Pro

Procedure

  1. In the navigation pane, choose Inventory > VM and Host.
  2. Select the root node.
  3. On the root node details page, click VM Specifications.
  4. On the VM Specifications tab, click New VM Specification.
  5. In the New VM Specification dialog, configure the following options:
    Option Description
    Name Enter a name for the VM customization specification.
    Description Enter a brief description for the VM specification.
    Target VM OS Select Windows.
    Workgroup or Domain Select how the virtual machine participates in the network. Options include workgroup and Windows domain server. For workgroup, you need to specify the workgroup name and choose whether to generate a new SID.
    Note: The workgroup name must 1 to 15 characters in length and can contain letters, numbers, underscores (_), dots (.), and hyphens (-). The workgroup name cannot be all numbers.
    For Windows domain server, you need to configure the domain name, domain username, domain password, OU, and choose whether to generate a new SID.
    Note:
    • The domain name must be 1 to 26 characters in length and can contain letters, numbers, underscores (_), dots (.), and hyphens (-).
    • The domain username must 1 to 15 characters in length and can contain letters, numbers, underscores (_), dots (.), and hyphens (-). The domain username cannot be all numbers.
    • OU example: OU=MyOU,DC=MyDom,DC=MyCompany,DC=com
    Specify Hostname Select how to configure a VM hostname. Options include using the VM name and entering a name.
    Note:
    • When you use the virtual machine name as the hostname, the Windows VM name will be truncated if it exceeds 15 characters.
    • The following rules apply for specifying a Windows hostname:
      • Length: 2 to 15 characters.
      • Allowed characters: Uppercase and lowercase letters, numbers, and hyphens (-).
      • No consecutive hyphens. You cannot start or end with a hyphen. The hostname cannot be all numbers.
    • When creating multiple VMs at once, a suffix (-1, -2, -3, etc.) is automatically appended to ensure uniqueness.
    Administrator Password Set the administrator password.
    Note: The password must contain 8 to 16 characters and at least two of the following character types: lowercase letters, uppercase letters, digits, and special characters.
    Confirm Password Enter the password again for confirmation.
  6. Review the configuration and click OK.

Create a Linux VM Specification

Save specific Linux VM operating system settings in a customization specification, such as the hostname configuration.

Procedure

  1. In the navigation pane, choose Inventory > VM and Host.
  2. Select the root node.
  3. On the root node details page, click VM Specifications.
  4. On the VM Specifications tab, click New VM Specification.
  5. In the New VM Specification dialog, configure the following options:
    Option Description
    Name Enter a name for the VM customization specification.
    Description Enter a brief description for the VM specification.
    Target VM OS Select Linux.
    Specify Hostname Select how to configure a VM hostname. Options include using the VM name and entering a name.
    Note:
    • When you use the virtual machine name as the hostname, the Linux VM name will be truncated if it exceeds 60 characters.
    • The following rules apply for specifying a Linux hostname:
      • Length: 2 to 60 characters.
      • Allowed characters: Uppercase and lowercase letters, numbers, and hyphens (-).
      • No consecutive hyphens. You cannot start or end with a hyphen.
    • When creating multiple VMs at once, a suffix (-1, -2, -3, etc.) is automatically appended to ensure uniqueness.
    Administrator Password Set the administrator password.
    Note: The password must contain 8 to 16 characters and at least two of the following character types: lowercase letters, uppercase letters, digits, and special characters.
    Confirm Password Enter the password again for confirmation.
  6. Review the configuration and click OK.

Manage VM Specifications

Procedure

  1. In the navigation pane, choose Inventory > VM and Host.
  2. Select the root node.
  3. On the root node details page, click VM Specifications.
  4. On the VM Specifications tab, select the target VM specification.
    Action Description
    Actions > Edit Name and Description Modify the name and description of the VM specification.
    Actions > Modify Configuration Modify VM specification configuration, such as network participation mode, host name configuration method, and administrator password reset.
    Actions > Delete Delete the VM specification.