Project

General

Profile

Actions

Feature #48339

closed

Use file references in NFS ganesha service configuration

Added by Juan Miguel Olmo Martínez over 3 years ago. Updated almost 3 years ago.

Status:
Rejected
Priority:
Normal
Assignee:
-
Category:
cephadm (binary)
Target version:
-
% Done:

0%

Source:
Community (user)
Tags:
Backport:
Reviewed:
Affected Versions:
Pull request ID:

Description

Using "cephadm deploy", it is possible to deploy a NFS Ganesha daemon in a host not included in the cluster. We can call this mode "nfs ganesha standalone". This is one of the specific use cases for the Open Stack team, but probably also completely sensible for other users.

The command needed to do that (for example) is:

cephadm --image docker.io/ceph/daemon-base:latest-master-devel deploy --fsid 3e6fcdc2-2a50-11eb-beea-525400d1a36b --name nfs.foo.ceph-node-01 --config-json <nfs-ganesha-config>

And in the --config-json parameter we need to pass a long string with all the configuration for the nfs daemon, for example:

<nfs-ganesha-config>:

{
"pool": "nfs-ganesha", 
"namespace": "foo", 
"userid": "nfs.foo.ceph-node-01", 
"extra_args": ["-N", "NIV_EVENT"], 
"files": {
"ganesha.conf": "# This file is generated by cephadm.\nNFS_CORE_PARAM {\n        Enable_NLM = false;\n        Enable_RQUOTA = false;\n        Protocols = 4;\n}\n\nMDCACHE {\n        Dir_Chunk = 0;\n}\n\nEXPORT_DEFAULTS {\n        Attr_Expiration_Time = 0;\n}\n\nNFSv4 {\n        Delegations = false;\n        RecoveryBackend = 'rados_cluster';\n        Minor_Versions = 1, 2;\n}\n\nRADOS_KV {\n        UserId = \"nfs.foo.ceph-node-01\";\n        nodeid = \"nfs.foo.ceph-node-01\";\n        pool = \"nfs-ganesha\";\n        namespace = \"foo\";\n}\n\nRADOS_URLS {\n        UserId = \"nfs.foo.ceph-node-01\";\n        watch_url = \"rados://nfs-ganesha/foo/conf-nfs.foo\";\n}\n\nRGW {\n        cluster = \"ceph\";\n        name = \"client.nfs.foo.ceph-node-01-rgw\";\n}\n\n%url    rados://nfs-ganesha/foo/conf-nfs.foo"}, 
"config": "# minimal ceph.conf for 3e6fcdc2-2a50-11eb-beea-525400d1a36b\n[global]\n\tfsid = 3e6fcdc2-2a50-11eb-beea-525400d1a36b\n\tmon_host = [v2:192.168.122.110:3300/0,v1:192.168.122.110:6789/0]\n", 
"keyring": "[client.nfs.foo.ceph-node-01]\n\tkey = AQAxWLZfKwxBBhAAYzlOJfYAcyDz2zv2mX3/iA==\n", 
"rgw": {"cluster": "ceph", "user": "nfs.foo.ceph-node-01-rgw", "keyring": "[client.nfs.foo.ceph-node-01-rgw]\n\tkey = AQAxWLZfVNYABxAAc6g0GslYxqAtjGuaqiMY6Q==\n"}}
}

What we want is make this kind of deployment more easy using references to real files in the "files" section instead of including all the content of this files. These files would have been generated previously in the external host, for example:

<nfs-ganesha-config>:

{
"pool": "nfs-ganesha", 
"namespace": "foo", 
"userid": "nfs.foo.ceph-node-01", 
"extra_args": ["-N", "NIV_EVENT"],
"use_host_files": True                <------------------  new parameter to change the way we are processing the "files" parameter
"files": {                            <------------------  Now, files can be set using external files references.
"ganesha.conf": "/etc/ceph/ganesha.conf",
"config": "/etc/ceph/ceph.conf",
"keyring": "/etc/ceph/client.nfs.foo.keyring",
"rgw": "/etc/ceph/rgw_nfs.conf" 
}

Actions #1

Updated by Sebastian Wagner almost 3 years ago

  • Status changed from New to Rejected

This is a bad idea. Especially when thinking about the ingress service.

Actions

Also available in: Atom PDF