]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
ctdb-recovery: Do not run local ip verification when in recovery
authorAmitay Isaacs <amitay@gmail.com>
Thu, 22 Jun 2017 06:15:47 +0000 (16:15 +1000)
committerKarolin Seeger <kseeger@samba.org>
Mon, 26 Jun 2017 14:57:51 +0000 (16:57 +0200)
BUG: https://bugzilla.samba.org/show_bug.cgi?id=12857

If we drop public IPs because CTDB is in recovery for too long, then
avoid spamming logs "Trigger takeoverrun" every second.

Signed-off-by: Amitay Isaacs <amitay@gmail.com>
Reviewed-by: Martin Schwenke <martin@meltin.net>
(cherry picked from commit ea46699b27ef8d4ac7b5dd07035465cb3df09ea4)

Autobuild-User(v4-5-test): Karolin Seeger <kseeger@samba.org>
Autobuild-Date(v4-5-test): Mon Jun 26 16:57:51 CEST 2017 on sn-devel-144

ctdb/server/ctdb_recoverd.c

index c7f31e321c1a1e08828ea7b9dff369d542886246..f947ee065c7cad8bef4a0278c92b428a0e76f71a 100644 (file)
@@ -2658,9 +2658,11 @@ static void main_loop(struct ctdb_context *ctdb, struct ctdb_recoverd *rec,
                return;
        }
 
-       /* Check if an IP takeover run is needed and trigger one if
-        * necessary */
-       verify_local_ip_allocation(ctdb, rec, pnn, nodemap);
+       if (ctdb->recovery_mode == CTDB_RECOVERY_NORMAL) {
+               /* Check if an IP takeover run is needed and trigger one if
+                * necessary */
+               verify_local_ip_allocation(ctdb, rec, pnn, nodemap);
+       }
 
        /* if we are not the recmaster then we do not need to check
           if recovery is needed