Direct DB Setup on Zabbix Data Source

I have added Zabbix and DirectDB (MySQL) as data source in Grafana. I also enabled DirectDB in Zabbix data source configuration. I want Grafana to connect to the database that I defined in DirectDB option. I also set the Zabbix PHP endpoint in Zabbix data source configuration. I am trying to understand if the Grafana reaches to the Direct DB database through Zabbix PHP frontend or natively. If yes, is there a method to prove it?

Grafana Version: v8.0.3
Operating System: Ubuntu 20.04.2 LTS


You can do it either via direct db connection or via the api.

I would recommend via api. That way when you upgrade and db schema change things are not broken as api needs to be on par with course.

Hello @yosiasz , thanks for your response. I have two RDS databases in AWS. One is primary RDS database and the other one is the read replica of this primary RDS database. I have defined primary database in Zabbix Frontend and Server configuration. This frontend endpoint is defined in Zabbix data source configuration in Zabbix. Also this Zabbix frontend is connected to the Zabbix server which has primary database in its configuration.

What I am trying to achieve is I want Grafana to use read replica database in its queries so that it wont load the primary database. In the DirectDB setup I defined read replica database. But I cannot prove that Grafana is using the read replica database. Is it possible for me to point a way to prove it?

One crude way is to momentarily stop mysqll service on the live zabbix

Is the replica read only?