ctdb-vacuum: Fix the incorrect counting of remote errors
commitcbfb00bc44c966905b657aa6647408ba706da02d
authorAmitay Isaacs <amitay@gmail.com>
Wed, 14 Feb 2018 04:18:17 +0000 (14 15:18 +1100)
committerKarolin Seeger <kseeger@samba.org>
Wed, 10 Oct 2018 13:51:56 +0000 (10 15:51 +0200)
tree99af49cedb0db69faf3ca68ce6252de6f9083ed0
parent485fa6b29eafbdc2c6937196bfffd68e0f274f40
ctdb-vacuum: Fix the incorrect counting of remote errors

If a node fails to delete a record in TRY_DELETE_RECORDS control during
vacuuming, then it's possible that other nodes also may fail to delete a
record.  So instead of deleting the record from RB tree on first failure,
keep track of the remote failures.

Update delete_list.remote_error and delete_list.left statistics only
once per record during the delete_record_traverse.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13641

Signed-off-by: Amitay Isaacs <amitay@gmail.com>
Reviewed-by: Martin Schwenke <martin@meltin.net>
(cherry picked from commit ef052397173522ac2dd0d0bd9660a18a13a3e4fc)
ctdb/server/ctdb_vacuum.c