title: Verify that master and slave database have the same data
body: <p>Currently, I am using Master-Slave replication (MySQL) as backup plan. Master feed any update/insert query to slave database and I automatically set a schedule in slave server to do regular full backup. What I concern the most is that there could be a rare case that my slave might not have the same data as my master.</p>
  
  <p><strong>Is there any way that I can confirm that my slave has the same data as my master database</strong>. Usually, I randomly check the ID of some tables and if the latest ID are the same then I assume that it is more likely that both have the same data (at least, have the same number of rows).</p>
  
  <p>This question could fit better in other StackExchange website such as S<a href="https://dba.stackexchange.com/">tackExchange - Database Administrators</a> and <a href="https://serverfault.com/">Serverfault</a>, but I prefer it here because this site has the most active people, and this question is not totally irrelevant to programmer. However, feel free to move if you think it is inappropriate.</p>