]> arthur.barton.de Git - netatalk.git/blob - doc/manpages/man5/afp.conf.5.xml
Add Docbook documentation to tree
[netatalk.git] / doc / manpages / man5 / afp.conf.5.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2 <refentry id="afp.conf.5">
3   <refmeta>
4     <refentrytitle>afp.conf</refentrytitle>
5
6     <manvolnum>5</manvolnum>
7
8     <refmiscinfo class="date">30 Apr 2013</refmiscinfo>
9
10     <refmiscinfo class="source">:NETATALK_VERSION:</refmiscinfo>
11   </refmeta>
12
13   <refnamediv>
14     <refname>afp.conf</refname>
15
16     <refpurpose>Netatalk configuration file <indexterm>
17         <primary>afp.conf</primary>
18       </indexterm></refpurpose>
19   </refnamediv>
20
21   <refsect1>
22     <title>SYNOPSIS</title>
23
24     <para>The <filename>afp.conf</filename> file is the configuration file for
25     the <emphasis role="bold">Netatalk</emphasis> AFP file server.</para>
26
27     <para>All AFP specific configuration and AFP volume definitions are done
28     via this file.</para>
29   </refsect1>
30
31   <refsect1 id="FILEFORMATSECT">
32     <title>FILE FORMAT</title>
33
34     <para>The file consists of sections and parameters. A section begins with
35     the name of the section in square brackets and continues until the next
36     section begins. Sections contain parameters of the form: <programlisting>
37     <replaceable>name</replaceable> = <replaceable>value </replaceable>
38     </programlisting></para>
39
40     <para>The file is line-based - that is, each newline-terminated line
41     represents either a comment, a section name or a parameter.</para>
42
43     <para>Section and parameter names are case sensitive.</para>
44
45     <para>Only the first equals sign in a parameter is significant. Whitespace
46     before or after the first equals sign is discarded. Leading, trailing and
47     internal whitespace in section and parameter names is irrelevant. Leading
48     and trailing whitespace in a parameter value is discarded. Internal
49     whitespace within a parameter value is retained verbatim.</para>
50
51     <para>Any line beginning with a semicolon (<quote>;</quote>) or a hash
52     (<quote>#</quote>) character is ignored, as are lines containing only
53     whitespace.</para>
54
55     <para>Any line ending in a <quote> <literal>\</literal> </quote> is
56     continued on the next line in the customary UNIX fashion.</para>
57
58     <para>The values following the equals sign in parameters are all either a
59     string (no quotes needed) or a boolean, which may be given as yes/no, 1/0
60     or true/false. Case is not significant in boolean values, but is preserved
61     in string values. Some items such as create masks are numeric.</para>
62
63     <para>The parameter <option>include =
64     <replaceable>path</replaceable></option> allows you to include one config
65     file inside another. The file is included literally, as though typed in
66     place. Nested includes are not supported.</para>
67   </refsect1>
68
69   <refsect1>
70     <title>SECTION DESCRIPTIONS</title>
71
72     <para>Each section in the configuration file (except for the [Global]
73     section) describes a shared resource (known as a <quote>volume</quote>).
74     The section name is the name of the volume and the parameters within the
75     section define the volume attributes and options.</para>
76
77     <para>There are two special sections, [Global] and [Homes], which are
78     described under <emphasis>special sections</emphasis>. The following notes
79     apply to ordinary section descriptions.</para>
80
81     <para>A volume consists of a directory to which access is being given plus
82     a description of the access rights which are granted to the user of the
83     service. For volumes the <option>path</option> option must specify the
84     directory to share.</para>
85
86     <para>Any volume section without <option>path</option> option is
87     considered a <emphasis>vol preset</emphasis> which can be selected in
88     other volume sections via the <option>vol preset</option> option and
89     constitutes defaults for the volume. For any option specified both in a
90     preset <emphasis>and</emphasis> in a volume section the volume section
91     setting completely substitutes the preset option.</para>
92
93     <para>The access rights granted by the server are masked by the access
94     rights granted to the specified or guest UNIX user by the host system. The
95     server does not grant more access than the host system grants.</para>
96
97     <para>The following sample section defines an AFP volume. The user has
98     full access to the path <filename>/foo/bar</filename>. The share is
99     accessed via the share name <literal>baz</literal>: <programlisting> [baz]
100     path = /foo/bar </programlisting></para>
101   </refsect1>
102
103   <refsect1>
104     <title>SPECIAL SECTIONS</title>
105
106     <refsect2>
107       <title>The [Global] section</title>
108
109       <para>Parameters in this section apply to the server as a whole.
110       Parameters denoted by a (G) below are must be set in this
111       section.</para>
112     </refsect2>
113
114     <refsect2>
115       <title>The [Homes] section</title>
116
117       <para>This section enable sharing of the UNIX server user home
118       directories. Specifying an optional <option>path</option> parameter
119       means that not the whole user home will be shared but the subdirectory
120       <option>path</option>. It is necessary to define the <option>basedir
121       regex</option> option. It should be a regex which matches the parent
122       directory of the user homes. Parameters denoted by a (H) belong to
123       volume sections. The optional parameter <option>home name</option> can
124       be used to change the AFP volume name which <emphasis>$u's
125       home</emphasis> by default. See below under VARIABLE
126       SUBSTITUTIONS.</para>
127
128       <para>The following example illustrates this. Given all user home
129       directories are stored under <filename>/home</filename>:
130       <programlisting> [Homes]
131       path = afp-data
132       basedir regex = /home</programlisting> For a user
133       <emphasis>john</emphasis> this results in an AFP home volume with a path
134       of <filename>/home/john/afp-data</filename>.</para>
135
136       <para>If <option>basedir regex</option> contains symlink, set the
137       canonicalized absolute path. When <filename>/home</filename> links to
138       <filename>/usr/home</filename>: <programlisting> [Homes]
139       basedir regex = /usr/home</programlisting></para>
140     </refsect2>
141   </refsect1>
142
143   <refsect1>
144     <title>PARAMETERS</title>
145
146     <para>Parameters define the specific attributes of sections.</para>
147
148     <para>Some parameters are specific to the [Global] section (e.g.,
149     <emphasis>log type</emphasis>). All others are permissible only in volume
150     sections. The letter <emphasis>G</emphasis> in parentheses indicates that
151     a parameter is specific to the [Global] section. The letter
152     <emphasis>V</emphasis> indicates that a parameter can be specified in a
153     volume specific section.</para>
154   </refsect1>
155
156   <refsect1>
157     <title>VARIABLE SUBSTITUTIONS</title>
158
159     <para>You can use variables in volume names. The use of variables in paths
160     is not supported for now.</para>
161
162     <orderedlist>
163       <listitem>
164         <para>if you specify an unknown variable, it will not get
165         converted.</para>
166       </listitem>
167
168       <listitem>
169         <para>if you specify a known variable, but that variable doesn't have
170         a value, it will get ignored.</para>
171       </listitem>
172     </orderedlist>
173
174     <para>The variables which can be used for substitutions are:</para>
175
176     <variablelist>
177       <varlistentry>
178         <term>$b</term>
179
180         <listitem>
181           <para>basename</para>
182         </listitem>
183       </varlistentry>
184
185       <varlistentry>
186         <term>$c</term>
187
188         <listitem>
189           <para>client's ip address</para>
190         </listitem>
191       </varlistentry>
192
193       <varlistentry>
194         <term>$d</term>
195
196         <listitem>
197           <para>volume pathname on server</para>
198         </listitem>
199       </varlistentry>
200
201       <varlistentry>
202         <term>$f</term>
203
204         <listitem>
205           <para>full name (contents of the gecos field in the passwd
206           file)</para>
207         </listitem>
208       </varlistentry>
209
210       <varlistentry>
211         <term>$g</term>
212
213         <listitem>
214           <para>group name</para>
215         </listitem>
216       </varlistentry>
217
218       <varlistentry>
219         <term>$h</term>
220
221         <listitem>
222           <para>hostname</para>
223         </listitem>
224       </varlistentry>
225
226       <varlistentry>
227         <term>$i</term>
228
229         <listitem>
230           <para>client's ip, without port</para>
231         </listitem>
232       </varlistentry>
233
234       <varlistentry>
235         <term>$s</term>
236
237         <listitem>
238           <para>server name (this can be the hostname)</para>
239         </listitem>
240       </varlistentry>
241
242       <varlistentry>
243         <term>$u</term>
244
245         <listitem>
246           <para>user name (if guest, it is the user that guest is running
247           as)</para>
248         </listitem>
249       </varlistentry>
250
251       <varlistentry>
252         <term>$v</term>
253
254         <listitem>
255           <para>volume name</para>
256         </listitem>
257       </varlistentry>
258
259       <varlistentry>
260         <term>$$</term>
261
262         <listitem>
263           <para>prints dollar sign ($)</para>
264         </listitem>
265       </varlistentry>
266     </variablelist>
267   </refsect1>
268
269   <refsect1>
270     <title>EXPLANATION OF GLOBAL PARAMETERS</title>
271
272     <refsect2>
273       <title>Authentication Options</title>
274
275       <variablelist>
276         <varlistentry>
277           <term>ad domain = <parameter>DOMAIN</parameter>
278           <type>(G)</type></term>
279
280           <listitem>
281             <para>Append @DOMAIN to username when authenticating. Useful in
282             Active Directory environments that otherwise would require the
283             user to enter the full user@domain string.</para>
284           </listitem>
285         </varlistentry>
286
287         <varlistentry>
288           <term>admin auth user = <parameter>user</parameter>
289           <type>(G)</type></term>
290
291           <listitem>
292             <para>Specifying eg "<option>admin auth user = root</option>"
293             whenever a normal user login fails, afpd will try to authenticate
294             as the specified <option>admin auth user</option>. If this
295             succeeds, a normal session is created for the original connecting
296             user. Said differently: if you know the password of <option>admin
297             auth user</option>, you can authenticate as any other user.</para>
298           </listitem>
299         </varlistentry>
300
301         <varlistentry>
302           <term>k5 keytab = <replaceable>path</replaceable>
303           <type>(G)</type></term>
304
305           <term>k5 service = <replaceable>service</replaceable>
306           <type>(G)</type></term>
307
308           <term>k5 realm = <replaceable>realm</replaceable>
309           <type>(G)</type></term>
310
311           <listitem>
312             <para>These are required if the server supports the Kerberos 5
313             authentication UAM.</para>
314           </listitem>
315         </varlistentry>
316
317         <varlistentry>
318           <term>nt domain = <parameter>DOMAIN</parameter>
319           <type>(G)</type></term>
320
321           <term>nt separator = <parameter>SEPARATOR</parameter>
322           <type>(G)</type></term>
323
324           <listitem>
325             <para>Use for eg. winbind authentication, prepends both strings
326             before the username from login and then tries to authenticate with
327             the result through the available and active UAM authentication
328             modules.</para>
329           </listitem>
330         </varlistentry>
331
332         <varlistentry>
333           <term>save password = <replaceable>BOOLEAN</replaceable> (default:
334           <emphasis>yes</emphasis>) <type>(G)</type></term>
335
336           <listitem>
337             <para>Enables or disables the ability of clients to save passwords
338             locally.</para>
339           </listitem>
340         </varlistentry>
341
342         <varlistentry>
343           <term>set password = <replaceable>BOOLEAN</replaceable> (default:
344           <emphasis>no</emphasis>) <type>(G)</type></term>
345
346           <listitem>
347             <para>Enables or disables the ability of clients to change their
348             passwords via chooser or the "connect to server" dialog.</para>
349           </listitem>
350         </varlistentry>
351
352         <varlistentry>
353           <term>uam list = <replaceable>uam list</replaceable>
354           <type>(G)</type></term>
355
356           <listitem>
357             <para>Space or comma separated list of UAMs. (The default is
358             "uams_dhx.so uams_dhx2.so").</para>
359
360             <para>The most commonly used UAMs are:</para>
361
362             <variablelist>
363               <varlistentry>
364                 <term>uams_guest.so</term>
365
366                 <listitem>
367                   <para>allows guest logins</para>
368                 </listitem>
369               </varlistentry>
370
371               <varlistentry>
372                 <term>uams_clrtxt.so</term>
373
374                 <listitem>
375                   <para>(uams_pam.so or uams_passwd.so) Allow logins with
376                   passwords transmitted in the clear. (legacy)</para>
377                 </listitem>
378               </varlistentry>
379
380               <varlistentry>
381                 <term>uams_randum.so</term>
382
383                 <listitem>
384                   <para>allows Random Number and Two-Way Random Number
385                   Exchange for authentication (requires a separate file
386                   containing the passwords, either :ETCDIR:/afppasswd file or
387                   the one specified via "<option>passwd file</option>". See
388                   <citerefentry>
389                       <refentrytitle>afppasswd</refentrytitle>
390
391                       <manvolnum>1</manvolnum>
392                     </citerefentry> for details. (legacy)</para>
393                 </listitem>
394               </varlistentry>
395
396               <varlistentry>
397                 <term>uams_dhx.so</term>
398
399                 <listitem>
400                   <para>(uams_dhx_pam.so or uams_dhx_passwd.so) Allow
401                   Diffie-Hellman eXchange (DHX) for authentication.</para>
402                 </listitem>
403               </varlistentry>
404
405               <varlistentry>
406                 <term>uams_dhx2.so</term>
407
408                 <listitem>
409                   <para>(uams_dhx2_pam.so or uams_dhx2_passwd.so) Allow
410                   Diffie-Hellman eXchange 2 (DHX2) for authentication.</para>
411                 </listitem>
412               </varlistentry>
413
414               <varlistentry>
415                 <term>uam_gss.so</term>
416
417                 <listitem>
418                   <para>Allow Kerberos V for authentication (optional)</para>
419                 </listitem>
420               </varlistentry>
421             </variablelist>
422           </listitem>
423         </varlistentry>
424
425         <varlistentry>
426           <term>uam path = <replaceable>path</replaceable>
427           <type>(G)</type></term>
428
429           <listitem>
430             <para>Sets the default path for UAMs for this server (default is
431             :LIBDIR:/netatalk).</para>
432           </listitem>
433         </varlistentry>
434       </variablelist>
435     </refsect2>
436
437     <refsect2>
438       <title>Charset Options</title>
439
440       <para>With OS X Apple introduced the AFP3 protocol. One of the big
441       changes was, that AFP3 uses Unicode names encoded as Decomposed UTF-8
442       (UTF8-MAC). Previous AFP/OS versions used charsets like MacRoman,
443       MacCentralEurope, etc.</para>
444
445       <para>To be able to serve AFP3 and older clients at the same time,
446       <command>afpd</command> needs to be able to convert between UTF-8 and
447       Mac charsets. Even OS X clients partly still rely on the mac charset. As
448       there's no way, <command>afpd</command> can detect the codepage a pre
449       AFP3 client uses, you have to specify it using the <option>mac
450       charset</option> option. The default is MacRoman, which should be fine
451       for most western users.</para>
452
453       <para>As <command>afpd</command> needs to interact with UNIX operating
454       system as well, it need's to be able to convert from UTF8-MAC / Mac
455       charset to the UNIX charset. By default <command>afpd</command> uses
456       <emphasis>UTF8</emphasis>. You can set the UNIX charset using the
457       <option>unix charset</option> option. If you're using extended
458       characters in the configuration files for <command>afpd</command>, make
459       sure your terminal matches the <option>unix charset</option>.</para>
460
461       <variablelist>
462         <varlistentry>
463           <term>mac charset = <parameter>CHARSET</parameter>
464           <type>(G)/(V)</type></term>
465
466           <listitem>
467             <para>Specifies the Mac clients charset, e.g.
468             <emphasis>MAC_ROMAN</emphasis>. This is used to convert strings
469             and filenames to the clients codepage for OS9 and Classic, i.e.
470             for authentication and AFP messages (SIGUSR2 messaging). This will
471             also be the default for the volumes <option>mac charset</option>.
472             Defaults to <emphasis>MAC_ROMAN</emphasis>.</para>
473           </listitem>
474         </varlistentry>
475
476         <varlistentry>
477           <term>unix charset = <parameter>CHARSET</parameter>
478           <type>(G)</type></term>
479
480           <listitem>
481             <para>Specifies the servers unix charset, e.g.
482             <emphasis>ISO-8859-15</emphasis> or <emphasis>EUC-JP</emphasis>.
483             This is used to convert strings to/from the systems locale, e.g.
484             for authentication, server messages and volume names. If
485             <emphasis>LOCALE</emphasis> is set, the systems locale is used.
486             Defaults to <emphasis>UTF8</emphasis>.</para>
487           </listitem>
488         </varlistentry>
489
490         <varlistentry>
491           <term>vol charset = <parameter>CHARSET</parameter>
492           <type>(G)/(V)</type></term>
493
494           <listitem>
495             <para>Specifies the encoding of the volumes filesystem. By
496             default, it is the same as <option>unix charset</option>.</para>
497           </listitem>
498         </varlistentry>
499       </variablelist>
500     </refsect2>
501
502     <refsect2>
503       <title>Password Options</title>
504
505       <variablelist>
506         <varlistentry>
507           <term>passwd file = <parameter>path</parameter>
508           <type>(G)</type></term>
509
510           <listitem>
511             <para>Sets the path to the Randnum UAM passwd file for this server
512             (default is :ETCDIR:/afppasswd).</para>
513           </listitem>
514         </varlistentry>
515
516         <varlistentry>
517           <term>passwd minlen = <parameter>number</parameter>
518           <type>(G)</type></term>
519
520           <listitem>
521             <para>Sets the minimum password length, if supported by the
522             UAM</para>
523           </listitem>
524         </varlistentry>
525       </variablelist>
526     </refsect2>
527
528     <refsect2>
529       <title>Network Options</title>
530
531       <variablelist>
532         <varlistentry>
533           <term>advertise ssh = <replaceable>BOOLEAN</replaceable> (default:
534           <emphasis>no</emphasis>) <type>(G)</type></term>
535
536           <listitem>
537             <para>Allows old Mac OS X clients (10.3.3-10.4) to automagically
538             establish a tunneled AFP connection through SSH. If this option is
539             set, the server's answers to client's FPGetSrvrInfo requests
540             contain an additional entry. It depends on both client's settings
541             and a correctly configured and running <citerefentry>
542                 <refentrytitle>sshd</refentrytitle>
543
544                 <manvolnum>8</manvolnum>
545               </citerefentry> on the server to let things work.</para>
546
547             <note>
548               <para>Setting this option is not recommended since globally
549               encrypting AFP connections via SSH will increase the server's
550               load significantly. On the other hand, Apple's client side
551               implementation of this feature in MacOS X versions prior to
552               10.3.4 contained a security flaw.</para>
553             </note>
554           </listitem>
555         </varlistentry>
556
557         <varlistentry>
558           <term>afp listen = <replaceable>ip address[:port] [ip address[:port]
559           ...]</replaceable> <type>(G)</type></term>
560
561           <listitem>
562             <para>Specifies the IP address that the server should advertise
563             <emphasis role="bold">and</emphasis> listens to. The default is
564             advertise the first IP address of the system, but to listen for
565             any incoming request. The network address may be specified either
566             in dotted-decimal format for IPv4 or in hexadecimal format for
567             IPv6.</para>
568           </listitem>
569         </varlistentry>
570
571         <varlistentry>
572           <term>afp port = <replaceable>port number</replaceable>
573           <type>(G)</type></term>
574
575           <listitem>
576             <para>Allows a different TCP port to be used for AFP. The default
577             is 548. Also sets the default port applied when none specified in
578             an <option>afp listen</option> option.</para>
579           </listitem>
580         </varlistentry>
581
582         <varlistentry>
583           <term>cnid listen = <replaceable>ip address[:port] [ip
584           address[:port] ...]</replaceable> <type>(G)</type></term>
585
586           <listitem>
587             <para>Specifies the IP address that the CNID server should listen
588             on. The default is <emphasis
589             role="bold">localhost:4700</emphasis>.</para>
590           </listitem>
591         </varlistentry>
592
593         <varlistentry>
594           <term>disconnect time = <replaceable>number</replaceable>
595           <type>(G)</type></term>
596
597           <listitem>
598             <para>Keep disconnected AFP sessions for
599             <parameter>number</parameter> hours before dropping them. Default
600             is 24 hours.</para>
601           </listitem>
602         </varlistentry>
603
604         <varlistentry>
605           <term>dsireadbuf = <replaceable>number</replaceable>
606           <type>(G)</type></term>
607
608           <listitem>
609             <para>Scale factor that determines the size of the DSI/TCP
610             readahead buffer, default is 12. This is multiplies with the DSI
611             server quantum (default ~300k) to give the size of the buffer.
612             Increasing this value might increase throughput in fast local
613             networks for volume to volume copies. <emphasis>Note</emphasis>:
614             This buffer is allocated per afpd child process, so specifying
615             large values will eat up large amount of memory (buffer size *
616             number of clients).</para>
617           </listitem>
618         </varlistentry>
619
620         <varlistentry>
621           <term>fqdn = <replaceable>name:port</replaceable>
622           <type>(G)</type></term>
623
624           <listitem>
625             <para>Specifies a fully-qualified domain name, with an optional
626             port. This is discarded if the server cannot resolve it. This
627             option is not honored by AppleShare clients &lt;= 3.8.3. This
628             option is disabled by default. Use with caution as this will
629             involve a second name resolution step on the client side. Also
630             note that afpd will advertise this name:port combination but not
631             automatically listen to it.</para>
632           </listitem>
633         </varlistentry>
634
635         <varlistentry>
636           <term>hostname = <replaceable>name</replaceable>
637           <type>(G)</type></term>
638
639           <listitem>
640             <para>Use this instead of the result from calling hostname for
641             determining which IP address to advertise, therefore the hostname
642             is resolved to an IP which is the advertised. This is NOT used for
643             listening and it is also overwritten by <option>afp
644             listen</option>.</para>
645           </listitem>
646         </varlistentry>
647
648         <varlistentry>
649           <term>max connections = <replaceable>number</replaceable>
650           <type>(G)</type></term>
651
652           <listitem>
653             <para>Sets the maximum number of clients that can simultaneously
654             connect to the server (default is 200).</para>
655           </listitem>
656         </varlistentry>
657
658         <varlistentry>
659           <term>server quantum = <replaceable>number</replaceable>
660           <type>(G)</type></term>
661
662           <listitem>
663             <para>This specifies the DSI server quantum. The default value is
664             1 MB. The maximum value is 0xFFFFFFFFF, the minimum is 32000. If
665             you specify a value that is out of range, the default value will
666             be set. Do not change this value unless you're absolutely sure,
667             what you're doing</para>
668           </listitem>
669         </varlistentry>
670
671         <varlistentry>
672           <term>sleep time = <replaceable>number</replaceable>
673           <type>(G)</type></term>
674
675           <listitem>
676             <para>Keep sleeping AFP sessions for <parameter>number</parameter>
677             hours before disconnecting clients in sleep mode. Default is 10
678             hours.</para>
679           </listitem>
680         </varlistentry>
681
682         <varlistentry>
683           <term>tcprcvbuf = <replaceable>number</replaceable>
684           <type>(G)</type></term>
685
686           <listitem>
687             <para>Try to set TCP receive buffer using setsockpt(). Often OSes
688             impose restrictions on the applications ability to set this
689             value.</para>
690           </listitem>
691         </varlistentry>
692
693         <varlistentry>
694           <term>tcpsndbuf = <replaceable>number</replaceable>
695           <type>(G)</type></term>
696
697           <listitem>
698             <para>Try to set TCP send buffer using setsockpt(). Often OSes
699             impose restrictions on the applications ability to set this
700             value.</para>
701           </listitem>
702         </varlistentry>
703
704         <varlistentry>
705           <term>use sendfile = <replaceable>BOOLEAN</replaceable> (default:
706           <emphasis>yes</emphasis>) <type>(G)</type></term>
707
708           <listitem>
709             <para>Whether to use sendfile<indexterm>
710                 <primary>sendfile</primary>
711               </indexterm> syscall for sending file data to clients.</para>
712           </listitem>
713         </varlistentry>
714
715         <varlistentry>
716           <term>zeroconf = <replaceable>BOOLEAN</replaceable> (default:
717           <emphasis>yes</emphasis>) <type>(G)</type></term>
718
719           <listitem>
720             <para>Whether to use automatic Zeroconf<indexterm>
721                 <primary>Zeroconf</primary>
722
723                 <secondary>Bonjour</secondary>
724               </indexterm> service registration if Avahi or mDNSResponder were
725             compiled in.</para>
726           </listitem>
727         </varlistentry>
728       </variablelist>
729     </refsect2>
730
731     <refsect2>
732       <title>Miscellaneous Options</title>
733
734       <variablelist>
735         <varlistentry>
736           <term>admin group = <replaceable>group</replaceable>
737           <type>(G)</type></term>
738
739           <listitem>
740             <para>Allows users of a certain group to be seen as the superuser
741             when they log in. This option is disabled by default.</para>
742           </listitem>
743         </varlistentry>
744
745         <varlistentry>
746           <term>afp read locks = <replaceable>BOOLEAN</replaceable> (default:
747           <emphasis>no</emphasis>) <type>(G)</type></term>
748
749           <listitem>
750             <para>Whether to apply locks to the byte region read in FPRead
751             calls. The AFP spec mandates this, but it's not really in line
752             with UNIX semantics and is a performance hug.</para>
753           </listitem>
754         </varlistentry>
755
756         <varlistentry>
757           <term>afpstats = <replaceable>BOOLEAN</replaceable> (default:
758           <emphasis>no</emphasis>) <type>(G)</type></term>
759
760           <listitem>
761             <para>Whether to provide AFP runtime statistics (connected
762             users, open volumes) via dbus.</para>            
763           </listitem>
764         </varlistentry>
765
766         <varlistentry>
767           <term>basedir regex = <replaceable>regex</replaceable>
768           <type>(H)</type></term>
769
770           <listitem>
771             <para>Regular expression which matches the parent directory of the
772             user homes. If <option>basedir regex</option> contains symlink,
773             you must set the canonicalized absolute path. In the simple case
774             this is just a path ie <option>basedir regex =
775             /home</option></para>
776           </listitem>
777         </varlistentry>
778
779         <varlistentry>
780           <term>close vol = <replaceable>BOOLEAN</replaceable> (default:
781           <emphasis>no</emphasis>) <type>(G)</type></term>
782
783           <listitem>
784             <para>Whether to close volumes possibly opened by clients when
785             they're removed from the configuration and the configuration is
786             reloaded.</para>
787           </listitem>
788         </varlistentry>
789
790         <varlistentry>
791           <term>cnid server = <replaceable>ipaddress[:port]</replaceable>
792           <type>(G)/(V)</type></term>
793
794           <listitem>
795             <para>Specifies the IP address and port of a cnid_metad server,
796             required for CNID dbd backend. Defaults to localhost:4700. The
797             network address may be specified either in dotted-decimal format
798             for IPv4 or in hexadecimal format for IPv6.-</para>
799           </listitem>
800         </varlistentry>
801
802         <varlistentry>
803           <term>dircachesize = <replaceable>number</replaceable>
804           <type>(G)</type></term>
805
806           <listitem>
807             <para>Maximum possible entries in the directory cache. The cache
808             stores directories and files. It is used to cache the full path to
809             directories and CNIDs which considerably speeds up directory
810             enumeration.</para>
811
812             <para>Default size is 8192, maximum size is 131072. Given value is
813             rounded up to nearest power of 2. Each entry takes about 100
814             bytes, which is not much, but remember that every afpd child
815             process for every connected user has its cache.</para>
816           </listitem>
817         </varlistentry>
818
819         <varlistentry>
820           <term>extmap file = <parameter>path</parameter>
821           <type>(G)</type></term>
822
823           <listitem>
824             <para>Sets the path to the file which defines file extension
825             type/creator mappings. (default is :ETCDIR:/extmap.conf).</para>
826           </listitem>
827         </varlistentry>
828
829         <varlistentry>
830           <term>guest account = <replaceable>name</replaceable>
831           <type>(G)</type></term>
832
833           <listitem>
834             <para>Specifies the user that guests should use (default is
835             "nobody"). The name should be quoted.</para>
836           </listitem>
837         </varlistentry>
838
839         <varlistentry>
840           <term>home name = <replaceable>name</replaceable>
841           <type>(H)</type></term>
842
843           <listitem>
844             <para>AFP user home volume name. The default is <emphasis>user's
845             home</emphasis>.</para>
846           </listitem>
847         </varlistentry>
848
849         <varlistentry>
850           <term>login message = <replaceable>message</replaceable>
851           <type>(G)/(V)</type></term>
852
853           <listitem>
854             <para>Sets a message to be displayed when clients logon to the
855             server. The message should be in <option>unix charset</option> and
856             should be quoted. Extended characters are allowed.</para>
857           </listitem>
858         </varlistentry>
859
860         <varlistentry>
861           <term>mimic model = <replaceable>model</replaceable>
862           <type>(G)</type></term>
863
864           <listitem>
865             <para>Specifies the icon model that appears on clients. Defaults
866             to off. Note that afpd must support Zeroconf.
867             Examples: RackMac (same as Xserve), PowerBook, PowerMac,
868             Macmini, iMac, MacBook, MacBookPro, MacBookAir, MacPro,
869             AppleTV1,1, AirPort.</para>
870           </listitem>
871         </varlistentry>
872
873         <varlistentry>
874           <term>signature = &lt;text&gt; <type>(G)</type></term>
875
876           <listitem>
877             <para>Specify a server signature. The maximum length is 16
878             characters. This option is useful for clustered environments, to
879             provide fault isolation etc. By default, afpd generate signature
880             and saving it to
881             <filename>:STATEDIR:/netatalk/afp_signature.conf</filename>
882             automatically (based on random number). See also
883             asip-status.pl(1).</para>
884           </listitem>
885         </varlistentry>
886
887         <varlistentry>
888           <term>solaris share reservations =
889           <replaceable>BOOLEAN</replaceable> (default:
890           <emphasis>yes</emphasis>) <type>(G)</type></term>
891
892           <listitem>
893             <para>Use share reservations on Solaris. Solaris CIFS server uses
894             this too, so this makes a lock coherent multi protocol
895             server.</para>
896           </listitem>
897         </varlistentry>
898
899         <varlistentry>
900           <term>vol dbpath = <replaceable>path</replaceable>
901           <type>(G)</type></term>
902
903           <listitem>
904             <para>Sets the database information to be stored in path. You have
905             to specify a writable location, even if the volume is read only.
906             The default is
907             <filename>:STATEDIR:/netatalk/CNID/</filename>.</para>
908           </listitem>
909         </varlistentry>
910
911         <varlistentry>
912           <term>volnamelen = <replaceable>number</replaceable>
913           <type>(G)</type></term>
914
915           <listitem>
916             <para>Max length of UTF8-MAC volume name for Mac OS X. Note that
917             Hangul is especially sensitive to this.</para>
918
919             <para><programlisting> 73: limit of Mac OS X 10.1 80: limit of Mac
920             OS X 10.4/10.5 (default) 255: limit of recent Mac OS
921             X</programlisting> Mac OS 9 and earlier are not influenced by
922             this, because Maccharset volume name is always limited to 27
923             bytes.</para>
924           </listitem>
925         </varlistentry>
926
927         <varlistentry>
928           <term>vol preset = <replaceable>name</replaceable>
929           <type>(G)/(V)</type></term>
930
931           <listitem>
932             <para>Use section <option>name</option> as option preset for all
933             volumes (when set in the [Global] section) or for one volume (when
934             set in that volume's section).</para>
935           </listitem>
936         </varlistentry>
937       </variablelist>
938     </refsect2>
939
940     <refsect2>
941       <title>Logging Options</title>
942
943       <variablelist>
944         <varlistentry>
945           <term>log file = <replaceable>logfile</replaceable>
946           <type>(G)</type></term>
947
948           <listitem>
949             <para>If not specified Netatalk logs to syslogs daemon facility.
950             Otherwise it logs to <option>logfile</option>.</para>
951           </listitem>
952         </varlistentry>
953
954         <varlistentry>
955           <term>log level = <replaceable>type:level [type:level
956           ...]</replaceable> <type>(G)</type></term>
957
958           <term>log level = <replaceable>type:level,[type:level,
959           ...]</replaceable> <type>(G)</type></term>
960
961           <listitem>
962             <para>Specify that any message of a loglevel up to the given
963             <option>log level</option> should be logged.</para>
964
965             <para>By default afpd logs to syslog with a default logging setup
966             equivalent to <option>default:note</option></para>
967
968             <para>logtypes: default, afpdaemon, logger, uamsdaemon</para>
969
970             <para>loglevels: severe, error, warn, note, info, debug, debug6,
971             debug7, debug8, debug9, maxdebug</para>
972
973             <note>
974               <para>Both logtype and loglevels are case insensitive.</para>
975             </note>
976           </listitem>
977         </varlistentry>
978       </variablelist>
979     </refsect2>
980
981     <refsect2 id="fceconf">
982       <title>Filesystem Change Events (FCE<indexterm>
983           <primary>FCE</primary>
984         </indexterm>)</title>
985
986       <para>Netatalk includes a nifty filesystem change event mechanism where
987       afpd processes notify interested listeners about certain filesystem
988       event by UDP network datagrams.</para>
989
990       <variablelist>
991         <varlistentry>
992           <term>fce listener = <replaceable>host[:port]</replaceable>
993           <type>(G)</type></term>
994
995           <listitem>
996             <para>Enables sending FCE events to the specified
997             <parameter>host</parameter>, default <parameter>port</parameter>
998             is 12250 if not specified. Specifying multiple listeners is done
999             by having this option once for each of them.</para>
1000           </listitem>
1001         </varlistentry>
1002
1003         <varlistentry>
1004           <term>fce events =
1005           <replaceable>fmod,fdel,ddel,fcre,dcre,tmsz</replaceable>
1006           <type>(G)</type></term>
1007
1008           <listitem>
1009             <para>Specifies which FCE events are active, default is
1010             <parameter>fmod,fdel,ddel,fcre,dcre</parameter>.</para>
1011           </listitem>
1012         </varlistentry>
1013
1014         <varlistentry>
1015           <term>fce coalesce = <replaceable>all|delete|create</replaceable>
1016           <type>(G)</type></term>
1017
1018           <listitem>
1019             <para>Coalesce FCE events.</para>
1020           </listitem>
1021         </varlistentry>
1022
1023         <varlistentry>
1024           <term>fce holdfmod = <replaceable>seconds</replaceable>
1025           <type>(G)</type></term>
1026
1027           <listitem>
1028             <para>This determines the time delay in seconds which is always
1029             waited if another file modification for the same file is done by a
1030             client before sending an FCE file modification event (fmod). For
1031             example saving a file in Photoshop would generate multiple events
1032             by itself because the application is opening, modifying and
1033             closing a file multiple times for every "save". Default: 60
1034             seconds.</para>
1035           </listitem>
1036         </varlistentry>
1037       </variablelist>
1038     </refsect2>
1039
1040     <refsect2>
1041       <title>Debug Parameters</title>
1042
1043       <para>These options are useful for debugging only.</para>
1044
1045       <variablelist>
1046         <varlistentry>
1047           <term>tickleval = <replaceable>number</replaceable>
1048           <type>(G)</type></term>
1049
1050           <listitem>
1051             <para>Sets the tickle timeout interval (in seconds). Defaults to
1052             30.</para>
1053           </listitem>
1054         </varlistentry>
1055
1056         <varlistentry>
1057           <term>timeout = <replaceable>number</replaceable>
1058           <type>(G)</type></term>
1059
1060           <listitem>
1061             <para>Specify the number of tickles to send before timing out a
1062             connection. The default is 4, therefore a connection will timeout
1063             after 2 minutes.</para>
1064           </listitem>
1065         </varlistentry>
1066
1067         <varlistentry>
1068           <term>client polling = <replaceable>BOOLEAN</replaceable> (default:
1069           <emphasis>no</emphasis>) <type>(G)</type></term>
1070
1071           <listitem>
1072             <para>With this option enabled, afpd won't advertise that it is
1073             capable of server notifications, so that connected clients poll
1074             the server every 10 seconds to detect changes in opened server
1075             windows. <emphasis>Note</emphasis>: Depending on the number of
1076             simultaneously connected clients and the network's speed, this can
1077             lead to a significant higher load on your network!</para>
1078
1079             <para>Do not use this option any longer as present Netatalk
1080             correctly supports server notifications, allowing connected
1081             clients to update folder listings in case another client changed
1082             the contents.</para>
1083           </listitem>
1084         </varlistentry>
1085       </variablelist>
1086     </refsect2>
1087
1088     <refsect2 id="acl_options">
1089       <title>Options for ACL handling</title>
1090
1091       <para>By default, the effective permission of the authenticated user are
1092       only mapped to the mentioned UARights permission structure, not the UNIX
1093       mode. You can adjust this behaviour with the configuration option
1094       <option>mac acls</option>:</para>
1095
1096       <variablelist id="mac_acls">
1097         <varlistentry>
1098           <term>map acls = <parameter>none|rights|mode</parameter>
1099           <type>(G)</type></term>
1100
1101           <listitem>
1102             <para><variablelist>
1103                 <varlistentry>
1104                   <term>none</term>
1105
1106                   <listitem>
1107                     <para>no mapping of ACLs </para>
1108                   </listitem>
1109                 </varlistentry>
1110
1111                 <varlistentry>
1112                   <term>rights</term>
1113
1114                   <listitem>
1115                     <para>effective permissions are mapped to UARights
1116                     structure. This is the default.</para>
1117                   </listitem>
1118                 </varlistentry>
1119
1120                 <varlistentry>
1121                   <term>mode</term>
1122
1123                   <listitem>
1124                     <para>ACLs are additionally mapped to the UNIX mode of the
1125                     filesystem object.</para>
1126                   </listitem>
1127                 </varlistentry>
1128               </variablelist></para>
1129           </listitem>
1130         </varlistentry>
1131       </variablelist>
1132
1133       <para>If you want to be able to display ACLs on the client, you must
1134       setup both client and server as part on a authentication domain
1135       (directory service, eg LDAP, Open Directory, Active Directory). The
1136       reason is, in OS X ACLs are bound to UUIDs, not just uid's or gid's.
1137       Therefor Netatalk must be able to map every filesystem uid and gid to a
1138       UUID so that it can return the server side ACLs which are bound to UNIX
1139       uid and gid mapped to OS X UUIDs.</para>
1140
1141       <para>Netatalk can query a directory server using LDAP queries. Either
1142       the directory server already provides an UUID attribute for user and
1143       groups (Active Directory, Open Directory) or you reuse an unused
1144       attribute (or add a new one) to you directory server (eg
1145       OpenLDAP).</para>
1146
1147       <para>The following LDAP options must be configured for Netatalk:</para>
1148
1149       <variablelist>
1150         <varlistentry>
1151           <term>ldap auth method = <parameter>none|simple|sasl</parameter>
1152           <type>(G)</type></term>
1153
1154           <listitem>
1155             <para>Authentication method: <option>none | simple |
1156             sasl</option></para>
1157
1158             <para><variablelist>
1159                 <varlistentry>
1160                   <term>none</term>
1161
1162                   <listitem>
1163                     <para>anonymous LDAP bind</para>
1164                   </listitem>
1165                 </varlistentry>
1166
1167                 <varlistentry>
1168                   <term>simple</term>
1169
1170                   <listitem>
1171                     <para>simple LDAP bind</para>
1172                   </listitem>
1173                 </varlistentry>
1174
1175                 <varlistentry>
1176                   <term>sasl</term>
1177
1178                   <listitem>
1179                     <para>SASL. Not yet supported !</para>
1180                   </listitem>
1181                 </varlistentry>
1182               </variablelist></para>
1183           </listitem>
1184         </varlistentry>
1185
1186         <varlistentry>
1187           <term>ldap auth dn = <parameter>dn</parameter>
1188           <type>(G)</type></term>
1189
1190           <listitem>
1191             <para>Distinguished Name of the user for simple bind.</para>
1192           </listitem>
1193         </varlistentry>
1194
1195         <varlistentry>
1196           <term>ldap auth pw = <parameter>password</parameter>
1197           <type>(G)</type></term>
1198
1199           <listitem>
1200             <para>Distinguished Name of the user for simple bind.</para>
1201           </listitem>
1202         </varlistentry>
1203
1204         <varlistentry>
1205           <term>ldap server = <parameter>host</parameter>
1206           <type>(G)</type></term>
1207
1208           <listitem>
1209             <para>Name or IP address of your LDAP Server. This is only needed
1210             for explicit ACL support in order to be able to query LDAP for
1211             UUIDs.</para>
1212
1213             <para>You can use <citerefentry>
1214                 <refentrytitle>afpldaptest</refentrytitle>
1215
1216                 <manvolnum>1</manvolnum>
1217               </citerefentry> to syntactically check your config.</para>
1218           </listitem>
1219         </varlistentry>
1220
1221         <varlistentry>
1222           <term>ldap userbase = <parameter>base dn</parameter>
1223           <type>(G)</type></term>
1224
1225           <listitem>
1226             <para>DN of the user container in LDAP.</para>
1227           </listitem>
1228         </varlistentry>
1229
1230         <varlistentry>
1231           <term>ldap userscope = <parameter>scope</parameter>
1232           <type>(G)</type></term>
1233
1234           <listitem>
1235             <para>Search scope for user search: <option>base | one |
1236             sub</option></para>
1237           </listitem>
1238         </varlistentry>
1239
1240         <varlistentry>
1241           <term>ldap groupbase = <parameter>base dn</parameter>
1242           <type>(G)</type></term>
1243
1244           <listitem>
1245             <para>DN of the group container in LDAP.</para>
1246           </listitem>
1247         </varlistentry>
1248
1249         <varlistentry>
1250           <term>ldap groupscope = <parameter>scope</parameter>
1251           <type>(G)</type></term>
1252
1253           <listitem>
1254             <para>Search scope for user search: <option>base | one |
1255             sub</option></para>
1256           </listitem>
1257         </varlistentry>
1258
1259         <varlistentry>
1260           <term>ldap uuid attr = <parameter>dn</parameter>
1261           <type>(G)</type></term>
1262
1263           <listitem>
1264             <para>Name of the LDAP attribute with the UUIDs.</para>
1265
1266             <para>Note: this is used both for users and groups.</para>
1267           </listitem>
1268         </varlistentry>
1269
1270         <varlistentry>
1271           <term>ldap name attr = <parameter>dn</parameter>
1272           <type>(G)</type></term>
1273
1274           <listitem>
1275             <para>Name of the LDAP attribute with the users short name.</para>
1276           </listitem>
1277         </varlistentry>
1278
1279         <varlistentry>
1280           <term>ldap uuid string = <parameter>STRING</parameter>
1281           <type>(G)</type></term>
1282
1283           <listitem>
1284             <para>Format of the uuid string in the directory. A series of x
1285             and -, where every x denotes a value 0-9a-f and every - is a
1286             separator.</para>
1287
1288             <para>Default: xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx</para>
1289           </listitem>
1290         </varlistentry>
1291
1292         <varlistentry>
1293           <term>ldap uuid encoding = <parameter>string | ms-guid (default:
1294           string)</parameter> <type>(G)</type></term>
1295
1296           <listitem>
1297             <para>Format of the UUID of the LDAP attribute, allows usage of
1298             the binary objectGUID fields from Active Directory. If left
1299             unspecified, string is the default, which passes through the ASCII
1300             UUID returned by most other LDAP stores. If set to ms-guid, the
1301             internal UUID representation is converted to and from the binary
1302             format used in the objectGUID attribute found on objects in Active
1303             Directory when interacting with the server.</para>
1304
1305             <para><variablelist>
1306                 <varlistentry>
1307                   <term>string</term>
1308
1309                   <listitem>
1310                     <para>UUID is a string, use with eg OpenDirectory.</para>
1311                   </listitem>
1312                 </varlistentry>
1313
1314                 <varlistentry>
1315                   <term>ms-guid</term>
1316
1317                   <listitem>
1318                     <para>Binary objectGUID from Active Directory</para>
1319                   </listitem>
1320                 </varlistentry>
1321               </variablelist></para>
1322           </listitem>
1323         </varlistentry>
1324
1325         <varlistentry>
1326           <term>ldap group attr = <parameter>dn</parameter>
1327           <type>(G)</type></term>
1328
1329           <listitem>
1330             <para>Name of the LDAP attribute with the groups short
1331             name.</para>
1332           </listitem>
1333         </varlistentry>
1334       </variablelist>
1335     </refsect2>
1336   </refsect1>
1337
1338   <refsect1>
1339     <title>EXPLANATION OF VOLUME PARAMETERS</title>
1340
1341     <refsect2>
1342       <title>Parameters</title>
1343
1344       <para>The section name defines the volume name.
1345       No two volumes may have the same
1346       name. The volume name cannot contain the <keycode>':'</keycode>
1347       character. The volume name is mangled if it is very long. Mac charset
1348       volume name is limited to 27 characters. UTF8-MAC volume name is limited
1349       to volnamelen parameter.</para>
1350
1351       <variablelist>
1352         <varlistentry>
1353           <term>path = <replaceable>PATH</replaceable> <type>(V)</type></term>
1354
1355           <listitem>
1356             <para>The path name must be a fully qualified path name.</para>
1357           </listitem>
1358         </varlistentry>
1359
1360         <varlistentry>
1361           <term>appledouble = <replaceable>ea|v2</replaceable>
1362           <type>(V)</type></term>
1363
1364           <listitem>
1365             <para>Specify the format of the metadata files, which are used for
1366             saving Mac resource fork as well. Earlier versions used
1367             AppleDouble v2, the new default format is <emphasis
1368             role="bold">ea</emphasis>.</para>
1369           </listitem>
1370         </varlistentry>
1371
1372         <varlistentry>
1373           <term>vol size limit = <replaceable>size in MiB</replaceable>
1374           <type>(V)</type></term>
1375
1376           <listitem>
1377             <para>Useful for Time Machine: limits the reported volume size,
1378             thus preventing Time Machine from using the whole real disk space
1379             for backup. Example: "vol size limit = 1000" would limit the
1380             reported disk space to 1 GB. <emphasis role="bold">IMPORTANT:
1381             </emphasis> This is an approximated calculation taking into
1382             account the contents of Time Machine sparsebundle images. Therefor
1383             you MUST NOT use this volume to store other content when using
1384             this option, because it would NOT be accounted. The calculation
1385             works by reading the band size from the Info.plist XML file of the
1386             sparsebundle, reading the bands/ directory counting the number of
1387             band files, and then multiplying one with the other.</para>
1388           </listitem>
1389         </varlistentry>
1390
1391         <varlistentry>
1392           <term>valid users = <replaceable>user @group</replaceable>
1393           <type>(V)</type></term>
1394
1395           <listitem>
1396             <para>The allow option allows the users and groups that access a
1397             share to be specified. Users and groups are specified, delimited
1398             by spaces or commas. Groups are designated by a @ prefix. Names
1399             may be quoted in order to allow for spaces in names. Example:
1400             <programlisting>valid users = user "user 2" @group â€œ@group 2"</programlisting></para>
1401           </listitem>
1402         </varlistentry>
1403
1404         <varlistentry>
1405           <term>invalid users = <replaceable>users/groups</replaceable>
1406           <type>(V)</type></term>
1407
1408           <listitem>
1409             <para>The deny option specifies users and groups who are not
1410             allowed access to the share. It follows the same format as the
1411             "valid users" option.</para>
1412           </listitem>
1413         </varlistentry>
1414
1415         <varlistentry>
1416           <term>hosts allow = <replaceable>IP host address/IP netmask bits [
1417           ... ]</replaceable> <type>(V)</type></term>
1418
1419           <listitem>
1420             <para>Only listed hosts and networks are allowed, all others are
1421             rejected. The network address may be specified either in
1422             dotted-decimal format for IPv4 or in hexadecimal format for
1423             IPv6.</para>
1424
1425             <para>Example: hosts allow = 10.1.0.0/16 10.2.1.100
1426             2001:0db8:1234::/48</para>
1427           </listitem>
1428         </varlistentry>
1429
1430         <varlistentry>
1431           <term>hosts deny = <replaceable>IP host address/IP netmask bits [
1432           ... ]</replaceable> <type>(V)</type></term>
1433
1434           <listitem>
1435             <para>Listed hosts and nets are rejected, all others are
1436             allowed.</para>
1437
1438             <para>Example: hosts deny = 192.168.100/24 10.1.1.1
1439             2001:db8::1428:57ab</para>
1440           </listitem>
1441         </varlistentry>
1442
1443         <varlistentry>
1444           <term>cnid scheme = <replaceable>backend</replaceable>
1445           <type>(V)</type></term>
1446
1447           <listitem>
1448             <para>set the CNID backend to be used for the volume, default is
1449             [:DEFAULT_CNID_SCHEME:] available schemes:
1450             [:COMPILED_BACKENDS:]</para>
1451           </listitem>
1452         </varlistentry>
1453
1454         <varlistentry>
1455           <term>ea = <replaceable>none|auto|sys|ad</replaceable>
1456           <type>(V)</type></term>
1457
1458           <listitem>
1459             <para>Specify how Extended Attributes<indexterm>
1460                 <primary>Extended Attributes</primary>
1461               </indexterm> are stored. <option>auto</option> is the
1462             default.</para>
1463
1464             <variablelist>
1465               <varlistentry>
1466                 <term>auto</term>
1467
1468                 <listitem>
1469                   <para>Try <option>sys</option> (by setting an EA on the
1470                   shared directory itself), fallback to <option>ad</option>.
1471                   Requires writable volume for performing test. "<option>read
1472                   only = yes</option>" overwrites <option>auto</option> with
1473                   <option>none</option>. Use explicit "<option>ea =
1474                   sys|ad</option>" for read-only volumes where
1475                   appropriate.</para>
1476                 </listitem>
1477               </varlistentry>
1478
1479               <varlistentry>
1480                 <term>sys</term>
1481
1482                 <listitem>
1483                   <para>Use filesystem Extended Attributes.</para>
1484                 </listitem>
1485               </varlistentry>
1486
1487               <varlistentry>
1488                 <term>ad</term>
1489
1490                 <listitem>
1491                   <para>Use files in <emphasis>.AppleDouble</emphasis>
1492                   directories.</para>
1493                 </listitem>
1494               </varlistentry>
1495
1496               <varlistentry>
1497                 <term>none</term>
1498
1499                 <listitem>
1500                   <para>No Extended Attributes support.</para>
1501                 </listitem>
1502               </varlistentry>
1503             </variablelist>
1504           </listitem>
1505         </varlistentry>
1506
1507         <varlistentry>
1508           <term>mac charset = <replaceable>CHARSET</replaceable>
1509           <type>(V)</type></term>
1510
1511           <listitem>
1512             <para>specifies the Mac client charset for this Volume, e.g.
1513             <emphasis>MAC_ROMAN</emphasis>, <emphasis>MAC_CYRILLIC</emphasis>.
1514             If not specified the global setting is applied. This setting is
1515             only required if you need volumes, where the Mac charset differs
1516             from the one globally set in the [Global] section.</para>
1517           </listitem>
1518         </varlistentry>
1519
1520         <varlistentry>
1521           <term>casefold = <option>option</option> <type>(V)</type></term>
1522
1523           <listitem>
1524             <para>The casefold option handles, if the case of filenames should
1525             be changed. The available options are:</para>
1526
1527             <para><option>tolower</option> - Lowercases names in both
1528             directions.</para>
1529
1530             <para><option>toupper</option> - Uppercases names in both
1531             directions.</para>
1532
1533             <para><option>xlatelower</option> - Client sees lowercase, server
1534             sees uppercase.</para>
1535
1536             <para><option>xlateupper</option> - Client sees uppercase, server
1537             sees lowercase.</para>
1538           </listitem>
1539         </varlistentry>
1540
1541         <varlistentry>
1542           <term>password = <replaceable>password</replaceable>
1543           <type>(V)</type></term>
1544
1545           <listitem>
1546             <para>This option allows you to set a volume password, which can
1547             be a maximum of 8 characters long (using ASCII strongly
1548             recommended at the time of this writing).</para>
1549           </listitem>
1550         </varlistentry>
1551
1552         <varlistentry>
1553           <term>file perm = <replaceable>mode</replaceable>
1554           <type>(V)</type></term>
1555
1556           <term>directory perm = <replaceable>mode</replaceable>
1557           <type>(V)</type></term>
1558
1559           <listitem>
1560             <para>Add(or) with the client requested permissions: <option>file
1561             perm</option> is for files only, <option>directory perm</option>
1562             is for directories only. Don't use with "<option>unix priv =
1563             no</option>".</para>
1564
1565             <example>
1566               <title>Volume for a collaborative workgroup</title>
1567
1568               <para><programlisting>file perm = 0660 directory perm =
1569               0770</programlisting></para>
1570             </example>
1571           </listitem>
1572         </varlistentry>
1573
1574         <varlistentry>
1575           <term>umask = <replaceable>mode</replaceable>
1576           <type>(V)</type></term>
1577
1578           <listitem>
1579             <para>set perm mask. Don't use with "<option>unix priv =
1580             no</option>".</para>
1581           </listitem>
1582         </varlistentry>
1583
1584         <varlistentry>
1585           <term>preexec = <replaceable>command</replaceable>
1586           <type>(V)</type></term>
1587
1588           <listitem>
1589             <para>command to be run when the volume is mounted, ignored for
1590             user defined volumes</para>
1591           </listitem>
1592         </varlistentry>
1593
1594         <varlistentry>
1595           <term>postexec = <replaceable>command</replaceable>
1596           <type>(V)</type></term>
1597
1598           <listitem>
1599             <para>command to be run when the volume is closed, ignored for
1600             user defined volumes</para>
1601           </listitem>
1602         </varlistentry>
1603
1604         <varlistentry>
1605           <term>root preexec = <replaceable>command</replaceable>
1606           <type>(V)</type></term>
1607
1608           <listitem>
1609             <para>command to be run as root when the volume is mounted,
1610             ignored for user defined volumes</para>
1611           </listitem>
1612         </varlistentry>
1613
1614         <varlistentry>
1615           <term>root postexec = <replaceable>command</replaceable>
1616           <type>(V)</type></term>
1617
1618           <listitem>
1619             <para>command to be run as root when the volume is closed, ignored
1620             for user defined volumes</para>
1621           </listitem>
1622         </varlistentry>
1623
1624         <varlistentry>
1625           <term>rolist = <option>users/groups</option> <type>(V)</type></term>
1626
1627           <listitem>
1628             <para>Allows certain users and groups to have read-only access to
1629             a share. This follows the allow option format.</para>
1630           </listitem>
1631         </varlistentry>
1632
1633         <varlistentry>
1634           <term>rwlist = <replaceable>users/groups</replaceable>
1635           <type>(V)</type></term>
1636
1637           <listitem>
1638             <para>Allows certain users and groups to have read/write access to
1639             a share. This follows the allow option format.</para>
1640           </listitem>
1641         </varlistentry>
1642
1643         <varlistentry>
1644           <term>veto files = <replaceable>vetoed names</replaceable>
1645           <type>(V)</type></term>
1646
1647           <listitem>
1648             <para>hide files and directories,where the path matches one of the
1649             '/' delimited vetoed names. The veto string must always be
1650             terminated with a '/', eg. "veto1/", "veto1/veto2/".</para>
1651           </listitem>
1652         </varlistentry>
1653       </variablelist>
1654     </refsect2>
1655
1656     <refsect2>
1657       <title>Volume options</title>
1658
1659       <para>Boolean volume options.</para>
1660
1661       <variablelist>
1662         <varlistentry>
1663           <term>acls = <replaceable>BOOLEAN</replaceable> (default:
1664           <emphasis>yes</emphasis>) <type>(V)</type></term>
1665
1666           <listitem>
1667             <para>Whether to flag volumes as supporting ACLs. If ACL support
1668             is compiled in, this is yes by default.</para>
1669           </listitem>
1670         </varlistentry>
1671
1672         <varlistentry>
1673           <term>cnid dev = <replaceable>BOOLEAN</replaceable> (default:
1674           <emphasis>yes</emphasis>) <type>(V)</type></term>
1675
1676           <listitem>
1677             <para>Whether to use the device number in the CNID backends. Helps
1678             when the device number is not constant across a reboot, eg
1679             cluster, ...</para>
1680           </listitem>
1681         </varlistentry>
1682
1683         <varlistentry>
1684           <term>convert appledouble = <replaceable>BOOLEAN</replaceable>
1685           (default: <emphasis>yes</emphasis>) <type>(V)</type></term>
1686
1687           <listitem>
1688             <para>Whether automatic conversion from <option>appledouble =
1689             v2</option> to <option>appledouble = ea</option> is performed when
1690             accessing filesystems from clients. This is generally useful, but
1691             costs some performance. It's recommendable to run
1692             <command>dbd</command> on volumes and do the conversion with that.
1693             Then this option can be set to no.</para>
1694           </listitem>
1695         </varlistentry>
1696
1697         <varlistentry>
1698           <term>follow symlinks = <replaceable>BOOLEAN</replaceable> (default:
1699           <emphasis>no</emphasis>) <type>(V)</type></term>
1700
1701           <listitem>
1702             <para>The default setting is false thus symlinks are not followed
1703             on the server. This is the same behaviour as OS X's AFP server.
1704             Setting the option to true causes afpd to follow symlinks on the
1705             server. symlinks may point outside of the AFP volume, currently
1706             afpd doesn't do any checks for "wide symlinks".</para>
1707           </listitem>
1708         </varlistentry>
1709
1710         <varlistentry>
1711           <term>invisible dots = <replaceable>BOOLEAN</replaceable> (default:
1712           <emphasis>no</emphasis>) <type>(V)</type></term>
1713
1714           <listitem>
1715             <para>make dot files invisible. WARNING: enabling this option will
1716               lead to unwanted sideeffects were OS X applications when saving
1717               files to a temporary file starting with a dot first, then renaming
1718               the temp file to its final name, result in the saved file being
1719               invisible. The only thing this option is useful for is making
1720               files that start with a dot invisible on Mac OS 9. It's
1721               completely useless on Mac OS X, as both in Finder and in Terminal
1722               files starting with a dot are hidden anyway.</para>
1723           </listitem>
1724         </varlistentry>
1725
1726         <varlistentry>
1727           <term>network ids = <replaceable>BOOLEAN</replaceable> (default:
1728           <emphasis>yes</emphasis>) <type>(V)</type></term>
1729
1730           <listitem>
1731             <para>Whether the server support network ids. Setting this to
1732             <emphasis>no</emphasis> will result in the client not using ACL
1733             AFP functions.</para>
1734           </listitem>
1735         </varlistentry>
1736
1737         <varlistentry>
1738           <term>preexec close = <replaceable>BOOLEAN</replaceable> (default:
1739           <emphasis>no</emphasis>) <type>(V)</type></term>
1740
1741           <listitem>
1742             <para>A non-zero return code from preexec close the volume being
1743             immediately, preventing clients to mount/see the volume in
1744             question.</para>
1745           </listitem>
1746         </varlistentry>
1747
1748         <varlistentry>
1749           <term>read only = <replaceable>BOOLEAN</replaceable> (default:
1750           <emphasis>no</emphasis>) <type>(V)</type></term>
1751
1752           <listitem>
1753             <para>Specifies the share as being read only for all users.
1754             Overwrites <option>ea = auto</option> with <option>ea =
1755             none</option></para>
1756           </listitem>
1757         </varlistentry>
1758
1759         <varlistentry>
1760           <term>root preexec close= <replaceable>BOOLEAN</replaceable>
1761           (default: <emphasis>no</emphasis>) <type>(V)</type></term>
1762
1763           <listitem>
1764             <para>A non-zero return code from root_preexec closes the volume
1765             immediately, preventing clients to mount/see the volume in
1766             question.</para>
1767           </listitem>
1768         </varlistentry>
1769
1770         <varlistentry>
1771           <term>search db = <replaceable>BOOLEAN</replaceable> (default:
1772           <emphasis>no</emphasis>) <type>(V)</type></term>
1773
1774           <listitem>
1775             <para>Use fast CNID database namesearch instead of slow recursive
1776             filesystem search. Relies on a consistent CNID database, ie Samba
1777             or local filesystem access lead to inaccurate or wrong results.
1778             Works only for "dbd" CNID db volumes.</para>
1779           </listitem>
1780         </varlistentry>
1781
1782         <varlistentry>
1783           <term>stat vol = <replaceable>BOOLEAN</replaceable> (default:
1784           <emphasis>yes</emphasis>) <type>(V)</type></term>
1785
1786           <listitem>
1787             <para>Whether to stat volume path when enumerating volumes list,
1788             useful for automounting or volumes created by a preexec
1789             script.</para>
1790           </listitem>
1791         </varlistentry>
1792
1793         <varlistentry>
1794           <term>time machine = <replaceable>BOOLEAN</replaceable> (default:
1795           <emphasis>no</emphasis>) <type>(V)</type></term>
1796
1797           <listitem>
1798             <para>Whether to enable Time Machine support for this
1799             volume.</para>
1800           </listitem>
1801         </varlistentry>
1802
1803         <varlistentry>
1804           <term>unix priv = <replaceable>BOOLEAN</replaceable> (default:
1805           <emphasis>yes</emphasis>) <type>(V)</type></term>
1806
1807           <listitem>
1808             <para>Whether to use AFP3 UNIX privileges. This should be set for
1809             OS X clients. See also: <option>file perm</option>,
1810             <option>directory perm</option> and <option>umask</option>.</para>
1811           </listitem>
1812         </varlistentry>
1813       </variablelist>
1814     </refsect2>
1815   </refsect1>
1816
1817   <refsect1>
1818     <title>CNID backends</title>
1819
1820     <para>The AFP protocol mostly refers to files and directories by ID and
1821     not by name. Netatalk needs a way to store these ID's in a persistent way,
1822     to achieve this several different CNID backends are available. The CNID
1823     Databases are by default located in the
1824     <filename>:STATEDIR:/netatalk/CNID/(volumename)/.AppleDB/</filename>
1825     directory.</para>
1826
1827     <variablelist>
1828       <varlistentry>
1829         <term>cdb</term>
1830
1831         <listitem>
1832           <para>"Concurrent database", backend is based on Oracle Berkley DB.
1833           With this backend several <command>afpd</command> daemons access the
1834           CNID database directly. Berkeley DB locking is used to synchronize
1835           access, if more than one <command>afpd</command> process is active
1836           for a volume. The drawback is, that the crash of a single
1837           <command>afpd</command> process might corrupt the database.</para>
1838         </listitem>
1839       </varlistentry>
1840
1841       <varlistentry>
1842         <term>dbd</term>
1843
1844         <listitem>
1845           <para>Access to the CNID database is restricted to the
1846           <command>cnid_metad</command> daemon process.
1847           <command>afpd</command> processes communicate with the daemon for
1848           database reads and updates. If built with Berkeley DB transactions
1849           the probability for database corruption is practically zero, but
1850           performance can be slower than with <option>cdb</option></para>
1851         </listitem>
1852       </varlistentry>
1853
1854       <varlistentry>
1855         <term>last</term>
1856
1857         <listitem>
1858           <para>This backend is an exception, in terms of ID persistency. ID's
1859           are only valid for the current session. This is basically what
1860           <command>afpd</command> did in the 1.5 (and 1.6) versions. This
1861           backend is still available, as it is useful for e.g. sharing cdroms.
1862           Starting with Netatalk 3.0, it becomes the <emphasis>read only
1863           mode</emphasis> automatically.</para>
1864
1865           <para><emphasis role="bold">Warning</emphasis>: It is
1866           <emphasis>NOT</emphasis> recommended to use this backend for volumes
1867           anymore, as <command>afpd</command> now relies heavily on a
1868           persistent ID database. Aliases will likely not work and filename
1869           mangling is not supported.</para>
1870         </listitem>
1871       </varlistentry>
1872     </variablelist>
1873
1874     <para>Even though <command>./configure --help</command> might show that
1875     there are other CNID backends available, be warned those are likely broken
1876     or mainly used for testing. Don't use them unless you know what you're
1877     doing, they may be removed without further notice from future
1878     versions.</para>
1879   </refsect1>
1880
1881   <refsect1>
1882     <title>Charset options</title>
1883
1884     <para>With OS X Apple introduced the AFP3 protocol. One of the most
1885     important changes was that AFP3 uses unicode names encoded as UTF-8
1886     decomposed. Previous AFP/OS versions used codepages, like MacRoman,
1887     MacCentralEurope, etc.</para>
1888
1889     <para><command>afpd</command> needs a way to preserve extended Macintosh
1890     characters, or characters illegal in unix filenames, when saving files on
1891     a unix filesystem. Earlier versions used the the so called CAP encoding.
1892     An extended character (&gt;0x7F) would be converted to a :xx sequence,
1893     e.g. the Apple Logo (MacRoman: 0xF0) was saved as <literal>:f0</literal>.
1894     Some special characters will be converted as to :xx notation as well.
1895     '<keycode>/</keycode>' will be encoded to <literal>:2f</literal>, if
1896     <option>usedots</option> is not specified, a leading dot
1897     '<keycode>.</keycode>' will be encoded as <literal>:2e</literal>.</para>
1898
1899     <para>This version now uses UTF-8 as the default encoding for names.
1900     '<keycode>/</keycode>' will be converted to '<keycode>:</keycode>'.</para>
1901
1902     <para>The <option>vol charset</option> option will allow you to select
1903     another volume encoding. E.g. for western users another useful setting
1904     could be vol charset ISO-8859-15. <command>afpd</command> will accept any
1905     <citerefentry>
1906         <refentrytitle><command>iconv</command></refentrytitle>
1907
1908         <manvolnum>1</manvolnum>
1909       </citerefentry> provided charset. If a character cannot be converted
1910     from the <option>mac charset</option> to the selected <option>vol
1911     charset</option>, afpd will save it as a CAP encoded character. For AFP3
1912     clients, <command>afpd</command> will convert the UTF-8<indexterm>
1913         <primary>UTF8</primary>
1914
1915         <secondary>afpd's vol charset setting</secondary>
1916       </indexterm><indexterm>
1917         <primary>UTF8-MAC</primary>
1918
1919         <secondary>afpd's vol charset setting</secondary>
1920       </indexterm><indexterm>
1921         <primary>ISO-8859-15</primary>
1922
1923         <secondary>afpd's vol charset setting</secondary>
1924       </indexterm><indexterm>
1925         <primary>ISO-8859-1</primary>
1926
1927         <secondary>afpd's vol charset setting</secondary>
1928       </indexterm> character to <option>mac charset</option> first. If this
1929     conversion fails, you'll receive a -50 error on the mac.</para>
1930
1931     <para><emphasis>Note</emphasis>: Whenever you can, please stick with the
1932     default UTF-8 volume format.</para>
1933   </refsect1>
1934
1935   <refsect1>
1936     <title>SEE ALSO</title>
1937
1938     <para><citerefentry>
1939         <refentrytitle>afpd</refentrytitle>
1940
1941         <manvolnum>8</manvolnum>
1942       </citerefentry>, <citerefentry>
1943         <refentrytitle>afppasswd</refentrytitle>
1944
1945         <manvolnum>5</manvolnum>
1946       </citerefentry>, <citerefentry>
1947         <refentrytitle>afp_signature.conf</refentrytitle>
1948
1949         <manvolnum>5</manvolnum>
1950       </citerefentry>, <citerefentry>
1951         <refentrytitle>extmap.conf</refentrytitle>
1952
1953         <manvolnum>5</manvolnum>
1954       </citerefentry>, <citerefentry>
1955         <refentrytitle>cnid_metad</refentrytitle>
1956
1957         <manvolnum>8</manvolnum>
1958       </citerefentry></para>
1959   </refsect1>
1960 </refentry>