List of Admin Variables

NOTE: You can click on the variable name to jump to its definition

Variable NameDefault Value
admin-admin_credentialsadmin:admin
admin-checksum_admin_variablestrue
admin-checksum_ldap_variablestrue
admin-checksum_mysql_query_rulestrue
admin-checksum_mysql_serverstrue
admin-checksum_mysql_userstrue
admin-checksum_mysql_variablestrue
admin-cluster_admin_variables_diffs_before_sync3
admin-cluster_admin_variables_save_to_disktrue
admin-cluster_check_interval_ms1000
admin-cluster_check_status_frequency10
admin-cluster_ldap_variables_diffs_before_sync3
admin-cluster_ldap_variables_save_to_disktrue
admin-cluster_mysql_query_rules_diffs_before_sync3
admin-cluster_mysql_query_rules_save_to_disktrue
admin-cluster_mysql_servers_diffs_before_sync3
admin-cluster_mysql_servers_save_to_disktrue
admin-cluster_mysql_users_diffs_before_sync3
admin-cluster_mysql_users_save_to_disktrue
admin-cluster_mysql_variables_diffs_before_sync3
admin-cluster_mysql_variables_save_to_disktrue
admin-cluster_password
admin-cluster_proxysql_servers_diffs_before_sync3
admin-cluster_proxysql_servers_save_to_disktrue
admin-cluster_username
admin-debugfalse
admin-hash_passwords (deprecated)true
admin-mysql_ifaces0.0.0.0:6032
admin-prometheus_memory_metrics_interval61
admin-read_onlyfalse
admin-refresh_interval2000
admin-restapi_enabledfalse
admin-restapi_port6070
admin-stats_credentialsstats:stats
admin-stats_mysql_connection_pool60
admin-stats_mysql_connections60
admin-stats_mysql_query_cache60
admin-stats_mysql_query_digest_to_disk0
admin-stats_system_cpu60
admin-stats_system_memory60
admin-telnet_admin_ifaces(null)
admin-telnet_stats_ifaces(null)
admin-vacuum_statstrue
admin-versionX.Y.Z-N-gXXXXXXXX
admin-web_enabledfalse
admin-web_port6080

admin-admin_credentials

System VariableNameadmin-admin_credentials
DynamicYes
Permitted ValuesTypeString
Defaultadmin:admin

This is a list of semi-colon separated user:password pairs, that can be used to authenticate to the admin interface with read-write rights. For read-only credentials that can be used to connect to the admin, see the variable admin-stats_credentials. It is important to note that:

  • For security reasons, the default admin user can only connect locally, regardless of its password. In order to connect remotely a secondary user needs to be created by defining this in the admin-admin_credentials variable E.G. admin-admin_credentials="admin:admin;radminuser:radminpass" or admin-admin_credentials="admin:admin;adminremote:*520BA5BE3924F1A0DB9941C4EA0911B19CBDE1A3".
  • users defined in admin-admin_credentials or admin-stats_credentials cannot be used also in mysql_users table.
  • the password can be either in clear text, or hashed using either mysql_native_password or caching_sha2_password . When using caching_sha2_password ensure that your editor supports hidden characters if editing configuration file, or use CACHING_SHA2_PASSWORD() function in Admin interface

Further details in the blog post Managing ProxySQL Admin Credentials: A Guide to admin-admin_credentials

admin-checksum_admin_variables

System VariableNameadmin-checksum_admin_variables
DynamicYes
Permitted ValuesTypeBoolean
Defaulttrue

If enabled, Admin variables will be synchronized by ProxySQL Cluster. See ProxySQL Cluster for further details.

admin-checksum_ldap_variables

System VariableNameadmin-checksum_ldap_variables
DynamicYes
Permitted ValuesTypeBoolean
Defaulttrue

If enabled, LDAP variables will be synchronized by ProxySQL Cluster. Note that this variable is meaningful only if LDAP Plugin is enabled. See ProxySQL Cluster for further details.

admin-checksum_mysql_query_rules

System VariableNameadmin-checksum_mysql_query_rules
DynamicYes
Permitted ValuesTypeBoolean
Defaulttrue

If enabled, tables mysql_query_rules and mysql_query_rules_fast_routing will be synchronized by ProxySQL Cluster. See ProxySQL Cluster for further details.

admin-checksum_mysql_servers

