All Products
Search
Document Center

Elastic Compute Service:Overview

Last Updated:Feb 06, 2024

Alibaba Cloud provides the Image Family feature that allows you to group related images together to better manage and use images. If you specify an image family when you create Elastic Compute Service (ECS) instances, the latest image that is in the Available state in the image family is automatically used.

Features

  • You can use an image family to create ECS instances only by calling API operations. When you call the RunInstances or CreateInstance operation to create an ECS instance, specify the ImageFamily parameter instead of the ImageId parameter. In this case, the latest image that is in the Available state in the specified image family is automatically used to create the ECS instance. For more information, see Create an ECS instance from an image family.

    Note
    • Image families recognize the latest images based on the image creation time. The image that has the most recent creation time is the latest image. Each image family always points to the latest image that is in the Available state. For example, if an image family contains one available image that was created on January 01, 2020 and the other available image that was created on January 03, 2020, the image that was created on January 03, 2020 is automatically selected when you use the image family to create ECS instances.

    • If you add images from multiple regions to an image family and use the image family to create ECS instances in a region, the latest image that belongs to the image family and is available in the region is automatically used to create the ECS instances.

  • You can deprecate or restore custom images in image families. To create ECS instances by using a previous image version in an image family, deprecate or delete the latest image that is in the Available state in the image family and then use the image family to create ECS instances. You can deprecate or restore an image in the ECS console or by calling the ModifyImageAttribute operation.

  • You can call the DescribeImageFromFamily operation to query the latest image that is in the Available state in an image family and call the DescribeImages operation to query the name of the image family to which an image belongs.

  • Public images, custom images, shared images, and community images support image families. The following table describes how to configure image families for different types of images.

    Image type

    Description

    Public images

    By default, public images have image family information. For more information, see Overview of public images.

    Custom images

    You can specify an image family when you create custom images or modify the attributes of custom images. For more information, see Set an image family.

    Note
    • The image family names of custom images cannot start with acs.

    • When you copy custom images, the image copies do not inherit the image family information of the copied custom images.

    Shared images

    • If you do not add a source custom image to an image family, the shared image does not have image family information.

    • If you add a source custom image to an image family, the shared image has image family information.

      • Sharer: the image family of the source custom image

      • Sharee: acs:<ID of the Alibaba Cloud account that shares the source custom image>:<Image family name>

    Community images

    • If you do not add a custom image that is published as a community image to an image family, the community image does not have image family information.

    • If you add a custom image that is published as a community image to an image family, the community image has image family information.

      • Image provider: the image family of the custom image

      • Image user: acs:<ID of the Alibaba Cloud account that provides the image>:<Image family name>

    Examples on how to use the image families of shared and community images:

    User M has Custom Images A1 and B1 that are added to Image Family A, publishes A1 as Community Image A2, and shares B1 as Shared Image B2 with User N.

    • Community Image A2: The image family name is acs:<UID of User M>:A

    • Shared Image B2: The image family name is acs:<UID of User M>:A

    Example 1:

    When User N calls the RunInstances or CreateInstance operation with ImageFamily set to acs:<UID of User M>:A, the latest available image in the specified image family (A2 or B2) is automatically used to create the ECS instance.

    Example 2:

    When User N copies B2 to create Custom Image B3, B3 does not inherit the image family information of B2. User N must specify an image family for B3.

    Example 3:

    If User M does not publish A1 as a community image but shares B1 as B2 with User N, User N can obtain B2 when User N references the acs:<UID of User M>:A image family to create an ECS instance.

    Example 4:

    The image family name of a custom image cannot start with acs. User N cannot add a custom image to the acs:<UID of User M>:A image family that contains Shared Image B2 and Community Image A1.

  • The following figure shows the flowchart for using an image family.

    image

Limits

  • After you specify an image family for a custom image, you can change but cannot delete the image family.

  • Image family names must be unique in an Alibaba Cloud account within a region. Image family names can be the same across different regions.

  • The number of images in each image family cannot exceed 100.

  • The number of image families in each region cannot exceed 100.

  • The following limits apply when you deprecate or restore images:

    • You can deprecate or restore only custom images.

    • If you want to deprecate a custom image that you share with other users, unshare the image before you deprecate the image.

    • You can use custom images that are in the Deprecated state to create ECS instances or replace system disks, but you cannot share or copy the images.