In 5.2 when importing a host with items, discovery rules and item prototypes that use a non existing interface the error message is always the same: "Item uses incorrect interface type", but in 4.0 it is explicitly mentioned which instance on which host has caused the error: "Cannot find interface "if3" used for item prototype "Hostname" of discovery rule "DR ZA" on "test"."
Steps to reproduce:
- Create a host with a Zabbix agent interface (if1), an item and a discoverry rule with item prototype that use this interface.
- Export the host
- In the exported file change the "interface_ref" parameter of the item prototype or of the discovery rule from "if1" to a non-existing reference "if2"
- Delete the previously created host
- Import the previously exported xml (or other selected type of export).
Result: the following error message is returned:
Item uses incorrect interface type.
Expected: Same as in the 4.0 branch, the error should clearly mention the host and the corresponding instance that caused the problem during import:
Cannot find interface "if2" used for item prototype "Hostname" of discovery rule "DR ZA" on "test".
Host export with incorrect item prototype interface: host_with_incorrect_interface.xml