Check out the mk-table-sync . It compares two tables on different servers using checksums of pieces of rows. If this block is identical between two servers, copying is not required. If a piece is different, it copies only the piece that it needs. You do not need to erase the local table.
Another alternative is to copy the deleted data to a separate table name. If it succeeds, then DROP the old table and RENAME the new local copy in the original table name. If the copy fails or is interrupted, open a local copy with a different name and try again. Meanwhile, your other local table with previous data is not affected.
source share