备份MySQL数据时最好从备库中备份

数据备份对数据库本身有cpu压力;如果为了追求一致性,可能还要施加锁表操作,影响一定的可用性。数据量越大,这些代价就越高。

可以专门设置一个备库,然后从这个备库中把数据和binlog备份出来。

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.