Open main menu

Changes

1,007 bytes added ,  14:33, 26 March 2014
adds monitoring info
password=giveMeSomeDBgoodne55
</source>
 
== What's going on? ==
Want to find out what's going on in your MySQL server, but don't want to install client tools and access? Just make sure that the General Query Log is turned on, and tail the log file:
<source lang="sql">
SHOW VARIABLES LIKE "general_log%";
 
+------------------+----------------------------+
| Variable_name | Value |
+------------------+----------------------------+
| general_log | OFF |
| general_log_file | /var/run/mysqld/mysqld.log |
+------------------+----------------------------+
 
mysql> SET GLOBAL general_log = 'ON';
</source>
Then you can tail the log file to see what it's doing:<source lang="bash">tail -f /var/run/mysqld/mysqld.log</source>
 
'''Be sure to turn off the log''' or your disk will fill up and you will not be happy.
<source lang="sql">
mysql> SET GLOBAL general_log = 'OFF';
</source>
 
If you want more info than you can get from the direct query logging, then try [http://mtop.sourceforge.net/|mtop]
[[Category:Database]]
4,558

edits