Reply
Accepted Solution

func:nextavailableip: range

kenmaglio
Techie
Posts: 4
352     0

We are having a problem withe func:nextavailableip

 

We can successfully do something like: func:nextavailableip:10.10.10.0/24,default  

However, this fails: func:nextavailableip:10.10.10.10-10.10.10.50,default

 

 

We are posting to   /record:host

 

10.10.10.10-10.10.10.50,default does not match any unique networks/ranges (ipv4addr)

 

Any ideas?   we are using  v1.6 of the API.

 

Re: func:nextavailableip: range

GHorne Community Manager
Community Manager
Posts: 254
352     0

That sounds like a bug. And it may have been fixed with later versions of the API.

 

Kick the question to support and see what they say.

Re: func:nextavailableip: range

kenmaglio
Techie
Posts: 4
352     0

So I went a different way, and we have in our templates a reserved range, for these "auto-selected" ip's I want to automate creating a host..  so I found the range using   /range?network~=10.10.10.0  ( as we use /23 and /24 networks and can't determine that ahead of tiem)  and   &comment~=WACKY  (whatever word is in your range comment you want to filter on).  

 

Then using the reference of the Range object  range/________   I fed that into  nextavailableip:range/____

and it's working!!!

Highlighted

Re: func:nextavailableip: range

[ Edited ]
BHanson
Techie
Posts: 9
352     0

any answer to the original syntax of using a range within a subnet?

shouldn't it work?  I get the same error.  v2.7.3

 

So to specify a range the range has to be defined (as a reserved (DHCP) range) within the subnet? It isn't clear. And it isn't really used for DHCP, it is used by those calling the API (i checked the DHCP disable).

 

Now the range can be given a name. Can that name be used in place of the range itself? It sure would be nice to insulate the caller (and the code that calls the API) from having to know what the IP subnet or IP range is.   

 

Thanks for any insight on how to get this done!  

Showing results for 
Search instead for 
Do you mean 

Recommended for You