国产av日韩一区二区三区精品,成人性爱视频在线观看,国产,欧美,日韩,一区,www.成色av久久成人,2222eeee成人天堂

characters

MySQL主從復制部署配置問題匯總

  • MySQL主從復制部署配置問題匯總

      • 主庫show master status沒結(jié)果

      • change master to 時多了空格錯誤

      • MySQL在多實例的情況下啟動故障

      • 由于切換binlog日志導致show master status位置變化對主從無影響

主庫show master status沒結(jié)果

主庫binlog功能開關沒改或沒生效

[root@curder.centos5 /data/3308/data]
# egrep "server-id|log-bin" /data/3307/my.cnf 
log-bin=mysql-bin
server-id = 3307
mysql> show variables like "server_id";
+---------------+-------+
| Variable_name | Value |
+---------------+-------+
| server_id     | 3307  |
+---------------+-------+
1 row in set (0.00 sec)
mysql> show variables like "log_bin";
+---------------+-------+
| Variable_name | Value |
+---------------+-------+
| log_bin       | ON    |
+---------------+-------+
1 row in set (0.00 sec)
提示:配置文件里的參數(shù)和show variables中的參數(shù)不一致,例如my.cnf里log-bin在show variables的時候看到的是log_bin

change master to 時多了空格錯誤

change master to 
master_host="192.168.0.15",
master_port=3307,
master_user='rep',
master_password='reppasswd',
master_log_file=' mysql-bin.000005 ',
master_log_pos=344;
 Last_IO_Error: Got fatal error 1236 from master when reading data from binary log: 'Could not find first log file name in binary log index file'

MySQL在多實例的情況下啟動故障

find /data/3307/ -type f -name 'mysqld.pid'|xargs rm

由于切換binlog日志導致show master status位置變化對主從無影響


Previous article: Next article: