source: general/sysutils/autofs.xml@ 7aa91c69

10.1 11.0 ken/refactor-virt lazarus qt5new trunk xry111/git-date xry111/git-date-for-trunk xry111/git-date-test
Last change on this file since 7aa91c69 was 7aa91c69, checked in by Douglas R. Reno <renodr@…>, 9 months ago

Update to feh-3.6.3
Update to autofs-5.1.7
Update to talloc-2.3.2
Update to gparted-1.2.0
Update to xarchiver-0.5.4.17
Update to asciidoc-9.0.5
Update to util-macros-1.19.2
Update to libXt-1.2.1 (Xorg Library)
Update to wireshark-3.4.3 (Security Update)

git-svn-id: svn://svn.linuxfromscratch.org/BLFS/trunk/BOOK@24158 af4574ff-66df-0310-9fd7-8a98e5e911e0

  • Property mode set to 100644
File size: 13.6 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 autofs-download-http "&kernel-dl;/linux/daemons/autofs/v5/autofs-&autofs-version;.tar.xz">
8 <!ENTITY autofs-download-ftp " ">
9 <!ENTITY autofs-md5sum "6bd1ea8a9e5dc3a7dc95119e3bbaf52c">
10 <!ENTITY autofs-size "324 KB">
11 <!ENTITY autofs-buildsize "6.7 MB">
12 <!ENTITY autofs-time "0.1 SBU">
13]>
14
15<sect1 id="autofs" xreflabel="Autofs-&autofs-version;">
16 <?dbhtml filename="autofs.html"?>
17
18 <sect1info>
19 <othername>$LastChangedBy$</othername>
20 <date>$Date$</date>
21 </sect1info>
22
23 <title>autofs-&autofs-version;</title>
24
25 <indexterm zone="autofs">
26 <primary sortas="a-Autofs">Autofs</primary>
27 </indexterm>
28
29 <sect2 role="package">
30 <title>Introduction to Autofs</title>
31
32 <para>
33 <application>Autofs</application> controls the operation of the automount
34 daemons. The automount daemons automatically mount filesystems when they
35 are accessed and unmount them after a period of inactivity. This is done
36 based on a set of pre-configured maps.
37 </para>
38
39 &lfs10_checked;
40
41 <bridgehead renderas="sect3">Package Information</bridgehead>
42 <itemizedlist spacing="compact">
43 <listitem>
44 <para>
45 Download (HTTP): <ulink url="&autofs-download-http;"/>
46 </para>
47 </listitem>
48 <listitem>
49 <para>
50 Download (FTP): <ulink url="&autofs-download-ftp;"/>
51 </para>
52 </listitem>
53 <listitem>
54 <para>
55 Download MD5 sum: &autofs-md5sum;
56 </para>
57 </listitem>
58 <listitem>
59 <para>
60 Download size: &autofs-size;
61 </para>
62 </listitem>
63 <listitem>
64 <para>
65 Estimated disk space required: &autofs-buildsize;
66 </para>
67 </listitem>
68 <listitem>
69 <para>
70 Estimated build time: &autofs-time;
71 </para>
72 </listitem>
73 </itemizedlist>
74
75 <bridgehead renderas="sect3">Autofs Dependencies</bridgehead>
76
77 <bridgehead renderas="sect4">Required</bridgehead>
78 <para role="required">
79 <xref linkend="libtirpc"/> and
80 <xref linkend="rpcsvc-proto"/>
81 </para>
82
83 <bridgehead renderas="sect4">Optional</bridgehead>
84 <para role="optional">
85 <xref linkend="nfs-utils"/>,
86 <xref linkend="libnsl"/>,
87 <xref linkend="libxml2"/>,
88 <xref linkend="mitkrb"/>,
89 <xref linkend="openldap"/> (client only), and
90 <xref linkend="cyrus-sasl"/>
91 </para>
92
93 <para condition="html" role="usernotes">User Notes:
94 <ulink url="&blfs-wiki;/autofs"/></para>
95
96 </sect2>
97
98 <sect2 role="kernel" id="autofs-kernel">
99 <title>Kernel Configuration</title>
100
101 <indexterm zone="autofs autofs-kernel">
102 <primary sortas="d-Automounter">Automounter</primary>
103 </indexterm>
104
105 <para>
106 Verify that automounter kernel support has been enabled:
107 </para>
108
109<screen><literal>File systems ---&gt;
110 &lt;*/M&gt; Kernel automounter support (supports v3, v4, and v5) [CONFIG_AUTOFS_FS]</literal></screen>
111
112 <para>
113 Optionally, enable the following options in the kernel configuration:
114 </para>
115
116<screen><literal>File systems ---&gt;
117 [*] Network File Systems ---&gt; [CONFIG_NETWORK_FILESYSTEMS]
118 &lt;*/M&gt; NFS client support [CONFIG_NFS_FS]
119 &lt;*/M&gt; SMB3 and CIFS support (advanced network filesystem) [CONFIG_CIFS]</literal></screen>
120
121 <para>
122 Recompile and install the new kernel, if necessary.
123 </para>
124
125 </sect2>
126
127 <sect2 role="installation">
128
129 <title>Installation of Autofs</title>
130
131 <para>
132 Install <application>Autofs</application> by running the following
133 commands:
134 </para>
135
136<screen revision="sysv"><userinput>./configure --prefix=/ \
137 --with-libtirpc \
138 --without-openldap \
139 --mandir=/usr/share/man &amp;&amp;
140make</userinput></screen>
141
142<screen revision="systemd"><userinput>./configure --prefix=/ \
143 --with-libtirpc \
144 --with-systemd \
145 --without-openldap \
146 --mandir=/usr/share/man &amp;&amp;
147make</userinput></screen>
148
149 <para>
150 This package does not come with a test suite.
151 </para>
152
153 <para>
154 Now, as the <systemitem class="username">root</systemitem> user:
155 </para>
156
157<screen role="root"><userinput>make install</userinput></screen>
158
159<!-- As of version 5.1.5, the configuration files are not installed anymore -->
160 <caution>
161 <para>
162 If <application>autofs</application> is already installed on your
163 system, be sure to backup your configuration files. They'll be
164 overwritten by the following command.
165 </para>
166 </caution>
167
168 <para>
169 Install the default configuration files, still as the
170 <systemitem class="username">root</systemitem> user:
171 </para>
172
173<screen role="root"><userinput>make install_samples</userinput></screen>
174
175 </sect2>
176
177 <sect2 role="commands">
178 <title>Command Explanations</title>
179
180 <para>
181 <parameter>--with-libtirpc</parameter>: This switch forces the package to
182 use libtirpc for RPC functionality instead of relying on implementation
183 from Glibc, which was removed in LFS 8.1.
184 </para>
185
186 <para revision="systemd">
187 <parameter>--with-systemd</parameter>: This switch enables installation
188 of the bundled systemd units.
189 </para>
190
191 <para>
192 <parameter>--without-openldap</parameter>: This switch disables openldap
193 if found. If openldap is desired, omit this switch. Note that openldap
194 support in autofs requires <xref linkend="mitkrb"/>.
195 </para>
196
197 </sect2>
198
199 <sect2 role="configuration">
200 <title>Configuring Autofs</title>
201
202 <sect3 id="autofs-config">
203 <title>Config Files</title>
204
205 <para>
206 <filename>/etc/sysconfig/autofs.conf</filename>,
207 <filename>/etc/auto.master</filename>,
208 <filename>/etc/auto.misc</filename>, and
209 <filename>/etc/auto.net</filename>
210 </para>
211
212 <indexterm zone="autofs autofs-config" >
213 <primary sortas="e-etc-sysconfig-autofs.conf">/etc/sysconfig/autofs.conf</primary>
214 </indexterm>
215
216 <indexterm zone="autofs autofs-config">
217 <primary sortas="e-etc-auto.master">/etc/auto.master</primary>
218 </indexterm>
219
220 <indexterm zone="autofs autofs-config">
221 <primary sortas="e-etc-auto.misc">/etc/auto.misc</primary>
222 </indexterm>
223
224 <indexterm zone="autofs autofs-config">
225 <primary sortas="e-etc-auto.net">/etc/auto.net</primary>
226 </indexterm>
227
228 </sect3>
229
230 <sect3>
231 <title>Configuration Information</title>
232
233 <para>
234 The installation process creates <filename>auto.master</filename>,
235 <filename>auto.misc</filename>, <filename>auto.smb</filename>, and
236 <filename>auto.net</filename>. Replace the
237 <filename>auto.master</filename> file with the following commands
238 as the <systemitem class="username">root</systemitem> user:
239 </para>
240
241<screen role="root"><userinput>mv /etc/auto.master /etc/auto.master.bak &amp;&amp;
242cat &gt; /etc/auto.master &lt;&lt; "EOF"
243<literal># Begin /etc/auto.master
244
245/media/auto /etc/auto.misc --ghost
246#/home /etc/auto.home
247
248# End /etc/auto.master</literal>
249EOF</userinput></screen>
250
251 <para>
252 This file creates a new media directory,
253 <filename>/media/auto</filename> that will overlay any existing
254 directory of the same name. In this example, the file,
255 <filename>/etc/auto.misc</filename>, has a line:
256 </para>
257
258<screen>cd -fstype=iso9660,ro,nosuid,nodev :/dev/cdrom</screen>
259
260 <para>
261 that will mount a cdrom as <filename>/media/auto/cd</filename> if
262 that directory is accessed. The <option>--ghost</option> option tells
263 the automounter to create <quote>ghost</quote> versions (i.e. empty
264 directories) of all the mount points listed in the configuration file
265 regardless whether any of the file systems are actually mounted or not.
266 This is very convenient and highly recommended, because it will show
267 you the available auto-mountable file systems as existing directories,
268 even when their file systems aren't currently mounted. Without the
269 <option>--ghost</option> option, you'll have to remember the names of
270 the directories. As soon as you try to access one of them, the
271 directory will be created and the file system will be mounted. When
272 the file system gets unmounted again, the directory is destroyed too,
273 unless the <option>--ghost</option> option was given.
274 </para>
275
276 <note>
277 <para>
278 An alternative method would be to specify another automount
279 location such as <filename
280 class='directory'>/var/lib/auto/cdrom</filename> and create a
281 symbolic link from <filename
282 class='directory'>/media/cdrom</filename> to the automount location.
283 </para>
284 </note>
285
286 <para>
287 The <filename>auto.misc</filename> file must be configured to your
288 working hardware. The loaded configuration file should load your cdrom
289 if <filename>/dev/cdrom</filename> is active or it can be edited to
290 match your device setup. Examples for floppies are available in the
291 file and easily activated. Documentation for this file is available
292 using the <command>man 5 autofs</command> command.
293 </para>
294
295 <para>
296 In the second line, if enabled, a user's home directory would be
297 mounted via NFS upon login. The <filename>/etc/home.auto</filename>
298 would need to exist and have an entry similar to:
299 </para>
300
301<screen>joe example.org:/export/home/joe</screen>
302
303 <para>
304 where the directory <filename>/export/home/joe</filename> is
305 exported via NFS from the system example.org. NFS shares
306 are covered on the next page.
307 </para>
308
309 <para>
310 This package could also be used to mount SMB shares, however that
311 feature is not configured in these instructions. For additional
312 configuration information, see the man pages for auto.master(5). There
313 are also web resources such as this <ulink
314 url='http://wiki.gentoo.org/wiki/AutoFS'>AUTOFS
315 HOWTO</ulink> available.
316 </para>
317
318 </sect3>
319
320 <sect3 id="autofs-init">
321 <title><phrase revision="sysv">Boot Script</phrase>
322 <phrase revision="systemd">Systemd Unit</phrase></title>
323
324 <para revision="sysv">
325 <application>autofs</application> installs its own
326 boot script, but it has no capability for logging or visual conformance
327 with other BLFS scripts.
328 </para>
329
330 <para revision="sysv">
331 Install the <filename>/etc/init.d/autofs</filename>
332 mount script included with the <xref linkend="bootscripts"/>
333 package.
334 </para>
335
336 <para revision="systemd">
337 To start <application>Autofs</application> at boot, enable the
338 previously installed systemd unit by running the following command as
339 the <systemitem class="username">root</systemitem> user:
340 </para>
341
342 <indexterm zone="autofs autofs-init">
343 <primary sortas="f-autofs-init">autofs</primary>
344 </indexterm>
345
346<screen role="root" revision="sysv"><userinput>make install-autofs</userinput></screen>
347
348<screen role="root" revision="systemd"><userinput>systemctl enable autofs</userinput></screen>
349
350 <para revision="sysv">
351 The time-out variable is set in
352 <filename>/etc/sysconfig/autofs.conf</filename>. The installed file sets
353 a default of 60 seconds of inactivity before unmounting the device. A
354 much shorter time may be necessary to protect buffer writing to a floppy
355 if users tend to remove the media prior to the timeout setting.
356 </para>
357
358 <note revision="systemd">
359 <para>
360 You can also specify <envar>OPTIONS</envar> variable in the
361 <filename>/etc/sysconfig/autofs</filename> file with any additional
362 parameters that you might want to pass to the automount daemon.
363 </para>
364 </note>
365
366 </sect3>
367
368 </sect2>
369
370 <sect2 role="content">
371 <title>Contents</title>
372
373 <segmentedlist>
374 <segtitle>Installed Program</segtitle>
375 <segtitle>Installed Libraries</segtitle>
376 <segtitle>Installed Directories</segtitle>
377
378 <seglistitem>
379 <seg>automount</seg>
380 <seg>
381 lookup_dir.so, lookup_file.so, lookup_files.so, lookup_hosts.so,
382 lookup_ldap.so, lookup_multi.so, lookup_nis.so, lookup_nisplus.so,
383 lookup_program.so, lookup_userhome.so, lookup_yp.so, mount_afs.so,
384 mount_autofs.so, mount_bind.so, mount_changer.so, mount_ext2.so,
385 mount_ext3.so, mount_ext4.so, mount_generic.so, mount_nfs.so,
386 mount_nfs4.so, parse_amd.so, and parse_sun.so
387 </seg>
388 <seg>/lib/autofs</seg>
389 </seglistitem>
390 </segmentedlist>
391
392 <variablelist>
393 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
394 <?dbfo list-presentation="list"?>
395 <?dbhtml list-presentation="table"?>
396
397 <varlistentry id="automount">
398 <term><command>automount</command></term>
399 <listitem>
400 <para>
401 is the daemon that performs the mounting when a request is
402 made for the device.
403 </para>
404 <indexterm zone="autofs automount">
405 <primary sortas="b-automount">automount</primary>
406 </indexterm>
407 </listitem>
408 </varlistentry>
409
410 </variablelist>
411
412 </sect2>
413
414</sect1>
Note: See TracBrowser for help on using the repository browser.