Bootstrap FreeKB - mySQL / MariaDB - log level
mySQL / MariaDB - log level

Updated:   |  mySQL / MariaDB articles

The following command can be used to determine the current log level.

mysql -e "select @@log_warnings"

 

Something like this should be returned.

+----------------+
| @@log_warnings |
+----------------+
|              2 |
+----------------+

 

There are a number of log levels.

  • 0 = the least logging
  • 1 = more logging
  • 2 = even more logging
  • 3 = verbose logging
  • 4 = even more verbose logging
  • 9 = the most logging possible

 

The log level can temporarily be change at runtime like this.

mysql -e "SET GLOBAL log_warnings=9"

 

Or the log level can permanently be changed in the my.cnf file. If you change the directive in my.cnf, you will need to restart mySQL or MariaDB for this change to take effect.

log_warnings=9

 




Did you find this article helpful?

If so, consider buying me a coffee over at Buy Me A Coffee



Comments


Add a Comment


Please enter 2a4b21 in the box below so that we can be sure you are a human.