1
0
mirror of https://github.com/samba-team/samba.git synced 2025-02-03 13:47:25 +03:00

ctdb-vacuum: Do not delete VACUUM MIGRATED records immediately

Such records should be processed by the local vacuuming daemon to ensure
that all the remote copies have been deleted first.

Signed-off-by: Amitay Isaacs <amitay@gmail.com>
Reviewed-by: Martin Schwenke <martin@meltin.net>
This commit is contained in:
Amitay Isaacs 2014-04-14 14:53:25 +10:00 committed by Amitay Isaacs
parent dbb1958284
commit 257311e337

View File

@ -115,6 +115,11 @@ static int ctdb_ltdb_store_server(struct ctdb_db_context *ctdb_db,
* fails. So storing the empty record makes sure that we do not
* need to change the client code.
*/
if ((header->flags & CTDB_REC_FLAG_VACUUM_MIGRATED) &&
(ctdb_db->ctdb->pnn == header->dmaster)) {
keep = true;
schedule_for_deletion = true;
}
if (!(header->flags & CTDB_REC_FLAG_VACUUM_MIGRATED)) {
keep = true;
} else if (ctdb_db->ctdb->pnn != header->dmaster) {