Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- mysqldump
- --all-databases
- --flush-logs
- --single-transaction
- --master-data
- | gzip > dump.sql.gz
- CHANGE MASTER TO MASTER_LOG_FILE='mysql-bin.000012', MASTER_LOG_POS=120;
- FLUSH PRIVILEGES;
- CHANGE MASTER TO
- master_host='master',
- master_user='username',
- master_password='secret';
- START SLAVE;
- SHOW SLAVE STATUSG
- Master_Log_File: mysql-bin.000012
- Read_Master_Log_Pos: 800917736
- Relay_Log_File: relay-bin.000002
- Relay_Log_Pos: 635
- Relay_Master_Log_File: mysql-bin.000001
- Last_Error: Could not execute Write_rows event on table myschema.mytable; Duplicate entry '5191176' for key 'PRIMARY', Error_code: 1062; handler error HA_ERR_FOUND_DUPP_KEY; the event's master log mysql-bin.000001, end_log_pos 778
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement