Este conteúdo não está disponível no idioma selecionado.

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.

Prerequisites

Before you begin, make sure that you have the following prerequisites in place:

  • 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 Object→NFS.
  6. Click Create.
  7. Complete the Create NFS export form and click Create NFS export to save and continue.

    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 File→NFS.

    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.

Prerequisites

Before you begin, make sure that you have the following prerequisites in place:

  • 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. Complete the Create NFS export form and click Create NFS export to save and continue.

    Figure 8.1. CephFS NFS export form

    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.

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.

Verification

  • The selected row is deleted successfully.

Additional Resources

Red Hat logoGithubRedditYoutubeTwitter

Aprender

Experimente, compre e venda

Comunidades

Sobre a documentação da Red Hat

Ajudamos os usuários da Red Hat a inovar e atingir seus objetivos com nossos produtos e serviços com conteúdo em que podem confiar.

Tornando o open source mais inclusivo

A Red Hat está comprometida em substituir a linguagem problemática em nosso código, documentação e propriedades da web. Para mais detalhes veja oBlog da Red Hat.

Sobre a Red Hat

Fornecemos soluções robustas que facilitam o trabalho das empresas em plataformas e ambientes, desde o data center principal até a borda da rede.

© 2024 Red Hat, Inc.