Method: 1. "show variables like 'log_error'" to query the error log; 2. "...like 'general_log_file'" to query the log; 3. "...like 'slow_query_log_file'" to query the slow log .
The operating environment of this tutorial: windows10 system, mysql8.0.22 version, Dell G3 computer.
First log in to mysql
1. Find the error log file path
show variables like ‘log_error’;
2 .Find the global log file path
show variables like ‘general_log_file’;
3. Slowly query the log file path
show variables like ‘slow_query_log_file’;
Recommended learning:mysql video tutorial
The above is the detailed content of How to query the log path in Mysql. For more information, please follow other related articles on the PHP Chinese website!