Hello guys!
I want to create dynamic items for each host.
The items should be created based on a result from a SQL query.
I saw that using LLD I can create this, but I don't know how to identify a host in the query.
For example: I have a table with columns zabbix_host_id and ip_destination.
I want to get ip_destination of my specific Zabbix Agent.
The result will create items to check ping to these ip_destination.
But, the Zabbix Host ID 1002 checks to server A, B and D. Zabbix Host ID 1005 checks to B, C and E.
How can I do this?
I want to create dynamic items for each host.
The items should be created based on a result from a SQL query.
I saw that using LLD I can create this, but I don't know how to identify a host in the query.
For example: I have a table with columns zabbix_host_id and ip_destination.
I want to get ip_destination of my specific Zabbix Agent.
Code:
SELECT ip_destination FROM monitoring WHERE zabbix_host_ID = {#SERVER_HOST_ID}
But, the Zabbix Host ID 1002 checks to server A, B and D. Zabbix Host ID 1005 checks to B, C and E.
How can I do this?