mirror of https://github.com/sysown/proxysql
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
159 lines
3.8 KiB
159 lines
3.8 KiB
#file proxysql.cfg
|
|
|
|
# This config file is parsed using libconfig , and its grammar is described in:
|
|
# http://www.hyperrealm.com/libconfig/libconfig_manual.html#Configuration-File-Grammar
|
|
# Grammar is also copied at the end of this file
|
|
|
|
uuid="9588556d-fc2d-48ac-9c48-201abab06768"
|
|
cluster_sync_interfaces=false
|
|
restart_on_missing_heartbeats=10
|
|
datadir="/var/lib/proxysql"
|
|
//execute_on_exit_failure="/path/to/script"
|
|
//ldap_auth_plugin="../../proxysql_ldap_plugin/MySQL_LDAP_Authentication_plugin.so"
|
|
#web_interface_plugin="../../proxysql_web_interface_plugin/src/Web_Interface_plugin.so"
|
|
#sqlite3_plugin="../../sqlite3_plugin/proxy_sqlite3.so"
|
|
|
|
admin_variables=
|
|
{
|
|
admin_credentials="admin:admin;cluster1:secret1pass"
|
|
mysql_ifaces="0.0.0.0:6032"
|
|
refresh_interval=2000
|
|
debug=true
|
|
cluster_username="cluster1"
|
|
cluster_password="secret1pass"
|
|
cluster_check_interval_ms=200
|
|
cluster_check_status_frequency=100
|
|
cluster_mysql_query_rules_save_to_disk=true
|
|
cluster_mysql_servers_save_to_disk=true
|
|
cluster_mysql_users_save_to_disk=true
|
|
cluster_proxysql_servers_save_to_disk=true
|
|
cluster_mysql_query_rules_diffs_before_sync=3
|
|
cluster_mysql_servers_diffs_before_sync=3
|
|
cluster_mysql_users_diffs_before_sync=3
|
|
cluster_proxysql_servers_diffs_before_sync=3
|
|
}
|
|
|
|
mysql_variables=
|
|
{
|
|
threads=4
|
|
//threads=32
|
|
max_connections=2048
|
|
default_query_delay=0
|
|
default_query_timeout=10000
|
|
have_compress=true
|
|
poll_timeout=2000
|
|
interfaces="0.0.0.0:6033"
|
|
default_schema="information_schema"
|
|
stacksize=1048576
|
|
server_version="5.5.30"
|
|
connect_timeout_server=10000
|
|
monitor_history=60000
|
|
monitor_connect_interval=200000
|
|
monitor_ping_interval=200000
|
|
ping_interval_server=10000
|
|
ping_timeout_server=200
|
|
commands_stats=true
|
|
sessions_sort=true
|
|
}
|
|
|
|
mysql_servers =
|
|
(
|
|
{
|
|
address="127.0.0.1"
|
|
port=3306
|
|
hostgroup=0
|
|
max_connections=200
|
|
comment="test server"
|
|
}
|
|
)
|
|
|
|
scheduler=
|
|
(
|
|
{
|
|
id=1
|
|
active=0
|
|
interval_ms=10000
|
|
filename="/var/lib/proxysql/proxysql_galera_checker.sh"
|
|
arg1="0"
|
|
arg2="0"
|
|
arg3="0"
|
|
arg4="1"
|
|
arg5="/var/lib/proxysql/proxysql_galera_checker.log"
|
|
}
|
|
)
|
|
|
|
|
|
mysql_replication_hostgroups=
|
|
(
|
|
{
|
|
writer_hostgroup=30
|
|
reader_hostgroup=40
|
|
comment="test repl 1"
|
|
},
|
|
{
|
|
writer_hostgroup=50
|
|
reader_hostgroup=60
|
|
comment="test repl 2"
|
|
}
|
|
)
|
|
|
|
|
|
mysql_group_replication_hostgroups=
|
|
(
|
|
# {
|
|
# writer_hostgroup=10
|
|
# reader_hostgroup=20
|
|
# backup_writer_hostgroup=11
|
|
# offline_hostgroup=0
|
|
# active=1
|
|
# max_writers=1
|
|
# writer_is_also_reader=0
|
|
# max_transactions_behind=0
|
|
# comment="repl group 1"
|
|
# }
|
|
)
|
|
|
|
mysql_users:
|
|
(
|
|
{
|
|
username = "root"
|
|
password = "root"
|
|
default_hostgroup = 0
|
|
max_connections=1000
|
|
default_schema="information_schema"
|
|
active = 1
|
|
}
|
|
)
|
|
|
|
mysql_query_rules:
|
|
(
|
|
)
|
|
|
|
|
|
# http://www.hyperrealm.com/libconfig/libconfig_manual.html#Configuration-File-Grammar
|
|
#
|
|
# Below is the BNF grammar for configuration files. Comments and include directives are not part of the grammar, so they are not included here.
|
|
#
|
|
# configuration = setting-list | empty
|
|
#
|
|
# setting-list = setting | setting-list setting
|
|
#
|
|
# setting = name (":" | "=") value (";" | "," | empty)
|
|
#
|
|
# value = scalar-value | array | list | group
|
|
#
|
|
# value-list = value | value-list "," value
|
|
#
|
|
# scalar-value = boolean | integer | integer64 | hex | hex64 | float
|
|
# | string
|
|
#
|
|
# scalar-value-list = scalar-value | scalar-value-list "," scalar-value
|
|
#
|
|
# array = "[" (scalar-value-list | empty) "]"
|
|
#
|
|
# list = "(" (value-list | empty) ")"
|
|
#
|
|
# group = "{" (setting-list | empty) "}"
|
|
#
|
|
# empty =
|