All Products
Search
Document Center

Container Service for Kubernetes:Overview of disk expansion

Last Updated:Nov 19, 2024

Your disk space may become insufficient as your business develops and application data grows. To resolve this issue, you can expand your disk volume. This topic introduces how to choose a method to expand disk volumes based on different business scenarios, such as expansion without service interruptions, manual expansion, and automatic expansion. This topic also describes the billing of disk volume expansion.

Methods to expand disk volumes

To expand a disk volume, you need to expand the disk and file system.

  • Expand the disk: You must perform this operation in the Elastic Compute Service (ECS) console.

  • Expand the file system: You must connect to the ECS instance to which the disk is mounted and then perform this operation.

The disk and file system can be expanded without the need to stop the application to which the disk volume is mounted (the disk and file system are still mounted during the expansion process). To ensure the stability of the file system and application, we recommend that you stop the application, unmount the disk volume from the directory, and then expand the disk volume. However, in most scenarios, you are not allowed to suspend the application pods. Container Service for Kubernetes (ACK) allows you to expand disk volumes by using multiple methods. You can select a method that best suits your business requirements.

Item

Expansion without service interruptions

Manual expansion

Automatic expansion

Concept

Automatically expand the mounted disk and file system without suspending the application pods.

Manually expand the disk and run the resize2fs command to expand the file system.

  • Expand the mounted disk and file system without suspending the application pods.

  • Suspend the application pods, expand the disk and file system, and then restart the application pods.

You can define one or more expansion policies to automatically expand a disk volume when the utilization of the disk volume exceeds a specified threshold value.

Disk capacity limits

2000 GiB or less.

32 TiB or less.

2000 GiB or less.

Cluster version limits

1.16 and later.

Versions earlier than 1.16.

1.16 and later.

Volume types

Dynamically provisioned volumes (PVCs that have the StorageClassName configured).

Statically provisioned volumes.

Dynamically provisioned volumes (PVCs that have the StorageClassName configured).

Other limits

  • You cannot expand volumes that use basic disks without service interruptions.

  • You cannot expand disk volumes of the inline type. This type of disk volume is not created by using PVs and PVCs.

You need to run the resize2fs command to manually expand the file system.

  • The disk must be mounted and this method relies on the resize capability of the disk. For more information, see ResizeDisk.

  • The maximum interval between two expansion operations is 2 minutes. The disk expansion process requires 1 minute. Make sure that you do not exhaust the disk space within 3 minutes.

References

Expand a disk volume without service interruptions

Automatically expand a disk volume (public preview)

Billing

Disk expansion is billed in the same way in which you purchase disks. You are charged for the expanded storage when you expand a disk. For more information, see Billing of disk volumes.

Reference

For frequently asked questions and solutions about disk volumes, see FAQ about disk volumes.