Our DBA reported over the weekend the nagios_logentries was causing locking alerts and database slowdown because Nagios is attempting to do a select * on the table with over 13 million rows. The DBA have truncated the table in order to correct the issue for now. Do you have an recommendations to help prevent this from continuing to be a problem? We are still in our migration and still increasing the number of checks we will be performing.
I ran a test to see how quickly it is growing.
Time - Count
13:25:23 - 3432214
13:38:57 - 3478374
That is a 46,000 increase in less then 10 mins.
Nagios XI Version: 5.2.9
Max Log Entries Age is set to 7 Days
Code: Select all
mysql -V
mysql Ver 14.14 Distrib 5.6.25-73.1, for Linux (x86_64) using 6.2
Code: Select all
/usr/local/nagios/bin/nagios -v /usr/local/nagios/etc/nagios.cfg
Nagios Core 4.1.1
Copyright (c) 2009-present Nagios Core Development Team and Community Contributors
Copyright (c) 1999-2009 Ethan Galstad
Last Modified: 08-19-2015
License: GPL
Website: https://www.nagios.org
Reading configuration data...
Read main config file okay...
Read object config files okay...
Running pre-flight check on configuration data...
Checking objects...
Checked 13559 services.
Checked 2192 hosts.
Checked 5359 host groups.
Checked 3525 service groups.
Checked 174 contacts.
Checked 5327 contact groups.
Checked 141 commands.
Checked 9 time periods.
Checked 0 host escalations.
Checked 0 service escalations.
Checking for circular paths...
Checked 2192 hosts
Checked 0 service dependencies
Checked 0 host dependencies
Checked 9 timeperiods
Checking global event handlers...
Checking obsessive compulsive processor commands...
Checking misc settings...
Total Warnings: 0
Total Errors: 0
Things look okay - No serious problems were detected during the pre-flight check