CEPH is a very well documented technology. Just check out the documentation for ceph at ceph.com. Pretty much everything that you want to know about CEPH is documented there. However, this also means that you possibly need to dig around just to remember a few simple commands.
Because of this, I have decided to put a few notes below on creating, deleting, and working with CEPH pools.
List Pools
You can list your existing pools with the command below. In this example I only have one pool called rdb with a pool number of 13.
[root@mon01 ~]# ceph osd lspools
13 rbd,
Create a Pool
[root@mon01 ~]# ceph osd pool create test-pool 128
pool ‘test-pool’ created
Placement Groups
[root@mon01 ~]# ./pg_per_osd.bash
dumped all in format plainpool : 13 14 | SUM
——————————–
osd.26 48 36 | 84
osd.27 30 43 | 73
osd.19 41 38 | 79
osd.20 45 37 | 82
osd.21 42 53 | 95
osd.22 43 39 | 82
osd.23 50 38 | 88
osd.24 35 51 | 86
osd.25 50 49 | 99
——————————–
SUM : 384 384 |
[root@mon01 ~]# ceph osd pool get test-pool pg_num
pg_num: 128
[root@mon01 ~]# ceph osd pool get test-pool size
size: 3
[root@mon01 ~]# ceph osd pool get test-pool min_size
min_size: 2
Deleting A Pool
[root@mon01 ~]# ceph osd pool delete test-pool test-pool –yes-i-really-really-mean-it
pool ‘test-pool’ removed