89 lines
2.8 KiB
Django/Jinja
89 lines
2.8 KiB
Django/Jinja
# Here follows entries for some specific programs
|
|
|
|
# The MariaDB server
|
|
[mysqld]
|
|
user = mysql
|
|
{% if mysql_listen_on_ext_int %}
|
|
bind-address = 0.0.0.0
|
|
{% else %}
|
|
bind-address = 127.0.0.1
|
|
{% endif %}
|
|
port = {{ mysql_db_port }}
|
|
socket = {{ mysql_socket }}
|
|
basedir = /usr
|
|
datadir = {{ mysql_data_dir }}
|
|
log_error = {{ mysql_log_dir }}/error.log
|
|
skip-external-locking
|
|
# Point the following paths to different dedicated disks
|
|
tmpdir = /tmp
|
|
lc-messages-dir = /usr/share/mysql
|
|
|
|
#
|
|
# * Fine Tuning
|
|
#
|
|
max_connections = {{ mysql_db_max_connections }}
|
|
key_buffer_size = 16M
|
|
max_allowed_packet = {{ mysql_max_allowed_packet }}
|
|
table_open_cache = 512
|
|
sort_buffer_size = 8M
|
|
net_buffer_length = 8K
|
|
thread_stack = 192K
|
|
thread_cache_size = 8
|
|
read_buffer_size = {{ mysqld_db_read_buffer_size }}
|
|
read_rnd_buffer_size = {{ mysql_db_read_rnd_buffer_size }}
|
|
myisam_sort_buffer_size = 16M
|
|
{% if mysql_skip_name_resolve %}
|
|
skip-name-resolve
|
|
{% endif %}
|
|
|
|
{% if mysqld_sql_mode is defined %}
|
|
sql_mode = {{ mysqld_sql_mode }}
|
|
{% endif %}
|
|
{% if mysqld_ft_stopword_file is defined %}
|
|
ft_stopword_file = {{ mysqld_ft_stopword_file }}
|
|
{% endif %}
|
|
{% if mysqld_ft_min_word_lenght is defined %}
|
|
ft_min_word_len = {{ mysqld_ft_min_word_lenght }}
|
|
{% endif %}
|
|
ft_boolean_syntax = '{{ mysql_ft_boolean_syntax | default('+ -><()~*:\"\"&|') }}'
|
|
|
|
#
|
|
# * Query Cache Configuration
|
|
#
|
|
query_cache_limit = 1M
|
|
query_cache_size = 16M
|
|
|
|
{% if mysql_binary_logging %}
|
|
server-id={{ mysql_server_id }}
|
|
# Enable binary logging. This is required for acting as a MASTER in a
|
|
# replication configuration. You also need the binary log if you need
|
|
# the ability to do point in time recovery from your latest backup.
|
|
log-bin={{ mysql_binlog_dir }}/mysql-bin.log
|
|
expire_logs_days = {{ mysql_binlog_expire_logs_days }}
|
|
max_binlog_size = {{ mysql_binlog_max_binlog_size }}
|
|
# binary logging format - mixed recommended
|
|
binlog_format=mixed
|
|
{% endif %}
|
|
|
|
# Uncomment the following if you are using InnoDB tables
|
|
innodb_data_home_dir = {{ mysql_data_dir }}
|
|
innodb_data_file_path = {{ mysql_db_innodb_data_file_path }}
|
|
innodb_log_group_home_dir = {{ mysql_data_dir }}
|
|
# You can set .._buffer_pool_size up to 50 - 80 %
|
|
# of RAM but beware of setting memory usage too high
|
|
innodb_buffer_pool_size = {{ mysql_db_innodb_buffer_pool_size }}
|
|
# Set .._log_file_size to 25 % of buffer pool size
|
|
innodb_log_file_size = {{ mysql_db_innodb_log_file_size }}
|
|
innodb_log_buffer_size = {{ mysql_db_innodb_log_buffer_size }}
|
|
innodb_flush_log_at_trx_commit = 1
|
|
innodb_lock_wait_timeout = 50
|
|
|
|
{% if mysql_use_ssl %}
|
|
ssl-ca=/var/lib/mysql/ca.pem
|
|
ssl-cert=/var/lib/mysql/client-cert.pem
|
|
ssl-key=/var/lib/mysql/client-key.pem
|
|
{% endif %}
|
|
|
|
[mysqld_safe]
|
|
open-files-limit = {{ mysql_safe_open_files_limit }}
|