Reply

The action is not allowed. A parent was not found

Posts: 5
1985     1

Hello,

 

I've seen a couple of issues with the same error message but even after using the solutions provided I get the same error.

 

The error message: 

AdmConDataError: None (IBDataConflictError: IB.Data.Conflict:The action is not allowed. A parent was not found.)

 

With Python code:

url_add_hostwithaddr = wapi_url + "/record:host?_return_fields%2B=name,ipv4addrs&_return_as_object=1"
headers_add_hostwithaddr = {'content-type': 'application/json'}
data_add_hostwithaddr = "{\"name\": \"hostname\", \"view\": \"default\", \"comment\": \"a comment\", \"ipv4addrs\": [{\"ipv4addr\": \"10.0.0.15\", \"configure_for_dhcp\": false}]}"
allocated_host = api_request("POST", url_add_hostwithaddr, username, password, data=data_add_hostwithaddr, json=headers_add_hostwithaddr)

 

Or with a curl command:

 

curl -k1 -u user:pass -H "Content-Type: appliction/json" -X POST https://infoblox/wapi/v2.11.1/record:host -d "{\"name\": \"hostname\", \"view\": \"default\", \"comment\": \"a comment\", \"ipv4addrs\": [{\"ipv4addr\": \"10.0.0.15\", \"configure_for_dhcp\": false}]}"

 

 

After seeing those issues, I configured the view:

https://community.infoblox.com/t5/API-Integration/The-action-is-not-allowed-A-parent-was-not-found/m...

https://community.infoblox.com/t5/API-Integration/Error-quot-The-action-is-not-allowed-A-parent-was-...

 

Also, I saw this post but was not able to find any regex policy tab in my grid properties?

https://community.infoblox.com/t5/API-Integration/Can-you-create-a-host-record-via-the-API-without-a...

 

 

Thanks in advance!

Re: The action is not allowed. A parent was not found

Community Manager
Community Manager
Posts: 209
1985     1

Host records require either a parent zone or a network.  In the example shown, since DNS is not enabled and the hostname is not fully qualified, there must be a network where the host can be parented.

 

So make sure there's a network configured (such as 10.0.0.0/24 or whatever) before creating the host record.

 

 

Re: The action is not allowed. A parent was not found

Posts: 5
1985     1

The network exist and if I add the same fixed address with this code it's working:

add_fixed_address_url = wapi_url + "/fixedaddress?_return_fields%2B=ipv4addr,mac&_return_as_object=1"
data_fixed_address = "{\"ipv4addr\": \"10.0.0.15\", \"mac\":\"aa:bb:cc:11:22:21\"}"
headers_fixed_address = "{'content-type': 'application/json'}"
allocated_ip = api_request("POST", add_fixed_address_url, username, password, data=data_fixed_address, json=headers_fixed_address)

 

Is there a way to specify the parent nework in the record:host request? 

Re: The action is not allowed. A parent was not found

Posts: 5
1985     1

Well it seems that the solution was to add this in the request:

"configure_for_dns": false

 

Showing results for 
Search instead for 
Did you mean: 

Recommended for You