- 论坛徽章:
- 0
|
本帖最后由 fzud 于 2012-01-09 10:23 编辑
公司使用mysql,为了数据的安全以及以后的读写分离,做了主从复制,看了很多地方都使用这种模式,按理说应该是经过市场考验的,但是我这里的使用过程中一直出现个主从数据不一致的问题,主要体现在从服务器数据丢失情况,比如主服务器某字段改了,从服务器却没有变化,而且此现象还没找到规律,同样的操作可能有的同步有个别的就没有同步,从服务器没有设置跳过错误,并且日志中没有出现任何错误信息。
mysql版本5.1.56
主服务器相关设置:
server-id=1
log-bin=mysql-bin
binlog_format=mixed
sync_binlog=1
binlog-do-db=mms
从服务器相关设置:
server-id=3
replicate-do-db=mms
从库状态:
Slave_IO_Running: Yes
Slave_SQL_Running: Yes
Replicate_Ignore_DB: mysql
Replicate_Do_Table:
Replicate_Ignore_Table:
Replicate_Wild_Do_Table:
Replicate_Wild_Ignore_Table:
Last_Errno: 0
Last_Error:
Skip_Counter: 0
Exec_Master_Log_Pos: 129188236
Relay_Log_Space: 129189068
Until_Condition: None
Until_Log_File:
Until_Log_Pos: 0
Master_SSL_Allowed: No
Master_SSL_CA_File:
Master_SSL_CA_Path:
Master_SSL_Cert:
Master_SSL_Cipher:
Master_SSL_Key:
Seconds_Behind_Master: 0
Master_SSL_Verify_Server_Cert: No
这两天做了表的一致性检查约70%的表是完全一致,剩下的表出现不一致情况。
大家帮我分析下,问题可能出现在哪里,有什么办法能解决? |
|