mysql開啓binlog步驟講解

binlog是二進制日誌文件,用於記錄mysql的數據變更,數據在恢復的時候binlog日誌能起到很大的作用。mysql的主從複製就是利用的binlog原理 1、登錄mysql之後使用下面的命令查看是否開啓binlog show variables like 'log_%'; 2、編輯配置文件 vi /etc/my.cnf 3、加入以下內容 1 2 3 4 5 6 7 server_id=2  
相關文章
相關標籤/搜索