Manage image caches

更新时间:
复制 MD 格式

The image cache feature caches custom images from the public cloud to the local storage of a Cloud Box. When you create an ECS instance in the Cloud Box by using a cached custom image, the system uses the local cache to accelerate instance creation. This topic describes how to create and delete image caches.

Features

An image contains the operating system, initial application data, and pre-installed software for an ECS instance. You can use images to quickly deploy environments in batches. When you create an ECS instance in a Cloud Box, you can use images from the public cloud, including public images and custom images. However, because ECS instances are deployed locally on the Cloud Box, image downloads from the cloud are limited by network bandwidth. This can result in long instance creation times or even failures. To reduce dependency on network bandwidth, Cloud Box provides the image cache feature. You can use this feature to pre-cache custom images from the public cloud to the local storage of your Cloud Box to accelerate subsequent ECS instance creation.

Note
  • A Cloud Box connects to the public cloud through a leased line or the internet. Bandwidth and latency depend on the quality of the communication link between the Cloud Box and the public cloud.

  • A custom image is an image created from an ECS instance or a snapshot, or imported from an on-premises environment. For more information, see Custom images.

镜像缓存

Usage notes

  • Image caches are stored in a Cloud Box's local block storage and consume block storage capacity.

  • You can cache only custom images from the public cloud that contain only a system disk. Custom images that contain data disks or other types of images are not supported.

Before you begin

Before you create an image cache:

  • On the Images page, get the size of the custom image that you want to cache and confirm that the image status is Available. If you have not created a custom image, create one first. For more information, see Custom images.

    镜像状态

  • On the Cloud Box Details page, check the block storage capacity to ensure you have enough space for the image. If the block storage capacity is insufficient, you must expand the Cloud Box. For more information, see Expand a Cloud Box.

    云盒容量

Create an image cache

  1. Go to the Cloud Boxes tab.

    1. Log on to the ECS console.

    2. In the left-side navigation pane, choose Instances & Images > CloudBox.

    3. In the top navigation bar, select a region.

    4. Click Cloud Boxes.
  2. Find the target Cloud Box and click its ID.

  3. On the Cloud Box details page, click the Image Caches tab and then click Create Image Cache.

  4. In the dialog box that appears, select a custom image and then click OK.

    创建镜像缓存

    After the image cache is created, check its status. When the status changes to Cached, the image is successfully cached to the Cloud Box's local storage.

    镜像缓存

    Note

    After an image cache is created, the system automatically uses it to accelerate the creation of ECS instances from the corresponding custom image.

Delete an image cache

We recommend deleting unused image caches to free up storage capacity.

Important

Deleting an image cache removes only the image that is cached in the Cloud Box's local storage. This operation does not affect the original custom image in the public cloud. A deleted image cache cannot be restored. To use it again, you must recreate it.

  1. Go to the Image Caches tab on the Cloud Box details page.

  2. In the list of image caches, find the image cache that you want to delete and click Delete in the Actions column.

  3. In the dialog box that appears, confirm the information and click OK.

Related documents

You can create a custom image from an ECS instance in a Cloud Box, create an image cache from it, and then use the cache to quickly create multiple ECS instances with the same environment. For more information, see Accelerate ECS instance creation by using an image cache.