Reply

Node HA Failover by wAPI/REST

New Member
Posts: 3
2204     2

Hi Team!

 

We do node HA failover testing on a routine basis, currently we login to the grid and push buttons to force failover between nodes (pic below of what we choose, Grid - Grid Master - Members - checkmark the pair to HA - Control - Force HA Failover - Click Ok to confirm - Wait).

I am wondering if there is a wAPI/REST call to make this happen?  I looked through the wAPI/REST guides and searched here but didnt find anything.  I know sometimes there are hidden/undocumented APIs.

Thank you!

IB-HA-failover.png

Re: Node HA Failover by wAPI/REST

Techie
Posts: 17
2204     2

Hi apasquali_,

 

I looked through the WAPI documentation and I believe your assumption is correct, however, there may be a workaround. In the API call dhcpfailover,  two function calls exist that may help:

 

set_dhcp_failover_partner_down: Force a HA member into a 'Partner Down' state 

set_dhcp_failover_secondary_recovery: Force the failover recovery of the secondary member in the HA pair

These calls are on page 375 of the WAPI documentation (link). I cannot confirm that these calls will work the same as a 'Force HA failover' from the web interface, so I suggest testing these calls in a lab to confirm if they have the desired results.

 

Thank you,

David

Re: Node HA Failover by wAPI/REST

New Member
Posts: 6
2204     2

HA failover (Failover between two members that are in the same cluster) is very differnt than a DHCP failover association (Failover beween two members or clusters). "set_dhcp_failover_partner_down" and "set_dhcp_failover_secondary_recovery" only affect the DHCP relationship, not between members of the same cluster. 

Re: Node HA Failover by wAPI/REST

New Member
Posts: 6
2204     2

The call you are looking for is a function call on the member object. Here is a generic link to the appropriate documentation:

 

https://<GM>/wapidoc/objects/member.html#member-admin-operation

Let me know if you need an example call.


Re: Node HA Failover by wAPI/REST

New Member
Posts: 3
2204     2

I know this is like 9 months old but for anyone who comes looking...

 

Successfully tested example code - 

 

url = "https://<infoblox>/wapi/v2.11.3/member/member/ZG5zLm5ldHdvcmtfdmlldyQxMTk:member.com/"
params = {
	"_function": "member_admin_operation"
	}
data = {
	"operation": "FORCE_FAILOVER"
	}
r = session.post (url, auth=(user,passwd), verify=False, data=json.dumps(data), params=params)
Showing results for 
Search instead for 
Did you mean: 

Recommended for You