Commit | Line | Data |
---|---|---|
665935df | 1 | .\" Copyright (c) 1989, 1991 The Regents of the University of California. |
7dd5dab1 KM |
2 | .\" All rights reserved. |
3 | .\" | |
665935df | 4 | .\" %sccs.include.redist.roff% |
7dd5dab1 | 5 | .\" |
665935df | 6 | .\" @(#)nfsd.8 5.9 (Berkeley) %G% |
7dd5dab1 | 7 | .\" |
665935df CL |
8 | .Dd |
9 | .Dt NFSD 8 | |
10 | .Os | |
11 | .Sh NAME | |
12 | .Nm nfsd | |
13 | .Nd remote | |
14 | .Tn NFS | |
15 | server | |
16 | .Sh SYNOPSIS | |
17 | .Nm nfsd | |
18 | .Op Fl r | |
19 | .Bk -words | |
20 | .Op Fl t Ar msk,mtch,hostadr1,hostadr2,... | |
21 | .Ek | |
22 | .Bk -words | |
23 | .Op Fl u Ar msk,mtch,numprocs | |
24 | .Ek | |
25 | .Op Ar numprocs | |
26 | .Sh DESCRIPTION | |
27 | .Nm Nfsd | |
1b3a818d | 28 | runs on a server machine to service |
665935df | 29 | .Tn NFS |
1b3a818d KM |
30 | requests from client machines. |
31 | At least one | |
665935df | 32 | .Nm nfsd |
1b3a818d | 33 | must be running for a machine to operate as a server. |
1b3a818d | 34 | The options |
665935df | 35 | .Fl u |
1b3a818d | 36 | and |
665935df | 37 | .Fl t |
7a094649 | 38 | are used to indicate which transport protocols are to be served. |
665935df CL |
39 | .Pp |
40 | Options available to | |
41 | .Nm nfsd : | |
42 | .Bl -tag -width Ds | |
43 | .It Fl r | |
44 | Register the | |
45 | .Tn NFS | |
46 | service with | |
47 | .Xr portmap 8 | |
48 | without creating any servers. This option can be used along with the | |
49 | .Fl u | |
50 | or | |
51 | .Fl t | |
7d52935b | 52 | options to re-register NFS if the portmap server is restarted. |
665935df CL |
53 | .It Fl t |
54 | Serve | |
55 | .Tn TCP NFS | |
56 | clients. | |
57 | .It Fl u | |
58 | Serve | |
59 | .Tn UDP NFS | |
60 | clients. | |
61 | .El | |
62 | .Pp | |
7d52935b | 63 | The following arguments to the |
665935df | 64 | .Fl u |
7d52935b | 65 | or |
665935df | 66 | .Fl t |
7d52935b MK |
67 | options are used to specify parameters for service using the respective |
68 | protocol: | |
665935df CL |
69 | .Bl -tag -width Ds |
70 | .It Ar msk , mtch | |
71 | These arguments permit restriction of | |
72 | .Tn NFS | |
73 | services | |
7a094649 | 74 | to a subset of the host addresses. The |
665935df | 75 | .Ar msk |
1b3a818d | 76 | and |
665935df | 77 | .Ar mtch |
7a094649 | 78 | are applied to the client host address as follows: |
665935df CL |
79 | .Pp |
80 | .Bd -filled -offset indent -compact | |
7a094649 | 81 | if (( |
665935df | 82 | .Ar host_address No \&& Em msk |
7a094649 | 83 | ) == |
665935df | 84 | .Ar mtch |
7a094649 KM |
85 | ) |
86 | .br | |
665935df | 87 | \- service the client request |
1b3a818d | 88 | .br |
7a094649 KM |
89 | else |
90 | .br | |
665935df CL |
91 | \- drop the request |
92 | .Ed | |
93 | .It Ar hostadr1 , ... | |
7a094649 KM |
94 | You may also specify zero or more specific host addresses to be accepted |
95 | as well as ones that pass the | |
665935df | 96 | .Ar msk , mtch |
7a094649 KM |
97 | test above. |
98 | This may only be done for transport protocols that are connection based, such | |
665935df CL |
99 | as |
100 | .Tn TCP . | |
7a094649 | 101 | For the internet domain, |
665935df | 102 | .Ar msk , mtch |
7a094649 | 103 | and |
665935df | 104 | .Ar hostadrs |
7a094649 | 105 | are specified in internet |
665935df | 106 | .Em dot |
7a094649 | 107 | notation. |
665935df | 108 | .It Ar numprocs |
7a094649 | 109 | Specifies how many servers to fork off. This may only be specified for |
665935df CL |
110 | non-connection based protocols such as |
111 | .Tn UDP . | |
112 | .El | |
113 | .Pp | |
7a094649 | 114 | If neither |
665935df | 115 | .Fl u |
7a094649 | 116 | or |
665935df | 117 | .Fl t |
7a094649 | 118 | are specified, |
665935df CL |
119 | .Ar numprocs |
120 | servers for | |
121 | .Tn UDP | |
122 | accepting requests from all clients are started. | |
7a094649 | 123 | If |
665935df | 124 | .Ar numprocs |
7a094649 | 125 | is not specified, it defaults to 1. |
665935df | 126 | .Pp |
7a094649 | 127 | For example: |
665935df CL |
128 | .Bd -literal |
129 | nfsd \-u 255.255.255.0,131.104.48.0,4 \-t \e | |
130 | 255.255.0.0,131.104.0.0,131.102.31.2 | |
131 | .Ed | |
132 | .Bl -item -offset indent | |
133 | .It | |
134 | Serves | |
135 | .Tn UDP | |
136 | and | |
137 | .Tn TCP | |
138 | transports. For | |
139 | .Tn UDP , | |
7a094649 KM |
140 | it runs 4 daemons that accept requests |
141 | from any client on subnet 131.104.48. | |
665935df CL |
142 | For |
143 | .Tn TCP , | |
144 | it accepts connections from any client on network 131.104 | |
7a094649 | 145 | plus the client with the address 131.102.31.2. |
665935df CL |
146 | .El |
147 | .Bd -literal | |
7167345e | 148 | nfsd \-u 255.255.240.0,131.104.0.0,6 \-t 0,0 |
665935df CL |
149 | .Ed |
150 | .Bl -item -offset indent | |
151 | .It | |
152 | Serves | |
153 | .Tn UDP | |
154 | and | |
155 | .Tn TCP | |
156 | transports. | |
157 | For | |
158 | .Tn UDP , | |
159 | it runs 6 daemons that accept requests from clients with | |
7a094649 | 160 | addresses in the range 131.104.0.x - 131.104.15.x. |
665935df CL |
161 | For |
162 | .Tn TCP , | |
163 | it accepts connections from any client. | |
164 | .El | |
165 | .Pp | |
166 | .Li nfsd \-u 0,0,4 | |
167 | .Bl -item -offset indent | |
168 | .It | |
169 | Serves any | |
170 | .Tn UDP | |
171 | client with 4 servers, only. | |
172 | .El | |
173 | .Pp | |
174 | .Li nfsd 4 | |
175 | .Bl -item -offset indent | |
176 | .It | |
177 | Serves any | |
178 | .Tn UDP | |
179 | client with 4 servers, only. (Compatibility) | |
180 | .El | |
181 | .Pp | |
7a094649 KM |
182 | A server should typically run enough daemons to handle |
183 | the maximum level of concurrency from its clients, | |
184 | typically four to six. | |
665935df CL |
185 | .Pp |
186 | .Nm Nfsd | |
7dd5dab1 | 187 | listens for service requests at the port indicated in the |
665935df | 188 | .Tn NFS |
7dd5dab1 | 189 | server specification; see |
665935df CL |
190 | .%T "Network File System Protocol Specification" , |
191 | RFC1094. | |
192 | .Sh SEE ALSO | |
193 | .Xr nfsstat 1 , | |
194 | .Xr nfssvc 2 , | |
195 | .Xr mountd 8 , | |
196 | .Xr portmap 8 | |
197 | .Sh BUGS | |
7a094649 | 198 | The client host address restrictions specified here are unrelated to |
665935df CL |
199 | the mount restrictions specified in |
200 | .Pa /etc/exports | |
201 | for | |
202 | .Xr mountd 8 . | |
203 | .Sh HISTORY | |
204 | The | |
205 | .Nm | |
206 | command is | |
207 | .Ud . |