Found 0 result in total

Content is empty
If you don't find the content you expect, please try another search term
Elastic Block Storage (EBS)
User Guide
Resize partitions and file systems(Linux)
Resize the file system of a raw disk
Last updated:2021-07-01 14:34:04
After you expand the capacity of an EBS volume that has no partitions but a file system, you can directly resize the file system.
| Operating environment | Resource | Description |
|---|---|---|
| Operating system | CentOS 6.5 64-bit | |
| Data disk | /dev/vdb: has no partitions and uses an ext4 file system. The capacity of the disk has been expanded from 200 GB to 2,200GB. /dev/vdc: has no partitions and uses an xfs file system. The capacity of the disk has been expanded from 2,400 GB to 3,000 GB. |
Run the following command to view the information about the file systems on the data disks attached to your KEC instance:
df -Th
| The following figure shows the output.
|
Data disk | File system type | Mount point |
|---|---|---|---|
| /dev/vdb | ext4 | Mounted to /mnt/data_disk01 | |
| /dev/vdc | xfs | Mounted to /mnt/data_disk02 |
In the operating system of your KEC instance, resize a file system by running one of the following commands based on the type of the file system.
resize2fs /dev/vdb
The following figure shows the output.
Note: In the preceding command,
/dev/vdbis the name of the data disk for which you want to allocate the expanded capacity. You must change it based on your business requirements.
mount | grep /dev/vdc
Resize the file system on the /dev/vdc data disk
xfs_growfs /mnt/data_disk02
The following figure shows the output.
Note: In the preceding commands,
/mnt/data_disk02is the mount point of the/dev/vdcdata disk. You must change it based on your business requirements.
df -Th
The following figure shows the output.
The figure shows that the resizing succeeded. When you check the results, compare the results with the original capacities.
Pure Mode