Files
Controls-docs/admin-guide/configuration/nfs_server.md
T
2024-04-29 14:06:35 +02:00

1.4 KiB

NFS Server

Your node can serve as NFS server. This guide is for RHEL8 and later. By default RHEL8 serves NFS3 und NFS4, whereas RHEL9 and later will server only NFS4. Still NFS3 can be configured if required.

To enable the NFS server, set base::enable_nfs_server accordingly in Hiera:

base::enable_nfs_server: true

Then the exports go below nfs_server::exports:

  '/home/meg/dcbboot':
    clients:
      - hosts: '*'
        options: 'rw,sync,no_root_squash,no_subtree_check'
  '/export/swissfel_athos/raw/maloja-staff':
    options: 'fsid=1012'
    clients:
      - hosts: 'sf-export-1[2-3]-100g'
        options: 'rw,async,no_root_squash'

For each directory you want to export place its path as key. Below you can set the global options in options and a list of client specific access restrictions and options below clients.

Possible client host definitions and options you find in exports(5).

If you wish non-standard configuration in /etc/nfs.conf, you may set it in Hiera with key nfs_server::nfs_conf:

nfs_server::nfs_conf:
  nfsd:
    udp: 'y'
    vers3: 'n'

For more details see nfs.conf(5)

If you need/want to provide Kerberos authenticated access, please speak to the Core Linux Team as we need to add support for it to Puppet first.