Mount a specific pool with CephFS
The title of the article is a bit wrong, but it’s certainly the easiest to understand :-).
First let’s create a new pool, and call it
webdata. Ideally this pool will store web content.
$ ceph osd create webdata 500
Then grab the pool id:
$ ceph osd dump | grep webdata
$ ceph mds add_data_pool 5
Mount the Ceph Filesystem:
$ sudo mount -t ceph 172.17.1.7:/ /srv/mds/pools/webdata
Check the layout of the directory, as we can see the pool with the id 0 has been assigned by default to. This pool corresponds to the default pool called
data. By setting a new layout, we will change the default pool by the one we created before.
$ cephfs /srv/mds/pools/webdata/ show_layout
Unmount and mount the Ceph Filesystem:
$ sudo umount /srv/mds/pools/webdata
Oh! There are objects in there!
$ rados --pool=webdata ls