Error log is a log that contains information indicating the start and stops of MySQL server like mysqld and also contains critical errors while the server is running. It is an important point of reference when administering a MySQL Server. You can enable error log by writing log-error in option file (my.ini) and the log files will go to the data. You can name your error logs by writing
log-error[=file_name] in option file(my.ini).The General Query Log
General Query log is a log that contains information about what MySQL server like mysqld is doing. The information that is written inside the log was when the users connect or disconnect. You can enable general query log by writing log in option file (my.ini) and the log files will go to the data. You can name your general query logs by writing
log[=file_name] or –l [file_name] in option file(my.ini).The Binary Log
Binary log is a log that contains information about events that describe the changes in table data. For example, creating, deleting and editing table operation can be inserted in binary log. It is used on master replication servers as record of the statements. You can enable binary log by writing log-bin in option file (my.ini) and the log files will go to the data. You can name your binary logs by writing
log-bin[=base_name] in option file(my.ini).The Relay Log
Relay log is the same as binary log that contains information about database events and describe database changes such as creating, deleting and editing a table. The term “relay log file” generally denotes an individual numbered file containing database events. Events in the relay log are executed on the slave as part of the SQL thread. You can enable relay log by writing relay-log in option file (my.ini) and the log files will go to the data.
The Slow Query Log
Slow Query log is consisting of MySQL statements that take time to execute. Optimize, analyze and alter table MySQL statements is an example of slow query log but you need to write
log-slow-admin-statements in option file to written it to the slow query
log. You can enable slow query log by writing log-slow-queries in option file (my.ini) and the log
files will go to the data. You can name your slow query logs by writing log-slow-queries[=file_name] in option
file(my.ini).
No comments:
Post a Comment