Updated on 2024-07-12 GMT+08:00

Registering an External Image File as a Private Image

Scenarios

Register an image file uploaded to the OBS bucket as a private image.

Procedure

  1. Access the IMS console.

    1. Log in to the management console.
    2. Under Compute, click Image Management Service.

      The IMS console is displayed.

  2. Register an external image file as a private image.

    1. Click Create Image in the upper right corner.
    2. Set image parameters.

      Table 1 and Table 2 list the parameters in the Image Type and Source and Image Information areas, respectively.

      Table 1 Image type and source

      Parameter

      Description

      Type

      Select System disk image.

      Source

      Select Image File for Source. Select the bucket storing the image file from the list and then select the image file.

      Enable Fast Create

      This parameter is available only when you select a ZVHD2 or RAW image file.

      This function enables fast image creation and supports import of large files (maximum: 1 TB) as long as the files to be uploaded are converted to ZVHD2 or RAW format and optimized. If you have a file that meets the requirements, select Enable Fast Create and select the confirmation information following Image File Preparation.

      NOTE:

      To learn how to convert image file formats and generate bitmap files, see Fast Import of an Image File.

      Table 2 Image information

      Parameter

      Description

      Enable automatic configuration

      If you select this option, the system will automatically check and optimize the image file. For details, see What Will the System Do to an Image File When I Use the File to Register a Private Image?

      Function

      Specifies whether the image is used to create ECSs or BMSs. The value can be ECS system disk image or BMS system disk image. This section uses ECS system disk image as an example.

      Architecture

      Specify Architecture. Select x86 or ARM.

      • If the system detects an architecture type different from that you set, the architecture type detected by the system will be used.
      • If the system fails to detect the architecture type, the architecture type you set will be used.

      Boot Mode

      This parameter is optional. The value can be BIOS or UEFI. For details about the differences between them, see How Is BIOS Different from UEFI?

      For details about which OSs support UEFI boot, see OSs supporting UEFI Boot Mode.

      The boot mode must be the same as that in the image file. You need to confirm which boot mode is used in the image file. After you select the correct boot mode, the boot mode will be configured for the image at the background. Select the right boot mode, or ECSs created using the image will not be able to boot up.

      OS

      To ensure that the image can be created and used properly, select an OS consistent with that in the image file. If you do not select an OS, the system attempts to automatically identify the OS in the image file.

      NOTE:
      • If the system detects that the image file OS is different from the one you selected, the OS detected by the system will be used.
      • If the system cannot detect the OS in the image file, the OS you selected will be used.
      • If the OS you selected or identified by the system is incorrect, ECSs created from the image file may be affected.

      System Disk (GB)

      The system disk capacity (value range: 40 GB to 1024 GB). Ensure that this value is at least equal to the system disk capacity in the image file.

      NOTE:

      If the uploaded VHD image is generated using qemu-img or similar tools, check the system disk capacity based on What Do I Do If the System Disk Capacity in a VHD Image File Exceeds the One I Have Specified on the Management Console When I Use This File to Register a Private Image?

      Data Disk (GB)

      You can also add data disks to the image. You need to obtain an image file containing data disks in advance. This function is used to migrate VMs and data disks from other platforms to the current platform.

      To add data disks, click , configure the data disk capacity, and click Select Image File. In the displayed dialog box, select the target bucket and then the target image file containing the data disk.

      A maximum of three data disks can be added.

      Name

      Set a name for the image.

      Encryption

      (Optional) If you want to encrypt the image, select KMS encryption and select the key to be used from the key list. After you select KMS encryption, the system will create a default key ims/default for you. You can also select a key from the key list.

      For how to encrypt an image, see Creating Encrypted Images.

      Enterprise Project

      Select an enterprise project from the drop-down list. This parameter is available only if you have enabled enterprise projects or your account is an enterprise account.

      An enterprise project provides central management of cloud resources on a project by project basis.

      Tag

      (Optional) Set a tag key and a tag value for the image to make identification and management of your images easier.

      Description

      (Optional) Enter a description of the image.

    3. Click Next and confirm the image specifications. Select Statement of Commitment to Image Creation and Huawei Image Disclaimer. Click Submit.

  3. Go back to the Private Images page. The image is successfully registered when its status becomes Normal.

    If you add data disks during image creation, a system disk image and data disk images will be generated. The number of data disk images depends on the number of data disks you add (a maximum of 3).

    The time required for image registration is determined by the image file size. You may need to wait a long period of time for the image file to be successfully registered as a private image.