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 | <!-- Inserted as a reminder to do this. The mention of a test suite
|
---|
8 | is usually right before the root user installation commands. Please
|
---|
9 | delete these 12 (including one blank) lines after you are done.-->
|
---|
10 |
|
---|
11 | <!-- Use one of the two mentions below about a test suite,
|
---|
12 | delete the line that is not applicable. Of course, if the
|
---|
13 | test suite uses syntax other than "make check", revise the
|
---|
14 | line to reflect the actual syntax to run the test suite -->
|
---|
15 |
|
---|
16 | <!-- <para>This package does not come with a test suite.</para> -->
|
---|
17 | <!-- <para>To test the results, issue: <command>make check</command>.</para> -->
|
---|
18 |
|
---|
19 | <!ENTITY autofs-patch-dir "http://ftp.kernel.org/pub/linux/daemons/autofs/v4/">
|
---|
20 | <!ENTITY autofs-download-http "http://ftp.kernel.org/pub/linux/daemons/autofs/v4/autofs-&autofs-version;.tar.bz2">
|
---|
21 | <!ENTITY autofs-download-ftp "ftp://ftp.kernel.org/pub/linux/daemons/autofs/v4/autofs-&autofs-version;.tar.bz2">
|
---|
22 | <!ENTITY autofs-md5sum "7e3949114c00665b4636f0c318179657">
|
---|
23 | <!ENTITY autofs-size "168 KB">
|
---|
24 | <!ENTITY autofs-buildsize "2.3 MB">
|
---|
25 | <!ENTITY autofs-time "less than 0.1 SBU">
|
---|
26 | ]>
|
---|
27 |
|
---|
28 | <sect1 id="autofs" xreflabel="autofs-&autofs-version;">
|
---|
29 | <?dbhtml filename="autofs.html"?>
|
---|
30 |
|
---|
31 | <sect1info>
|
---|
32 | <othername>$LastChangedBy$</othername>
|
---|
33 | <date>$Date$</date>
|
---|
34 | </sect1info>
|
---|
35 |
|
---|
36 | <title>Automate Mounting of File Systems</title>
|
---|
37 |
|
---|
38 | <indexterm zone="autofs">
|
---|
39 | <primary sortas="a-Autofs">Autofs</primary>
|
---|
40 | </indexterm>
|
---|
41 |
|
---|
42 | <sect2 role="package">
|
---|
43 | <title>Introduction to Autofs</title>
|
---|
44 |
|
---|
45 | <para>The <application>autofs</application> package contains userspace
|
---|
46 | tools that work with the kernel to mount and un-mount removable file
|
---|
47 | systems. This is useful for allowing users to mount floppies, cdroms and
|
---|
48 | other removable storage devices without requiring the system
|
---|
49 | administrator to mount the devices. This may not be ideal for all
|
---|
50 | installations, so be aware of the risks before implementing this feature.</para>
|
---|
51 |
|
---|
52 | <bridgehead renderas="sect3">Package Information</bridgehead>
|
---|
53 | <itemizedlist spacing="compact">
|
---|
54 | <listitem>
|
---|
55 | <para>Download (HTTP): <ulink url="&autofs-download-http;"/></para>
|
---|
56 | </listitem>
|
---|
57 | <listitem>
|
---|
58 | <para>Download (FTP): <ulink url="&autofs-download-ftp;"/></para>
|
---|
59 | </listitem>
|
---|
60 | <listitem>
|
---|
61 | <para>Download MD5 sum: &autofs-md5sum;</para>
|
---|
62 | </listitem>
|
---|
63 | <listitem>
|
---|
64 | <para>Download size: &autofs-size;</para>
|
---|
65 | </listitem>
|
---|
66 | <listitem>
|
---|
67 | <para>Estimated disk space required: &autofs-buildsize;</para>
|
---|
68 | </listitem>
|
---|
69 | <listitem>
|
---|
70 | <para>Estimated build time: &autofs-time;</para>
|
---|
71 | </listitem>
|
---|
72 | </itemizedlist>
|
---|
73 |
|
---|
74 | <bridgehead renderas="sect3">Additional Downloads</bridgehead>
|
---|
75 | <itemizedlist spacing="compact">
|
---|
76 | <listitem>
|
---|
77 | <para>Recommended Patch: <ulink
|
---|
78 | url="&patch-root;/autofs-&autofs-version;-consolidated-1.patch"/></para>
|
---|
79 | </listitem>
|
---|
80 | </itemizedlist>
|
---|
81 |
|
---|
82 | <para condition="html" role="usernotes">User Notes:
|
---|
83 | <ulink url="&blfs-wiki;/autofs"/></para>
|
---|
84 |
|
---|
85 | </sect2>
|
---|
86 |
|
---|
87 | <sect2 role="kernel" id="autofs-kernel">
|
---|
88 | <title>Kernel Configuration</title>
|
---|
89 |
|
---|
90 | <indexterm zone="autofs autofs-kernel">
|
---|
91 | <primary sortas="d-Automounter">Automounter</primary>
|
---|
92 | </indexterm>
|
---|
93 |
|
---|
94 | <para>Verify that kernel support has been compiled in or built as
|
---|
95 | modules in the following areas:</para>
|
---|
96 |
|
---|
97 | <screen><literal>File systems ⇒
|
---|
98 | Kernel automounter version 4 support Y or M
|
---|
99 | Network File Systems ⇒
|
---|
100 | NFS file system support Y or M (optional)
|
---|
101 | SMB file system support Y or M (optional)</literal></screen>
|
---|
102 |
|
---|
103 | <para>Recompile and install the new kernel, if necessary.</para>
|
---|
104 |
|
---|
105 | </sect2>
|
---|
106 |
|
---|
107 | <sect2 role="installation">
|
---|
108 |
|
---|
109 | <title>Installation of Autofs</title>
|
---|
110 |
|
---|
111 | <para>Install <application>autofs</application> by running the following
|
---|
112 | commands:</para>
|
---|
113 |
|
---|
114 | <screen><userinput>patch -Np1 -i ../autofs-&autofs-version;-consolidated-1.patch &&
|
---|
115 | ./configure --prefix=/ --mandir=/usr/share/man &&
|
---|
116 | make</userinput></screen>
|
---|
117 |
|
---|
118 | <para>Now, as the <systemitem class="username">root</systemitem> user:</para>
|
---|
119 |
|
---|
120 | <screen role="root"><userinput>make install &&
|
---|
121 | rm /etc/rc.d/init.d/autofs</userinput></screen>
|
---|
122 |
|
---|
123 | </sect2>
|
---|
124 |
|
---|
125 | <sect2 role="commands">
|
---|
126 | <title>Command Explanations</title>
|
---|
127 |
|
---|
128 | <para><command>patch -Np1 -i
|
---|
129 | ../autofs-&autofs-version;-consolidated-1.patch</command>: This patch
|
---|
130 | is a consolidation of nine small patches available at <ulink
|
---|
131 | url="http://ftp.kernel.org/pub/linux/daemons/autofs/v4/"/>. The patches
|
---|
132 | can be applied individually if desired.</para>
|
---|
133 |
|
---|
134 | <para><command>rm /etc/rc.d/init.d/autofs</command>: This command removes
|
---|
135 | the installed script which only works on specific distributions.</para>
|
---|
136 |
|
---|
137 | </sect2>
|
---|
138 |
|
---|
139 | <sect2 role="configuration">
|
---|
140 | <title>Configuring Autofs</title>
|
---|
141 |
|
---|
142 | <sect3 id="autofs-config">
|
---|
143 | <title>Config Files</title>
|
---|
144 |
|
---|
145 | <para><filename>/etc/sysconfig/autofs.conf</filename>,
|
---|
146 | <filename>/etc/auto.master</filename>,
|
---|
147 | <filename>/etc/auto.misc</filename>, and
|
---|
148 | <filename>/etc/auto.net</filename></para>
|
---|
149 |
|
---|
150 | <indexterm zone="autofs autofs-config" >
|
---|
151 | <primary sortas="e-etc-sysconfig-autofs.conf">/etc/sysconfig/autofs.conf</primary>
|
---|
152 | </indexterm>
|
---|
153 |
|
---|
154 | <indexterm zone="autofs autofs-config">
|
---|
155 | <primary sortas="e-etc-auto.master">/etc/auto.master</primary>
|
---|
156 | </indexterm>
|
---|
157 |
|
---|
158 | <indexterm zone="autofs autofs-config">
|
---|
159 | <primary sortas="e-etc-auto.misc">/etc/auto.misc</primary>
|
---|
160 | </indexterm>
|
---|
161 |
|
---|
162 | <indexterm zone="autofs autofs-config">
|
---|
163 | <primary sortas="e-etc-auto.net">/etc/auto.net</primary>
|
---|
164 | </indexterm>
|
---|
165 |
|
---|
166 | </sect3>
|
---|
167 |
|
---|
168 | <sect3>
|
---|
169 | <title>Configuration Information</title>
|
---|
170 |
|
---|
171 | <para>The installation process creates <filename>auto.master</filename>,
|
---|
172 | <filename>auto.misc</filename> and <filename>auto.net</filename>. You
|
---|
173 | will replace the <filename>auto.master</filename> with the following
|
---|
174 | commands:</para>
|
---|
175 |
|
---|
176 | <screen role="root"><userinput>mv /etc/auto.master /etc/auto.master.bak &&
|
---|
177 | cat > /etc/auto.master << "EOF"
|
---|
178 | <literal># Begin /etc/auto.master
|
---|
179 |
|
---|
180 | /media /etc/auto.misc
|
---|
181 |
|
---|
182 | # End /etc/auto.master</literal>
|
---|
183 | EOF</userinput></screen>
|
---|
184 |
|
---|
185 | <note>
|
---|
186 | <para>This file mounts a new media directory over the one created by
|
---|
187 | LFS and will therefore hide any mounts made by the
|
---|
188 | <filename>fstab</filename> file into that directory.</para>
|
---|
189 | </note>
|
---|
190 |
|
---|
191 | <para>While this package could be used to mount NFS shares and SMB
|
---|
192 | shares, that feature is not configured in these instructions. NFS shares
|
---|
193 | are covered on the next page.</para>
|
---|
194 |
|
---|
195 | <para>The <filename>auto.misc</filename> must be configured to your
|
---|
196 | working hardware. The loaded configuration file should load your cdrom
|
---|
197 | if <filename>/dev/cdrom</filename> is active or it can be edited to
|
---|
198 | match your device setup and examples for floppies are available in the file
|
---|
199 | and easily activated. Documentation for this file is available using the
|
---|
200 | <command>man 5 autofs</command> command.</para>
|
---|
201 |
|
---|
202 | </sect3>
|
---|
203 |
|
---|
204 | <sect3 id="autofs-init">
|
---|
205 | <title>Boot Script</title>
|
---|
206 |
|
---|
207 |
|
---|
208 | <para>Install the <filename>/etc/rc.d/init.d/autofs</filename> mount script
|
---|
209 | and <filename>/etc/sysconfig/autofs.conf</filename> support file included
|
---|
210 | with the <xref linkend="bootscripts"/> package.</para>
|
---|
211 |
|
---|
212 | <indexterm zone="autofs autofs-init">
|
---|
213 | <primary sortas="f-autofs-init">autofs</primary>
|
---|
214 | </indexterm>
|
---|
215 |
|
---|
216 | <screen role="root"><userinput>make install-autofs</userinput></screen>
|
---|
217 |
|
---|
218 | <para>The time-out variable is set in
|
---|
219 | <filename>/etc/sysconfig/autofs.conf</filename>. The installed file sets
|
---|
220 | a default of 60 seconds of inactivity before unmounting the device. A
|
---|
221 | much shorter time may be necessary to protect buffer writing to a floppy
|
---|
222 | if users tend to remove the media prior to the timeout setting.</para>
|
---|
223 |
|
---|
224 | </sect3>
|
---|
225 |
|
---|
226 | </sect2>
|
---|
227 |
|
---|
228 | <sect2 role="content">
|
---|
229 | <title>Contents</title>
|
---|
230 |
|
---|
231 | <segmentedlist>
|
---|
232 | <segtitle>Installed Program</segtitle>
|
---|
233 | <segtitle>Installed Libraries</segtitle>
|
---|
234 | <segtitle>Installed Directories</segtitle>
|
---|
235 |
|
---|
236 | <seglistitem>
|
---|
237 | <seg>automount</seg>
|
---|
238 | <seg>autofs modules</seg>
|
---|
239 | <seg>/lib/autofs and /var/run/autofs</seg>
|
---|
240 | </seglistitem>
|
---|
241 | </segmentedlist>
|
---|
242 |
|
---|
243 | <variablelist>
|
---|
244 | <bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
---|
245 | <?dbfo list-presentation="list"?>
|
---|
246 | <?dbhtml list-presentation="table"?>
|
---|
247 |
|
---|
248 | <varlistentry id="automount">
|
---|
249 | <term><command>automount</command></term>
|
---|
250 | <listitem>
|
---|
251 | <para>is the daemon that performs the mounting when a request is
|
---|
252 | made for the device.</para>
|
---|
253 | <indexterm zone="autofs automount">
|
---|
254 | <primary sortas="b-automount">automount</primary>
|
---|
255 | </indexterm>
|
---|
256 | </listitem>
|
---|
257 | </varlistentry>
|
---|
258 |
|
---|
259 | </variablelist>
|
---|
260 |
|
---|
261 | </sect2>
|
---|
262 |
|
---|
263 | </sect1>
|
---|
264 |
|
---|