Dieser Inhalt ist in der von Ihnen ausgewählten Sprache nicht verfügbar.

Chapter 8. Managing NFS Ganesha exports on the Ceph dashboard


As a storage administrator, you can manage the NFS Ganesha exports that use Ceph Object Gateway as the backstore on the Red Hat Ceph Storage dashboard. You can deploy and configure, edit and delete the NFS ganesha daemons on the dashboard.

The dashboard manages NFS-Ganesha configuration files stored in RADOS objects on the Ceph Cluster. NFS-Ganesha must store part of their configuration in the Ceph cluster.

8.1. Configuring NFS Ganesha daemons on the Ceph dashboard

You can configure NFS Ganesha on the dashboard after configuring the Ceph object gateway and enabling a dedicated pool for NFS-Ganesha using the command line interface.

Note

Red Hat Ceph Storage 5 supports only NFSv4 protocol.

Prerequisites

  • A running Red Hat Ceph Storage cluster.
  • Dashboard is installed.
  • The Ceph Object Gateway is installed.
  • Ceph Object gateway login credentials are added to the dashboard.
  • A dedicated pool enabled and tagged with custom tag of nfs.
  • At least ganesha-manager level of access on the Ceph dashboard.

Procedure

  1. Log into the Cephadm shell:

    Example

    [root@host01 ~]# cephadm shell

  2. Create the RADOS pool, namespace, and enable rgw:

    Syntax

    ceph osd pool create POOL_NAME _
    ceph osd pool application enable POOL_NAME freeform/rgw/rbd/cephfs/nfs

    Example

    [ceph: root@host01 /]# ceph osd pool create nfs-ganesha
    [ceph: root@host01 /]# ceph osd pool application enable nfs-ganesha rgw

  3. Deploy NFS-Ganesha gateway using placement specification in the command line interface:

    Syntax

    ceph orch apply nfs SERVICE_ID --placement="NUMBER_OF_DAEMONS HOST_NAME_1 HOST_NAME_2 HOST_NAME_3"

    Example

    [ceph: root@host01 /]# ceph orch apply nfs foo --placement="2 host01 host02"

    This deploys an NFS-Ganesha cluster nfsganesha with one daemon on host01 and host02.

  4. Update ganesha-clusters-rados-pool-namespace parameter with the namespace and the service_ID:

    Syntax

    ceph dashboard set-ganesha-clusters-rados-pool-namespace POOL_NAME/SERVICE_ID

    Example

    [ceph: root@host01 /]# ceph dashboard set-ganesha-clusters-rados-pool-namespace nfs-ganesha/foo

  5. From the dashboard navigation, go to File→NFS.
  6. Click Create.
  7. In the Create NFS export form, set the following parameters and click Create NFS export:

    1. Cluster - Name of the cluster.
    2. Daemons - You can select all daemons.
    3. Storage Backend - You can select Object Gateway.
    4. Object Gateway User - Select the user created. In this example, it is test_user.
    5. Path - Any directory.
    6. NFS Protocol - NFSv4 is selected by default.
    7. Pseudo - root path
    8. Access Type - The supported access types are RO, RW, and NONE.
    9. Squash
    10. Transport Protocol
    11. Clients

      Create NFS export window
  8. Verify the NFS daemon is configured:

    Example

    [ceph: root@host01 /]# ceph -s

  9. As a root user, check if the NFS-service is active and running:

    Example

    [root@host01 ~]# systemctl list-units | grep nfs

  10. Mount the NFS export and perform a few I/O operations.
  11. Once the NFS service is up and running, in the NFS-RGW container, comment out the dir_chunk=0 parameter in etc/ganesha/ganesha.conf file. Restart the NFS-Ganesha service. This allows proper listing at the NFS mount.

Verification

  • You can view the NFS daemon by going to Object→Buckets.

    NFS bucket

Additional Resources

8.2. Configuring NFS exports with CephFS on the Ceph dashboard

You can create, edit, and delete NFS exports on the Ceph dashboard after configuring the Ceph File System (CephFS) using the command-line interface. You can export the CephFS namespaces over the NFS Protocol.

You need to create an NFS cluster which creates a common recovery pool for all the NFS Ganesha daemons, new user based on the CLUSTER_ID, and a common NFS Ganesha config RADOS objects.

Note

Red Hat Ceph Storage 5 supports only NFSv4 protocol.

Prerequisites

  • A running Red Hat Ceph Storage cluster.
  • Dashboard is installed.
  • Root-level access to the bootstrapped host.
  • At least ganesha-manager level of access on the Ceph dashboard.

