NFS Shares
Export ZFS filesystems as NFS shares for Linux and macOS clients. MayaNAS supports NFSv3, NFSv4, NFSv4.1, and NFSv4.2, with optional Kerberos authentication.
Access
Section titled “Access”Navigate to NFS Shares in the Web UI sidebar.
Create an NFS Share
Section titled “Create an NFS Share”- Click New
- Select a ZFS filesystem (from Volumes & Pools)
- Configure export options:
| Field | Description | Default |
|---|---|---|
| Volume | ZFS filesystem to export | — |
| Allowed Clients | IP/subnet filter (e.g., 10.0.0.0/24 or *) | * |
| Options | NFS export options | rw,no_root_squash |
- Click Create
Common Export Options
Section titled “Common Export Options”| Option | Description |
|---|---|
rw | Read-write access |
ro | Read-only access |
no_root_squash | Allow root access from clients |
root_squash | Map root to anonymous user |
sync | Synchronous writes (safer) |
async | Asynchronous writes (faster) |
sec=krb5 | Require Kerberos authentication |
sec=krb5i | Kerberos with integrity checking |
sec=krb5p | Kerberos with privacy (encryption) |
Manage Shares
Section titled “Manage Shares”Bind (Export)
Section titled “Bind (Export)”Select an inactive share and click Bind to make it available to NFS clients.
Unbind (Unexport)
Section titled “Unbind (Unexport)”Select an active share and click Unbind to stop serving it. Connected clients will lose access.
Delete
Section titled “Delete”Select a share and click Delete to remove the mapping entirely.
View Filters
Section titled “View Filters”- View All — All shares
- View Exported — Active shares only
- View Inactive — Shares not currently exported
Mount from Client
Section titled “Mount from Client”Using VIP (HA Deployments)
Section titled “Using VIP (HA Deployments)”# NFSv4 (recommended)sudo mount -t nfs4 <VIP>:/tank/data /mnt/data
# NFSv3sudo mount -t nfs -o vers=3 <VIP>:/tank/data /mnt/dataUsing Node IP (Single Node)
Section titled “Using Node IP (Single Node)”sudo mount -t nfs4 <NODE_IP>:/tank/data /mnt/dataAutomount with /etc/fstab
Section titled “Automount with /etc/fstab”# VIP-based mount (survives failover)10.0.1.100:/tank/data /mnt/data nfs4 defaults,_netdev 0 0NFS Server Configuration
Section titled “NFS Server Configuration”Navigate to Configure Server > NFS to tune NFS server settings:
| Setting | Description | Default |
|---|---|---|
| NFSd Threads | Number of NFS server threads (1 per CPU core recommended) | Auto |
| NFS Versions | Enable/disable v3, v4, v4.1, v4.2 | v3, v4, v4.1, v4.2 |
| TCP | TCP transport (port 2049) | Enabled |
| RDMA | RDMA transport (port 20049) | Disabled (unless hardware present) |
| NFSv4 Lease Time | Client lease duration (10–3600 seconds) | 90 seconds |
| NFSv4 Grace Period | Recovery window after server restart (10–3600 seconds) | 90 seconds |
Kerberos-Secured NFS
Section titled “Kerberos-Secured NFS”When Active Directory or standalone Kerberos is configured, NFS shares can require authentication. See Active Directory & Kerberos for setup.
Once configured:
- The NFS Shares panel shows a lock icon on Kerberos-secured exports
- Clients must have valid Kerberos tickets to mount
# Client-side Kerberos mountkinit user@DOMAIN.COMsudo mount -t nfs4 -o sec=krb5 <VIP>:/tank/data /mnt/data# Create an NFS share (volume must be a ZFS filesystem)mayacli create mapping volume=tank/data controller=nfs3 \ options='"*(rw,no_root_squash)"'
# Create an NFS share restricted to a subnetmayacli create mapping volume=tank/data controller=nfs3 \ options='"10.0.0.0/24(rw,sync)"'
# Export (bind) a sharemayacli bind mapping volume=tank/data
# Unexport (unbind) a sharemayacli unbind mapping volume=tank/data
# Show all NFS mappingsmayacli show mapping controller=nfs
# Delete a share mappingmayacli delete mapping volume=tank/data controller=nfsSee CLI Guide for the full command reference.