Put in proper address information for Poul-Henning Kamp.
[unix-history] / sbin / nfsd / nfsd.8
CommitLineData
15637ed4
RG
1.\" Copyright (c) 1989, 1991 The Regents of the University of California.
2.\" All rights reserved.
3.\"
4.\" Redistribution and use in source and binary forms, with or without
5.\" modification, are permitted provided that the following conditions
6.\" are met:
7.\" 1. Redistributions of source code must retain the above copyright
8.\" notice, this list of conditions and the following disclaimer.
9.\" 2. Redistributions in binary form must reproduce the above copyright
10.\" notice, this list of conditions and the following disclaimer in the
11.\" documentation and/or other materials provided with the distribution.
12.\" 3. All advertising materials mentioning features or use of this software
13.\" must display the following acknowledgement:
14.\" This product includes software developed by the University of
15.\" California, Berkeley and its contributors.
16.\" 4. Neither the name of the University nor the names of its contributors
17.\" may be used to endorse or promote products derived from this software
18.\" without specific prior written permission.
19.\"
20.\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
21.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
22.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
23.\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
24.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
25.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
26.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
27.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
28.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
29.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
30.\" SUCH DAMAGE.
31.\"
32.\" @(#)nfsd.8 5.9 (Berkeley) 8/5/91
33.\"
34.Dd August 5, 1991
35.Dt NFSD 8
36.Os
37.Sh NAME
38.Nm nfsd
39.Nd remote
40.Tn NFS
41server
42.Sh SYNOPSIS
43.Nm nfsd
44.Op Fl r
45.Bk -words
46.Op Fl t Ar msk,mtch,hostadr1,hostadr2,...
47.Ek
48.Bk -words
49.Op Fl u Ar msk,mtch,numprocs
50.Ek
51.Op Ar numprocs
52.Sh DESCRIPTION
53.Nm Nfsd
54runs on a server machine to service
55.Tn NFS
56requests from client machines.
57At least one
58.Nm nfsd
59must be running for a machine to operate as a server.
60The options
61.Fl u
62and
63.Fl t
64are used to indicate which transport protocols are to be served.
65.Pp
66Options available to
67.Nm nfsd :
68.Bl -tag -width Ds
69.It Fl r
70Register the
71.Tn NFS
72service with
73.Xr portmap 8
74without creating any servers. This option can be used along with the
75.Fl u
76or
77.Fl t
78options to re-register NFS if the portmap server is restarted.
79.It Fl t
80Serve
81.Tn TCP NFS
82clients.
83.It Fl u
84Serve
85.Tn UDP NFS
86clients.
87.El
88.Pp
89The following arguments to the
90.Fl u
91or
92.Fl t
93options are used to specify parameters for service using the respective
94protocol:
95.Bl -tag -width Ds
96.It Ar msk , mtch
97These arguments permit restriction of
98.Tn NFS
99services
100to a subset of the host addresses. The
101.Ar msk
102and
103.Ar mtch
104are applied to the client host address as follows:
105.Pp
106.Bd -filled -offset indent -compact
107if ((
108.Ar host_address No \&& Em msk
109) ==
110.Ar mtch
111)
112.br
113 \- service the client request
114.br
115else
116.br
117 \- drop the request
118.Ed
119.It Ar hostadr1 , ...
120You may also specify zero or more specific host addresses to be accepted
121as well as ones that pass the
122.Ar msk , mtch
123test above.
124This may only be done for transport protocols that are connection based, such
125as
126.Tn TCP .
127For the internet domain,
128.Ar msk , mtch
129and
130.Ar hostadrs
131are specified in internet
132.Em dot
133notation.
134.It Ar numprocs
135Specifies how many servers to fork off. This may only be specified for
136non-connection based protocols such as
137.Tn UDP .
138.El
139.Pp
140If neither
141.Fl u
142or
143.Fl t
144are specified,
145.Ar numprocs
146servers for
147.Tn UDP
148accepting requests from all clients are started.
149If
150.Ar numprocs
151is not specified, it defaults to 1.
152.Pp
153For example:
154.Bd -literal
155nfsd \-u 255.255.255.0,131.104.48.0,4 \-t \e
156 255.255.0.0,131.104.0.0,131.102.31.2
157.Ed
158.Bl -item -offset indent
159.It
160Serves
161.Tn UDP
162and
163.Tn TCP
164transports. For
165.Tn UDP ,
166it runs 4 daemons that accept requests
167from any client on subnet 131.104.48.
168For
169.Tn TCP ,
170it accepts connections from any client on network 131.104
171plus the client with the address 131.102.31.2.
172.El
173.Bd -literal
174nfsd \-u 255.255.240.0,131.104.0.0,6 \-t 0,0
175.Ed
176.Bl -item -offset indent
177.It
178Serves
179.Tn UDP
180and
181.Tn TCP
182transports.
183For
184.Tn UDP ,
185it runs 6 daemons that accept requests from clients with
186addresses in the range 131.104.0.x - 131.104.15.x.
187For
188.Tn TCP ,
189it accepts connections from any client.
190.El
191.Pp
192.Li nfsd \-u 0,0,4
193.Bl -item -offset indent
194.It
195Serves any
196.Tn UDP
197client with 4 servers, only.
198.El
199.Pp
200.Li nfsd 4
201.Bl -item -offset indent
202.It
203Serves any
204.Tn UDP
205client with 4 servers, only. (Compatibility)
206.El
207.Pp
208A server should typically run enough daemons to handle
209the maximum level of concurrency from its clients,
210typically four to six.
211.Pp
212.Nm Nfsd
213listens for service requests at the port indicated in the
214.Tn NFS
215server specification; see
216.%T "Network File System Protocol Specification" ,
217RFC1094.
218.Sh SEE ALSO
219.Xr nfsstat 1 ,
220.Xr nfssvc 2 ,
221.Xr mountd 8 ,
222.Xr portmap 8
223.Sh BUGS
224The client host address restrictions specified here are unrelated to
225the mount restrictions specified in
226.Pa /etc/exports
227for
228.Xr mountd 8 .
229.Sh HISTORY
230The
231.Nm
232command is
233.Ud .