Procedure

  1. Log in to the cephadm shell:

    Example

    [root@host01 ~]# cephadm shell

  2. Create the CephFS storage in the backend:

    Syntax

    ceph fs volume create CEPH_FILE_SYSTEM

    Example

    [ceph: root@host01 /]# ceph fs volume create cephfs

  3. Enable the Ceph Manager NFS module:

    Example

    [ceph: root@host01 /]# ceph mgr module enable nfs

  4. Create an NFS Ganesha cluster:

    Syntax

    ceph nfs cluster create NFS_CLUSTER_NAME "HOST_NAME_PLACEMENT_LIST"

    Example

    [ceph: root@host01 /]# ceph nfs cluster create nfs-cephfs host02
    NFS Cluster Created Successfully

  5. Get the dashboard URL:

    Example

    [ceph: root@host01 /]# ceph mgr services
    {
        "dashboard": "https://10.00.00.11:8443/",
        "prometheus": "http://10.00.00.11:9283/"
    }

  6. Log in to the Ceph dashboard with your credentials.
  7. On the dashboard landing page, click NFS.
  8. Click Create.
  9. In the Create NFS export window, set the following parameters and click Create NFS export:

    1. Cluster - Name of the cluster.
    2. Daemons - You can select all daemons.
    3. Storage Backend - You can select CephFS.
    4. CephFS User ID - Select the service where the NFS cluster is created.
    5. CephFS Name - Provide a user name.
    6. CephFs Path - Any directory.
    7. NFS Protocol - NFSv4 is selected by default.
    8. Pseudo - root path
    9. Access Type - The supported access types are RO, RW, and NONE.
    10. Squash - Select the squash type.
    11. Transport Protocol - Select either the UDP or TCP protocol.
    12. Clients

      Figure 8.1. CephFS NFS export window

      Create CephFS NFS export window
  10. As a root user on the client host, create a directory and mount the NFS export:

    Syntax

    mkdir -p /mnt/nfs/
    mount -t nfs -o port=2049 HOSTNAME:EXPORT_NAME _MOUNT_DIRECTORY_

    Example

    [root@ client ~]# mkdir -p /mnt/nfs/
    [root@ client ~]# mount -t nfs -o port=2049 host02:/export1 /mnt/nfs/

Verification

  • Verify if the NFS daemon is configured:

    Example

    [ceph: root@host01 /]# ceph -s

Additional Resources

8.3. Editing NFS Ganesha daemons on the Ceph dashboard

You can edit the NFS Ganesha daemons on the Red Hat Ceph Storage dashboard.

Prerequisites

  • A running Red Hat Ceph Storage cluster.
  • At least ganesha-manager level of access on the Ceph dashboard.
  • NFS Ganesha daemon configured on the dashboard.

Procedure

  1. From the dashboard navigation, go to Object NFS.
  2. Select the row that needs to be edited. and click Edit.
  3. In the Edit NFS export window, edit the required parameters.
  4. Complete by clicking Edit NFS export.

    A notification displays that the NFS object was updated successfully.

    Edit NFS export window

Additional Resources

8.4. Deleting NFS Ganesha daemons on the Ceph dashboard

The Ceph dashboard allows you to delete the NFS Ganesha daemons.

Prerequisites

  • A running Red Hat Ceph Storage cluster.
  • At least ganesha-manager level of access on the Ceph dashboard.
  • NFS Ganesha daemon configured on the dashboard.

Procedure

  1. From the dashboard navigation, go to File→NFS.
  2. Select the row that needs to be deleted and click Delete from the action drop-down.
  3. In the Delete NFS export notification, select Yes, I am sure and click Delete NFS export.

    Delete NFS export window

Verification

  • The selected row is deleted successfully.

Additional Resources

Red Hat logoGithubRedditYoutubeTwitter

Lernen

Testen, kaufen und verkaufen

Communitys

Über Red Hat Dokumentation

Wir helfen Red Hat Benutzern, mit unseren Produkten und Diensten innovativ zu sein und ihre Ziele zu erreichen – mit Inhalten, denen sie vertrauen können.

Mehr Inklusion in Open Source

Red Hat hat sich verpflichtet, problematische Sprache in unserem Code, unserer Dokumentation und unseren Web-Eigenschaften zu ersetzen. Weitere Einzelheiten finden Sie in Red Hat Blog.

Über Red Hat

Wir liefern gehärtete Lösungen, die es Unternehmen leichter machen, plattform- und umgebungsübergreifend zu arbeiten, vom zentralen Rechenzentrum bis zum Netzwerkrand.

© 2024 Red Hat, Inc.