Database Maintenance (dbmaint) stale (596 seconds old)
We receive these notification from time to time and they usually seem to clear themselves up. Unfortunately over the last few days the the issue does not seem to resolve itself.
I have run the posted script from a the support forum but that doesn't seem to resolve the issue.
/usr/local/nagiosxi/cron/dbmaint.php
I also ran the database repair script
stop mysqld
/usr/local/nagiosxi/scripts/repairmysql.sh nagios
start mysqld
Database Maintenance
-
slansing
- Posts: 7698
- Joined: Mon Apr 23, 2012 4:28 pm
- Location: Travelling through time and space...
Re: Database Maintenance
What do you have set for the "Optimize Interval" in Admin > Performance Settings > Databases. Also, did you notice any errors while manually executing that php script?
Re: Database Maintenance
You do not have the required permissions to view the files attached to this post.
-
slansing
- Posts: 7698
- Joined: Mon Apr 23, 2012 4:28 pm
- Location: Travelling through time and space...
Re: Database Maintenance
What do you have checking the dbmaint run time? If it is a service check on localhost, you are going to need to bump it's thresholds up as you are currently set to the default of 60 minutes. It was notifying you at roughly 9 minutes.
Re: Database Maintenance
this check is run from a peer nagios xi server ....
check_xi_nagiosserver
/usr/bin/php $USER1$/check_nagiosxiserver.php $ARG1$
--address=xxxxxxxxx --url=http://xxxxxxxxxx/nagiosxi/ --username=nagiosadmin --ticket="vj2786cv" --mode=jobs
check interval = 5 min
-----------------------------------------------------------------------------------------------
Testing check from command line...
COMMAND: /usr/bin/php /usr/local/nagios/libexec/check_nagiosxiserver.php --address=xxxxxxxxx --url=http://xxxxxxxxx/nagiosxi/ --username=nagiosadmin --ticket="vj2786cv" --mode=jobs
OUTPUT: Database Maintenance (dbmaint) stale (478 seconds old)
check_xi_nagiosserver
/usr/bin/php $USER1$/check_nagiosxiserver.php $ARG1$
--address=xxxxxxxxx --url=http://xxxxxxxxxx/nagiosxi/ --username=nagiosadmin --ticket="vj2786cv" --mode=jobs
check interval = 5 min
-----------------------------------------------------------------------------------------------
Testing check from command line...
COMMAND: /usr/bin/php /usr/local/nagios/libexec/check_nagiosxiserver.php --address=xxxxxxxxx --url=http://xxxxxxxxx/nagiosxi/ --username=nagiosadmin --ticket="vj2786cv" --mode=jobs
OUTPUT: Database Maintenance (dbmaint) stale (478 seconds old)
Re: Database Maintenance
Check the performance graphs for that service over the last month or so and see if there is an upward trend in the dbmaint "stale time" reported. If it is on the incline, it could be indicative of problems on the remote machine that might need to be fixed. If that is the case, until it gets fixed all you can really do is keep bumping up the thresholds on the check as slansing suggested.
Former Nagios employee
Re: Database Maintenance
Where do I adjust the thresholds for the check in the actual script ?
check_nagiosxiserver.php
check_nagiosxiserver.php
Re: Database Maintenance
The warning and critical threshold values used only for some modes (iowait, load). You can pass "--warn=<warning>" or "--crit=<critical>" to your command.
Be sure to check out our Knowledgebase for helpful articles and solutions!
- Box293
- Too Basu
- Posts: 5126
- Joined: Sun Feb 07, 2010 10:55 pm
- Location: Deniliquin, Australia
- Contact:
Re: Database Maintenance
It appears as though these are hard coded in the script.
Lines 204 and 205:
Lines 204 and 205:
Code: Select all
$warn=360;
$crit=900;As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
Re: Database Maintenance
I found those thresholds too, but if you look at my original post the we have been receiving critical notifications at 596 seconds which is obliviously below the 900 threshold.
Am I missing something ?
Am I missing something ?