southbridgeio / zabbix-review-export-import

Clone of zabbix-review-export with added import object(s) feature
https://gitlab.com/devopshq/zabbix-review-export
50 stars 30 forks source link

Failed import items and triggers with the template zabbix4.4.1 #2

Open kohan2392 opened 4 years ago

kohan2392 commented 4 years ago

Hi, I exported template from zabbix1 and imported to zabbix2. The template was created but without items and triggers.

evgkrsk commented 4 years ago

Yep, there is such problem in current code.

PR are welcome.

ivanmirandaf commented 3 years ago

Olá, ao importar um host obtive o seguinte erro.

2021-04-30 17:12:46,649 INFO JSON-RPC Server Endpoint: http://localhost/zabbix/api_jsonrpc.php 2021-04-30 17:12:52,061 INFO Trying to load Zabbix object (type: host) from: /home/zabbix-review/hosts/PAINEL-CYB-C.Q-5.8.yaml 2021-04-30 17:12:52,111 ERROR KeyError('default',) Traceback (most recent call last): File "zabbix-import.py", line 1518, in main host_cache, File "zabbix-import.py", line 406, in import_host for i in host["interfaces"]["interface"] File "zabbix-import.py", line 406, in for i in host["interfaces"]["interface"] KeyError: 'default' 2021-04-30 17:12:52,113 ERROR Operation failed 2021-04-30 17:12:52,113 ERROR Some operations failed

gjaekel commented 3 years ago

May you also add the failing yaml file, please? If possible, cut down to the problematic part.

evgkrsk commented 3 years ago

Please don't mess up different issues. Open new issue and attach failing yaml file and full --debug output, plus zabbix, python3 and OS versions.