0845680984
  1. Configure Cluster #1
  2. Configure Cluster #2
  3. Use Block Device
  4. Use File System
  5. Ceph Object Gateway
  6. Enable Dashboard
  7. Add or Remove OSDs
  8. CephFS + NFS-Ganesha

Install NFS-Ganesha to mount Ceph File System with NFS protocol.
For example, Configure NFS Export setting to CephFS like here.

[1] Install and Configure NFS-Ganesha on CephFS Node.
root@node01:~# apt -y install nfs-ganesha-ceph
root@node01:~# mv /etc/ganesha/ganesha.conf /etc/ganesha/ganesha.conf.org
root@node01:~# vi /etc/ganesha/ganesha.conf
# create new
NFS_CORE_PARAM {
    # disable NLM
    Enable_NLM = false;
    # disable RQUOTA (not suported on CephFS)
    Enable_RQUOTA = false;
    # NFS protocol
    Protocols = 4;
}
EXPORT_DEFAULTS {
    # default access mode
    Access_Type = RW;
}
EXPORT {
    # uniq ID
    Export_Id = 101;
    # mount path of CephFS
    Path = "/";
    FSAL {
        name = CEPH;
        # hostname or IP address of this Node
        hostname="10.0.0.51";
    }
    # setting for root Squash
    Squash="No_root_squash";
    # NFSv4 Pseudo path
    Pseudo="/vfs_ceph";
    # allowed security options
    SecType = "sys";
}
LOG {
    # default log level
    Default_Log_Level = WARN;
}

root@node01:~# systemctl restart nfs-ganesha
[2] Verify NFS mounting on a Client Host.

root@client:~# 

apt -y install nfs-common

# specify Pseudo path set on [Pseudo=***] in ganesha.conf
root@client:~# 

mount -t nfs4 node01.srv.world:/vfs_ceph /mnt
root@client:~# 

df -hT

Filesystem                        Type      Size  Used Avail Use% Mounted on
udev                              devtmpfs  1.9G     0  1.9G   0% /dev
tmpfs                             tmpfs     394M  1.1M  393M   1% /run
/dev/mapper/ubuntu--vg-ubuntu--lv ext4       25G  3.1G   21G  13% /
tmpfs                             tmpfs     2.0G     0  2.0G   0% /dev/shm
tmpfs                             tmpfs     5.0M     0  5.0M   0% /run/lock
tmpfs                             tmpfs     2.0G     0  2.0G   0% /sys/fs/cgroup
/dev/loop0                        squashfs   55M   55M     0 100% /snap/core18/1880
/dev/vda2                         ext4      976M  197M  713M  22% /boot
/dev/loop1                        squashfs   56M   56M     0 100% /snap/core18/1885
/dev/loop2                        squashfs   72M   72M     0 100% /snap/lxd/16100
/dev/loop3                        squashfs   71M   71M     0 100% /snap/lxd/16926
/dev/loop4                        squashfs   30M   30M     0 100% /snap/snapd/8542
/dev/loop5                        squashfs   30M   30M     0 100% /snap/snapd/8790
tmpfs                             tmpfs     394M     0  394M   0% /run/user/0
node01.srv.local:/vfs_ceph        nfs4       75G     0   75G   0% /mnt

Leave a Comment

Your email address will not be published. Required fields are marked *

Bài viết gần đây:

Shopping Cart