Closed davisionz closed 7 years ago
new infoblox user error... this was due to a lack of entries for range objects in Infoblox.
@davisionz
Can you explain what you did inside of Infoblox to enable this feature? I am getting the same error you are getting.
In order to call from a range you have to create a range inside of the IP network first. Once created, you have to call that range explicitly in your ansible script. In infoblox, you can create dhcp ranges and reservation ranges.
@davisionz The non-DHCP reservation worked perfectly. Thank you for the quick reply.
Good to hear. 👍
using the following YAML, i get "No network/range found for specified parameters trying to call from IPs in a certain range:
OUTPUT:
1 plays in infoblox_add_entry.yml 5 6 PLAY [Get an IP address from infoblox] *16:11:39 7 META: ran handlers 8 9 TASK [request IP address from Infoblox] ****16:11:39 10 Using module file /var/lib/awx/projects/_8__ansible_provision/library/infoblox.py 11 <127.0.0.1> ESTABLISH LOCAL CONNECTION FOR USER: awx 12 <127.0.0.1> EXEC /bin/sh -c 'echo ~ && sleep 0' 13 <127.0.0.1> EXEC /bin/sh -c '( umask 77 && mkdir -p "\n main()\n File \"/tmp/ansible_c9_YWs/ansible_module_infoblox.py\", line 1921, in main\n raise Exception(\"No network/range found for specified parameters\")\nException: No network/range found for specified parameters\n", "module_stdout": "", "msg": "MODULE FAILURE", "rc": 0}
19
20
PLAY RECAP ***** 16:11:40
21
localhost : ok=0 changed=0 unreachable=0 failed=1
22
echo /var/lib/awx/.ansible/tmp/ansible-tmp-1510265499.85-31244050963084
" && echo ansible-tmp-1510265499.85-31244050963084="echo /var/lib/awx/.ansible/tmp/ansible-tmp-1510265499.85-31244050963084
" ) && sleep 0' 14 <127.0.0.1> PUT /tmp/tmp5Ng2HU TO /var/lib/awx/.ansible/tmp/ansible-tmp-1510265499.85-31244050963084/infoblox.py 15 <127.0.0.1> EXEC /bin/sh -c 'chmod u+x /var/lib/awx/.ansible/tmp/ansible-tmp-1510265499.85-31244050963084/ /var/lib/awx/.ansible/tmp/ansible-tmp-1510265499.85-31244050963084/infoblox.py && sleep 0' 16 <127.0.0.1> EXEC /bin/sh -c '/usr/bin/python2 /var/lib/awx/.ansible/tmp/ansible-tmp-1510265499.85-31244050963084/infoblox.py; rm -rf "/var/lib/awx/.ansible/tmp/ansible-tmp-1510265499.85-31244050963084/" > /dev/null 2>&1 && sleep 0' 17 An exception occurred during task execution. To see the full traceback, use -vvv. The error was: Exception: No network/range found for specified parameters 18 fatal: [localhost]: FAILED! => {"changed": false, "failed": true, "module_stderr": "Traceback (most recent call last):\n File \"/tmp/ansible_c9_YWs/ansible_module_infoblox.py\", line 2205, in