git: 2cd9a4f0c229 - stable/14 - exports.5: Document the current behavior of -alldirs
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Mon, 20 Jan 2025 00:01:18 UTC
The branch stable/14 has been updated by rmacklem:
URL: https://cgit.FreeBSD.org/src/commit/?id=2cd9a4f0c229626f7422187b30723772336e8896
commit 2cd9a4f0c229626f7422187b30723772336e8896
Author: Rick Macklem <rmacklem@FreeBSD.org>
AuthorDate: 2024-12-28 21:51:08 +0000
Commit: Rick Macklem <rmacklem@FreeBSD.org>
CommitDate: 2025-01-20 00:00:35 +0000
exports.5: Document the current behavior of -alldirs
Commit 07cd69e272da adds a new "-a" mountd option,
which changes the behavior of mountd when file systems
are exported via -alldirs.
This patch updates the man page to reflect the actual
behavior when -alldirs is used when mountd is started
with/without -a. Prior to the above commit, exports(5)
documented that, when -alldirs was specified, the exports
line would fail unless the directory was a server file
system mount point. This behavior was only documented
in the Examples section and has not been implemented
since a change between FreeBSD 1 and FreeBSD 2 was done.
This is a contents change.
PR: 282995
(cherry picked from commit 295934eaa92cd917ae42a446899c0d527ad9c0c9)
---
usr.sbin/mountd/exports.5 | 23 +++++++++++++++++++----
1 file changed, 19 insertions(+), 4 deletions(-)
diff --git a/usr.sbin/mountd/exports.5 b/usr.sbin/mountd/exports.5
index 6c18e910c116..b8f0e93aec8a 100644
--- a/usr.sbin/mountd/exports.5
+++ b/usr.sbin/mountd/exports.5
@@ -27,7 +27,7 @@
.\"
.\" @(#)exports.5 8.3 (Berkeley) 3/29/95
.\"
-.Dd October 08, 2024
+.Dd December 16, 2024
.Dt EXPORTS 5
.Os
.Sh NAME
@@ -86,6 +86,15 @@ to limit exported directories to server local file system mount points.
When exporting ZFS datasets with the
.Sy sharenfs
property, this is auomatically the case.
+If the
+.Fl alldirs
+flag is specified and
+the
+.Fl a
+command line option is specified for
+.Xr mountd 8 ,
+the export will fail if the directory path is not a local file system
+mount point.
.Pp
There are three forms of the directory path specification.
The first is to list all mount points as absolute
@@ -552,12 +561,18 @@ will be exported read-only to the entire network 192.168.33.0/24, including
all its subdirectories.
Since
.Pa /cdrom
-is the conventional mountpoint for a CD-ROM device, this export will
-fail if no CD-ROM medium is currently mounted there since that line
+is the conventional mountpoint for a CD-ROM device,
+for the case where the
+.Fl a
+option has been specified for
+.Xr mountd 8 ,
+this export will
+fail if no CD-ROM medium is currently mounted there
+since that line
would then attempt to export a subdirectory of the root file system
with the
.Fl alldirs
-option which is not allowed.
+option.
The
.Fl quiet
option will then suppress the error message for this condition that