MySQL Metrics with InstrumentalD

MySQL logo

The best way to get MySQL metrics into Instrumental is with InstrumentalD, the fast and reliable server agent created by the Instrumental team. By using InstrumentalD to collect MySQL metrics, you'll get premade MySQL graphs and unlock the full power of our Query Language.

Quick Start

Check out our Installation Instructions for more details. Otherwise, here's the bare minimum to get up and running.

brew install instrumental/instrumentald/instrumentald
echo 'mysql = ["root@tcp(localhost:3306)/"]' >> instrumentald.toml
instrumentald -c instrumentald.toml -k PROJECT_TOKEN
curl | sudo bash
sudo apt-get install instrumentald
echo 'project_token = "PROJECT_TOKEN"' | sudo tee /etc/instrumentald.toml
echo 'mysql = ["root@tcp(localhost:3306)/"]' | sudo tee -a /etc/instrumentald.toml
sudo systemctl restart instrumentald
curl | sudo bash
sudo yum install instrumentald
echo 'project_token = "PROJECT_TOKEN"' | sudo tee /etc/instrumentald.toml
echo 'mysql = ["root@tcp(localhost:3306)/"]' | sudo tee -a /etc/instrumentald.toml
sudo service instrumentald restart

Configuring InstrumentalD

InstrumentalD will collect the metrics below from as many MySQL servers as configured. Here's a basic example of the MySQL config:

mysql = ["root@tcp(localhost:3306)/"]

Everything you need to know about configuring InstrumentalD, including more information about MySQL config, can be found in the InstrumentalD Configuration docs.

Metrics Collected

All MySQL metrics collected by InstrumentalD follow this pattern:

The following metrics are collected:
bytes_sent Count of bytes sent since server start
bytes_received Count of bytes received since server start
connections Count of the number of open connections since server started
slow_queries Count of slow queries since server start
queries Count of queries since server start

Note: You can use growth_rate to get the difference in count between units of resolution. For example, the following query will give you the the number of queries from minute to minute.


How many metrics can I expect from InstrumentalD?

InstrumentalD will collect 5 metrics per MySQL database configured.


Here are the graphs included in our MySQL Dashboard. It's a great way to get started visualizing these metrics.

Log in or sign up to add them to your project.

Questions? We can help!