This topic describes how to create a custom image and import it to Alibaba Cloud. If you want to create an instance that runs an operating system currently unavailable in Alibaba Cloud, you can create a custom image and import it to the ECS console. Then, you can use the custom image to create instances running the operating system.



  1. Create a new Virtual Machine (VM) on VirtualBox:
    1. Start VirtualBox and click New.
    2. Enter a name for the VM and select the correct OS type (for example, Microsoft Windows) and OS version (for example, Windows 7 (64-bit)).

    3. Set the memory size.

    4. Create a virtual hard disk.

    5. Select VHD (Virtual Hard Disk) as the hard disk file type. Alibaba Cloud supports RAW, VHD, and qcow2 formats.

    6. Select Dynamically allocated for the storage type.

    7. Enter a name for the virtual hard disk and click Create.

    8. Wait until the VHD file is created, and then double-click the newly created VM to launch it.

  2. Run the following command to install KVM virtualization platform drivers:
    yum install qemu-kvm qemu-img libvirt
  3. Run the following command to disable the firewall of the VM:
    service firewalld stop
  4. Upload the VHD file to OSS, and then use the ossbrowser to upload the VHD file to the region in which you want to create an instance. For more information, see ossbrowser quick start.

  5. Import the custom image:
    1. Log on to the ECS console.
    2. Select the same region that you selected for uploading the VHD file to OSS, and then click Import Image. For information about how to allow ECS to access your OSS resources, see Import custom images.

    3. Set the relevant parameters, and then click OK.
      • You can log on to the OSS console to obtain the OSS Object Address. For more information, see Download an object.
      • After the custom image is imported, it appears in the list of images.