FreeBSD/jails/config/db/server.cnf
2021-02-13 11:38:38 -08:00

91 lines
2.3 KiB
INI

# Options specific to server applications, see
# https://mariadb.com/kb/en/configuring-mariadb-with-option-files/#server-option-groups
# Options specific to all server programs
[server]
# Options specific to MariaDB server programs
[server-mariadb]
#
# Options for specific server tools
#
[mysqld]
user = mysql
# port = 3306 # set in /usr/local/etc/mysql/my.cnf
# socket = /var/run/mysql/mysql.sock # set in /usr/local/etc/mysql/my.cnf
bind-address = *
basedir = /usr/local
datadir = /var/db/mysql
net_retry_count = 16384
# [mysqld] configuration for ZFS
# From https://www.percona.com/resources/technical-presentations/zfs-mysql-percona-technical-webinar
# Create separate datasets for data and logs, eg
# zroot/mysql compression=on recordsize=128k atime=off
# zroot/mysql/data recordsize=16k
# zroot/mysql/logs
datadir = /var/db/mysql
innodb_log_group_home_dir = /var/db/mysql-log
#audit_log_file = /var/db/mysql-log/audit.log
general_log_file = /var/db/mysql-log/general.log
log_bin = /var/db/mysql-log/mysql-bin
relay_log = /var/db/mysql-log/relay-log
slow_query_log_file = /var/db/mysql-log/slow.log
innodb_doublewrite = 0
innodb_flush_method = O_DSYNC
##
log-error = /var/db/mysql-log/error.log
### custom optimizations
skip-external-locking
key_buffer_size = 16K
max_allowed_packet = 64M
table_open_cache = 16
sort_buffer_size = 64K
read_buffer_size = 256K
read_rnd_buffer_size = 256K
net_buffer_length = 2K
thread_stack = 240K
server-id = 1
binlog_format=ROW
innodb_buffer_pool_size = 1G
innodb_io_capacity=4000
transaction-isolation = READ-COMMITTED
innodb_log_file_size = 250M
innodb_flush_log_at_trx_commit = 2
innodb_checksum_algorithm = none
slow_query_log_file = /var/db/mysql-log/slow.log
expire_logs_days = 7
###
# Options read by `mysqld_safe`
# Renamed from [mysqld_safe] starting with MariaDB 10.4.6.
[mariadb_safe]
# Options read my `mariabackup`
[mariabackup]
# Options read by `mysql_upgrade`
# Renamed from [mysql_upgrade] starting with MariaDB 10.4.6.
[mariadb-upgrade]
# Specific options read by the mariabackup SST method
[sst]
# Options read by `mysqlbinlog`
# Renamed from [mysqlbinlog] starting with MariaDB 10.4.6.
[mariadb-binlog]
# Options read by `mysqladmin`
# Renamed from [mysqladmin] starting with MariaDB 10.4.6.
[mariadb-admin]