About Helios Smith
Author is a avid reader
The Server writes information to this log when client connects and disconnect. MySQL query used to find out the error in a client and want to know what exactly client sent to mysqld. This writes to log each SQL statement received from client. Let’s
You can Enable Query Log for MySQL below 5.1.29 Version, Then use the below settings in [mysqld] section.
There’re many log format for MySQL logs which can help you to find out the issues in the database or in tables.
Method 1 :
For permanent, vim /etc/my.cnf
log = /home/general-query.log
Set via MySQL Console,
SET general_log = 1;
Start the Service
systemctl restart mysqld
Method 2 :
You can Enable General Queries Log for MySQL above 5.1.29
version.
general_log_file = /path/to/general-query.log
general_log = 1
Set via MySQL Console,
SET general_query_log = 1;
Create a file general-query.log where you want to keep this logs.
touch general-query.log
chown -R mysql:mysql general-query.log
systemctl restart mysqld
YouTube Link :
You’re done
About Helios Smith
Author is a avid reader
How To Install Sentrifugo Open Source HR Management Tool On Linux