Large NDO Table
Michael Friedrich
michael.friedrich at univie.ac.at
Thu Sep 16 12:33:30 CEST 2010
Breandan Dezendorf wrote:
> The NDO tables nagios_host_contactgroups and
> nagios_service_contactgroups have grown to an incredible size on my
> nagios servers:
>
> SELECT count(*) FROM nagios_host_contactgroups;
> 1230862
>
> SELECT count(*) FROM nagios_service_contactgroups;
> 3310190
>
> The indexes are in place - when I run a "SHOW CREATE TABLE
> nagios_host_contactgroups", I get the following:
>
> CREATE TABLE `nagios_host_contactgroups` (
> `host_contactgroup_id` int(11) NOT NULL auto_increment,
> `instance_id` smallint(6) NOT NULL default '0',
> `host_id` int(11) NOT NULL default '0',
> `contactgroup_object_id` int(11) NOT NULL default '0',
> PRIMARY KEY (`host_contactgroup_id`),
> UNIQUE KEY `instance_id` (`host_id`,`contactgroup_object_id`)
> ) ENGINE=InnoDB AUTO_INCREMENT=2905453 DEFAULT CHARSET=latin1
> COMMENT='Host contact groups';
>
> There are similar UNIQUE KEYs on nagios_service_contactgroups.
>
this is not the current 1.4b9 schema. either it's modified for your
usage or you still have the old 1.4b7 schema or something else. 1.b8
changed the db engine from innodb to myisam (which is not good, but
that's the main difference).
>
> Should I be worried about the size of the table? I'm trying to do
> anything I can to speed up the database operations and limit database
> size. I'm running Nagios 3.0.6 and NDO 1.4b9. We have 109 contacts
> defined in the system, 1900+ hosts and 5000+ services. I've already
> tuned the trim option for nagios_externalcommands and
> nagios_logentries down to 30 minutes, for what it's worth, as we
> mostly use the NDO data for a front end package we developed in-house.
>
i don't remember any logentries trimming options for ndoutils. can you
post egrep -v "^$|^#" ndo2db.cfg
the numbers are a bit odd though. can you check if the unique key
columns match any id in objects or hosts?
kind regards,
michael
--
DI (FH) Michael Friedrich
Vienna University Computer Center
Universitaetsstrasse 7 A-1010 Vienna, Austria
email: michael.friedrich at univie.ac.at
phone: +43 1 4277 14359
fax: +43 1 4277 14279
web: http://www.univie.ac.at/zid
Icinga Core& IDOUtils Developer
http://www.icinga.org
------------------------------------------------------------------------------
Start uncovering the many advantages of virtual appliances
and start using them to simplify application deployment and
accelerate your shift to cloud computing.
http://p.sf.net/sfu/novell-sfdev2dev
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue.
::: Messages without supporting info will risk being sent to /dev/null
More information about the Users
mailing list