How to do it...

Deploying an MDS server through ceph-ansible is quite easy, let's review the steps on how this is done:

  1. Using Ansible from ceph-node1, we will deploy and configure MDS on ceph-node2. On our Ansible configuration node ceph-node1, add a new section [mdss] to the /etc/ansible/hosts file:
  2. Navigate to the Ansible configuration directory on ceph-node1, /usr/share/ceph-ansible:
        root@ceph-node1 # cd /usr/share/ceph-ansible
  1. Run the Ansible playbook to deploy the MDS on ceph-node2:
         # ansible-playbook site.yml
  1. Once the playbook completes successfully, you can validate that the MDS is up and active, that we have created two pools, cephfs_data and cephfs_metadata, and that the Ceph Filesystem was created successfully:
         # ceph mds stat
# ceph osd pool ls
# ceph fs ls
  1. It's recommended that you don't share client.admin user keyring with Ceph clients, so we will create a user client.cephfs on the Ceph cluster and will allow this user access to the Ceph FS pools, then we will transfer the keyring we created to client-node1:
        root@ceph-node1 # ceph auth get-or-create client.cephfs 
mon 'allow r'
mds 'allow r, allow rw path=/' osd 'allow rw pool=cephfs_data'
-o ceph.client.cephfs.keyring
        root@client-node1 # scp root@ceph-node1:/etc/ceph/
ceph.client.cephfs.keyring /etc/ceph/ceph.client.cephfs.keyring
root@client-node1 cat /etc/ceph/client.cephfs.keyring
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset