fill in the idmap_tdb man page
[import/samba-docs-svnimport.git] / manpages-3 / smbmount.8.xml
1 <?xml version="1.0" encoding="iso-8859-1"?>
2 <!DOCTYPE refentry PUBLIC "-//Samba-Team//DTD DocBook V4.2-Based Variant V1.0//EN" "http://www.samba.org/samba/DTD/samba-doc">
3 <refentry id="smbmount.8">
4
5 <refmeta>
6         <refentrytitle>smbmount</refentrytitle>
7         <manvolnum>8</manvolnum>
8 </refmeta>
9
10
11 <refnamediv>
12         <refname>smbmount</refname>
13         <refpurpose>mount an smbfs filesystem</refpurpose>
14 </refnamediv>
15
16 <refsynopsisdiv>
17         <cmdsynopsis>
18                 <command>smbmount</command>
19                 <arg choice="req">service</arg>
20                 <arg choice="req">mount-point</arg>
21                 <arg choice="opt">-o options</arg>
22         </cmdsynopsis>
23 </refsynopsisdiv>
24
25 <refsect1>
26         <title>DESCRIPTION</title>
27
28         <para><command>smbmount</command> mounts a Linux SMB filesystem. It 
29         is usually invoked as <command>mount.smbfs</command> by
30         the <citerefentry><refentrytitle>mount</refentrytitle>
31         <manvolnum>8</manvolnum></citerefentry> command when using the 
32         "-t smbfs" option. This command only works in Linux, and the kernel must
33         support the smbfs filesystem. </para>
34
35         <para>Options to <command>smbmount</command> are specified as a comma-separated
36         list of key=value pairs. It is possible to send options other
37         than those listed here, assuming that smbfs supports them. If
38         you get mount failures, check your kernel log for errors on
39         unknown options.</para>
40
41         <para><command>smbmount</command> is a daemon. After mounting it keeps running until
42         the mounted smbfs is umounted. It will log things that happen
43         when in daemon mode using the "machine name" smbmount, so
44         typically this output will end up in <filename>log.smbmount</filename>. The <command>
45         smbmount</command> process may also be called mount.smbfs.</para>
46
47         <note><para> <command>smbmount</command> 
48         calls <citerefentry><refentrytitle>smbmnt</refentrytitle>
49         <manvolnum>8</manvolnum></citerefentry> to do the actual mount. You 
50         must make sure that <command>smbmnt</command> is in the path so 
51         that it can be found. </para></note>
52         
53 </refsect1>
54
55 <refsect1>
56         <title>OPTIONS</title>
57
58         <variablelist>
59                 <varlistentry>
60                 <term>username=&lt;arg&gt;</term>
61                 <listitem><para>
62                 specifies the username to connect as. If this is not given, then the environment variable <envar> USER</envar>
63                 is used. This option can also take the form "user%password" or "user/workgroup" or "user/workgroup%password"
64                 to allow the password and workgroup to be specified as part of the username.
65                 </para></listitem>
66                 </varlistentry>
67
68                 <varlistentry>
69                 <term>password=&lt;arg&gt;</term>
70                 <listitem><para>
71                 specifies the SMB password. If this option is not given then the environment 
72                 variable <literal>PASSWD</literal> is used. If it can find no password 
73                 <command>smbmount</command> will prompt for a password, unless the guest option is given.
74                 </para>
75
76                 <para>
77                 Note that passwords which contain the argument delimiter character (i.e. a comma ',') will failed to be parsed
78                 correctly on the command line.  However, the same password defined in the PASSWD environment variable or a
79                 credentials file (see below) will be read correctly.
80                 </para>
81                 </listitem>
82                 </varlistentry>
83
84                 <varlistentry>
85                 <term>credentials=&lt;filename&gt;</term>
86                 <listitem><para>specifies a file that contains a username and/or password. 
87 The format of the file is:
88 <programlisting>
89 username = &lt;value&gt;
90 password = &lt;value&gt;
91 </programlisting></para>
92
93                 <para>This is preferred over having passwords in plaintext in a
94                 shared file, such as <filename>/etc/fstab</filename>. Be sure to protect any
95                 credentials file properly.
96                 </para></listitem>
97                 </varlistentry>
98
99                 <varlistentry>
100                 <term>krb</term>
101                 <listitem><para>Use kerberos (Active Directory). </para></listitem>
102                 </varlistentry>
103
104                 <varlistentry>
105                 <term>netbiosname=&lt;arg&gt;</term>
106                 <listitem><para>sets the source NetBIOS name. It defaults 
107                 to the local hostname. </para></listitem>
108                 </varlistentry>
109
110                 <varlistentry>
111                 <term>uid=&lt;arg&gt;</term>
112                 <listitem><para>sets the uid that will own all files on
113                 the mounted filesystem.
114                 It may be specified as either a username or a numeric uid.
115                 </para></listitem>
116                 </varlistentry>
117                 
118                 
119                 <varlistentry>
120                 <term>gid=&lt;arg&gt;</term>
121                 <listitem><para>sets the gid that will own all files on
122                 the mounted filesystem.
123                 It may be specified as either a groupname or a numeric 
124                 gid. </para></listitem>         
125                 </varlistentry>
126                 
127                 
128                 <varlistentry>
129                 <term>port=&lt;arg&gt;</term>
130                 <listitem><para>sets the remote SMB port number. The default 
131                 is 445, fallback is 139. </para></listitem>
132                 </varlistentry>
133                 
134                 
135                 <varlistentry>
136                 <term>fmask=&lt;arg&gt;</term>
137                 <listitem><para>sets the file mask. This determines the 
138                 permissions that remote files have in the local filesystem. 
139                 This is not a umask, but the actual permissions for the files.
140                 The default is based on the current umask. </para></listitem>
141                 </varlistentry>
142                 
143
144                 <varlistentry>
145                 <term>dmask=&lt;arg&gt;</term>
146                 <listitem><para>Sets the directory mask. This determines the 
147                 permissions that remote directories have in the local filesystem. 
148                 This is not a umask, but the actual permissions for the directories.
149                 The default is based on the current umask. </para></listitem>
150                 </varlistentry>
151                 
152                 
153                 <varlistentry>
154                 <term>debug=&lt;arg&gt;</term>
155                 <listitem><para>Sets the debug level. This is useful for 
156                 tracking down SMB connection problems. A suggested value to
157                 start with is 4. If set too high there will be a lot of
158                 output, possibly hiding the useful output.</para></listitem>
159                 </varlistentry>
160                 
161                 
162                 <varlistentry>
163                 <term>ip=&lt;arg&gt;</term>
164                 <listitem><para>Sets the destination host or IP address.
165                 </para></listitem>
166                 </varlistentry>
167
168
169
170                 <varlistentry>
171                 <term>workgroup=&lt;arg&gt;</term>
172                 <listitem><para>Sets the workgroup on the destination </para>
173                 </listitem>
174                 </varlistentry>
175
176
177                 <varlistentry>
178                 <term>sockopt=&lt;arg&gt;</term>
179                 <listitem><para>Sets the TCP socket options. See the <ulink
180                 url="smb.conf.5.html#SOCKETOPTIONS"><citerefentry><refentrytitle>smb.conf</refentrytitle>
181                 <manvolnum>5</manvolnum></citerefentry></ulink> <parameter>socket options</parameter> option.
182                 </para></listitem>
183                 </varlistentry>
184
185
186                 <varlistentry>
187                 <term>scope=&lt;arg&gt;</term>
188                 <listitem><para>Sets the NetBIOS scope </para></listitem>
189                 </varlistentry>
190
191                 <varlistentry>
192                 <term>guest</term>
193                 <listitem><para>Don't prompt for a password </para></listitem>
194                 </varlistentry>
195
196                 <varlistentry>
197                 <term>ro</term>
198                 <listitem><para>mount read-only </para></listitem>
199                 </varlistentry>
200
201                 <varlistentry>
202                 <term>rw</term><listitem><para>mount read-write </para></listitem>
203                 </varlistentry>
204
205                 <varlistentry>
206                 <term>iocharset=&lt;arg&gt;</term>
207                 <listitem><para>
208                 sets the charset used by the Linux side for codepage
209                 to charset translations (NLS). Argument should be the
210                 name of a charset, like iso8859-1. (Note: only kernel
211                 2.4.0 or later)
212                 </para></listitem>
213                 </varlistentry>
214
215                 <varlistentry>
216                 <term>codepage=&lt;arg&gt;</term>
217                 <listitem><para>
218                 sets the codepage the server uses. See the iocharset
219                 option. Example value cp850. (Note: only kernel 2.4.0
220                 or later)
221                 </para></listitem>
222                 </varlistentry>
223
224                 <varlistentry>
225                 <term>ttl=&lt;arg&gt;</term>
226                 <listitem><para>
227                 sets how long a directory listing is cached in milliseconds
228                 (also affects visibility of file size and date
229                 changes). A higher value means that changes on the
230                 server take longer to be noticed but it can give
231                 better performance on large directories, especially
232                 over long distances. Default is 1000ms but something
233                 like 10000ms (10 seconds) is probably more reasonable
234                 in many cases.
235                 (Note: only kernel 2.4.2 or later)
236                 </para></listitem>
237                 </varlistentry>
238
239         </variablelist>
240
241
242 </refsect1>
243
244 <refsect1>
245         <title>ENVIRONMENT VARIABLES</title>
246
247         <para>The variable <envar>USER</envar> may contain the username of the
248         person using the client.  This information is used only if the
249         protocol level is high enough to support session-level
250         passwords. The variable can be used to set both username and
251         password by using the format username%password.</para>
252
253         <para>The variable <envar>PASSWD</envar> may contain the password of the
254         person using the client.  This information is used only if the
255         protocol level is high enough to support session-level
256         passwords.</para>
257
258         <para>The variable <envar>PASSWD_FILE</envar> may contain the pathname
259         of a file to read the password from. A single line of input is
260         read and used as the password.</para>
261 </refsect1>
262
263 <refsect1>
264         <title>OTHER COMMANDS</title>
265
266         <para>
267         File systems that have been mounted using the <command>smbmount</command>
268         can be unmounted using the <command>smbumount</command> or the UNIX system
269         <command>umount</command> command.
270         </para>
271
272 </refsect1>
273
274
275 <refsect1>
276         <title>BUGS</title>
277
278         <para>Passwords and other options containing , can not be handled.
279         For passwords an alternative way of passing them is in a credentials
280         file or in the PASSWD environment.</para>
281
282         <para>The credentials file does not handle usernames or passwords with
283         leading space.</para>
284
285         <para>One smbfs bug is important enough to mention here, even if it
286         is a bit misplaced:</para>
287
288         <itemizedlist>
289
290         <listitem><para>Mounts sometimes stop working. This is usually
291         caused by smbmount terminating. Since smbfs needs smbmount to
292         reconnect when the server disconnects, the mount will eventually go
293         dead. An umount/mount normally fixes this. At least 2 ways to
294         trigger this bug are known.</para></listitem>
295
296         </itemizedlist>
297
298         <para>Note that the typical response to a bug report is suggestion
299         to try the latest version first. So please try doing that first,
300         and always include which versions you use of relevant software
301         when reporting bugs (minimum: samba, kernel, distribution)</para>
302
303 </refsect1>
304
305
306 <refsect1>
307         <title>SEE ALSO</title>
308
309         <para>Documentation/filesystems/smbfs.txt in the linux kernel
310         source tree may contain additional options and information.</para>
311
312         <para>FreeBSD also has a smbfs, but it is not related to smbmount</para>
313
314         <para>For Solaris, HP-UX and others you may want to look at <citerefentry><refentrytitle>smbsh</refentrytitle>
315         <manvolnum>1</manvolnum></citerefentry> or at other solutions, such as 
316         Sharity or perhaps replacing the SMB server with a NFS server.</para>
317
318 </refsect1>
319
320
321 <refsect1>
322         <title>AUTHOR</title>
323         
324         <para>Volker Lendecke, Andrew Tridgell, Michael H. Warfield 
325         and others.</para>
326         
327         <para>The current maintainer of smbfs and the userspace
328         tools <command>smbmount</command>, <command>smbumount</command>,
329         and <command>smbmnt</command> is <ulink 
330         url="mailto:urban@teststation.com">Urban Widmark</ulink>.
331         The <ulink url="mailto:samba@samba.org">SAMBA Mailing list</ulink>
332         is the preferred place to ask questions regarding these programs.
333         </para>
334         
335         <para>The conversion of this manpage for Samba 2.2 was performed 
336         by Gerald Carter. The conversion to DocBook XML 4.2 for Samba 3.0
337         was done by Alexander Bokovoy.</para>
338 </refsect1>
339
340 </refentry>