Use this when using NFS to share files with Linux and Unix hosts.
NFS · Storage Interfaces
NFS as a storage interface is the Unix and Linux network file-sharing protocol. NFSv3 is stateless and simple, while NFSv4.x adds stateful locking, Kerberos security and a single port (2049).
1. NFS shares files over TCP 2049 (v4).
2. v4.1+ for sessions and pNFS.
3. Use hard mounts for data safety.
4. ID mapping/Kerberos for security.
5. Exports control client access.
client → NFS RPC → server → filesystem
Context & applicabilityCommon mistakes · platform/version boundaries
Operational reference
Fast context before you go deeper.
Verification & Troubleshooting
Start with the observed symptom, prove the nearest boundary, and move outward only when the current state is understood.
Use the operational verification above to establish the expected state.
Capture the concrete output, symptom, packet, log or counter before changing anything.
Step 1 Checks Verify boundary
nfsstat -m
rpcinfo -p nfs01
showmount -e nfs01
Step 2 Common mistakes Narrow the fault
- Mixing NFS versions without understanding locking.
Evidence · 1 on this Topic
Expected observations and documentation recipes are reference material. Record actual output, device identity, scope and time before claiming a verified result.
- NFSv3 is stateless; NFSv4 is stateful with locking.
- NFSv4 uses one port (2049).
- Kerberos adds security in NFSv4.
showmount -e <server>— exportsnfsstat -m— client mounts and optionsrpcinfo -p <server>— RPC services
ReferenceHow it works1 section · depth on demand
How it works
NFS shares file systems over the network. The server exports a directory, clients mount it and send file operations (read, write, lookup) as RPCs. NFSv3 is stateless and trusts client UIDs (AUTH_SYS); NFSv4 is stateful, uses only port 2049, maps users by name and can use Kerberos for authentication and encryption.
ReferenceImportant terms & boundaries1 section · depth on demand
Facts
| Version | Ports | Notes |
|---|---|---|
| NFSv3 | 2049 + rpcbind 111, mountd | Stateless, AUTH_SYS |
| NFSv4.x | 2049 only | Stateful, ID mapping, Kerberos |
| NFSv4.1 | 2049 | Sessions, pNFS, multipath (nconnect) |
Additional reference context Scope · expected state · examples · history · terminology Open only when you need the supporting context
Verification history & basis
When and against what this Topic was checked. Later text edits do not count as a new check.
Authoritative/upstream documentation reviewed for bounded claims in Storage Interfaces → NFS. Documentation verification only; this is not observed lab or production Evidence.
Basis: https://www.t10.org/ · confidence 94%