Page 1 of 1
How to synchronize Mysql Database on 2 Nagios Master(Host)
Posted: Tue May 08, 2018 1:21 pm
by Johnsmit
hello,
i have Nagios installed, up and running. I would like to design High availability of nagios with the databases, files/folders synchronized. Currently, my site1 nagios XI is up and running, i would like to install nagiosXi on site 2 and synchronize database of site 1 to site 2, as i can have all of my monitoring stuff onto site 2. Is there any document or process to do so ?
Thanks in advance.
Re: How to synchronize Mysql Database on 2 Nagios Master(Hos
Posted: Tue May 08, 2018 3:25 pm
by mcapra
Here's the official documentation regarding high-availability within Nagios XI:
https://assets.nagios.com/downloads/nag ... ios-XI.pdf
I believe it is intentionally vague. High-availability with MyISAM is best done with an intermediary of some sort (like
Heartbeat).
Re: How to synchronize Mysql Database on 2 Nagios Master(Hos
Posted: Tue May 08, 2018 4:34 pm
by cdienger
Additioanlly
https://assets.nagios.com/downloads/nag ... ios-XI.pdf and
https://www.linbit.com/en/576-ha-nagios ... -on-rhel7/ may help. The former is for manually migrating data to a new server while the later provides detailed steps for setting up HA *Note that this is a third party solution.
Re: How to synchronize Mysql Database on 2 Nagios Master(Hos
Posted: Mon Jun 04, 2018 10:08 am
by Johnsmit
Hello,
Can i get the full schema layout of Databases NagiosXi using? Helps a lot for database replication.
Thanks,
Re: How to synchronize Mysql Database on 2 Nagios Master(Hos
Posted: Mon Jun 04, 2018 2:31 pm
by scottwilkerson
We do not provide this as it can change version to version. You can get a list of tables form the 3 databases
nagios
nagiosql
nagiosxi
but that is all that can be provided.
Code: Select all
echo "show tables;"|mysql -pnagiosxi nagios
echo "show tables;"|mysql -pnagiosxi nagiosql
echo "show tables;"|mysql -pnagiosxi nagiosxi
Re: How to synchronize Mysql Database on 2 Nagios Master(Hos
Posted: Mon Jun 04, 2018 5:31 pm
by gormank
You can dump the DB and import it on another host to duplicate. On the latest system I did this didn't like something so I had to remove the user table before importing. Once the DB is imported, you can remove the config files, then run the reconfigure script. It's a bit crude, but it works.
Re: How to synchronize Mysql Database on 2 Nagios Master(Hos
Posted: Tue Jun 05, 2018 9:05 am
by scottwilkerson
Yes this does work but is not realtime replication