Zabbix Database restore
Last updated
Last updated
We will be taking mysql database into consideration and will be using mysqldump
utility to restore the zabbix database.
In the previous sections we have taken the database backup and we will be using the same zabbix database restore process.
In case of any failure we will have to install the fresh mysql database copy with the same version old instance was running to ensure smooth & unintereppted restore process.
We will need to make some configuration changes to ensure database accepts connection other than the localhost in case when zabbix is deployed on the multinode model.
Look for the bind-address
directive under the [mysqld]
section. By default, it may be set to 127.0.0.1
(localhost) to restrict connections to the local machine. Change this to 0.0.0.0
to allow MySQL to listen on all network interfaces.
This will ensure mysql connection from foreign hosts but we need to add some security which we can do with ufw
:
Now we will restart the mysql connections to ensure that all settings & configurations are applied correctly.
â ī¸ UFW configuration might disconnect active sessions if not configured correctly.
Importing the databse using the mysqldump utility :
Once database is restored we can enable the zabbix-server back to resume normal operations.