Ceph Block Device images are thin-provisioned. They do not actually use any physical
storage until you begin saving data to them. However, they do have a maximum capacity that you set
with the --size option.
Procedure
- To increase the maximum size of a Ceph Block Device image for the default
rbd pool:
Syntax
rbd resize --image IMAGE_NAME --size SIZE
Example
[root@rbd-client ~]# rbd resize --image image1 --size 1024
- To decrease the maximum size of a Ceph Block Device image for the default
rbd pool:
Syntax
rbd resize --image IMAGE_NAME --size SIZE --allow-shrink
Example
[root@rbd-client ~]# rbd resize --image image1 --size 1024 --allow-shrink
- To increase the maximum size of a Ceph Block Device image for a specific pool:
Syntax
rbd resize --image POOL_NAME/IMAGE_NAME --size SIZE
Example
[root@rbd-client ~]# rbd resize --image pool1/image1 --size 1024
- To decrease the maximum size of a Ceph Block Device image for a specific pool:
Syntax
rbd resize --image POOL_NAME/IMAGE_NAME --size SIZE --allow-shrink
Example
[root@rbd-client ~]# rbd resize --image pool1/image1 --size 1024 --allow-shrink