1 <?xml version="1.0" encoding="iso-8859-1"?>
3 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
4 "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd">
6 <refentry id="ctdb.conf.5">
9 <refentrytitle>ctdb.conf</refentrytitle>
10 <manvolnum>5</manvolnum>
11 <refmiscinfo class="source">ctdb</refmiscinfo>
12 <refmiscinfo class="manual">CTDB - clustered TDB database</refmiscinfo>
16 <refname>ctdb.conf</refname>
17 <refpurpose>CTDB configuration file</refpurpose>
21 <title>DESCRIPTION</title>
24 This file contains CTDB configuration options that affect the
25 operation of CTDB daemons and command-line tools. The default
26 location of this file is
27 <filename>/usr/local/etc/ctdb/ctdb.conf</filename>.
31 Note that this is a Samba-style configuration file, so it has a
32 very different syntax to previous CTDB configuration files.
36 For event script options please see
37 <citerefentry><refentrytitle>ctdb-script.options</refentrytitle>
38 <manvolnum>5</manvolnum></citerefentry>.
42 Configuration options are grouped into several sections below.
43 There are only a few options in each section, allowing them to
44 be ordered (approximately) in decreasing order of importance.
55 Options in this section control CTDB's logging. They are valid
56 within the <emphasis>logging</emphasis> section of file,
57 indicated by <literal>[logging]</literal>.
63 <term>log level = <parameter>LOGLEVEL</parameter></term>
66 LOGLEVEL is a string that controls the verbosity of
67 ctdbd's logging. See the <citetitle>LOG
68 LEVELS</citetitle> section in
69 <citerefentry><refentrytitle>ctdb</refentrytitle>
70 <manvolnum>7</manvolnum></citerefentry> for more details.
73 Default: <literal>NOTICE</literal>
79 <term>location = <parameter>STRING</parameter></term>
82 STRING specifies where ctdbd will write its log.
89 <term>file:<parameter>FILENAME</parameter></term>
92 FILENAME where ctdbd will write its log. This is usually
93 <filename>/usr/local/var/log/log.ctdb</filename>.
98 <term>syslog<optional>:<parameter>METHOD</parameter></optional></term>
101 CTDB will log to syslog. By default this will use
105 If METHOD is specified then it specifies an
106 extension that causes logging to be done in a
107 non-blocking fashion. This can be useful under
108 heavy loads that might cause the syslog daemon to
109 dequeue messages too slowly, which would otherwise
110 cause CTDB to block when logging. METHOD must be
115 <term>nonblocking</term>
118 CTDB will log to syslog via
119 <filename>/dev/log</filename> in non-blocking
128 CTDB will log to syslog via UDP to
129 localhost:514. The syslog daemon must be
130 configured to listen on (at least)
131 localhost:514. Most implementations will log
132 the messages against hostname "localhost" -
133 this is a limit of the implementation for
134 compatibility with more syslog daemon
140 <term>udp-rfc5424</term>
143 As with "udp" but messages are sent in RFC5424
144 format. This method will log the correct
145 hostname but is not as widely implemented in
156 file:<filename>/usr/local/var/log/log.ctdb</filename>
166 CLUSTER CONFIGURATION
170 Options in this section affect the CTDB cluster setup. They
171 are valid within the <emphasis>cluster</emphasis> section of
172 file, indicated by <literal>[cluster]</literal>.
178 <term>recovery lock = <parameter>LOCK</parameter></term>
181 LOCK specifies the cluster-wide mutex used to detect and
182 prevent a partitioned cluster (or "split brain").
185 For information about the recovery lock please see the
186 <citetitle>RECOVERY LOCK</citetitle> section in
187 <citerefentry><refentrytitle>ctdb</refentrytitle>
188 <manvolnum>7</manvolnum></citerefentry>.
191 Default: NONE. However, uses of a recovery lock is
192 <emphasis>strongly recommended</emphasis>.
198 <term>node address = <parameter>IPADDR</parameter></term>
201 IPADDR is the private IP address that ctdbd will bind to.
204 This option is only required when automatic address
205 detection can not be used. This can be the case when
206 running multiple ctdbd daemons/nodes on the same physical
207 host (usually for testing), using InfiniBand for the
208 private network or on Linux when sysctl
209 net.ipv4.ip_nonlocal_bind=1.
212 Default: CTDB selects the first address from the nodes
213 list that it can bind to. See also the <citetitle>PRIVATE
214 ADDRESS</citetitle> section in
215 <citerefentry><refentrytitle>ctdb</refentrytitle>
216 <manvolnum>7</manvolnum></citerefentry>.
222 <term>transport = tcp|ib</term>
225 This option specifies which transport to use for ctdbd
226 internode communications on the private network.
229 <literal>ib</literal> means InfiniBand. The InfiniBand
230 support is not regularly tested. If it is known to be
231 broken then it may be disabled so that a value of
232 <literal>ib</literal> is considered invalid.
235 Default: <literal>tcp</literal>
245 DATABASE CONFIGURATION
249 Options in this section affect the CTDB database setup. They
250 are valid within the <emphasis>database</emphasis> section of
251 file, indicated by <literal>[database]</literal>.
257 <term>volatile database directory = <parameter>DIRECTORY</parameter></term>
260 DIRECTORY on local storage where CTDB keeps a local copy
261 of volatile TDB databases. This directory is local for
262 each node and should not be stored on the shared cluster
266 Mounting a tmpfs (or similar memory filesystem) on this
267 directory can provide a significant performance
268 improvement when there is I/O contention on the local
272 Default: <filename>/usr/local/var/lib/ctdb/volatile</filename>
278 <term>persistent database directory=<parameter>DIRECTORY</parameter></term>
281 DIRECTORY on local storage where CTDB keeps a local copy
282 of persistent TDB databases. This directory is local for
283 each node and should not be stored on the shared cluster
287 Default: <filename>/usr/local/var/lib/ctdb/persistent</filename>
293 <term>state database directory = <parameter>DIRECTORY</parameter></term>
296 DIRECTORY on local storage where CTDB keeps a local copy
297 of internal state TDB databases. This directory is local
298 for each node and should not be stored on the shared
302 Default: <filename>/usr/local/var/lib/ctdb/state</filename>
308 <term>lock debug script = <parameter>FILENAME</parameter></term>
311 FILENAME is a script used by CTDB's database locking code
312 to attempt to provide debugging information when CTDB is
313 unable to lock an entire database or a record.
316 This script should be a bare filename relative to the CTDB
317 configuration directory
318 (<filename>/usr/local/etc/ctdb/</filename>). Any
319 directory prefix is ignored and the path is calculated
320 relative to this directory.
323 CTDB provides a lock debugging script and installs it as
324 <filename>/usr/local/etc/ctdb/debug_locks.sh</filename>.
337 EVENT HANDLING CONFIGURATION
341 Options in this section affect CTDB event handling. They are
342 valid within the <emphasis>event</emphasis> section of file,
343 indicated by <literal>[event]</literal>.
349 <term>debug script = <parameter>FILENAME</parameter></term>
352 FILENAME is a script used by CTDB's event handling code to
353 attempt to provide debugging information when an event
357 This script should be a bare filename relative to the CTDB
358 configuration directory
359 (<filename>/usr/local/etc/ctdb/</filename>). Any
360 directory prefix is ignored and the path is calculated
361 relative to this directory.
364 CTDB provides a script for debugging timed out event
365 scripts and installs it as
366 <filename>/usr/local/etc/ctdb/debug-hung-script.sh</filename>.
383 Options in this section affect legacy CTDB setup. They are valid
384 within the <emphasis>legacy</emphasis> section of file,
385 indicated by <literal>[legacy]</literal>.
391 <term>ctdb start as stopped = true|false</term>
394 If set to <literal>true</literal> CTDB starts in the
398 To allow the node to take part in the cluster it must be
399 manually continued with the the <command>ctdb
400 continue</command> command.
403 Please see the <citetitle>NODE STATES</citetitle> section
404 in <citerefentry><refentrytitle>ctdb</refentrytitle>
405 <manvolnum>7</manvolnum></citerefentry> for more
406 information about the STOPPED state.
409 Default: <literal>false</literal>
415 <term>start as disabled = true|false</term>
418 If set to <literal>true</literal> CTDB starts in the
422 To allow the node to host public IP addresses and
423 services, it must be manually enabled using the
424 <command>ctdb enable</command> command.
427 Please see the <citetitle>NODE STATES</citetitle> section
428 in <citerefentry><refentrytitle>ctdb</refentrytitle>
429 <manvolnum>7</manvolnum></citerefentry> for more
430 information about the DISABLED state.
433 Default: <literal>false</literal>
439 <term>no realtime = true|false</term>
442 Usually CTDB runs with real-time priority. This helps it
443 to perform effectively on a busy system, such as when
444 there are thousands of Samba clients. If you are running
445 CTDB on a platform that does not support real-time
446 priority, you can set this to <literal>true</literal>.
449 Default: <literal>false</literal>
455 <term>recmaster capability = true|false</term>
458 Indicates whether a node can become the recovery master
459 for the cluster. If this is set to
460 <literal>false</literal> then the node will not be able to
461 become the recovery master for the cluster. This feature
462 is primarily used for making a cluster span across a WAN
463 link and use CTDB as a WAN-accelerator.
466 Please see the <citetitle>REMOTE CLUSTER NODES</citetitle>
468 <citerefentry><refentrytitle>ctdb</refentrytitle>
469 <manvolnum>7</manvolnum></citerefentry> for more
473 Default: <literal>true</literal>
479 <term>lmaster capability = true|false</term>
482 Indicates whether a node can become a location master for
483 records in a database. If this is set to
484 <literal>false</literal> then the node will not be part of
485 the vnnmap. This feature is primarily used for making a
486 cluster span across a WAN link and use CTDB as a
490 Please see the <citetitle>REMOTE CLUSTER NODES</citetitle>
492 <citerefentry><refentrytitle>ctdb</refentrytitle>
493 <manvolnum>7</manvolnum></citerefentry> for more
497 Default: <literal>true</literal>
503 <term>script log level = <parameter>LOGLEVEL</parameter></term>
506 This option sets the debug level of event script output to
510 See the <citetitle>DEBUG LEVELS</citetitle> section in
511 <citerefentry><refentrytitle>ctdb</refentrytitle>
512 <manvolnum>7</manvolnum></citerefentry> for more
516 Default: <literal>ERROR</literal>
529 <member><filename>/usr/local/etc/ctdb/ctdb.conf</filename></member>
534 <title>SEE ALSO</title>
536 <citerefentry><refentrytitle>ctdbd</refentrytitle>
537 <manvolnum>1</manvolnum></citerefentry>,
539 <citerefentry><refentrytitle>onnode</refentrytitle>
540 <manvolnum>1</manvolnum></citerefentry>,
542 <citerefentry><refentrytitle>ctdb.sysconfig</refentrytitle>
543 <manvolnum>5</manvolnum></citerefentry>,
545 <citerefentry><refentrytitle>ctdb-script.options</refentrytitle>
546 <manvolnum>5</manvolnum></citerefentry>,
548 <citerefentry><refentrytitle>ctdb</refentrytitle>
549 <manvolnum>7</manvolnum></citerefentry>,
551 <citerefentry><refentrytitle>ctdb-tunables</refentrytitle>
552 <manvolnum>7</manvolnum></citerefentry>,
554 <ulink url="http://ctdb.samba.org/"/>
561 This documentation was written by
569 <holder>Andrew Tridgell</holder>
570 <holder>Ronnie Sahlberg</holder>
574 This program is free software; you can redistribute it and/or
575 modify it under the terms of the GNU General Public License as
576 published by the Free Software Foundation; either version 3 of
577 the License, or (at your option) any later version.
580 This program is distributed in the hope that it will be
581 useful, but WITHOUT ANY WARRANTY; without even the implied
582 warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
583 PURPOSE. See the GNU General Public License for more details.
586 You should have received a copy of the GNU General Public
587 License along with this program; if not, see
588 <ulink url="http://www.gnu.org/licenses"/>.