Image

An image is an image template used by a VM instance or volume.
  • Image templates include root volume images and data volume images.
  • Root volume images can be in the format of ISO or Image, while data volume images can be in the format of Image.
  • The Image format can either be raw or qcow2.
  • Images are stored on backup storage. If you are creating VM instances or volumes for the first time, the images will be downloaded to primary storage and stored as image caches.
When you create a VM instance, the type of the image platform decides whether to use a KVM Virtio driver (including disk driver and NIC driver). The supported image platforms are as follows:
  • Linux: Uses a Virtio driver.
  • Windows: Not to use a Virtio driver. Instead, QEMU is used. The image operating system is a Windows OS without a Virtio driver installed.
  • WindowsVirtio: Uses a Virtio driver. The image operating system is a Windows OS with a Virtio driver (including disk driver and NIC driver) installed.
  • Other: Not to use a Virtio driver. Instead, QEMU is used. The image operating system can be of any types.
  • Paravirtualization: Uses a Virtio driver. The image operating system can be any operating system with a Virtio driver installed.
To add an image, add a URL or upload a local file.
  1. URL: Adds an image through the specified URL.
    • HTTP/HTTPS:
      • Format: http://path/file or https://path/file
      • Example: http://cdn.zstack.io/product_downloads/images/zstack-image.qcow2
    • FTP:
      • Anonymous format: ftp://hostname[:port]/path/file

        Example: ftp://172.20.0.10/pub/zstack-image.qcow2

      • Non-anonymous format: ftp://user:password@hostname[:port]/path/file

        Example: ftp://zstack:password@172.20.0.10/pub/zstack-image.qcow2

    • SFTP:
      • Format with password specified: sftp://user:password@hostname[:port]/path/file

        Example: sftp://root:password@172.20.0.10/pub/zstack-image.qcow2

      • Password-free format: sftp://user@hostname[:port]/path/file

        Example: sftp://root@172.20.0.10/pub/zstack-image.qcow2

    • The absolute path on backup storage, which supports SFTP backup storage and ImageStore.

      Example: file:///opt/zstack-dvd/zstack-image-1.4.qcow2

    Note:
    • Before you enter a URL, make sure that the URL can be accessed by a backup storage and the corresponding backup storage file exists.
    • Before you upload an image by using the SFTP password-free method, make sure that password-free SSH access can be achieved between a backup storage and the SFTP server.
    • Smooth, continuous display of progress bar, and breakpoint resume:
      • The ImageStore backup storage supports smooth, continuous display of progress bar, and breakpoint resume.
      • The Ceph backup storage supports smooth, continuous display of progress bar, but does not support breakpoint resume.
      • The SFTP backup storage does not support smooth, continuous display of progress bar, or breakpoint resume.
    • If you upload an image by using file:///, make sure that:
      • The Ceph backup storage currently does not support the file:/// format.
      • The file:/// path contains three forward slashes (/), which correspond to the absolute path of the backup storage. For example, file:///opt/zstack-dvd/zstack-image-1.4.qcow2. The zstack-image-1.4.qcow2 file needs to be stored in the /opt/zstack-dvd directory of the backup storage.
  2. Upload a local file: You can upload an image that can be accessed by your current browser. Both ImageStore and Ceph backup storages are supported, as shown in Image Uploading via Local Browser.
    As shown in Figure 1.
    Figure 1. Image Uploading via Local Browser


    Note:

    When you add an image by uploading a local file, you use the local browser as a transit point. Therefore, do not refresh or close the current browser, and do not stop the management node service. Otherwise, the image might fail to be added.