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="ctdbd.conf.5">
9 <refentrytitle>ctdbd.conf</refentrytitle>
10 <manvolnum>5</manvolnum>
11 <refmiscinfo class="source">ctdb</refmiscinfo>
12 <refmiscinfo class="manual">CTDB - clustered TDB database</refmiscinfo>
16 <refname>ctdbd.conf</refname>
17 <refpurpose>CTDB daemon configuration file</refpurpose>
21 <title>DESCRIPTION</title>
24 This file contains CTDB configuration variables that are affect
25 the operation of CTDB. The default location of this file is
26 <filename>/usr/local/etc/ctdb/ctdbd.conf</filename>.
30 This file is a shell script (see
31 <citerefentry><refentrytitle>sh</refentrytitle>
32 <manvolnum>1</manvolnum></citerefentry>) but is usually limited
33 to simple variable assignments and shell-style comments.
37 CTDB configuration variables are grouped into several categories below.
41 Variables defined in this document can also be set in a
42 distribution-specific configuration file such as
43 <filename>/etc/sysconfig/ctdb</filename> (Red Hat) or
44 <filename>/etc/default/ctdb</filename> (Debian). However, these
45 files should be reserved for variables used by the initscript.
46 A historical alternative is
47 <filename>/usr/local/etc/ctdb/sysconfig/ctdb</filename> - this is
59 These options may be used in the initscripts, daemon and
60 scripts. If any of these options are required then they should
61 be set in the distribution-specific initscript configuration,
62 such as <filename>/etc/sysconfig/ctdb</filename> or
63 <filename>/etc/default/ctdb</filename>.
69 <term>CTDB_INIT_STYLE=debian|redhat|suse</term>
72 This is the init style used by the Linux distribution (or
73 other operating system) being used. This is usually
74 determined dynamically by checking the system. This
75 variable is used by the initscript to determine which init
76 system primitives to use. It is also used by some
77 eventscripts to choose the name of initscripts for certain
78 services, since these can vary between distributions.
84 If this option needs to be changed from the calculated
85 default for the initscript to function properly, then it
86 must be set in the distribution-specific initscript
87 configuration, such as
88 <filename>/etc/sysconfig/ctdb</filename>
102 Variables in this section are processed by
103 <citerefentry><refentrytitle>ctdbd_wrapper</refentrytitle>
104 <manvolnum>1</manvolnum></citerefentry> and are converted into
105 command-line arguments to
106 <citerefentry><refentrytitle>ctdbd</refentrytitle>
107 <manvolnum>1</manvolnum></citerefentry>. Correspondence with
108 <citerefentry><refentrytitle>ctdbd</refentrytitle>
109 <manvolnum>1</manvolnum></citerefentry> options is shown for
110 each variable. The the documentation for the relevant options
115 Many of these variables are also used by event scripts.
121 <term>CTDB_CAPABILITY_LMASTER=yes|no</term>
124 Defaults to yes. Corresponds to <option>--no-lmaster</option>.
130 <term>CTDB_CAPABILITY_RECMASTER=yes|no</term>
133 Defaults to yes. Corresponds to
134 <option>--no-recmaster</option>.
140 <term>CTDB_DBDIR=<parameter>DIRECTORY</parameter></term>
143 Defaults to <filename>/usr/local/var/lib/ctdb</filename>.
146 Apart from a DIRECTORY, this can take a special value of
148 <option>tmpfs</option><optional>:<parameter>OPTIONS</parameter></optional>.
149 OPTIONS is a comma-separated list of any permissible
150 options to the tmpfs filesystem. The only pre-specified
151 default is <option>mode=700</option>, which can
152 overridden by specifying <option>mode</option> in
153 OPTIONS. It probably makes sense to specify a maximum
154 <option>size</option>.
157 Corresponds to <option>--dbdir</option>.
163 <term>CTDB_DBDIR_PERSISTENT=<parameter>DIRECTORY</parameter></term>
166 Defaults to <filename>/usr/local/var/lib/ctdb/persistent</filename>.
169 Corresponds to <option>--dbdir-persistent</option>.
175 <term>CTDB_DBDIR_STATE=<parameter>DIRECTORY</parameter></term>
178 Defaults to <filename>/usr/local/var/lib/ctdb/state</filename>.
181 Corresponds to <option>--dbdir-state</option>.
187 <term>CTDB_DEBUG_HUNG_SCRIPT=<parameter>FILENAME</parameter></term>
190 FILENAME is a script to run to log debug information when
191 an event script times out.
194 Default is <filename>/usr/local/etc/ctdb/debug-hung-script.sh</filename>.
200 <term>CTDB_DEBUG_HUNG_SCRIPT_STACKPAT=<parameter>REGEXP</parameter></term>
203 REGEXP specifies interesting processes for which stack
204 traces should be logged when debugging hung eventscripts
205 and those processes are matched in pstree output. REGEXP
206 is an extended regexp so choices are separated by pipes
207 ('|'). However, REGEXP should not contain parentheses.
208 See also <citetitle>CTDB_DEBUG_HUNG_SCRIPT</citetitle>.
211 Default is "exportfs|rpcinfo".
217 <term>CTDB_DEBUG_LOCKS=<parameter>FILENAME</parameter></term>
220 FILENAME is a script to run to log debug information when
221 an CTDB fails to freeze databases during recovery.
225 <filename>/usr/local/etc/ctdb/debug_locks.sh</filename>.
231 <term>CTDB_DEBUGLEVEL=<parameter>DEBUGLEVEL</parameter></term>
234 Default is NOTICE. Corresponds to <option>-d</option> or
235 <option>--debug</option>.
241 <term>CTDB_LOGGING=<parameter>STRING</parameter></term>
244 STRING specifies where ctdbd will write its log. The
246 file:<filename>/usr/local/var/log/log.ctdb</filename>.
247 Corresponds to <option>--logging</option>.
254 <term>file:<parameter>FILENAME</parameter></term>
257 FILENAME where ctdbd will write its log. This is usually
258 <filename>/usr/local/var/log/log.ctdb</filename>.
263 <term>syslog<optional>:<parameter>METHOD</parameter></optional></term>
266 CTDB will log to syslog. By default this will use
270 If METHOD is specified then it specifies an
271 extension that causes logging to be done in a
272 non-blocking fashion. This can be useful under
273 heavy loads that might cause the syslog daemon to
274 dequeue messages too slowly, which would otherwise
275 cause CTDB to block when logging. METHOD must be
280 <term>nonblocking</term>
283 CTDB will log to syslog via
284 <filename>/dev/log</filename> in non-blocking
293 CTDB will log to syslog via UDP to
294 localhost:514. The syslog daemon must be
295 configured to listen on (at least)
296 localhost:514. Most implementations will log
297 the messages against hostname "localhost" -
298 this is a limit of the implementation for
299 compatibility with more syslog daemon
305 <term>udp-rfc5424</term>
308 As with "udp" but messages are sent in RFC5424
309 format. This method will log the correct
310 hostname but is not as widely implemented in
323 <term>CTDB_MAX_OPEN_FILES=<parameter>NUM</parameter></term>
326 NUM is the maximum number of open files.
335 <term>CTDB_NOSETSCHED=yes|no</term>
338 Defaults to no. Corresponds to <option>--nosetsched</option>.
341 Usually CTDB runs with real-time priority. If you are running
342 CTDB on a platform that does not support real-time priority,
349 <term>CTDB_NOTIFY_SCRIPT=<parameter>FILENAME</parameter></term>
353 <filename>/usr/local/etc/ctdb/notify.sh</filename>. Corresponds to
354 <option>--notification-script</option>.
360 <term>CTDB_MAX_PERSISTENT_CHECK_ERRORS=<parameter>NUM</parameter></term>
363 Default 0. Corresponds to
364 <option>--max-persistent-check-errors</option>.
370 <term>CTDB_NODE_ADDRESS=<parameter>IPADDR</parameter></term>
373 IPADDR is the private IP address that ctdbd will bind to.
374 Corresponds to <option>--listen</option>.
377 By default ctdbd will select the first address from the
378 nodes list that in can bind to. See also the
379 <citetitle>Private address</citetitle> section in
380 <citerefentry><refentrytitle>ctdb</refentrytitle>
381 <manvolnum>7</manvolnum></citerefentry>.
384 This option is only required when automatic address
385 detection can not be used. This can be the case when
386 running multiple ctdbd daemons/nodes on the same physical
387 host (usually for testing), using InfiniBand for the
388 private network or on Linux when sysctl
389 net.ipv4.ip_nonlocal_bind=1.
395 <term>CTDB_RECOVERY_LOCK=<parameter>LOCK</parameter></term>
398 LOCK specifies the cluster-wide mutex used to detect and
399 prevent a partitioned cluster (or "split brain").
402 No default, but the default configuration file specifies
403 <filename>/some/place/on/shared/storage</filename>, which
404 should be change to a useful value. Corresponds to
405 <option>--reclock</option>.
408 For information about the recovery lock please see the
409 <citetitle>RECOVERY LOCK</citetitle> section in
410 <citerefentry><refentrytitle>ctdb</refentrytitle>
411 <manvolnum>7</manvolnum></citerefentry>.
417 <term>CTDB_SCRIPT_LOG_LEVEL=<parameter>DEBUGLEVEL</parameter></term>
420 Defaults to ERR. Corresponds to
421 <option>--script-log-level</option>.
427 <term>CTDB_START_AS_DISABLED=yes|no</term>
430 Default is no. Corresponds to
431 <option>--start-as-disabled</option>.
437 <term>CTDB_START_AS_STOPPED=yes|no</term>
440 Default is no. Corresponds to
441 <option>--start-as-stopped</option>.
447 <term>CTDB_SUPPRESS_COREFILE=yes|no</term>
450 Whether CTDB core files should be suppressed.
459 <term>CTDB_TRANSPORT=tcp|infiniband</term>
462 Defaults to tcp. Corresponds to
463 <option>--transport</option>.
471 While the following variables do not translate into daemon
472 options they are used by
473 <citerefentry><refentrytitle>ctdbd_wrapper</refentrytitle>
474 <manvolnum>1</manvolnum></citerefentry> when starting and
475 stopping <citerefentry><refentrytitle>ctdbd</refentrytitle>
476 <manvolnum>1</manvolnum></citerefentry>.
482 <term>CTDB_STARTUP_TIMEOUT=<parameter>NUM</parameter></term>
485 NUM is the number of seconds to wait for
486 <citerefentry><refentrytitle>ctdbd</refentrytitle>
487 <manvolnum>1</manvolnum></citerefentry> complete early
488 initialisation up to a point where it is unlikely to
489 abort. If <command>ctdbd</command> doesn't complete the
490 "setup" event before this timeout then it is killed.
503 <title>NETWORK CONFIGURATION</title>
506 <title>NAT GATEWAY</title>
509 NAT gateway is used to configure fallback routing for nodes
510 when they do not host any public IP addresses. For example,
511 it allows unhealthy nodes to reliably communicate with
512 external infrastructure. One node in a NAT gateway group will
513 be designated as the NAT gateway master node and other (slave)
514 nodes will be configured with fallback routes via the NAT
515 gateway master node. For more information, see the
516 <citetitle>NAT GATEWAY</citetitle> section in
517 <citerefentry><refentrytitle>ctdb</refentrytitle>
518 <manvolnum>7</manvolnum></citerefentry>.
524 <term>CTDB_NATGW_DEFAULT_GATEWAY=<parameter>IPADDR</parameter></term>
527 IPADDR is an alternate network gateway to use on the NAT
528 gateway master node. If set, a fallback default route
529 is added via this network gateway.
532 No default. Setting this variable is optional - if not
533 set that no route is created on the NAT gateway master
540 <term>CTDB_NATGW_NODES=<parameter>FILENAME</parameter></term>
543 FILENAME contains the list of nodes that belong to the
544 same NAT gateway group.
549 <parameter>IPADDR</parameter> <optional>slave-only</optional>
553 IPADDR is the private IP address of each node in the NAT
557 If "slave-only" is specified then the corresponding node
558 can not be the NAT gateway master node. In this case
559 <varname>CTDB_NATGW_PUBLIC_IFACE</varname> and
560 <varname>CTDB_NATGW_PUBLIC_IP</varname> are optional and
565 <filename>/usr/local/etc/ctdb/natgw_nodes</filename> when enabled.
571 <term>CTDB_NATGW_PRIVATE_NETWORK=<parameter>IPADDR/MASK</parameter></term>
574 IPADDR/MASK is the private sub-network that is
575 internally routed via the NAT gateway master node. This
576 is usually the private network that is used for node
586 <term>CTDB_NATGW_PUBLIC_IFACE=<parameter>IFACE</parameter></term>
589 IFACE is the network interface on which the
590 CTDB_NATGW_PUBLIC_IP will be configured.
599 <term>CTDB_NATGW_PUBLIC_IP=<parameter>IPADDR/MASK</parameter></term>
602 IPADDR/MASK indicates the IP address that is used for
603 outgoing traffic (originating from
604 CTDB_NATGW_PRIVATE_NETWORK) on the NAT gateway master
605 node. This <emphasis>must not</emphasis> be a
606 configured public IP address.
615 <term>CTDB_NATGW_STATIC_ROUTES=<parameter>IPADDR/MASK[@GATEWAY]</parameter> ...</term>
618 Each IPADDR/MASK identifies a network or host to which
619 NATGW should create a fallback route, instead of
620 creating a single default route. This can be used when
621 there is already a default route, via an interface that
622 can not reach required infrastructure, that overrides
623 the NAT gateway default route.
626 If GATEWAY is specified then the corresponding route on
627 the NATGW master node will be via GATEWAY. Such routes
629 <varname>CTDB_NATGW_DEFAULT_GATEWAY</varname> is not
630 specified. If GATEWAY is not specified for some
631 networks then routes are only created on the NATGW
632 master node for those networks if
633 <varname>CTDB_NATGW_DEFAULT_GATEWAY</varname> is
637 This should be used with care to avoid causing traffic
638 to unnecessarily double-hop through the NAT gateway
639 master, even when a node is hosting public IP addresses.
640 Each specified network or host should probably have a
641 corresponding automatically created link route or static
653 <title>Example</title>
655 CTDB_NATGW_NODES=/usr/local/etc/ctdb/natgw_nodes
656 CTDB_NATGW_PRIVATE_NETWORK=192.168.1.0/24
657 CTDB_NATGW_DEFAULT_GATEWAY=10.0.0.1
658 CTDB_NATGW_PUBLIC_IP=10.0.0.227/24
659 CTDB_NATGW_PUBLIC_IFACE=eth0
663 A variation that ensures that infrastructure (ADS, DNS, ...)
664 directly attached to the public network (10.0.0.0/24) is
665 always reachable would look like this:
668 CTDB_NATGW_NODES=/usr/local/etc/ctdb/natgw_nodes
669 CTDB_NATGW_PRIVATE_NETWORK=192.168.1.0/24
670 CTDB_NATGW_PUBLIC_IP=10.0.0.227/24
671 CTDB_NATGW_PUBLIC_IFACE=eth0
672 CTDB_NATGW_STATIC_ROUTES=10.0.0.0/24
675 Note that <varname>CTDB_NATGW_DEFAULT_GATEWAY</varname> is
683 <title>POLICY ROUTING</title>
686 A node running CTDB may be a component of a complex network
687 topology. In particular, public addresses may be spread
688 across several different networks (or VLANs) and it may not be
689 possible to route packets from these public addresses via the
690 system's default route. Therefore, CTDB has support for
691 policy routing via the <filename>13.per_ip_routing</filename>
692 eventscript. This allows routing to be specified for packets
693 sourced from each public address. The routes are added and
694 removed as CTDB moves public addresses between nodes.
698 For more information, see the <citetitle>POLICY
699 ROUTING</citetitle> section in
700 <citerefentry><refentrytitle>ctdb</refentrytitle>
701 <manvolnum>7</manvolnum></citerefentry>.
706 <term>CTDB_PER_IP_ROUTING_CONF=<parameter>FILENAME</parameter></term>
709 FILENAME contains elements for constructing the desired
710 routes for each source address.
714 The special FILENAME value
715 <constant>__auto_link_local__</constant> indicates that no
716 configuration file is provided and that CTDB should
717 generate reasonable link-local routes for each public IP
724 <parameter>IPADDR</parameter> <parameter>DEST-IPADDR/MASK</parameter> <optional><parameter>GATEWAY-IPADDR</parameter></optional>
730 <filename>/usr/local/etc/ctdb/policy_routing</filename> when enabled.
736 <term>CTDB_PER_IP_ROUTING_RULE_PREF=<parameter>NUM</parameter></term>
739 NUM sets the priority (or preference) for the routing
740 rules that are added by CTDB.
744 This should be (strictly) greater than 0 and (strictly)
745 less than 32766. A priority of 100 is recommended, unless
746 this conflicts with a priority already in use on the
748 <citerefentry><refentrytitle>ip</refentrytitle>
749 <manvolnum>8</manvolnum></citerefentry>, for more details.
756 CTDB_PER_IP_ROUTING_TABLE_ID_LOW=<parameter>LOW-NUM</parameter>,
757 CTDB_PER_IP_ROUTING_TABLE_ID_HIGH=<parameter>HIGH-NUM</parameter>
761 CTDB determines a unique routing table number to use for
762 the routing related to each public address. LOW-NUM and
763 HIGH-NUM indicate the minimum and maximum routing table
764 numbers that are used.
768 <citerefentry><refentrytitle>ip</refentrytitle>
769 <manvolnum>8</manvolnum></citerefentry> uses some
770 reserved routing table numbers below 255. Therefore,
771 CTDB_PER_IP_ROUTING_TABLE_ID_LOW should be (strictly)
776 CTDB uses the standard file
777 <filename>/etc/iproute2/rt_tables</filename> to maintain
778 a mapping between the routing table numbers and labels.
779 The label for a public address
780 <replaceable>ADDR</replaceable> will look like
781 ctdb.<replaceable>addr</replaceable>. This means that
782 the associated rules and routes are easy to read (and
787 No default, usually 1000 and 9000.
794 <title>Example</title>
796 CTDB_PER_IP_ROUTING_CONF=/usr/local/etc/ctdb/policy_routing
797 CTDB_PER_IP_ROUTING_RULE_PREF=100
798 CTDB_PER_IP_ROUTING_TABLE_ID_LOW=1000
799 CTDB_PER_IP_ROUTING_TABLE_ID_HIGH=9000
809 For a general description see the <citetitle>LVS</citetitle>
810 section in <citerefentry><refentrytitle>ctdb</refentrytitle>
811 <manvolnum>7</manvolnum></citerefentry>.
815 <title>Eventscript</title>
818 <member><filename>91.lvs</filename></member>
825 <term>CTDB_LVS_NODES=<parameter>FILENAME</parameter></term>
828 FILENAME contains the list of nodes that belong to the
834 <parameter>IPADDR</parameter> <optional>slave-only</optional>
838 IPADDR is the private IP address of each node in the LVS
842 If "slave-only" is specified then the corresponding node
843 can not be the LVS master node. In this case
844 <varname>CTDB_LVS_PUBLIC_IFACE</varname> and
845 <varname>CTDB_LVS_PUBLIC_IP</varname> are optional and
850 <filename>/usr/local/etc/ctdb/lvs_nodes</filename> when enabled.
856 <term>CTDB_LVS_PUBLIC_IFACE=<parameter>INTERFACE</parameter></term>
859 INTERFACE is the network interface that clients will use
860 to connection to <varname>CTDB_LVS_PUBLIC_IP</varname>.
861 This is optional for slave-only nodes.
868 <term>CTDB_LVS_PUBLIC_IP=<parameter>IPADDR</parameter></term>
871 CTDB_LVS_PUBLIC_IP is the LVS public address. No
881 <title>MISCELLANEOUS NETWORK CONFIGURATION</title>
886 <term>CTDB_PARTIALLY_ONLINE_INTERFACES=yes|no</term>
889 Whether one or more offline interfaces should cause a
890 monitor event to fail if there are other interfaces that
891 are up. If this is "yes" and a node has some interfaces
892 that are down then <command>ctdb status</command> will
893 display the node as "PARTIALLYONLINE".
897 Note that CTDB_PARTIALLY_ONLINE_INTERFACES=yes is
898 incompatible with NAT gateway, since NAT gateway relies
899 on the interface configured by CTDB_NATGW_PUBLIC_IFACE
915 <title>SERVICE CONFIGURATION</title>
918 CTDB can be configured to manage and/or monitor various NAS (and
919 other) services via its eventscripts.
923 In the simplest case CTDB will manage a service. This means the
924 service will be started and stopped along with CTDB, CTDB will
925 monitor the service and CTDB will do any required
926 reconfiguration of the service when public IP addresses are
934 <title>Eventscripts</title>
937 <member><filename>49.winbind</filename></member>
938 <member><filename>50.samba</filename></member>
945 <term>CTDB_MANAGES_SAMBA=yes|no</term>
948 Should CTDB manage Samba?
957 <term>CTDB_MANAGES_WINBIND=yes|no</term>
960 Should CTDB manage Winbind?
969 <term>CTDB_SAMBA_CHECK_PORTS=<parameter>PORT-LIST</parameter></term>
972 When monitoring Samba, check TCP ports in
973 space-separated PORT-LIST.
976 Default is to monitor ports that Samba is configured to listen on.
982 <term>CTDB_SAMBA_SKIP_SHARE_CHECK=yes|no</term>
985 As part of monitoring, should CTDB skip the check for
986 the existence of each directory configured as share in
987 Samba. This may be desirable if there is a large number
997 <term>CTDB_SERVICE_NMB=<parameter>SERVICE</parameter></term>
1000 Distribution specific SERVICE for managing nmbd.
1003 Default is distribution-dependant.
1008 <term>CTDB_SERVICE_SMB=<parameter>SERVICE</parameter></term>
1011 Distribution specific SERVICE for managing smbd.
1014 Default is distribution-dependant.
1020 <term>CTDB_SERVICE_WINBIND=<parameter>SERVICE</parameter></term>
1023 Distribution specific SERVICE for managing winbindd.
1026 Default is "winbind".
1039 This includes parameters for the kernel NFS server.
1040 Alternative NFS subsystems (such as <ulink
1041 url="https://github.com/nfs-ganesha/nfs-ganesha/wiki">NFS-Ganesha</ulink>)
1042 can be integrated using <varname>CTDB_NFS_CALLOUT</varname>.
1046 <title>Eventscript</title>
1049 <member><filename>60.nfs</filename></member>
1056 <term>CTDB_MANAGES_NFS=yes|no</term>
1059 Should CTDB manage NFS?
1068 <term>CTDB_NFS_CALLOUT=<parameter>COMMAND</parameter></term>
1071 COMMAND specifies the path to a callout to handle
1072 interactions with the configured NFS system, including
1073 startup, shutdown, monitoring.
1076 Default is the included
1077 <command>nfs-linux-kernel-callout</command>.
1083 <term>CTDB_NFS_CHECKS_DIR=<parameter>DIRECTORY</parameter></term>
1086 Specifies the path to a DIRECTORY containing files that
1087 describe how to monitor the responsiveness of NFS RPC
1088 services. See the README file for this directory for an
1089 explanation of the contents of these "check" files.
1092 CTDB_NFS_CHECKS_DIR can be used to point to different
1093 sets of checks for different NFS servers.
1096 One way of using this is to have it point to, say,
1097 <filename>/usr/local/etc/ctdb/nfs-checks-enabled.d</filename>
1098 and populate it with symbolic links to the desired check
1099 files. This avoids duplication and is upgrade-safe.
1103 <filename>/usr/local/etc/ctdb/nfs-checks.d</filename>,
1104 which contains NFS RPC checks suitable for Linux kernel
1111 <term>CTDB_NFS_SKIP_SHARE_CHECK=yes|no</term>
1114 As part of monitoring, should CTDB skip the check for
1115 the existence of each directory exported via NFS. This
1116 may be desirable if there is a large number of exports.
1125 <term>CTDB_RPCINFO_LOCALHOST=<parameter>IPADDR</parameter>|<parameter>HOSTNAME</parameter></term>
1128 IPADDR or HOSTNAME indicates the address that
1129 <command>rpcinfo</command> should connect to when doing
1130 <command>rpcinfo</command> check on IPv4 RPC service during
1131 monitoring. Optimally this would be "localhost".
1132 However, this can add some performance overheads.
1135 Default is "127.0.0.1".
1141 <term>CTDB_RPCINFO_LOCALHOST6=<parameter>IPADDR</parameter>|<parameter>HOSTNAME</parameter></term>
1144 IPADDR or HOSTNAME indicates the address that
1145 <command>rpcinfo</command> should connect to when doing
1146 <command>rpcinfo</command> check on IPv6 RPC service
1147 during monitoring. Optimally this would be "localhost6"
1148 (or similar). However, this can add some performance
1158 <term>CTDB_NFS_STATE_FS_TYPE=<parameter>TYPE</parameter></term>
1161 The type of filesystem used for a clustered NFS' shared
1168 <term>CTDB_NFS_STATE_MNT=<parameter>DIR</parameter></term>
1171 The directory where a clustered NFS' shared state will be
1172 located. No default.
1182 <title>APACHE HTTPD</title>
1185 CTDB can manage the Apache web server.
1189 <title>Eventscript</title>
1192 <member><filename>41.httpd</filename></member>
1198 <term>CTDB_MANAGES_HTTPD=yes|no</term>
1201 Should CTDB manage the Apache web server?
1212 <title>CLAMAV</title>
1215 CTDB has support to manage the popular anti-virus daemon
1220 <title>Eventscript</title>
1223 <member><filename>31.clamd</filename></member>
1227 This eventscript is not enabled by default. Use
1228 <command>ctdb enablescript</command> to enable it.
1236 <term>CTDB_MANAGES_CLAMD=yes|no</term>
1239 Should CTDB manage ClamAV?
1248 <term>CTDB_CLAMD_SOCKET=<parameter>FILENAME</parameter></term>
1251 FILENAME is the socket to monitor ClamAV.
1264 <title>ISCSI</title>
1267 CTDB has support for managing the Linux iSCSI tgtd service.
1271 <title>Eventscript</title>
1274 <member><filename>70.iscsi</filename></member>
1281 <term>CTDB_MANAGES_ISCSI=yes|no</term>
1284 Should CTDB manage iSCSI tgtd?
1293 <term>CTDB_START_ISCSI_SCRIPTS=<parameter>DIRECTORY</parameter></term>
1296 DIRECTORY on shared storage containing scripts to start
1297 tgtd for each public IP address.
1308 <title>MULTIPATHD</title>
1311 CTDB can monitor multipath devices to ensure that active paths
1316 <title>Eventscript</title>
1319 <member><filename>20.multipathd</filename></member>
1323 This eventscript is not enabled by default. Use
1324 <command>ctdb enablescript</command> to enable it.
1330 <term>CTDB_MONITOR_MPDEVICES=<parameter>MP-DEVICE-LIST</parameter></term>
1333 MP-DEVICE-LIST is a list of multipath devices for CTDB to monitor?
1344 <title>VSFTPD</title>
1347 CTDB can manage the vsftpd FTP server.
1351 <title>Eventscript</title>
1354 <member><filename>40.vsftpd</filename></member>
1360 <term>CTDB_MANAGES_VSFTPD=yes|no</term>
1363 Should CTDB manage the vsftpd FTP server?
1379 CTDB checks the consistency of databases during startup.
1383 <title>Eventscripts</title>
1386 <member><filename>00.ctdb</filename></member>
1394 <term>CTDB_MAX_CORRUPT_DB_BACKUPS=<parameter>NUM</parameter></term>
1397 NUM is the maximum number of volatile TDB database backups
1398 to be kept (for each database) when a corrupt database is
1399 found during startup. Volatile TDBs are zeroed during
1400 startup so backups are needed to debug any corruption that
1401 occurs before a restart.
1414 SYSTEM RESOURCE MONITORING CONFIGURATION
1418 CTDB can experience seemingly random (performance and other)
1419 issues if system resources become too constrained. Options in
1420 this section can be enabled to allow certain system resources
1421 to be checked. They allows warnings to be logged and nodes to
1422 be marked unhealthy when system resource usage reaches the
1423 configured thresholds.
1427 Some checks are enabled by default. It is recommended that
1428 these checks remain enabled or are augmented by extra checks.
1429 There is no supported way of completely disabling the checks.
1433 <title>Eventscripts</title>
1436 <member><filename>05.system</filename></member>
1440 Filesystem and memory usage monitoring is in
1441 <filename>05.system</filename>.
1448 <term>CTDB_MONITOR_FILESYSTEM_USAGE=<parameter>FS-LIMIT-LIST</parameter></term>
1451 FS-LIMIT-LIST is a space-separated list of
1452 <parameter>FILESYSTEM</parameter>:<parameter>WARN_LIMIT</parameter><optional>:<parameter>UNHEALTHY_LIMIT</parameter></optional>
1453 triples indicating that warnings should be logged if the
1454 space used on FILESYSTEM reaches WARN_LIMIT%. If usage
1455 reaches UNHEALTHY_LIMIT then the node should be flagged
1456 unhealthy. Either WARN_LIMIT or UNHEALTHY_LIMIT may be
1457 left blank, meaning that check will be omitted.
1461 Default is to warn for each filesystem containing a
1462 database directory (<envar>CTDB_DBDIR</envar>,
1463 <envar>CTDB_DBDIR_PERSISTENT</envar>,
1464 <envar>CTDB_DBDIR_STATE</envar>) with a threshold of
1471 <term>CTDB_MONITOR_MEMORY_USAGE=<parameter>MEM-LIMITS</parameter></term>
1474 MEM-LIMITS takes the form
1475 <parameter>WARN_LIMIT</parameter><optional>:<parameter>UNHEALTHY_LIMIT</parameter></optional>
1476 indicating that warnings should be logged if memory
1477 usage reaches WARN_LIMIT%. If usage reaches
1478 UNHEALTHY_LIMIT then the node should be flagged
1479 unhealthy. Either WARN_LIMIT or UNHEALTHY_LIMIT may be
1480 left blank, meaning that check will be omitted.
1483 Default is 80, so warnings will be logged when memory
1490 <term>CTDB_MONITOR_SWAP_USAGE=<parameter>SWAP-LIMITS</parameter></term>
1493 SWAP-LIMITS takes the form
1494 <parameter>WARN_LIMIT</parameter><optional>:<parameter>UNHEALTHY_LIMIT</parameter></optional>
1495 indicating that warnings should be logged if
1496 swap usage reaches WARN_LIMIT%. If usage reaches
1497 UNHEALTHY_LIMIT then the node should be flagged
1498 unhealthy. Either WARN_LIMIT or UNHEALTHY_LIMIT may be
1499 left blank, meaning that check will be omitted.
1502 Default is 25, so warnings will be logged when swap
1519 Variable in this section are for testing CTDB. They should not
1520 generally be needed.
1526 <term>CTDB_DEBUG_HUNG_SCRIPT_LOGFILE=<parameter>FILENAME</parameter></term>
1529 FILENAME specifies where log messages should go when
1530 debugging hung eventscripts. This is a testing option.
1531 See also <citetitle>CTDB_DEBUG_HUNG_SCRIPT</citetitle>.
1534 No default. Messages go to stdout/stderr and are logged
1535 to the same place as other CTDB log messages.
1541 <term>CTDB_SYS_ETCDIR=<parameter>DIRECTORY</parameter></term>
1544 DIRECTORY containing system configuration files. This is
1545 used to provide alternate configuration when testing and
1546 should not need to be changed from the default.
1549 Default is <filename>/etc</filename>.
1555 <term>CTDB_RUN_TIMEOUT_MONITOR=yes|no</term>
1558 Whether CTDB should simulate timing out monitor events.
1559 This uses the <filename>99.timeout</filename> eventscript.
1568 <term>CTDB_VALGRIND=yes|no|<parameter>COMMAND</parameter></term>
1571 If "yes", this causes
1572 <citerefentry><refentrytitle>ctdbd</refentrytitle>
1573 <manvolnum>1</manvolnum></citerefentry> to be run under
1574 <citerefentry><refentrytitle>valgrind</refentrytitle>
1575 <manvolnum>1</manvolnum></citerefentry> with logs going to
1576 <filename>/usr/local/var/log/ctdb_valgrind</filename>. If neither
1577 "yes" nor "no" then the value is assumed to be a COMMAND
1578 (e.g. a <command>valgrind</command> variation, a
1579 <citerefentry><refentrytitle>gdb</refentrytitle>
1580 <manvolnum>1</manvolnum></citerefentry> command) that is
1581 used in place of the default <command>valgrind</command>
1582 command. In either case, the <option>--valgrind</option>
1583 option is passed to <command>ctdbd</command>.
1592 <term>CTDB_VARDIR=<parameter>DIRECTORY</parameter></term>
1595 DIRECTORY containing CTDB files that are modified at
1599 Defaults to <filename>/usr/local/var/lib/ctdb</filename>.
1610 <title>FILES</title>
1613 <member><filename>/usr/local/etc/ctdb/ctdbd.conf</filename></member>
1614 <member><filename>/etc/sysconfig/ctdb</filename></member>
1615 <member><filename>/etc/default/ctdb</filename></member>
1620 <title>SEE ALSO</title>
1622 <citerefentry><refentrytitle>ctdbd</refentrytitle>
1623 <manvolnum>1</manvolnum></citerefentry>,
1625 <citerefentry><refentrytitle>ctdbd_wrapper</refentrytitle>
1626 <manvolnum>1</manvolnum></citerefentry>,
1628 <citerefentry><refentrytitle>onnode</refentrytitle>
1629 <manvolnum>1</manvolnum></citerefentry>,
1631 <citerefentry><refentrytitle>ctdb</refentrytitle>
1632 <manvolnum>7</manvolnum></citerefentry>,
1634 <citerefentry><refentrytitle>ctdb-tunables</refentrytitle>
1635 <manvolnum>7</manvolnum></citerefentry>,
1637 <ulink url="http://ctdb.samba.org/"/>
1644 This documentation was written by
1652 <holder>Andrew Tridgell</holder>
1653 <holder>Ronnie Sahlberg</holder>
1657 This program is free software; you can redistribute it and/or
1658 modify it under the terms of the GNU General Public License as
1659 published by the Free Software Foundation; either version 3 of
1660 the License, or (at your option) any later version.
1663 This program is distributed in the hope that it will be
1664 useful, but WITHOUT ANY WARRANTY; without even the implied
1665 warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
1666 PURPOSE. See the GNU General Public License for more details.
1669 You should have received a copy of the GNU General Public
1670 License along with this program; if not, see
1671 <ulink url="http://www.gnu.org/licenses"/>.