Icinga / icinga2

The core of our monitoring platform with a powerful configuration language and REST API.
https://icinga.com/docs/icinga2/latest
GNU General Public License v2.0
2.03k stars 578 forks source link

IDO database performance enhancement #7197

Closed jhou4 closed 5 years ago

jhou4 commented 5 years ago

Is your feature request related to a problem? Please describe.

With a large environment, IDO queue keeps backing up. Already tried tuning backend Mysql database, which helped in some degree. Had to reduce the number of hosts/services to get IDO queue under control.

Describe the solution you'd like

Please reconsider the solution in: https://github.com/Icinga/icinga2/issues/3830, allowing multiple connections to database. I understand it was already discussed and decided, but since it was 3 years ago, maybe it is a good time to revisit it. This may need some major rework, but it would make Icinga much more scalable.

Describe alternatives you've considered

Alternatively, if icingaweb can connect to multiple backends at the same time as discussed in https://github.com/Icinga/icingaweb2/issues/2868, then we can have multiple smaller icinga environment but can still provide a central view.

Additional context

First time opening an issue, thanks for your consideration.

dnsmichi commented 5 years ago

3830 is blocked by the schema, this did not change over the years. The way data is dumped to the database relies on insert IDs and a sequential way of executing queries. There is no way of moving this into a connection pool.

That being said, with all the other short-comings, there is work underway for a new backend. You'll find references with "IcingaDB" here and recorded talks from Icinga Camps. Once that's released, it will become the successor of the IDO database backend.

As such, the IDO backend won't be rewritten nor changed in large pieces in the future, except for bugs we actually can fix without breaking things.

Cheers, Michael

jhou4 commented 5 years ago

Thanks for the updates. When new icingaDB is available, we will definitely try it. For the time being, do you have any suggestions on how to work around the IDO bottleneck?