Step To Configure Centralised Database For Grafana On CentOs 7

Step To Configure Centralised Database is the core of your company. you always need to make a backup server for the high availability of the database. If we make a database on the same server where an application is installed and running. We can configure a centralized grafana high availability database on Linux. so

Check Out: Active Directory Integration With Grafana Version 5.x.x

It can be very dangerous for both database and application as if the server failed, You do not have any way to recover it until you have some backup of that server. so

Step To Configure Centralised Database For Grafana:

The purpose of connecting Grafana application it to the centralized database as it can improve the performance of servers and data always be available for users. so

Our Scenario Requirement

  1. Centralized database server IP
  2. Grafana Testing Application IP
  3. Grafana Production Application IP

Configuration Database:

Login to your database server mysql –u root -p

Create a USER and grant Permission on database

so CREATE USER ‘username’@’’ IDENTIFIED BY ‘password’;

  1. Grants Permission to access the database  
GRANT ALL PRIVILEGES ON database_name.* TO ‘username’@’’ IDENTIFIED BY ‘password’;


GRANT ALL PRIVILEGES ON database_name.* TO ‘username’@’’ IDENTIFIED BY ‘password’;

In Case, you have two Grafana Server.

Check Out: Step To Configure HA (High Availability) For Grafana


Configure Grafana to use this database

Go to the Grafana file location /etc/grafana/grafana.ini

Edit the section of [database]

Put these same settings on both servers

Type = MySQL
host =
Name = database_name
User = username
Password = password

Save the file

  1. Restart the service
systemctl restart grafana-server

Check Out: How To Change Grafana Default Port In Linux

Now the last step is to check database stored on a centralised server. so

Login to your database server using mysql –u root –p so

Run the following command so

use database_name;
show tables;

It will show you what is stored in the database. so

That’s it. grafana database high availability centralized configure

Share on:

I'm the founder of Curious Viral. I hope this blog will provide you complete information about Linux Technology & I would like to share my technical knowledge with you which I have learned during this period.

Other Posts You May Like...

Leave a comment