3 # Verify that a node's public IP address can be deleted using 'ctdb deleteip'.
5 # This is an extended version of simple/17_ctdb_config_delete_ip.sh
7 .
"${TEST_SCRIPTS_DIR}/cluster.bash"
11 test_node_has_test_ip
()
13 # $test_node and $test_ip set by select_test_node_and_ips()
14 # shellcheck disable=SC2154
15 try_command_on_node
"$test_node" "ip addr show to ${test_ip}"
21 select_test_node_and_ips
23 echo "Checking that node ${test_node} hosts ${test_ip}..."
26 echo "Attempting to remove ${test_ip} from node ${test_node}."
27 try_command_on_node
$test_node $CTDB delip
$test_ip
28 try_command_on_node
$test_node $CTDB ipreallocate
29 wait_until_ips_are_on_node
'!' $test_node $test_ip
31 echo "Waiting for ${test_ip} to disappear from node ${test_node}..."
32 wait_until
60/5 '!' test_node_has_test_ip
34 echo "GOOD: IP was successfully removed!"