Error Log
Contents
The error log contains a record of critical errors that occurred during the server's operation, as well as start and stop information.
If the log-warnings server system variable is 1 (default), SQL warnings will be logged in the error log. If its value is 0, the logging of SQL warnings is disabled. If its value is greater than 1, aborted connections and access-denied errors for new connection attempts are also written to the error log.
SQL errors can also be logged in a separate file using the SQL_ERROR_LOG plugin.
Activating the Error Log
The error log is active by default. The log-error=filename option determines where the output will be written. If no file name is specified, the log will be written to host-name.err. If no absolute path is specified, the file will be written to the data directory (determined by the value of the datadir system variable).
On Unix systems, if the --log-error option is not used, the errors are written to stderr
(usually, the command line).
On Windows, if the --console option is specified, and --log-error is not used, the errors are written to the console. If --log-error is present, --console is ignored.