As of version 0.8, Galera Cluster accepts parameters as semicolon-separated key value pair lists, such as key1 = value1; key2 = value2. In this way, you can configure an arbitrary number of Galera Cluster parameters in one call. A key consists of parameter group and parameter name:
<group>.<name>
Where <group> roughly corresponds to some Galera module.
Table legend:
Parameter | Default | Introduced | Deprecated | Dynamic |
---|---|---|---|---|
protonet.backend | asio | 1.0 | n/a | No |
protonet.version | 0 | 1.0 | n/a | No |
socket.ssl_cert | 1.0 | n/a | No | |
socket.ssl_key | 1.0 | n/a | No | |
socket.ssl_compression | yes | 1.0 | n/a | No |
socket.ssl_cipher | AES128-SHA | 1.0 | n/a | No |
gmcast.listen_addr | tcp://0.0.0.0:4567 | 1.0 | n/a | No |
gmcast.mcast_addr | 1.0 | n/a | No | |
gmcast.mcast_ttl | 1 | 1.0 | n/a | No |
gmcast.peer_timeout | PT3S | 1.0 | n/a | No |
gmcast.time_wait | PT5S | 1.0 | n/a | No |
gmcast.version | 0 | 1.0 | n/a | No |
evs.causal_keepalive_period | 1.0 | n/a | No | |
evs.consensus_timeout | PT30S | 1.0 | Yes, as of 2.0 | No |
evs.debug_log_mask | 0x1 | 1.0 | n/a | Yes |
evs.inactive_check_period | PT1S | 1.0 | n/a | No |
evs.inactive_timeout | PT15S | 1.0 | n/a | No |
evs.info_log_mask | 0 | 1.0 | n/a | No |
evs.install_timeout | PT15S | 1.0 | n/a | Yes |
evs.join_retrans_period | PT1S | 1.0 | n/a | Yes |
evs.keepalive_period | PT1S | 1.0 | n/a | No |
evs.max_install_timeouts | 1 | 1.0 | n/a | No |
evs.send_window | 4 | 1.0 | n/a | Yes |
evs.stats_report_period | PT1M | 1.0 | n/a | No |
evs.suspect_timeout | PT5S | 1.0 | n/a | No |
evs.use_aggregate | true | 1.0 | n/a | No |
evs.user_send_window | 2 | 1.0 | n/a | Yes |
evs.view_forget_timeout | PT5M | 1.0 | n/a | No |
evs.version | 0 | 1.0 | n/a | No |
pc.bootstrap | 1.0 | n/a | No | |
pc.checksum | true | 1.0 | n/a | No |
pc.ignore_sb | false | 1.0 | n/a | Yes |
pc.ignore_quorum | false | 1.0 | n/a | Yes |
pc.linger | PT2S | 1.0 | n/a | No |
pc.npvo | false | 1.0 | n/a | No |
pc.wait_prim | false | 1.0 | n/a | No |
pc.weight | 1 | 2.4 | n/a | Yes |
pc.version | 0 | 1.0 | n/a | No |
gcs.fc_debug | 0 | 1.0 | n/a | No |
gcs.fc_factor | 0.5 | 1.0 | n/a | Yes |
gcs.fc_limit | 16 | 1.0 | n/a | Yes |
gcs.fc_master_slave | NO | 1.0 | n/a | No |
gcs.max_packet_size | 32616 | 1.0 | n/a | No |
gcs.max_throttle | 0.25 | 1.0 | n/a | No |
gcs.recv_q_hard_limit | LLONG_MAX | 1.0 | n/a | No |
gcs.recv_q_soft_limit | 0.25 | 1.0 | n/a | No |
gcs.sync_donor | NO | 1.0 | n/a | No |
ist.recv_addr | 1.0 | n/a | No | |
replicator.commit_order | 3 | 1.0 | n/a | No |
replicator.causal_read_timeout | PT30S | 1.0 | n/a | No |
gcache.dir | 1.0 | n/a | No | |
gcache.name | “galera.cache” | 1.0 | n/a | No |
gcache.size | 128Mb | 1.0 | n/a | No |
gcache.page_size | 128Mb | 1.0 | n/a | No |
gcache.keep_pages_size | 0 | 1.0 | n/a | No |
gcache.mem_size | 0 | 1.0 | n/a | No |
protonet.backend
Which transport backend to use. Currently only ASIO is supported.
protonet.version
This status variable is used to check which transport backend protocol version is used. This variable is mostly used for troubleshooting purposes.
socket.ssl_cert
A path (absolute or relative to the working directory )to an SSL certificate (in PEM format).
socket.ssl_key
A path (absolute or relative to the working directory to a private key for a certificate (in PEM format).
socket.ssl_compression
Whether to enable compression on SSL connections.
socket.ssl_cipher
Symmetric cipher to use. AES128 is used by default it is considerably faster and no less secure than AES256.
gmcast.listen_addr
Address at which Galera Cluster listens to connections from other nodes. By default the port to listen at is taken from the connection address. This setting can be used to overwrite that.
gmcast.mcast_addr
If set, UDP multicast will be used for replication, for example:
gmcast.mcast_addr=239.192.0.11
The value must be the same on all nodes.
If you are planning to build a large cluster, we recommend using UDP.
gmcast.mcast_ttl
Time to live value for multicast packets.
gmcast.peer_timeout
Connection timeout to initiate message relaying.
gmcast.time_wait
Time to wait until allowing peer declared outside of stable view to reconnect.
gmcast.version
This status variable is used to check which gmcast protocol version is used. This variable is mostly used for troubleshooting purposes.
evs.causal_keepalive_period
For developer use only. Defaults to evs.keepalive_period.
evs.consensus_timeout
Timeout on reaching the consensus about cluster membership.
Deprecated See evs.install_timeout.
evs.debug_log_mask
Control EVS debug logging, only effective when wsrep_debug is in use.
evs.inactive_check_period
How often to check for peer inactivity.
evs.inactive_timeout
Hard limit on the inactivity period, after which the node is pronounced dead.
evs.info_log_mask
Control extra EVS info logging. Bits:
evs.install_timeout
Timeout on waiting for install message acknowledgments. Successor to evs.consensus_timeout.
evs.join_retrans_period
How often to retransmit EVS join messages when forming the cluster membership.
evs.keepalive_period
How often to emit keepalive beacons (in the absence of any other traffic).
evs.max_install_timeouts
How many membership install rounds to try before giving up (total rounds will be evs.max_install_timeouts + 2).
evs.send_window
Maximum packets in replication at a time. For WAN setups may be set considerably higher, e.g. 512. Must be no less than evs.user_send_window. If you must use other that the default value, we recommend using double the evs.user_send_window value.
evs.stats_report_period
Control period of EVS statistics reporting. the node is pronounced dead.
evs.suspect_timeout
Inactivity period after which the node is suspected to be dead. If all remaining nodes agree on that, the node is dropped out of cluster before evs.inactive_timeout is reached.
evs.use_aggregate
Aggregate small packets into one, when possible.
evs.user_send_window
Maximum data packets in replication at a time. For WAN setups, this value can be set considerably higher, to, for example, 512.
evs.view_forget_timeout
Drop past views from the view history after this timeout.
evs.version
This status variable is used to check which evs protocol version is used. This variable is mostly used for troubleshooting purposes.
pc.bootstrap
If you set this value to true is a signal to turn a NON-PRIMARY component into PRIMARY.
pc.checksum
Checksum replicated messages.
pc.ignore_sb
Should we allow nodes to process updates even in the case of split brain? This is a dangerous setting in multi-master setup, but should simplify things in master-slave cluster (especially if only 2 nodes are used).
pc.ignore_quorum
Completely ignore quorum calculations. For example if the master splits from several slaves it still remains operational. Use with extreme caution even in master-slave setups, as slaves will not automatically reconnect to master in this case.
pc.linger
The period for which the PC protocol waits for the EVS termination.
pc.npvo
If set to true, the more recent primary component overrides older ones in the case of conflicting primaries.
pc.wait_prim
If set to true, the node waits for the primary component forever. Useful to bring up a non-primary component and make it primary with pc.bootstrap.
pc.weight
As of version 2.4. Node weight for quorum calculation.
pc.version
This status variable is used to check which pc protocol version is used. This variable is mostly used for troubleshooting purposes.
gcs.fc_debug
Post debug statistics about SST flow every this number of writesets.
gcs.fc_factor
Resume replication after recv queue drops below this fraction of gcs.fc_limit.
gcs.fc_limit
Pause replication if recv queue exceeds this number of writesets. For master-slave setups this number can be increased considerably.
gcs.fc_master_slave
Should we assume that there is only one master in the group?
gcs.max_packet_size
All writesets exceeding that size will be fragmented.
gcs.max_throttle
How much to throttle replication rate during state transfer (to avoid running out of memory). Set the value to 0.0 if stopping replication is acceptable for completing state transfer.
gcs.recv_q_hard_limit
Maximum allowed size of recv queue. This should normally be half of (RAM + swap). If this limit is exceeded, Galera Cluster will abort the server.
gcs.recv_q_soft_limit
The fraction of gcs.recv_q_hard_limit after which replication rate will be throttled.
The degree of throttling is a linear function of recv queue size and goes from 1.0 (full rate) at gcs.recv_q_soft_limit to gcs.max_throttle at gcs.recv_q_hard_limit Note that full rate, as estimated between 0 and gcs.recv_q_soft_limit is a very imprecise estimate of a regular replication rate.
gcs.sync_donor
Should the rest of the cluster keep in sync with the donor? Yes means that if the donor is blocked by state transfer, the whole cluster is blocked with it.
If you choose to use value YES, it is theoretically possible that the donor node cannot keep up with the rest of the cluster due to the extra load from the SST. If the node lags behind, it may send flow control messages stalling the whole cluster. However, you can monitor this using the wsrep_flow_control_paused status variable.
ist.recv_addr
As of 2.0. Address to listen for Incremental State Transfer. By default this is the <address>:<port+1> from wsrep_node_address.
replicator.commit_order
Whether to allow Out-Of-Order committing (improves parallel applying performance). Possible settings:
replicator.causal_read_timeout
Sometimes causal reads need to timeout.
gcache.dir
Directory where GCache should place its files. Defaults to the working directory.
gcache.name
Name of the ring buffer storage file.
gcache.size
Size of the persistent on-disk ring buffer storage. This will be preallocated on startup.
The buffer file name is galera.cache.
See also
Chapter Customizing GCache Size.
gcache.page_size
Size of the page files in page storage. The limit on overall page storage is the size of the disk. Pages are prefixed by gcache.page.
gcache.keep_pages_size
Total size of the page storage pages to keep for caching purposes. If only page storage is enabled, one page is always present.
gcache.mem_size
Max size of the malloc() store (read: RAM). For setups with spare RAM.
You can set Galera Cluster parameters in the my.cnf configuration file as follows:
wsrep_provider_options="gcs.fc_limit=256;gcs.fc_factor=0.9"
This is useful in master-slave setups.
You can set Galera Cluster parameters through a MySQL client as follows:
mysql> SET GLOBAL wsrep_provider_options="evs.send_window=16";
This command would only change the evs.send_window value.
To check which parameters are used in Galera Cluster, enter the command below:
mysql> SHOW VARIABLES LIKE 'wsrep_provider_options';