Monitoring mysql database using telegraf

hi everyone i’am using telegraf and influxdb to monitor mysql database in order to display thread connections,connected_users,number of requests on my database
so i used the [[inputs.mysql]] plugin
-telegraf status working fine without error

  • i tested telegraf with “telegraf --config /etc/telegraf/telegraf.conf --config /etc/telegraf/telegraf.conf --test” it shows data
    but while updloading a mysql dashboard on my Grafana i got that unknown error and all graph shows ‘‘no data’’:
    Template variables could not be initialized: Error 1064: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ‘TAG VALUES WITH KEY=“server”’ at line 1

So it sounds like there’s an error in your Grafana template. I don’t really know much about that, so you might have better luck on the Grafana support forums or with the template author.

Try building a dashboard from scratch rather than importing an existing one. Let us know how it goes.

1 Like