Open jurim76 opened 3 years ago
We also about to switch to 5.4.2. While there is an on-the-fly migration of screens to dashboards, there's still no ex-/import for dashboards.
Formerly, we use a screen generator tool. This is cut-off, because after migration, there's seems no possibility to "import-and-convert" screens, anymore.
We might rewrite our tool to create dashboards. But at the moment, there seems also no possibility to import dashboards, right?
PR-s are welcome. Unfortunately, we don't have zabbix-5.4 stand right now.
There is support for dashboard import, but it is poorly tested on 5.x branches.
We used ex- and import on our 4.4.2 and I works for us, i.e. for the Zabbix features we use.
We'll try to investigate the code and develop patches.
I found that zabbix_import
seems to fail on retreiving users even if I use something without like a dashboard YAML as input. On https://www.zabbix.com/documentation/current/manual/api/changes_5.2_-_5.4 I found the "first big change":
user
Changes: ZBXNEXT-6474 user.login: Renamed parameter user → username. ZBXNEXT-6474 Renamed field alias → username in user object.
How you would handle this? In a way that's up- and downward compatible, i.e. get the API version and switch exported tags, but try to convert at import? Well, probably like https://github.com/southbridgeio/zabbix-review-export-import/blob/ddbad3c2aadcf74c693fdc86761cb5ac22fecf7e/zabbix-import.py#L1064-L1094
Hi, I have only tested on yaml export, the following works on Zabbix 5.4.7:
sed 's/alias/username/g' -i zabbix-export.py
Off course this renders the script incompatible with previous Zabbix versions.
I am only exporting the following:
Hi, I have only tested on yaml export, the following works on Zabbix 5.4.7:
sed 's/alias/username/g' -i zabbix-export.py
Off course this renders the script incompatible with previous Zabbix versions.
Mostly screens and dashboards are affected.
zabbix api 5.4.10
2022-02-09 05:20:29,486 ERROR ('Error -32602: Invalid params., Invalid parameter "/options": unexpected parameter "valueMaps".', -32602)
Export throws an errors, while dumping screens, dashboards, users and valuemaps from Zabbix 5.4.2. Also templates have yaml format by default and user's alias changed to username.