Configuration
|
|
[mariadb]
|
plugin-maturity=gamma
|
|
feedback-user-info='enterprise'
|
|
## -- Remove the following line to enable feedback reporting to mariadb.org
|
feedback-url=''
|
|
[mysqld]
|
# -- Disable for applications using old auth protocol
|
enable-secure-auth
|
# -- Auditing - pre-load Plugin
|
plugin-load=server_audit
|
|
###########################################
|
[mysqld]
|
log-error=/var/log/mysqld.log
|
# General
|
# bind_address = 127.0.0.1
|
skip-name-resolve
|
max-allowed-packet = 64M
|
open-files-limit = 65535
|
max-connect-errors = 100000
|
max-connections = 4000
|
thread-cache-size = 200
|
back-log = 128
|
#net_buffer_length = 16K
|
#connect_timeout = 10
|
#net_read_timeout = 30
|
#net_write_timeout = 60
|
#interactive_timeout = 28800
|
interactive_timeout = 600
|
#wait_timeout = 28800
|
wait_timeout = 600
|
#net_retry_count = 10
|
character-set-server = 'utf8'
|
collation-server = 'utf8_general_ci'
|
# -- Do not change these defaults, unless you really know.
|
#read_rnd_buffer_size = 256K
|
#sort_buffer_size = 2M
|
#read_buffer_size = 128K
|
#max_tmp_tables = 32
|
tmp-table-size = 256M
|
max-heap-table-size = 256M
|
tmpdir = /dev/shm
|
# -- This will enable a stricter SQL mode to avoid bad data
|
sql-mode = 'ALLOW_INVALID_DATES,STRICT_TRANS_TABLES'
|
|
optimizer_search_depth = 0
|
optimizer_switch = 'index_merge=on'
|
optimizer_switch = 'index_merge_union=on'
|
optimizer_switch = 'index_merge_sort_union=on'
|
optimizer_switch = 'index_merge_intersection=on'
|
optimizer_switch = 'index_merge_sort_intersection=off'
|
optimizer_switch = 'index_condition_pushdown=on'
|
optimizer_switch = 'derived_merge=on'
|
optimizer_switch = 'derived_with_keys=on'
|
optimizer_switch = 'firstmatch=on'
|
optimizer_switch = 'loosescan=on'
|
optimizer_switch = 'materialization=on'
|
optimizer_switch = 'in_to_exists=on'
|
optimizer_switch = 'semijoin=on'
|
optimizer_switch = 'partial_match_rowid_merge=on'
|
optimizer_switch = 'partial_match_table_scan=on'
|
optimizer_switch = 'subquery_cache=on,mrr=on'
|
optimizer_switch = 'mrr_cost_based=on'
|
optimizer_switch = 'mrr_sort_keys=off'
|
optimizer_switch = 'outer_join_with_cache=on'
|
optimizer_switch = 'semijoin_with_cache=on'
|
optimizer_switch = 'join_cache_incremental=on'
|
optimizer_switch = 'join_cache_hashed=on'
|
optimizer_switch = 'join_cache_bka=on'
|
optimizer_switch = 'optimize_join_buffer_size=on'
|
optimizer_switch = 'table_elimination=on'
|
optimizer_switch = 'extended_keys=on'
|
|
join-buffer-space-limit = 4M
|
join-cache-level = 6
|
join-buffer-size = 4M
|
|
# Security
|
symbolic-links = 0
|
local-infile = 0
|
|
# Logging
|
log-warnings = 2
|
slow-query-log = 1
|
long-query-time = 5
|
log-slow-verbosity = 'query_plan,innodb'
|
#log_slow_rate_limit = 1000
|
|
# Replication / Binary logs
|
server-id = 101
|
log_bin_trust_function_creators = 1
|
#slave_net_timeout = 60
|
#max_prepared_stmt_count = 16382
|
binlog-annotate-row-events = ON
|
log-bin=mariadb-bin
|
binlog-format = ROW
|
expire-logs-days = 7
|
max-binlog-size = 1024M
|
sync-binlog = 1
|
binlog-stmt-cache-size = 128K
|
binlog-cache-size = 256K
|
#slave_compressed_protocol = ON
|
slave-transaction-retries = 10
|
#relay_log_recovery = ON
|
#sync_master_info = 1
|
#sync_relay_log = 0
|
#sync_relay_log_info = 1
|
log_slave_updates=1
|
|
# InnoDB
|
default-storage-engine = 'InnoDB'
|
innodb-stats-on-metadata = 0
|
innodb-stats-sample-pages = 32
|
table-definition-cache = 2048
|
table-open-cache = 2048
|
transaction-isolation = READ-COMMITTED
|
innodb-support-xa = ON
|
|
# Query Cache
|
query-cache-size = 0
|
query-cache-type = 0
|
innodb-buffer-pool-instances = 8
|
#innodb-buffer-pool-size = 2G
|
innodb-max-dirty-pages-pct = 50
|
innodb-file-per-table = 1
|
innodb-file-format = Barracuda
|
innodb-flush-log-at-trx-commit = 1
|
#innodb_flush_method = O_DIRECT
|
innodb-log-buffer-size = 64M
|
innodb-log-files-in-group = 2
|
#innodb-log-file-size = 1024M
|
#innodb_purge_threads = 1
|
#innodb_io_capacity = 200
|
#innodb_flush_neighbors = 0
|
#innodb-read-io-threads = 8
|
#innodb-write-io-threads = 8
|
#innodb-thread-concurrency = 64
|
|
#innodb-open-files = 2048
|
|
innodb_io_capacity = 50000
|
innodb_lru_scan_depth = 4000
|
innodb-read-io-threads = 64
|
innodb-write-io-threads = 64
|
innodb-buffer-pool-size = 100G
|
innodb_log_file_size = 4G
|
innodb_flush_neighbors = 0
|
innodb-open-files = 4000
|
innodb_checksum_algorithm = CRC32
|
thread_handling = pool-of-threads
|
|
# MyISAM
|
key-buffer-size = 64M
|
flush = OFF
|
myisam-recover-options = BACKUP,FORCE
|
myisam-sort-buffer-size = 64M
|
|
# Other
|
# -- Enable INFORMATION_SCHEMA.%_STATISTICS tables
|
userstat = ON
|
archive = OFF
|
blackhole = OFF
|
#federated = OFF
|
#innodb = FORCE
|
|
[mysql]
|
default-character-set = 'utf8'
|
auto-rehash = FALSE
|
local-infile = 1
|
max-allowed-packet = 64M
|
secure-auth = TRUE
|
|
[mysqldump]
|
max-allowed-packet = 1G
|
default-character-set = 'utf8'
|
|
[myisamchk]
|
key-buffer-size = 1G
|
sort-buffer-size = 1G
|
read-buffer-size = 8M
|
write-buffer-size = 8M
|
|
[galera]
|
wsrep_provider="/usr/lib64/galera/libgalera_smm.so"
|
binlog_format=row
|
default_storage_engine=InnoDB
|
innodb_autoinc_lock_mode=2
|
bind-address=0.0.0.0
|
wsrep_slave_threads=64
|
innodb_flush_log_at_trx_commit=0
|
innodb_force_primary_key=1
|
wsrep_provider_options="gcache.size=32G; gcs.fc_master_slave=yes"
|
wsrep_node_address="10.0.7.45"
|
wsrep_max_ws_size=2147483648
|
wsrep_sst_method=xtrabackup-v2
|
|
[xtrabackup]
|
parallel=16
|
|
[sst]
|
compressor='pigz -p16'
|
decompressor='pigz -p16 -dc'
|
|