summaryrefslogtreecommitdiff
path: root/templates-op/force/cluster/active/node.def
blob: fc91fc70952c9c630dc9523cbaf0f67728c6e003 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
help: Attempt to take over cluster resources and become the active node
run: local -a grp ;
     local -a params ;
     eval "grp=($(cli-shell-api listActiveNodes cluster group))"
     if [ -n "$grp" ]; then
       params=($(cli-shell-api returnActiveValue cluster group $grp auto-failback))
       if [ "$params" == "true" ]; then
         echo "Warning: Auto-failback is configured."
       fi
       sudo /usr/share/heartbeat/hb_takeover >&/dev/null
       echo "Requesting to take over cluster resources"
     else
       echo "Clustering is not configured"
     fi