- Ceph Cookbook
- Karan Singh
- 225字
- 2021-07-16 13:01:17
Ceph RBD resizing
Ceph supports thin provisioned block devices, which means that the physical storage space will not get occupied until you begin storing data on the block device. The Ceph block device is very flexible; you can increase or decrease the size of an RBD on the fly from the Ceph storage end. However, the underlying filesystem should support resizing. Advance filesystems such as XFS, Btrfs, EXT, ZFS, and others support filesystem resizing to a certain extent. Please follow filesystem specific documentation to know more about resizing.
How to do it…
To increase or decrease Ceph RBD image size, use the --size <New_Size_in_MB>
option with the rbd resize
command, this will set the new size for the RBD image:
- The original size of the RBD image that we created earlier was 10 GB. We will now increase its size to 20 GB:
# rbd resize --image rbd1 --size 20480 --name client.rbd # rbd info --image rbd1 --name client.rbd
- Grow the filesystem so that we can make use of increased storage space. It's worth knowing that the filesystem resize is a feature of the OS as well as the device filesystem. You should read filesystem documentation before resizing any partition. The XFS filesystem supports online resizing. Check system messages to know the filesystem size change:
# dmesg | grep -i capacity # xfs_growfs -d /mnt/ceph-disk1
推薦閱讀
- AngularJS Testing Cookbook
- Fundamentals of Linux
- Apache ZooKeeper Essentials
- 云計算通俗講義(第3版)
- INSTANT Django 1.5 Application Development Starter
- 數(shù)據(jù)結構習題解析與實驗指導
- RESTful Java Web Services(Second Edition)
- HTML5+CSS3+JavaScript 從入門到項目實踐(超值版)
- App Inventor 2 Essentials
- Groovy 2 Cookbook
- HTML5與CSS3權威指南
- Monitoring Docker
- Go Systems Programming
- Koa與Node.js開發(fā)實戰(zhàn)
- 讀故事學編程:Python王國歷險記