1.\" $NetBSD: mountd.8,v 1.42 2023/03/15 20:39:12 uwe Exp $ 2.\" 3.\" Copyright (c) 1989, 1991, 1993 4.\" The Regents of the University of California. All rights reserved. 5.\" 6.\" Redistribution and use in source and binary forms, with or without 7.\" modification, are permitted provided that the following conditions 8.\" are met: 9.\" 1. Redistributions of source code must retain the above copyright 10.\" notice, this list of conditions and the following disclaimer. 11.\" 2. Redistributions in binary form must reproduce the above copyright 12.\" notice, this list of conditions and the following disclaimer in the 13.\" documentation and/or other materials provided with the distribution. 14.\" 3. Neither the name of the University nor the names of its contributors 15.\" may be used to endorse or promote products derived from this software 16.\" without specific prior written permission. 17.\" 18.\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND 19.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 20.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 21.\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE 22.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 23.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 24.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 25.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 26.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 27.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 28.\" SUCH DAMAGE. 29.\" 30.\" @(#)mountd.8 8.4 (Berkeley) 4/28/95 31.\" 32.Dd February 16, 2021 33.Dt MOUNTD 8 34.Os 35.Sh NAME 36.Nm mountd 37.Nd service remote 38.Tn NFS 39mount requests 40.Sh SYNOPSIS 41.Nm 42.Op Fl dN 43.Op Fl P Ar policy 44.Op Fl p Ar port 45.Op Ar exportsfile ... 46.Sh DESCRIPTION 47.Nm 48is the server for 49.Tn NFS 50mount requests from other client machines. 51.Nm 52listens for service requests at the port indicated in the 53.Tn NFS 54server specification; see 55.%T "Network File System Protocol Specification" , 56RFC 1094, Appendix A, and 57.%T "NFS: Network File System Version 3 Protocol Specification" , 58Appendix I. 59.Pp 60Options and operands available for 61.Nm mountd : 62.Bl -tag -width Fl 63.It Fl d 64Enable debugging mode. 65.Nm 66will not detach from the controlling terminal and will print 67debugging messages to stderr. 68.It Fl N 69Do not require privileged ports for mount or NFS RPC calls. 70This option is equivalent to specifying 71.Ql -noresvport -noresvmnt 72on every export. 73See 74.Xr exports 5 75for more information. 76Some operating systems (notably Mac OS X) require this option. 77.It Fl P Ar policy 78IPsec 79.Ar policy 80string, 81as described in 82.Xr ipsec_set_policy 3 . 83Multiple IPsec policy strings may be specified by using a semicolon as 84a separator. 85If conflicting policy strings are found in a single line, 86the last string will take effect. 87If an invalid IPsec policy string is used 88.Nm 89logs an error message and terminates itself. 90.It Fl p Ar port 91Force 92.Nm 93to bind to the given port. 94If this option is not given, 95.Nm 96may bind to every anonymous port 97(in the range 600\^\(en1023) which causes trouble when trying to use 98NFS through a firewall. 99.It Ar exportsfile 100The 101.Ar exportsfile 102argument specifies an alternative location 103for the 104.Xr exports 5 105file. 106Multiple exports files can be defined. 107.El 108.Pp 109When 110.Nm 111is started, 112it loads the export host addresses and options into the kernel 113using the 114.Xr nfssvc 2 115system call. 116After changing the exports file, 117a hangup signal should be sent to the 118.Nm 119daemon to get it to reload the export information. 120After sending the 121.Dv SIGHUP 122.Pp 123.Dl kill \-s HUP $(cat /var/run/mountd.pid) 124.Pp 125check the syslog output to see if 126.Nm 127logged any parsing errors in the exports file. 128.Pp 129After receiving 130.Dv SIGTERM , 131.Nm 132sends a broadcast request to remove the mount list from all the clients. 133This can take a long time, since the broadcast request waits for each 134client to respond. 135.Sh FILES 136.Bl -tag -width ".Pa /var/run/mountd.pid" -compact 137.It Pa /etc/exports 138the list of exported filesystems 139.It Pa /var/run/mountd.pid 140the pid of the currently running 141.Nm 142.It Pa /var/db/mountdtab 143the list of remotely mounted filesystems 144.El 145.Sh SEE ALSO 146.Xr nfsstat 1 , 147.Xr nfssvc 2 , 148.Xr ipsec_set_policy 3 , 149.Xr exports 5 , 150.Xr nfsd 8 , 151.Xr rpcbind 8 , 152.Xr showmount 8 153.Sh HISTORY 154The 155.Nm 156utility first appeared in 157.Bx 4.4 . 158