source: networking/netprogs/nfs-utils.xml@ d7bee48

systemd-13485
Last change on this file since d7bee48 was d7bee48, checked in by Douglas R. Reno <renodr@…>, 8 years ago

Sync to trunk r17332

git-svn-id: svn://svn.linuxfromscratch.org/BLFS/branches/systemd@17335 af4574ff-66df-0310-9fd7-8a98e5e911e0

  • Property mode set to 100644
File size: 17.8 KB
Line 
1<?xml version="1.0" encoding="ISO-8859-1"?>
2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
3 "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
4 <!ENTITY % general-entities SYSTEM "../../general.ent">
5 %general-entities;
6
7 <!ENTITY nfs-utils-download-http "&sourceforge-repo;/nfs/nfs-utils-&nfs-utils-version;.tar.bz2">
8 <!ENTITY nfs-utils-download-ftp " ">
9 <!ENTITY nfs-utils-md5sum "9b87d890669eaaec8e97a2b0a35b2665">
10 <!ENTITY nfs-utils-size "776 KB">
11 <!ENTITY nfs-utils-buildsize "14 MB">
12 <!ENTITY nfs-utils-time "0.2 SBU">
13]>
14
15<sect1 id="nfs-utils" xreflabel="nfs-utils-&nfs-utils-version;">
16 <?dbhtml filename="nfs-utils.html"?>
17
18 <sect1info>
19 <othername>$LastChangedBy$</othername>
20 <date>$Date$</date>
21 </sect1info>
22
23 <title>NFS-Utils-&nfs-utils-version;</title>
24
25 <indexterm zone="nfs-utils">
26 <primary sortas="a-Nfs-utils">NFS Utilities</primary>
27 </indexterm>
28
29 <sect2 role="package">
30 <title>Introduction to NFS Utilities</title>
31
32 <para>The <application>NFS Utilities</application> package contains the
33 userspace server and client tools necessary to use the kernel's NFS
34 abilities. NFS is a protocol that allows sharing file systems over the
35 network.</para>
36
37 &lfs78_checked;
38
39 <bridgehead renderas="sect3">Package Information</bridgehead>
40 <itemizedlist spacing='compact'>
41 <listitem>
42 <para>Download (HTTP): <ulink url="&nfs-utils-download-http;"/></para>
43 </listitem>
44 <listitem>
45 <para>Download (FTP): <ulink url="&nfs-utils-download-ftp;"/></para>
46 </listitem>
47 <listitem>
48 <para>Download MD5 sum: &nfs-utils-md5sum;</para>
49 </listitem>
50 <listitem>
51 <para>Download size: &nfs-utils-size;</para>
52 </listitem>
53 <listitem>
54 <para>Estimated disk space required: &nfs-utils-buildsize;</para>
55 </listitem>
56 <listitem>
57 <para>Estimated build time: &nfs-utils-time;</para>
58 </listitem>
59 </itemizedlist>
60
61 <bridgehead renderas="sect3">NFS Utilities Dependencies</bridgehead>
62
63 <bridgehead renderas="sect4">Required</bridgehead>
64 <para role="required">
65 <xref linkend="libtirpc"/>
66 </para>
67
68 <bridgehead renderas="sect4">Optional</bridgehead>
69 <para role="optional">
70 <xref linkend="libevent"/>,
71 <xref linkend="sqlite"/> and
72 <xref linkend="libnfsidmap"/> (for NFSv4 support),
73 <xref linkend="mitkrb"/> or
74 <ulink url="http://www.citi.umich.edu/projects/nfsv4/linux/">libgssapi</ulink>, and
75 <ulink url="http://www.citi.umich.edu/projects/nfsv4/linux/">librpcsecgss</ulink> (for GSS and RPC security support) and
76 <xref linkend="libcap-pam"/>
77 </para>
78
79 <bridgehead renderas="sect4">Required (runtime)</bridgehead>
80 <para role="required">
81 <xref linkend="rpcbind"/>
82 </para>
83
84 <para condition="html" role="usernotes">User Notes:
85 <ulink url="&blfs-wiki;/nfs-utils"/></para>
86
87 </sect2>
88
89 <sect2 role="kernel" id='nfs-utils-kernel'>
90 <title>Kernel Configuration</title>
91
92 <para>Enable the following options in the kernel configuration
93 (choose client and/or server support as appropriate) and recompile the
94 kernel if necessary:</para>
95
96<screen><literal>File systems ---&gt;
97 [*] Network File Systems ---&gt; [CONFIG_NETWORK_FILESYSTEMS]
98 &lt;*/M&gt; NFS client support [CONFIG_NFS_FS]
99 &lt;*/M&gt; NFS server support [CONFIG_NFSD]</literal></screen>
100
101 <para>Select the appropriate sub-options that appear when the above options
102 are selected.</para>
103
104 <note>
105 <para>
106 In BLFS we assume that nfs v3 will be used. If the
107 <emphasis>server</emphasis> offers nfs v4 (for linux, CONFIG_NFSD_V4)
108 then auto-negotiation for v3 will fail and you will need to add
109 <literal>nfsver=3</literal> to the mount options. This also applies
110 if that option is enabled in the <emphasis>client's</emphasis> kernel,
111 for example in a distro trying to mount from a BLFS v3 server.
112 </para>
113 </note>
114
115 <indexterm zone="nfs-utils nfs-utils-kernel">
116 <primary sortas="d-nfs-utils">NFS Utilities</primary>
117 </indexterm>
118
119 </sect2>
120
121 <sect2 role="installation" id='nfs-utils-install'
122 xreflabel='NFS Utilities Installation'>
123 <title>Installation of NFS Utilities</title>
124
125 <para>Install <application>NFS Utilities</application> by running
126 the following commands:</para>
127
128<screen><userinput>./configure --prefix=/usr \
129 --sysconfdir=/etc \
130 --without-tcp-wrappers \
131 --disable-nfsv4 \
132 --disable-gss &amp;&amp;
133make</userinput></screen>
134
135 <para>If your <filename class="directory">/usr</filename> directory
136 is NFS mounted, you should install the executables in
137 <filename class="directory">/sbin</filename> by passing
138 an additional parameter <option>--sbindir=/sbin</option> to the
139 above <command>./configure</command> command.</para>
140
141 <para>Now, as the <systemitem class="username">root</systemitem> user:</para>
142
143<!-- dev note: make statduser=$(whoami) DESTDIR=<DESTDIR> install -->
144
145<screen role='root'><userinput>make install &amp;&amp;
146chmod u+w,go+r /sbin/mount.nfs</userinput></screen>
147
148 <para>The tests for this package require that the package be installed and
149 configured as specified below. In addition, the the daemon from <xref
150 linkend="rpcbind"/> needs to be running and the tests need to be run as the
151 <systemitem class="username">root</systemitem> user.</para>
152
153 <para>To test the results, issue, as root: <command>make check</command>.</para>
154
155 </sect2>
156
157 <sect2 role="commands">
158 <title>Command Explanations</title>
159
160 <para><parameter>--without-tcp-wrappers</parameter>: This option is
161 needed because TCP Wrappers is not in BLFS.</para>
162
163 <para><parameter>--disable-nfsv4</parameter>: This allows the package to be
164 built when libnfsidmap has not been installed.</para>
165
166 <para><parameter>--disable-gss</parameter>: Disables support for
167 RPCSEC GSS (RPC Security).</para>
168
169 </sect2>
170
171 <sect2 role="configuration">
172 <title>Configuring NFS Utilities</title>
173
174 <sect3 id='nfs-utils-server-config'>
175 <title>Server Configuration</title>
176
177 <para><filename>/etc/exports</filename> contains the exported directories
178 on NFS servers. Refer to the <filename>exports.5</filename> manual page
179 for the syntax of this file. Also refer to the "NFS HowTo" available at
180 <ulink url="http://nfs.sourceforge.net/nfs-howto/"/> for information on
181 how to configure the servers and clients in a secure manner. For example,
182 for sharing the <filename class="directory">/home</filename> directory
183 over the local network, the following line may be added:</para>
184
185<screen role="root"><userinput>/home <replaceable>192.168.0.0/24</replaceable>(rw,subtree_check,anonuid=99,anongid=99)</userinput></screen>
186
187 <note><para>Be sure to replace the directory, network address. and prefix above
188 to match your network. The only space in the line above should be between
189 the directory and the network address.</para></note>
190
191 <indexterm zone="nfs-utils nfs-utils-server-config">
192 <primary sortas="e-etc-exportfs">/etc/exportfs</primary>
193 </indexterm>
194
195 <sect4 id="nfs-utils-server-init">
196 <title>Systemd Units</title>
197
198 <para>
199 To start the NFS server daemons at boot,
200 install the systemd units from the <xref linkend="bootscripts"/>
201 package by running the following command as the
202 <systemitem class="username">root</systemitem> user:
203 </para>
204
205<screen role="root"><userinput>make install-nfsv4-server</userinput></screen>
206
207 <para>
208 If you have disabled NFSv4 support, run the following
209 command as the <systemitem
210 class="username">root</systemitem> user to omit the NFSv4
211 specific systemd units:
212 </para>
213
214<screen role="root"><userinput>make install-nfs-server</userinput></screen>
215
216 <indexterm zone="nfs-utils nfs-utils-server-init">
217 <primary sortas="f-nfs-server">nfs-server</primary>
218 </indexterm>
219
220 <para>
221 You can edit the <filename>/etc/default/nfs-utils</filename>
222 file to change the startup options for NFS daemons. Defaults
223 should be fine for most use cases.
224 </para>
225
226 <indexterm zone="nfs-utils nfs-utils-server-init">
227 <primary sortas="e-etc-default-nfs-utils">/etc/default/nfs-utils</primary>
228 </indexterm>
229
230 </sect4>
231
232 </sect3>
233
234 <sect3 id='nfs-utils-client-config'>
235 <title>Client Configuration</title>
236
237 <para><filename>/etc/fstab</filename> contains the directories that
238 are to be mounted on the client. Alternately the partitions can be
239 mounted by using the <command>mount</command> command with the proper
240 options. To mount the <filename class="directory">/home</filename>
241 and <filename class="directory">/usr</filename> partitions, add the
242 following to the <filename>/etc/fstab</filename>:</para>
243
244<screen role="root"><userinput><replaceable>&lt;server-name&gt;</replaceable>:/home /home nfs rw,_netdev 0 0
245<replaceable>&lt;server-name&gt;</replaceable>:/usr /usr nfs ro,_netdev 0 0</userinput></screen>
246
247 <para>The options which can be used are specified in <command>man 5 nfs</command>.
248 If both the client and server are running recent versions of linux, most of the
249 options will be negotiated. You can specify either <literal>rw</literal> or
250 <literal>ro</literal>, <literal>_netdev</literal> if the filesystem is to be
251 automatically mounted at boot, or <literal>noauto</literal> (and perhaps
252 <literal>user</literal>) for other filesystems.</para>
253
254 <para>If the fileserver is not running a recent version of linux, you may need to
255 specifiy other options.</para>
256
257 <para>If you are using systemd, you may need to enable autofs v4 in your kernel,
258 and add the option <literal>comment=systemd.automount</literal>. Some machines
259 need this, because systemd tries to mount the external fs&apos;s before the network
260 is up, others do not need it. An alternative is for <systemitem
261 class="username">root</systemitem> to run <command>mount -a</command>.</para>
262
263 <indexterm zone="nfs-utils nfs-utils-client-config">
264 <primary sortas="e-etc-fstab">/etc/fstab</primary>
265 </indexterm>
266
267 <sect4 id="nfs-utils-client-init">
268 <title>Systemd Units</title>
269
270 <note>
271 <para>
272 The following systemd unis are not required if the
273 nfs-server units were previously installed.
274 </para>
275 </note>
276
277 <para>
278 To start the NFS client services at boot,
279 install the systemd units from the <xref linkend="bootscripts"/>
280 package by running the following command as the
281 <systemitem class="username">root</systemitem> user:
282 </para>
283
284<screen role="root"><userinput>make install-nfs-client</userinput></screen>
285
286 <indexterm zone="nfs-utils nfs-utils-client-config">
287 <primary sortas="f-nfs-client">nfs-client</primary>
288 </indexterm>
289
290 </sect4>
291
292 </sect3>
293
294 </sect2>
295
296 <sect2 role="content">
297 <title>Contents</title>
298 <segmentedlist>
299 <segtitle>Installed Programs</segtitle>
300 <segtitle>Installed Libraries</segtitle>
301 <segtitle>Installed Directories</segtitle>
302
303 <seglistitem>
304 <seg>exportfs, mountstats, mount.nfs, mount.nfs4 (link to mount.nfs),
305 nfsiostat, nfsstat, osd_login, rpc.mountd, rpc.nfsd, rpc.statd, rpcdebug,
306 showmount, sm-notify, start-statd, umount.nfs (link to mount.nfs),
307 and umount.nfs4 (link to mount.nfs)</seg>
308 <seg>None</seg>
309 <seg>/var/lib/nfs</seg>
310 </seglistitem>
311 </segmentedlist>
312
313 <variablelist>
314 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
315 <?dbfo list-presentation="list"?>
316 <?dbhtml list-presentation="table"?>
317
318 <varlistentry id="exportfs">
319 <term><command>exportfs</command></term>
320 <listitem>
321 <para>maintains a list of NFS exported file systems.</para>
322 <indexterm zone="nfs-utils exportfs">
323 <primary sortas="b-exportfs">exportfs</primary>
324 </indexterm>
325 </listitem>
326 </varlistentry>
327
328 <varlistentry id="mountstats">
329 <term><command>mountstats</command></term>
330 <listitem>
331 <para>displays NFS client per-mount statistics.</para>
332 <indexterm zone="nfs-utils mountstats">
333 <primary sortas="b-mountstats">mountstats</primary>
334 </indexterm>
335 </listitem>
336 </varlistentry>
337
338 <varlistentry id="mount.nfs">
339 <term><command>mount.nfs</command></term>
340 <listitem>
341 <para>Used to mount a network share using NFS</para>
342 <indexterm zone="nfs-utils mount.nfs">
343 <primary sortas="b-mount.nfs">mount.nfs</primary>
344 </indexterm>
345 </listitem>
346 </varlistentry>
347
348 <varlistentry id="mount.nfs4">
349 <term><command>mount.nfs4</command></term>
350 <listitem>
351 <para>Used to mount a network share using NFSv4</para>
352 <indexterm zone="nfs-utils mount.nfs4">
353 <primary sortas="b-mount.nfs4">mount.nfs4</primary>
354 </indexterm>
355 </listitem>
356 </varlistentry>
357
358 <varlistentry id="nfsiostat-nfs-utils">
359 <term><command>nfsiostat</command></term>
360 <listitem>
361 <para>Report input/output statistics for network filesystems.</para>
362 <indexterm zone="nfs-utils nfsiostat-nfs-utils">
363 <primary sortas="b-nfsiostat-nfs-utils">nfsiostat</primary>
364 </indexterm>
365 </listitem>
366 </varlistentry>
367
368 <varlistentry id="nfsstat">
369 <term><command>nfsstat</command></term>
370 <listitem>
371 <para>displays statistics kept about NFS client and server activity.</para>
372 <indexterm zone="nfs-utils nfsstat">
373 <primary sortas="b-nfsstat">nfsstat</primary>
374 </indexterm>
375 </listitem>
376 </varlistentry>
377
378 <varlistentry id="osd_login">
379 <term><command>osd_login</command></term>
380 <listitem>
381 <para>is a script that is a part of the autologin feature
382 mandated by the pnfs-objects standard.</para>
383 <indexterm zone="nfs-utils osd_login">
384 <primary sortas="b-osd_login">osd_login</primary>
385 </indexterm>
386 </listitem>
387 </varlistentry>
388
389
390 <varlistentry id="rpc.mountd">
391 <term><command>rpc.mountd</command></term>
392 <listitem>
393 <para>implements the NFS mount protocol on an NFS server.</para>
394 <indexterm zone="nfs-utils rpc.mountd">
395 <primary sortas="b-rpc.mountd">rpc.mountd</primary>
396 </indexterm>
397 </listitem>
398 </varlistentry>
399
400 <varlistentry id="rpc.nfsd">
401 <term><command>rpc.nfsd</command></term>
402 <listitem>
403 <para>implements the user level part of the NFS
404 service on the server.</para>
405 <indexterm zone="nfs-utils rpc.nfsd">
406 <primary sortas="b-rpc.nfsd">rpc.nfsd</primary>
407 </indexterm>
408 </listitem>
409 </varlistentry>
410
411 <varlistentry id="rpc.statd">
412 <term><command>rpc.statd</command></term>
413 <listitem>
414 <para>is used by the NFS file locking service. Run on both sides,
415 client as well as server, when you want file locking enabled.</para>
416 <indexterm zone="nfs-utils rpc.statd">
417 <primary sortas="b-rpc.statd">rpc.statd</primary>
418 </indexterm>
419 </listitem>
420 </varlistentry>
421
422 <varlistentry id="rpcdebug">
423 <term><command>rpcdebug</command></term>
424 <listitem>
425 <para>sets or clears the kernel's NFS client and server debug
426 flags.</para>
427 <indexterm zone="nfs-utils rpcdebug">
428 <primary sortas="b-rpcdebug">rpcdebug</primary>
429 </indexterm>
430 </listitem>
431 </varlistentry>
432
433 <varlistentry id="showmount">
434 <term><command>showmount</command></term>
435 <listitem>
436 <para>displays mount information for an NFS server.</para>
437 <indexterm zone="nfs-utils showmount">
438 <primary sortas="b-showmount">showmount</primary>
439 </indexterm>
440 </listitem>
441 </varlistentry>
442
443 <varlistentry id="sm-notify">
444 <term><command>sm-notify</command></term>
445 <listitem>
446 <para>is used to send Network Status Monitor reboot messages.</para>
447 <indexterm zone="nfs-utils sm-notify">
448 <primary sortas="b-sm-notify">sm-notify</primary>
449 </indexterm>
450 </listitem>
451 </varlistentry>
452
453 <varlistentry id="start-statd">
454 <term><command>start-statd</command></term>
455 <listitem>
456 <para>is a script called by nfsmount when mounting a filesystem with
457 locking enabled, if statd does not appear to be running. It can be
458 customised with whatever flags are appropriate for the site.</para>
459 <indexterm zone="nfs-utils start-statd">
460 <primary sortas="b-start-statd">start-statd</primary>
461 </indexterm>
462 </listitem>
463 </varlistentry>
464
465 <varlistentry id="umount.nfs">
466 <term><command>umount.nfs</command></term>
467 <listitem>
468 <para>Used to unmount a network share using NFS</para>
469 <indexterm zone="nfs-utils umount.nfs">
470 <primary sortas="b-umount.nfs">umount.nfs</primary>
471 </indexterm>
472 </listitem>
473 </varlistentry>
474
475 <varlistentry id="umount.nfs4">
476 <term><command>umount.nfs4</command></term>
477 <listitem>
478 <para>Used to unmount a network share using NFSv4</para>
479 <indexterm zone="nfs-utils umount.nfs4">
480 <primary sortas="b-umount.nfs4">umount.nfs4</primary>
481 </indexterm>
482 </listitem>
483 </varlistentry>
484
485 </variablelist>
486
487 </sect2>
488
489</sect1>
Note: See TracBrowser for help on using the repository browser.