Historical Tables vs Current Status Tables

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
compuware
Posts: 3
Joined: Tue Nov 16, 2010 10:14 am

Historical Tables vs Current Status Tables

Post by compuware »

In the Nagios database, the historical data is stored in nagios_servicechecks and nagios_hostchecks tables and the current status is store in nagios_hoststatus and nagios_servicestatus tables. It looks to me that the current status is inserted into the current status tables and the historical tables at the same time. Are there any benefits to query the current status tables?
tonyyarusso
Posts: 1128
Joined: Wed Mar 03, 2010 12:38 pm
Location: St. Paul, MN, USA
Contact:

Re: Historical Tables vs Current Status Tables

Post by tonyyarusso »

As opposed to pulling the most recent record from the historical table you mean? Performance, as the SQL query for sorting and pulling the last one from a potentially very large table will never be as fast as pulling the single record directly from a small table.
Tony Yarusso
Technical Services
___
TIES
Web: http://ties.k12.mn.us/
compuware
Posts: 3
Joined: Tue Nov 16, 2010 10:14 am

Re: Historical Tables vs Current Status Tables

Post by compuware »

Thanks for your answer! In our case, we need to query the historical tables anyway since we want to retrieve all the status from a previous timestamp until the cureent time. If the result of querying the historical tables already includes the current status, we do not need to do a second query into the current status tables. Is that correct?
tonyyarusso
Posts: 1128
Joined: Wed Mar 03, 2010 12:38 pm
Location: St. Paul, MN, USA
Contact:

Re: Historical Tables vs Current Status Tables

Post by tonyyarusso »

I believe so, yes.
Tony Yarusso
Technical Services
___
TIES
Web: http://ties.k12.mn.us/
compuware
Posts: 3
Joined: Tue Nov 16, 2010 10:14 am

Re: Historical Tables vs Current Status Tables

Post by compuware »

How long will the data be kept in the historical tables? Is there any way to configure it? It looks to me that by defautl they are purged quite frequently.
mguthrie
Posts: 4380
Joined: Mon Jun 14, 2010 10:21 am

Re: Historical Tables vs Current Status Tables

Post by mguthrie »

The newest release 1.4b has a page Admin->Performance settings where you can now specify the ages of your table data.
Locked