Reply

Avoid Conversion of Parent Network into "Network Container" upon Subnet Creation

sameer82
Techie
Posts: 1
3193     1

Hi,

 

We have 2 use cases of creating either any available network(which works perfectly) or user-specified subnet.

Use Case 1(Creation of next available free subnet)

Lets say, we need to create next free /29 under the exisitng /23 Network Container. For this we use below mentioned API. And it works perfectly. 

Step 1:

We get the Network Container _ref by calling below API

https://<infoblox-dns.com>/wapi/v1.4.2/networkcontainer?network=221.22.22.0/23&_return_fields=extattrs

This returns lets say _ref = networkcontainer/ZG5zLm5ld:221.22.22.0/23/default

Step 2:

Request for next available /29 subnet under the Network Container specified by _ref

https://<infoblox-dns.com>/wapi/v1.4.2/networkcontainer/ZG5zLm5ld:221.22.22.0/23/default?_function=next_available_network&cidr=28

This returns lets say: 221.22.22.112/28

 

Use Case 2(Creation of user-specified subnet):

Considering I already hold a 221.22.22.112/28 subnet whose hosts are yet to be used, but should not get modified as its considered reserved.

This is a case, where user specified subnet as : 221.22.22.112/29 and user sends the request to create subnet as:

https://<infoblox-dns.com>/wapi/v1.4.2/network

    {

        "network": "221.22.22.112/29"

    }

This creates a subnet as 221.22.22.112/29, but converts 221.22.22.112/28 from subnet to a Network Container which we don';t expect it to, as its a Subnet overlap.

Please suggest how can we avoid this overlap or is there any other API or attributes we should send in the POST request to avoid this further.

 

So, in this case case we typically do not want 221.22.22.112/29 to get created, rather it should throw back an error, saying that already we have a /28 as a subnet (which is not a network container).

Re: Avoid Conversion of Parent Network into "Network Container" upon Subnet Creation

spenumaka Community Manager
Community Manager
Posts: 137
3194     1

Thanks Sameer82 for sharing. I moved it to API & Integration. forum.

--------------------------------------
Check out our new Tech docs website for latest documentation on Infoblox products.
Showing results for 
Search instead for 
Do you mean 

Recommended for You