ctdb-recoverd: Clean up logging on failure to take recovery lock
authorMartin Schwenke <martin@meltin.net>
Mon, 21 Jan 2019 05:36:13 +0000 (16:36 +1100)
committerAmitay Isaacs <amitay@samba.org>
Mon, 25 Feb 2019 01:12:16 +0000 (02:12 +0100)
Add an explicit case for a timeout and clean up the other messages.

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

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
ctdb/server/ctdb_recoverd.c

index a63021e4d8b69ae26575b55d2c5a77125876d19e..473e6cbe8cc8d3bf9c6beda4a8582a2d253d0a00 100644 (file)
@@ -913,12 +913,15 @@ static void take_reclock_handler(char status,
                break;
 
        case '1':
-               DEBUG(DEBUG_ERR,
-                     ("Unable to take recovery lock - contention\n"));
+               D_ERR("Unable to take recovery lock - contention\n");
+               break;
+
+       case '2':
+               D_ERR("Unable to take recovery lock - timeout\n");
                break;
 
        default:
-               DEBUG(DEBUG_ERR, ("ERROR: when taking recovery lock\n"));
+               D_ERR("Unable to take recover lock - unknown error\n");
        }
 
        s->done = true;