we are running an Icinga2 Master-Master Cluster where both instances also host the icinga2-web service (with a loadbalancer in front, with priority for the primary master node which is running Director).
Except the Director module we have all Icinga2-web modules installed and activated on both nodes.
We recently installed Icingadb and icingadb-web (in parallel with the old monitoring right now) and as soon as we have icingadb-web module running on both nodes the mysql database replication breaks.
We are running a MySQL Master-Master setup on the nodes, which works well with all other icinga features and IDO so far.
Is this setup not supported or are we missing something?
No, the setup should work. We use it as well (with a PostgreSQL db).
What errors are you getting?
Hint: You can also install the Director on the second server, just make sure to point it to the config master for config deployment.
Thank you for your answer @log1c !
We investigated a bit further and you’re right it’s not a problem with icingadb-web running on both nodes.
It seems to be a problem with icingadb.
In our setup we have a MySQL master-master setup and both icinga master nodes write to their respecting MySQL master node. We configured this for icingadb as well and this seems to be the problem.
We now changed our setup so that icingadb on the secondary master also writes to the MySQL on the primary master and this seems to have solved the problem (though I think this is not a ideal setup HA wise…)
Before we got duplicate entry errors in the mysql after some time and the replication broke.
I’m just wondering why out old setup is not working with icingadb, because it was working with all other icinga components so far, especially with IDO.
Our MySQL cluster is configured in a way that autoincrements on one node only produce even ids the other one only odd ids.