ctdb-tests: Fix flakey test complex/18_ctdb_reloadips.sh
authorAmitay Isaacs <amitay@gmail.com>
Mon, 11 Apr 2016 04:01:42 +0000 (14:01 +1000)
committerMartin Schwenke <martins@samba.org>
Sat, 23 Apr 2016 21:55:14 +0000 (23:55 +0200)
This test sets TakeoverTimeout=90 to avoid banning during takeover.
However, the setting is done on the test node instead of the recovery
master node.  During "ctdb reloadips", the recovery master will used
the default value of TakeoverTimeout.

Signed-off-by: Amitay Isaacs <amitay@gmail.com>
Reviewed-by: Martin Schwenke <martin@meltin.net>
ctdb/tests/complex/18_ctdb_reloadips.sh

index 9a408353901048fb383a29b1a4a154de2602b037..c61dcdc7c6d7aa7881f2fac67792fe48084e1b73 100755 (executable)
@@ -93,9 +93,10 @@ iface=$(echo "$ctdb_ip_info" | awk -v pnn=$test_node '$2 == pnn { print $3 ; exi
 
 ####################
 
+# This needs to be set only on the recmaster. All nodes should do the trick.
 new_takeover_timeout=90
 echo "Setting TakeoverTimeout=${new_takeover_timeout} to avoid potential bans"
-try_command_on_node $test_node "$CTDB setvar TakeoverTimeout ${new_takeover_timeout}"
+try_command_on_node all "$CTDB setvar TakeoverTimeout ${new_takeover_timeout}"
 
 ####################