本文主要向大家介绍了MySQL数据库之开启和查看mysql的bin-log日志 ,通过具体的内容向大家展现,希望对大家学习MySQL数据库有所帮助。
[root@VM_0_7_centosdata]#vim/etc/f
[root@VM_0_7_centosdata]#vim/etc/f
[root@VM_0_7_centosdata]#/etc/init.d/mysqldrestart
ShuttingdownMySQL....SUCCESS!
StartingMySQL.SUCCESS!
[root@VM_0_7_centosdata]#greplog_bin/etc/f
[root@VM_0_7_centosdata]#greplog-bin/etc/f
log-bin=/opt/mysql/data/mysql-bin
mysql>showvariableslike‘%log_bin%‘;
ERROR(HY000):MySQLserverhasgoneaway
Noconnection.Tryingtoreconnect...
Connectionid:2
Currentdatabase:wordpress
+---------------------------------+---------------------------------+
|Variable_name|Value|
+---------------------------------+---------------------------------+
|log_bin|ON|
|log_bin_basename|/opt/mysql/data/mysql-bin|
|log_bin_index|/opt/mysql/data/mysql-bin.index|
|log_bin_trust_function_creators|OFF|
|log_bin_use_v1_row_events|OFF|
|sql_log_bin|ON|
+---------------------------------+---------------------------------+
6rowsinset(0.01sec)
以上就介绍了MySQL的相关知识,希望对MySQL有兴趣的朋友有所帮助。了解更多内容,请关注职坐标数据库MySQL频道!