community.zabbix
community.zabbix copied to clipboard
Cannot import zabbix4 inventory.
- ansible version
ansible-inventory [core 2.15.1]
- python version but zabbix server is python2.7
python version = 3.9.17
plugin: community.zabbix.zabbix_inventory
server_url: https://zabbix.test.net/zabbix
add_zabbix_groups: true
login_user: Zabbix
login_password: zabbixpassword
host_zapi_query:
selectInterfaces: ['ip']
selectParentTemplates: ['name']
validate_certs: false
timeout: 300
[WARNING]: * Failed to parse /runner/project/collections/zabbix_inventory.yml
with auto plugin: 'result'
File "/usr/local/lib/python3.9/site-packages/ansible/inventory/manager.py", line 293, in parse_source
plugin.parse(self._inventory, self._loader, source, cache=cache)
File "/usr/local/lib/python3.9/site-packages/ansible/plugins/inventory/auto.py", line 59, in parse
plugin.parse(inventory, loader, path, cache=cache)
File "/runner/requirements_collections/ansible_collections/community/zabbix/plugins/inventory/zabbix_inventory.py", line 420, in parse
self.login_zabbix()
File "/runner/requirements_collections/ansible_collections/community/zabbix/plugins/inventory/zabbix_inventory.py", line 397, in login_zabbix
self.auth = res["result"]
...
16.176 INFO Processing JSON output...
16.177 INFO Loaded 0 groups, 0 hosts
16.190 INFO Inventory import completed for zabbix4 in 0.0s
zabbix inventory is not imported. I'd appreciate your help. please help me @D3DeFi. I need your help.