Server Variables view — MySQL
Reading and changing the server's configuration.
The Variables view lists every MySQL system variable with its Global Value and Session Value, and lets you change those the server allows to be changed while running.
Global and Session Values #
The global value is the server-wide setting that new connections inherit. The session value applies to one connection. Seeing both side by side is the advantage over SHOW VARIABLES: a session value that differs from the global one explains many "works differently from my machine" problems.
Some variables are global only, some session only, and some are read-only which can only be set in the configuration file or on the command line.
Finding a Variable #
The Show: scope bar has All plus one item per group. Groups are by name prefix, so all innodb_ variables sit together. The search field narrows by name.
Changing a Value #
-
Find the variable.
-
Click Edit on the global or session value.
-
Type the new value and press Return.
If the server rejects the change (read-only variable, out-of-range value, or no SUPER privilege), the error is shown and nothing changes.
Recipes #
To confirm a configuration change took effect
-
Search for the variable and read the Global Value, not the session value.
-
Compare it with the value in
my.cnf.If it doesn't match, the server didn't read that file or read a different one. Check Basedir and Datadir in Server Status to see where the server lives.
To check whether slow query logging is on
-
Search for
slow_query_log(or choose theslowgroup) and confirm it'sON.long_query_timeis the threshold. -
Check whether
log_outputsends entries to a file or a table.That decides whether Slow Queries can read them without Server Access.
The Slow Queries view can change slow_query_log, long_query_time, and log_output directly, which is usually easier.