System VariableNameadmin-checksum_mysql_servers
DynamicYes
Permitted ValuesTypeBoolean
Defaulttrue

If enabled, tables mysql_servers, mysql_aws_aurora_hostgroups, mysql_galera_hostgroups, mysql_group_replication_hostgroups and mysql_replication_hostgroups will be synchronized by ProxySQL Cluster. See ProxySQL Cluster for further details.

admin-checksum_mysql_users

System VariableNameadmin-checksum_mysql_users
DynamicYes
Permitted ValuesTypeBoolean
Defaulttrue

If enabled, table mysql_users will be synchronized by ProxySQL Cluster. See ProxySQL Cluster for further details.

admin-checksum_mysql_variables

System VariableNameadmin-checksum_mysql_variables
DynamicYes
Permitted ValuesTypeBoolean
Defaulttrue

If enabled, MySQL variables (both General MySQL Variables and MySQL Monitor Variables will be synchronized by ProxySQL Cluster. See ProxySQL Cluster for further details.

admin-cluster_admin_variables_diffs_before_sync

System VariableNameadmin-cluster_admin_variables_diffs_before_sync
DynamicYes
Permitted ValuesTypeInteger (count)
Default3
Minimum0
Maximum1000

This variable defines how many mismatching checks will trigger the synchronization of Admin variables. See admin-checksum_admin_variables and ProxySQL Cluster for further details.

admin-cluster_ldap_variables_save_to_disk

System VariableNameadmin-cluster_admin_variables_save_to_disk
DynamicYes
Permitted ValuesTypeBoolean
Defaulttrue

If enabled (default), after ProxySQL Cluster synchronizes Admin variables **from** a remote node, the configuration is also locally persisted to disk. See admin-checksum_admin_variables and ProxySQL Cluster for further details.

admin-cluster_check_interval_ms

See ProxySQL Cluster

admin-cluster_check_status_frequency

See ProxySQL Cluster

admin-cluster_ldap_variables_diffs_before_sync

System VariableNameadmin-cluster_ldap_variables_diffs_before_sync
DynamicYes
Permitted ValuesTypeInteger (count)
Default3
Minimum0
Maximum1000

This variable defines how many mismatching checks will trigger the synchronization of LDAP variables. See admin-checksum_ldap_variables and ProxySQL Cluster for further details. Note: this variable is relevant only if LDAP Plugin is enabled.

admin-cluster_ldap_variables_save_to_disk

System VariableNameadmin-cluster_ldap_variables_save_to_disk
DynamicYes
Permitted ValuesTypeBoolean
Defaulttrue

If enabled (default), after ProxySQL Cluster synchronizes LDAP variables **from** a remote node, the configuration is also locally persisted to disk. See admin-checksum_ldap_variables and ProxySQL Cluster for further details. Note: this variable is relevant only if LDAP Plugin is enabled.

admin-cluster_mysql_query_rules_diffs_before_sync

System VariableNameadmin-cluster_mysql_query_rules_diffs_before_sync
DynamicYes
Permitted ValuesTypeInteger (count)
Default3
Minimum0
Maximum1000

This variable defines how many mismatching checks will trigger the synchronization of MySQL Query Rules related tables. See admin-checksum_mysql_query_rules and ProxySQL Cluster for further details.

admin-cluster_mysql_query_rules_save_to_disk

System VariableNameadmin-cluster_mysql_query_rules_save_to_disk
DynamicYes
Permitted ValuesTypeBoolean
Defaulttrue

If enabled (default), after ProxySQL Cluster synchronizes MySQL Query Rules tables **from** a remote node, the configuration is also locally persisted to disk. See admin-checksum_mysql_query_rules and ProxySQL Cluster for further details.

admin-cluster_mysql_servers_diffs_before_sync

System VariableNameadmin-cluster_mysql_servers_diffs_before_sync
DynamicYes
Permitted ValuesTypeInteger (count)
Default3
Minimum0
Maximum1000

This variable defines how many mismatching checks will trigger the synchronization of MySQL Servers related tables. See admin-checksum_mysql_servers and ProxySQL Cluster for further details.

admin-cluster_mysql_servers_save_to_disk

System VariableNameadmin-cluster_mysql_servers_save_to_disk
DynamicYes
Permitted ValuesTypeBoolean
Defaulttrue

If enabled (default), after ProxySQL Cluster synchronizes MySQL Servers tables **from** a remote node, the configuration is also locally persisted to disk. See admin-checksum_mysql_servers and ProxySQL Cluster for further details.

admin-cluster_mysql_users_diffs_before_sync

System VariableNameadmin-cluster_mysql_users_diffs_before_sync
DynamicYes
Permitted ValuesTypeInteger (count)
Default3
Minimum0
Maximum1000

This variable defines how many mismatching checks will trigger the synchronization of MySQL Users related tables. See admin-checksum_mysql_servers and ProxySQL Cluster for further details.

admin-cluster_mysql_users_save_to_disk

System VariableNameadmin-cluster_mysql_users_save_to_disk
DynamicYes
Permitted ValuesTypeBoolean
Defaulttrue

If enabled (default), after ProxySQL Cluster synchronizes MySQL Users tables **from** a remote node, the configuration is also locally persisted to disk. See admin-checksum_mysql_users and ProxySQL Cluster for further details.

admin-cluster_password

System VariableNameadmin-cluster_password
DynamicYes
Permitted ValuesTypeString
Default(empty string)

In order for ProxySQL Cluster to work, instances need to connect to each other to perform checks and eventually pull new configuration(s). Credentials defined in admin-cluster_username and admin-cluster_password are used to connect to the remote ProxySQL nodes that are part of the cluster. Note that the same credentials must also be present in the variable admin-admin_credentials of the remote ProxySQL nodes, or the current node won’t be able to connect.

admin-cluster_proxysql_servers_diffs_before_sync

System VariableNameadmin-cluster_proxysql_servers_diffs_before_sync
DynamicYes
Permitted ValuesTypeInteger (count)
Default3
Minimum0
Maximum1000

This variable defines how many mismatching checks will trigger the synchronization of proxysql_servers table. See ProxySQL Cluster for further details.

admin-cluster_mysql_servers_save_to_disk

System VariableNameadmin-cluster_proxysql_servers_save_to_disk
DynamicYes
Permitted ValuesTypeBoolean
Defaulttrue

If enabled (default), after ProxySQL Cluster synchronizes ProxySQL Servers table **from** a remote node, the configuration is also locally persisted to disk. See ProxySQL Cluster for further details.

admin-cluster_mysql_variables_diffs_before_sync

System VariableNameadmin-cluster_mysql_variables_diffs_before_sync
DynamicYes
Permitted ValuesTypeInteger (count)
Default3
Minimum0
Maximum1000

This variable defines how many mismatching checks will trigger the synchronization of MySQL variables. See admin-checksum_mysql_variables and ProxySQL Cluster for further details.

admin-cluster_mysql_variables_save_to_disk

System VariableNameadmin-cluster_mysql_variables_save_to_disk
DynamicYes
Permitted ValuesTypeBoolean
Defaulttrue

If enabled (default), after ProxySQL Cluster synchronizes MySQL variables **from** a remote node, the configuration is also locally persisted to disk. See admin-checksum_mysql_variables and ProxySQL Cluster for further details.

admin-cluster_username

System VariableNameadmin-cluster_username
DynamicYes
Permitted ValuesTypeString
Default(empty string)

In order for ProxySQL Cluster to work, instances need to connect to each other to perform checks and eventually pull new configuration(s). Credentials defined in admin-cluster_username and admin-cluster_password are used to connect to the remote ProxySQL nodes that are part of the cluster. Note that the same credentials must also be present in the variable admin-admin_credentials of the remote ProxySQL nodes, or the current node won’t be able to connect. If admin-cluster_username is empty (the default) , ProxySQL Cluster cannot start because there is no defined user to connect to remote ProxySQL nodes.

admin-debug

System VariableNameadmin-debug
DynamicYes
Permitted ValuesTypeBoolean
Defaultfalse

This variable enables the debugging in proxysql binaries built in debug mode. Note that this variable is only present in debug builds, therefore you shouldn’t see this variable in a production environment.

admin-hash_passwords (deprecated)

Deprecated in 2.6.0. Prior to this version:

System VariableNameadmin-hash_passwords
DynamicYes
Permitted ValuesTypeBoolean
Defaulttrue

When admin-hash_passwords=true (enabled by default), passwords are automatically hashed at RUNTIME when running LOAD MYSQL USERS TO RUNTIME. Passwords in mysql_users table are not automatically hashed (they are hashed only in runtime_mysql_users) and require you to run SAVE MYSQL USERS FROM RUNTIME. Also note that if on the backend the user is configured to use caching_sha2_password, passwords in mysql_users.password need to be in clear text (not hashed), therefore variable admin-hash_passwords needs to be set to false. See Password Management for further details.

Since version 2.6.0 users should be able set the passwords as they prefer, either hashed or in clear text in mysql_users table. For furhter details on how this is achieved please refer to Password Management.

admin-mysql_ifaces

System VariableNameadmin-mysql_ifaces
DynamicYes
Permitted ValuesTypeString
Default (up to 1.4.0)127.0.0.1:6032
Default (from 1.4.1 onwards)0.0.0.0:6032

Semicolon-separated list of hostname:port entries for interfaces on which the admin interface should listen. It also supports UNIX domain sockets for the cases where the connection is done from an application on the same machine: in this case the full path of the socket must be specified. For example: SET admin-mysql_ifaces='127.0.0.1:6032;/tmp/proxysql_admin.sock'. Please note that the default admin user can only connect locally for security reasons. In order to connect remotely a secondary user needs to be created by defining this in the admin-admin_credentials variable, for example admin-admin_credentials="admin:admin;radminuser:radminpass".

admin-prometheus_memory_metrics_interval

Minimum61Maximum61

System VariableNameadmin-prometheus_memory_metrics_interval
DynamicYes
Permitted ValuesTypeInteger (seconds)
Default61
Minimum0
Maximum

ProxySQL has a built-in Prometheus Exporter that is able to export statistics when the REST API is enabled. Metrics are collected all the time no matter if the REST API is enabled or not. While some metrics are collected and refreshed in real time, some metrics (currently only memory metrics) are collected and refreshed only at regular intervals defined by admin-prometheus_memory_metrics_interval .

admin-read_only

System VariableNameadmin-read_only
DynamicYes
Permitted ValuesTypeBoolean
Defaultfalse

When this variable is set to true and loaded at runtime, the Admin module does not accept writes anymore. This is useful to ensure that ProxySQL cannot be further configured. When ProxySQL Admin is in read-only mode, the only way to revert it to read-write and set admin-read_only to false at runtime (and therefore also make the Admin module writable again) is to run the command PROXYSQL READWRITE. Note that this feature is mostly useful for future development of new features, and you shouldn’t normally configure ProxySQL Admin to be in read-only mode.

admin-refresh_interval

System VariableNameadmin-refresh_interval
DynamicYes
Permitted ValuesTypeInteger (milliseconds)
Default2000
Minimum100
Maximum100000

In very old versions this variable defined the refresh interval (in milliseconds) for updates to the query rules statistics and commands counters statistics. Now this variable only defines the timeout for poll() calls, thus for how long an Admin connection can be blocked waiting for a network event. Be careful about tweaking this to a value that is:

  • too low, because it might affect the overall performance of the proxy if there are a a lot (several thousands) of Admin connections
  • too high, because it might affect the graceful shutdown of proxysql if some Admin connections are blocked for a long time

This variable is likely to be deprecated in the future.

admin-restapi_enabled

System VariableNameadmin-restapi_enabled
DynamicYes
Permitted ValuesTypeBoolean
Defaultfalse

It allows users to create new REST API endpoints and execute scripts on behalf of ProxySQL. If admin-restapi_enabled is set to true, the REST-API is automatically enabled and the module is listening on port admin-restapi_port

admin-restapi_port

System VariableNameadmin-restapi_port
DynamicYes
Permitted ValuesTypeInteger
Default6070

This variable defines on which port the REST API is listening if the REST API module is enabled. (admin-restapi_enabled=’true’) .

admin-stats_credentials

System VariableNameadmin-stats_credentials
DynamicYes
Permitted ValuesTypeString
Defaultstats:stats

This is a list of semi-colon separated user:password pairs that defines the read-only credentials for connecting to the admin interface. These are not allowed to update internal data structures such as the list of MySQL backend servers (or hostgroups), query rules, etc., neither to read configuration tables. They are only allowed to read from the statistics and monitoring tables. Note: there are several restrictions on use of users in admin-stats_credentials : the restrictions are the same as those listed in admin-admin_credentials

admin-telnet_admin_ifaces

Not currently used (planned usage in a future version).

admin-telnet_stats_ifaces

Not currently used (planned usage in a future version).

admin-version

System VariableNameadmin-version
DynamicNo
Permitted ValuesTypeString
Read Onlytrue

This variable displays ProxySQL version. This variable is read only: do not attempt to change it.

Admin historical statistics

Since ProxySQL Admin stores historical metrics in a new database named proxysql_stats.db in the datadir. Tables structures may be subject to future changes.

admin-stats_mysql_connection_pool

System VariableNameadmin-stats_mysql_connection_pool
DynamicYes
Permitted ValuesTypeInteger (seconds)
Default60
Valid values5, 10, 30, 60, 120, 300

The refresh interval (in seconds) to update the historical statistics of the connection pool.

admin-stats_mysql_connections

System VariableNameadmin-stats_mysql_connections
DynamicYes
Permitted ValuesTypeInteger (seconds)
Default60
Valid values5, 10, 30, 60, 120, 300

The refresh interval (in seconds) to update the historical statistics of MySQL connections, both frontends and backends.

admin-stats_mysql_query_cache

System VariableNameadmin-stats_mysql_query_cache
DynamicYes
Permitted ValuesTypeInteger (seconds)
Default60
Valid values5, 10, 30, 60, 120, 300

The refresh interval (in seconds) to update the historical statistics of MySQL Query Cache.

admin-stats_mysql_digest_to_disk

Maximum86400 (24 hours)

System VariableNameadmin-stats_mysql_query_digest_to_disk
DynamicYes
Permitted ValuesTypeInteger (seconds)
Default0
Minimum0

The refresh interval (in seconds) to dump the content of stats_mysql_query_digest into stats_history.history_mysql_query_digest , and reset stats_mysql_query_digest . A value of 0 (default) disables this feature. If the feature is enabled, please be very careful on how frequently the dump is performed and how many distinct query patterns your application is generating: the size of the database on disk can potentially grow quickly.

admin-stats_system_cpu

System VariableNameadmin-stats_system_cpu
DynamicYes
Permitted ValuesTypeInteger (seconds)
Default60
Valid values5, 10, 30, 60, 120, 300, 600

The refresh interval (in seconds) to update the historical statistics of CPU usage.

admin-stats_system_memory

System VariableNameadmin-stats_system_memory
DynamicYes
Permitted ValuesTypeInteger (seconds)
Default60
Valid values5, 10, 30, 60, 120, 300, 600

The refresh interval (in seconds) to update the historical statistics of memory usage. Note: These statistics are not available if ProxySQL is not compiled with jemalloc. Note that all official packages are compiled with jemalloc.

admin-vacuum_stats

System VariableNameadmin-vacuum_stats
DynamicYes
Permitted ValuesTypeBoolean (seconds)
Defaulttrue
Valid valuestrue, false

This parameter enables or disables the vacuum operation on the SQLite database storing the statistics tables. VACUUM command cleans and eliminates free pages, aligns table data to be contiguous, and otherwise cleans up the database memory structure. This allows to free memory when large statistics tables are queried. Note that this applies only to statistics tables: all the tables with name starting with stats_ and stored in memory.

Admin web interface

ProxySQL embeds an HTTP web server from where it is possible to gather certain metrics. Credentials to access the web interfaces are the same as those defined in admin-stats_credentials. When Web UI plugin is enabled, the HTTP web server can be used to reconfigure ProxySQL itself, and the credentials configured in admin-admin_credentials can be used to access the web interface.

admin-web_enabled

System VariableNameadmin-web_enabled
DynamicYes
Permitted ValuesTypeBoolean
Defaultfalse

If admin-web_enabled is set to true, the web server is automatically enabled and listening on port admin-web_port. The web server can be turned on and off at runtime.

admin-web_port

System VariableNameadmin-web_port
DynamicYes
Permitted ValuesTypeInteger
Default6080

This variable defines on which port the web server is listening if admin-web_enabled is set to true

admin-web_verbosity

System VariableNameadmin-web_verbosity
DynamicYes
Permitted ValuesTypeInteger
Default0
Minimum0
Maximum10

This variable defines the verbosity level of the web server if it is active (admin-web_enabled is set to true) . The verbosity level is used for debugging purposes only.