Analysis of MySQL 7 types of logs (I) Error Log ① parameter log_error: Specify the log location and name ② function (I) Error/alarm information (ii) optimization help (ii) Slow query log ① parameter log_slow_queries: specify the log location and name long_query_time: the SQL statement whose running time is less than or equal to this threshold value will not be logged as log_queries_not_using_indexes: the SQL statement without an index will be logged as log_output: specify the log output format, the default value is FILE, and the value can also be set to TABLE ② for SQL optimization (iii) Transaction Log ① parameter innodb_log_file_size: Log FILE Size innodb_log_files_in_group: the number of log files in each group innodb_mirrored: how many groups of innodb_log_group_home_dir: log Group Path ② active instance or media recovery (iv) relay log ① parameter relay-log: specify the location and name of the relay log ② act as the standby database to copy the logs of the master database to its own relay log (v) General log ① parameter general_log_file: specify the location and name of the general log general_log: 1 Enabled; 0 close ② function audit: Which account, at which time, what is done (vi) binary log ① parameter log_bin: Specify the log location and name [NOTE: In my. cnf should be log-bin, and the parameter is log_bin.] binlog_format: Specify the log format sync_binlog: 1 indicates synchronous write to disk (2) log writing (1) Restoration Based on time points (2) Copy (7) query log (1) parameter log: Specify the log name log_output: if it is TABLE, all mysql request information is recorded under MySQL database ②.