Update Version of Centreon inferior to Centreon2-RC5
From Wiki Centreon
This tutorial only concerns the reporting tool (dashboard). Centreon 2 reporting tool engine has changed a lot for two reasons :
- improvement of data treatment method and execution time for reporting engine
- Faster Information access in Centreon web frontend.
Contents |
Reporting engine before Centreon2-RC5
Two tables in Centstorage contain the information displayed in the reporting dashboard :
- log_archive_host
- log_archive_service
These tables are updated every day by reading the previous day nagios log file (archived in nagios/var/archives)
But at the same time, an exec file logAnalyser is run every minute to enter nagios logs in the table log of Centstorage. That's why we changed the method of filling the tables log_archive_host and log_archive_service.
Reporting engine with Centreon2-RC5
Data to update log_archive_host and log_archive_service are retrieved, every day, from the table log of centstorage. The exec archiveDayLog (in centreon/cron/) performs this action. The table "log_archive_last_status" store last status of each host and service which statistics was entered in "log_archive_host" and "log_archive_service". This fix main bugs that we had we the last reporting engine.
Update steps
How to upgrade the new reporting dashboard?
As the tables log_archive_host and log_archive_service underwent few modifications. We have rebuild theses two tables data rows : centreon/cron/archiveDayLog truncate these tables and retrieve data from the table log to re-calculate statistics on hosts and services.
But as the table log has a retention period (1 month by default). If some hosts and services have been checked by Nagios before the last month, their logs must be re-integrated in the table log in order to build statistics to the entire running period of Nagios.
So :
- first step : re-integrate all nagios logs by executing (only if nagios is running for over the retention period of logs in Centstorage, default is one month)
root@centreon/bin/#./logAnalyser -a
root@centreon/cron/#./archiveDayLog -r
There is still one bug left : some services are reported as undetermined at 100% even if they where checked by Nagios. It will be corrected in centreon2-RC6.
What if it does not work?
- verify that a table log_archive_last_status exists in centstorage DB
- verify that the field UNDETERMINEDTimeScheduled was created in the table log_archive_host and log_archive_service
- Is there data rows in table log of centstorage? what about log_archive_host and log_archive_service?
- Try to rebuild statistics with :
root@centreon/cron/#./archiveDayLog -r
IN ANY CASE, AS LONG AS YOU HAVE NAGIOS LOG FILES IN NAGIOS ARCHIVES PATH, YOU WILL BE ABLE TO RECOVER YOUR REPORTING DASHBOARD.

