
上QQ阅读APP看书,第一时间看更新
How to do it...
Let's walk-through the steps to utilize client-node1 as an NFS-Ganesha server to export Ceph FS as NFS:
- On ceph-node1, install the packages required for nfs-ganesha:
# sudo yum install -y nfs-utils nfs-ganesha
- Since this is a test setup, disable the firewall. For the production setup, you might consider enabling the required ports over a firewall, which is generally 2049:
# systemctl stop firewalld; systemctl disable firewalld
- Enable the rpc services required by NFS:
# systemctl start rpcbind; systemctl enable rpcbind
# systemctl start rpc-stat.d.service
- Create the NFS-Ganesha configuration file, /etc/ganesha.conf, with the following content:

- Finally, start the NFS Ganesha daemon by providing the ganesha.conf file that we created in the last step. You can verify the exported NFS share using the showmount command:
# ganesha.nfsd -f /etc/ganesha.conf -L /var/log/ganesha.log -N NIV_DEBUG
# showmount -e

Let's recall the steps that we have taken: ceph-node2 has been configured as Ceph MDS, and ceph-node1 has been configured as the NFS-Ganesha server. Next, in order to mount the NFS share on the client machines, we just need to install the NFS client packages and mount the share exported by ceph-node1, as shown next:
Install the NFS client packages on client-node1 and mount:
root@client-node1 # yum install -y nfs-utils
# mkdir /mnt/cephfs
# mount -o rw,noatime 10.19.1.101:/ /mnt/cephfs
