2022-06-09 13:38:00 +02:00
|
|
|
# {{ ansible_managed }}
|
|
|
|
|
|
|
|
[mysqld]
|
|
|
|
bind_address={{ mariadb.bind_address|default("127.0.0.1") }}
|
|
|
|
|
2023-01-14 00:53:10 +01:00
|
|
|
{% if inventory_hostname == "database.sao" %}
|
|
|
|
open_files_limit = 64184
|
|
|
|
{% endif %}
|
|
|
|
|
2022-06-09 13:38:00 +02:00
|
|
|
# Slow-Log
|
|
|
|
slow_query_log = 1
|
|
|
|
slow_query_log_file = /var/log/mysql/mariadb-slow.log
|
|
|
|
long_query_time = 10
|
|
|
|
log_slow_rate_limit = 1000
|
|
|
|
log_slow_verbosity = query_plan
|
2023-01-13 19:26:59 +01:00
|
|
|
|
2023-01-16 16:30:49 +01:00
|
|
|
{% if inventory_hostname != "database.sao" %}
|
2023-01-13 19:26:59 +01:00
|
|
|
innodb_buffer_pool_size = {{ (ansible_memtotal_mb / 1024 * 0.8) | round (0, 'floor') | int }}G
|
|
|
|
innodb_log_file_size = 256M
|
|
|
|
innodb_log_buffer_size = 4M
|
|
|
|
innodb_buffer_pool_instances = 4
|
|
|
|
performance_schema = on
|
2023-01-14 00:53:10 +01:00
|
|
|
{% endif %}
|