diff options
author | Martin Schwenke <martin@meltin.net> | 2014-02-07 17:19:20 +1100 |
---|---|---|
committer | Amitay Isaacs <amitay@samba.org> | 2014-02-13 02:03:24 +0100 |
commit | f1a20d748f6ab4702be5b17047a3fbfa0f3e8d0c (patch) | |
tree | cb321633e223ad8547af3f163a5b2923d4f80e3b /ctdb/tests/takeover/lcp2.023.sh | |
parent | 50fc53d7f11a3c28fd4ef5318d90f842bbc0f19c (diff) | |
download | samba-f1a20d748f6ab4702be5b17047a3fbfa0f3e8d0c.tar.gz samba-f1a20d748f6ab4702be5b17047a3fbfa0f3e8d0c.tar.xz samba-f1a20d748f6ab4702be5b17047a3fbfa0f3e8d0c.zip |
ctdb-recoverd: Fix a bug in the LCP2 rebalancing code
srcimbl gets changed on every iteration of the loop. The value that
should be stored for the new imbalance of the source node is
minsrcimbl.
To help diagnose this, added some extra debug that can be left in.
The extra debug changes the output of a couple of tests. Note that
the resulting IP allocations in those tests is unchanged - only the
debug output is changed.
Also add some new tests that illustrates the bug.
Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Diffstat (limited to 'ctdb/tests/takeover/lcp2.023.sh')
-rwxr-xr-x | ctdb/tests/takeover/lcp2.023.sh | 34 |
1 files changed, 27 insertions, 7 deletions
diff --git a/ctdb/tests/takeover/lcp2.023.sh b/ctdb/tests/takeover/lcp2.023.sh index 9bffc58c6b..0f35b3ea88 100755 --- a/ctdb/tests/takeover/lcp2.023.sh +++ b/ctdb/tests/takeover/lcp2.023.sh @@ -10,6 +10,11 @@ required_result <<EOF DATE TIME [PID]: ---------------------------------------- DATE TIME [PID]: CONSIDERING MOVES (UNASSIGNED) DATE TIME [PID]: ---------------------------------------- +DATE TIME [PID]: +++++++++++++++++++++++++++++++++++++++++ +DATE TIME [PID]: Selecting most imbalanced node from: +DATE TIME [PID]: 0 [89609] +DATE TIME [PID]: 1 [0] +DATE TIME [PID]: 2 [147968] DATE TIME [PID]: ---------------------------------------- DATE TIME [PID]: CONSIDERING MOVES FROM 2 [147968] DATE TIME [PID]: 2 [-58359] -> 192.168.21.254 -> 1 [+0] @@ -19,6 +24,11 @@ DATE TIME [PID]: 2 [-59823] -> 192.168.20.251 -> 1 [+0] DATE TIME [PID]: 2 [-59823] -> 192.168.20.249 -> 1 [+0] DATE TIME [PID]: ---------------------------------------- DATE TIME [PID]: 2 [-59823] -> 192.168.20.251 -> 1 [+0] +DATE TIME [PID]: +++++++++++++++++++++++++++++++++++++++++ +DATE TIME [PID]: Selecting most imbalanced node from: +DATE TIME [PID]: 0 [89609] +DATE TIME [PID]: 1 [0] +DATE TIME [PID]: 2 [88145] DATE TIME [PID]: ---------------------------------------- DATE TIME [PID]: CONSIDERING MOVES FROM 0 [89609] DATE TIME [PID]: 0 [-42483] -> 192.168.21.253 -> 1 [+14161] @@ -27,6 +37,11 @@ DATE TIME [PID]: 0 [-45662] -> 192.168.20.252 -> 1 [+15625] DATE TIME [PID]: 0 [-45411] -> 192.168.20.250 -> 1 [+16129] DATE TIME [PID]: ---------------------------------------- DATE TIME [PID]: 0 [-45662] -> 192.168.20.254 -> 1 [+15625] +DATE TIME [PID]: +++++++++++++++++++++++++++++++++++++++++ +DATE TIME [PID]: Selecting most imbalanced node from: +DATE TIME [PID]: 0 [43947] +DATE TIME [PID]: 1 [15625] +DATE TIME [PID]: 2 [88145] DATE TIME [PID]: ---------------------------------------- DATE TIME [PID]: CONSIDERING MOVES FROM 2 [88145] DATE TIME [PID]: 2 [-44198] -> 192.168.21.254 -> 1 [+28322] @@ -35,24 +50,29 @@ DATE TIME [PID]: 2 [-43947] -> 192.168.20.253 -> 1 [+31501] DATE TIME [PID]: 2 [-43947] -> 192.168.20.249 -> 1 [+31501] DATE TIME [PID]: ---------------------------------------- DATE TIME [PID]: 2 [-44198] -> 192.168.21.254 -> 1 [+28322] +DATE TIME [PID]: +++++++++++++++++++++++++++++++++++++++++ +DATE TIME [PID]: Selecting most imbalanced node from: +DATE TIME [PID]: 0 [43947] +DATE TIME [PID]: 1 [43947] +DATE TIME [PID]: 2 [43947] DATE TIME [PID]: ---------------------------------------- -DATE TIME [PID]: CONSIDERING MOVES FROM 0 [44198] +DATE TIME [PID]: CONSIDERING MOVES FROM 0 [43947] DATE TIME [PID]: 0 [-28322] -> 192.168.21.253 -> 1 [+44198] DATE TIME [PID]: 0 [-29786] -> 192.168.20.252 -> 1 [+45662] DATE TIME [PID]: 0 [-29786] -> 192.168.20.250 -> 1 [+45915] DATE TIME [PID]: ---------------------------------------- DATE TIME [PID]: ---------------------------------------- -DATE TIME [PID]: CONSIDERING MOVES FROM 2 [44198] -DATE TIME [PID]: 2 [-28322] -> 192.168.21.252 -> 1 [+44198] -DATE TIME [PID]: 2 [-29786] -> 192.168.20.253 -> 1 [+45662] -DATE TIME [PID]: 2 [-29786] -> 192.168.20.249 -> 1 [+45662] -DATE TIME [PID]: ---------------------------------------- -DATE TIME [PID]: ---------------------------------------- DATE TIME [PID]: CONSIDERING MOVES FROM 1 [43947] DATE TIME [PID]: 1 [-28322] -> 192.168.21.254 -> 1 [+28322] DATE TIME [PID]: 1 [-29786] -> 192.168.20.254 -> 1 [+29786] DATE TIME [PID]: 1 [-29786] -> 192.168.20.251 -> 1 [+29786] DATE TIME [PID]: ---------------------------------------- +DATE TIME [PID]: ---------------------------------------- +DATE TIME [PID]: CONSIDERING MOVES FROM 2 [43947] +DATE TIME [PID]: 2 [-28322] -> 192.168.21.252 -> 1 [+44198] +DATE TIME [PID]: 2 [-29786] -> 192.168.20.253 -> 1 [+45662] +DATE TIME [PID]: 2 [-29786] -> 192.168.20.249 -> 1 [+45662] +DATE TIME [PID]: ---------------------------------------- 192.168.21.254 1 192.168.21.253 0 192.168.21.252 2 |