- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
Trying to add a DHCP range with a Failover association instead of a DHCP member using the REST API.
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
05-02-2018 08:51 AM
I'm new to the REST API and I'm trying to add a DHCP range with the member set to a failover association. I've been successful at adding a range with a single member but I've been unable to find the data structure for adding a range with the failover association. The structure for adding a range with a member is this.
{"result": {"_ref": "range/ZG5zLmRoY3BfcmFuZ2UkMTAuMTAuMTAuMjAvMTAuMTAuMTAuMTAwLy8vMC8:10.10.10.20/10.10.10.100/default", "end_addr": "10.10.10.100", "member": {"_struct": "dhcpmember", "ipv4addr": "172.26.1.3", "ipv6addr": null, "name": "member1.localdomain" }, "network": "10.10.10.0/24", "network_view": "default", "start_addr": "10.10.10.20" }}
Can anyone tell me what construct looks like for adding the range with a failover association instead of a member?
Thanks very much.
Solved! Go to Solution.
Re: Trying to add a DHCP range with a Failover association instead of a DHCP member using the REST A
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
05-02-2018 07:43 PM
Adding a range and assinging a failover is a bit more simple than the member, we just need to give the name of the failover association. For example:
{"start_addr": "10.99.1.100", "end_addr": "10.99.1.199","failover_association": "Dallas-Chicago"}"
And here's the full unix curl example to make a new range, assigned to the failover:
curl -k1 -u admin:infoblox -X POST 'https://10.9.16.6/wapi/v2.7/range' -H "Content-Type: application/json" \
-d "{\"end_addr\": \"10.99.1.199\",\"start_addr\": \"10.99.1.100\",\"failover_association\": \"Dallas-Chicago\"}"
Re: Trying to add a DHCP range with a Failover association instead of a DHCP member using the REST A
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
05-03-2018 02:32 PM
That worked perfectly. Thank you so much for your assitance.
Re: Trying to add a DHCP range with a Failover association instead of a DHCP member using the REST A
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
05-03-2018 02:42 PM
On a side note, if you use single quotes around the -d string you don't need to use the backslashes.
-d '{"end_addr": "10.99.1.199","start_addr": "10.99.1.100","failover_association": "Dallas-Chicago"}'
This works too. I find it just makes it easier to read and type.
Re: Trying to add a DHCP range with a Failover association instead of a DHCP member using the REST A
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
03-21-2020 03:58 PM
Can you suggest how to do this using the /network endpoint? I usually create the network, range and tie it to the vlan all in one step. Like:
Re: Trying to add a DHCP range with a Failover association instead of a DHCP member using the REST A
[ Edited ]- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
03-21-2020 04:08 PM - edited 03-24-2020 02:32 PM
I'm guessing I have to pull the members from the failover association, and add all members to the network endpoint call. Caveat being if one member is replaced with another, would I lose the association with the failover group members in the DHCP range?
Would love to see the curls that do the assignment to the network, then the assignment of the dhcp failover to the range.
Re: Trying to add a DHCP range with a Failover association instead of a DHCP member using the REST A
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
a week ago
Do you get the answer? How can we add DHCP range with a failover association while create network?