xref: /netbsd-src/usr.sbin/mountd/mountd.8 (revision a5847cc334d9a7029f6352b847e9e8d71a0f9e0c)
1.\"	$NetBSD: mountd.8,v 1.36 2011/11/02 20:27:33 wiz 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 November 2, 2011
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 Ds
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.Dq -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-1023) 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 exports file.
104.El
105.Pp
106When
107.Nm
108is started,
109it loads the export host addresses and options into the kernel
110using the
111.Xr nfssvc 2
112system call.
113After changing the exports file,
114a hangup signal should be sent to the
115.Nm
116daemon to get it to reload the export information.
117After sending the SIGHUP
118(kill \-s HUP `cat /var/run/mountd.pid`),
119check the syslog output to see if
120.Nm
121logged any parsing errors in the exports file.
122.Pp
123After receiving SIGTERM,
124.Nm
125sends a broadcast request to remove the mount list from all the clients.
126This can take a long time, since the broadcast request waits for each
127client to respond.
128.Sh FILES
129.Bl -tag -width /var/run/mountd.pid -compact
130.It Pa /etc/exports
131the list of exported filesystems
132.It Pa /var/run/mountd.pid
133the pid of the currently running
134.Nm
135.It Pa /var/db/mountdtab
136the list of remotely mounted filesystems
137.El
138.Sh SEE ALSO
139.Xr nfsstat 1 ,
140.Xr nfssvc 2 ,
141.Xr exports 5 ,
142.Xr nfsd 8 ,
143.Xr rpcbind 8 ,
144.Xr showmount 8
145.Sh HISTORY
146The
147.Nm
148utility first appeared in
149.Bx 4.4 .
150