System Servicesnfsnetworkfilesystemmountserverclientkerberosrpc

nfs-utils

nfs-utils provides packages and binaries for NFS (Network File System) client and server support on Linux systems. It includes tools for mounting/unmounting NFS shares, managing exports, displaying statistics, and handling ID mapping.

Description

nfs-utils is a collection of packages and binaries essential for implementing NFS functionality on Kali Linux, supporting both client and server roles. The nfs-common package contains support files used on any machine acting as NFS client or server, including programs like lockd, statd, showmount, nfsstat, gssd, idmapd, and mount.nfs. The nfs-kernel-server package provides user-space support for the recommended Linux NFS kernel server, featuring NFSv3, NFSv4, Kerberos via GSS, and improved performance over user-space alternatives.

Use cases include setting up NFS servers for file sharing across networks, mounting remote NFS shares on clients, monitoring NFS statistics and performance, and managing NFS configurations and security features like ID mapping for NFSv4 names to local uids/gids. Tools cover mounting/unmounting, export management, statistics display, daemon control, and debugging for NFS operations.

The package supports advanced features like RPCSEC_GSS for secure authentication, client tracking in NFSv4, and kernel-level NFS server control, making it suitable for enterprise network file sharing environments requiring reliability and security.

How It Works

nfs-utils implements NFS protocols (v2, v3, v4) over RPC (Remote Procedure Call) for network file sharing. Client tools like mount.nfs and mount.nfs4 connect to NFS servers using RPC to mount remote filesystems locally, handling options for read-only/read-write, ID mapping via libnfsidmap (mapping NFSv4 user@domain to local uid/gid), and security via rpc.gssd (RPCSEC_GSS with Kerberos). Server-side, rpc.nfsd runs the NFS kernel server process, rpc.mountd handles mount requests, exportfs manages /etc/exports, and daemons like rpc.statd provide NSM (Network Status Monitor) for lock recovery. Statistics tools parse /proc/self/mountstats and kernel counters for per-mount NFS/RPC metrics. Configuration uses /etc/nfs.conf queried by nfsconf.

Installation

bash
sudo apt install nfs-common

Flags

-rMount file system readonly (mount.nfs)
-vVerbose (mount.nfs, mount.nfs4, umount.nfs)
-VPrint version (mount.nfs, mount.nfs4)
-wMount file system read-write (mount.nfs)
-fFake mount, do not actually mount (mount.nfs); force unmount (umount.nfs)
-nDo not update /etc/mtab (mount.nfs, umount.nfs)
-sTolerate sloppy mount options rather than fail (mount.nfs)
-hPrint this help (mount.nfs, mount.nfs4, umount.nfs)
-mShow statistics on mounted NFS filesystems (nfsstat)
-cShow NFS client statistics (nfsstat)
-sShow NFS server statistics (nfsstat)
-adisplays statistics related to the attribute cache (nfsiostat)
-ddisplays statistics related to directory operations (nfsiostat)

Examples

Display help for mount.nfs usage and options
mount.nfs -h
Display help for mount.nfs4 usage and options
mount.nfs4 -h
Display help for mountstats sub-commands (mountstats, nfsstat, iostat)
mountstats -h
Display nfsconf usage for querying NFS configuration settings
nfsconf -h
Display help for NFS idmapper upcall program
nfsidmap -h
Display help for nfsiostat, emulating iostat for NFS mount points
nfsiostat -h
Display help for nfsstat to list NFS statistics
nfsstat --help
Display help for showmount to show mount information for NFS servers
showmount -h
Updated 2026-04-16kali.org ↗