Hi,
Using MySQL 5.5;
I am taking a consistent mysqldump for replicating the existing master data to the slave.
Please confirm my steps are correct ? I am getting 1% more records in slave db after import.
1)
mysqldump --user=root --password=my_pwd -A --single-transaction --quick --master-data=2 --extended-insert --flush-logs --all-databases --add-drop-database --add-drop-table > /tmp/backup.sql
2) After dump complete, log-in to “mysql” in the same session and run;
mysql> UNLOCK TABLES;
3) mysql --user=root --password=my_pwd < /tmp/backup.sql
Thanks
Using MySQL 5.5;
I am taking a consistent mysqldump for replicating the existing master data to the slave.
Please confirm my steps are correct ? I am getting 1% more records in slave db after import.
1)
mysqldump --user=root --password=my_pwd -A --single-transaction --quick --master-data=2 --extended-insert --flush-logs --all-databases --add-drop-database --add-drop-table > /tmp/backup.sql
2) After dump complete, log-in to “mysql” in the same session and run;
mysql> UNLOCK TABLES;
3) mysql --user=root --password=my_pwd < /tmp/backup.sql
Thanks