summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSteve Dickson <steved@redhat.com>2022-04-19 11:10:27 -0400
committerSteve Dickson <steved@redhat.com>2022-04-19 15:50:29 -0400
commit589b0f898a757b03c4573d65309df8f6e8d6c524 (patch)
treecf5c8d1a6ebfcff5b5671311fa534fdf74ac17e4
parent0cc3a8aac8a69d07eaf44745fc4ee947f718fca8 (diff)
downloadnfs-utils-589b0f898a757b03c4573d65309df8f6e8d6c524.tar.gz
nfsrahead: User documentation
Add the man page for nfsrahead, and add the new section to nfs.conf. Signed-off-by: Thiago Becker <tbecker@redhat.com> Signed-off-by: Steve Dickson <steved@redhat.com>
-rw-r--r--systemd/nfs.conf.man11
-rw-r--r--tools/nfsrahead/Makefile.am3
-rw-r--r--tools/nfsrahead/nfsrahead.man72
3 files changed, 86 insertions, 0 deletions
diff --git a/systemd/nfs.conf.man b/systemd/nfs.conf.man
index be487a1..e74083e 100644
--- a/systemd/nfs.conf.man
+++ b/systemd/nfs.conf.man
@@ -294,6 +294,17 @@ Only
.B debug=
is recognized.
+.TP
+.B nfsrahead
+Recognized values:
+.BR nfs ,
+.BR nfsv4 ,
+.BR default .
+
+See
+.BR nfsrahead (5)
+for deatils.
+
.SH FILES
.TP 10n
.I /etc/nfs.conf
diff --git a/tools/nfsrahead/Makefile.am b/tools/nfsrahead/Makefile.am
index 60a1102..845ea0d 100644
--- a/tools/nfsrahead/Makefile.am
+++ b/tools/nfsrahead/Makefile.am
@@ -3,6 +3,9 @@ nfsrahead_SOURCES = main.c
nfsrahead_LDFLAGS= -lmount
nfsrahead_LDADD = ../../support/nfs/libnfsconf.la
+man5_MANS = nfsrahead.man
+EXTRA_DIST = $(man5_MANS)
+
udev_rulesdir = /usr/lib/udev/rules.d/
udev_rules_DATA = 99-nfs.rules
diff --git a/tools/nfsrahead/nfsrahead.man b/tools/nfsrahead/nfsrahead.man
new file mode 100644
index 0000000..5488f63
--- /dev/null
+++ b/tools/nfsrahead/nfsrahead.man
@@ -0,0 +1,72 @@
+.\" Manpage for nfsrahead.
+.nh
+.ad l
+.TH man 5 "08 Mar 2022" "1.0" "nfsrahead man page"
+.SH NAME
+
+nfsrahead \- Configure the readahead for NFS mounts
+
+.SH SYNOPSIS
+
+nfsrahead [-F] [-d] <device>
+
+.SH DESCRIPTION
+
+\fInfsrahead\fR is a tool intended to be used with udev to set the \fIread_ahead_kb\fR parameter of NFS mounts, according to the configuration file (see \fICONFIGURATION\fR). \fIdevice\fR is the device number for the NFS backing device as provided by the kernel.
+
+.SH OPTIONS
+.TP
+.B -F
+Send messages to
+.I stderr
+instead of
+.I syslog
+
+.TP
+.B -d
+Increase the debugging level.
+
+.SH CONFIGURATION
+.I nfsrahead
+is configured in
+.IR /etc/nfs.conf ,
+in the section titled
+.IR nfsrahead .
+It accepts the following configurations.
+
+.TP
+.B nfs=<value>
+The readahead value applied to NFSv3 mounts.
+
+.TP
+.B nfs4=<value>
+The readahead value applied to NFSv4 mounts.
+
+.TP
+.B default=<value>
+The default configuration when none of the configurations above is set.
+
+.SH EXAMPLE CONFIGURATION
+[nfsrahead]
+.br
+nfs=15000 # readahead of 15000 for NFSv3 mounts
+.br
+nfs4=16000 # readahead of 16000 for NFSv4 mounts
+.br
+default=128 # default is 128
+
+.SH SEE ALSO
+
+.BR mount.nfs (8),
+.BR nfs (5),
+.BR nfs.conf (5),
+.BR udev (7),
+.BR bcc-readahead (8)
+
+.SH BUGS
+
+No known bugs.
+
+.SH AUTHOR
+
+Thiago Rafael Becker <trbecker@gmail.com>