Passive Checks Have 01-01-1970 00:00:08 as Last Check Time
-
BlancaBasura
- Posts: 2
- Joined: Wed May 13, 2015 11:19 am
Passive Checks Have 01-01-1970 00:00:08 as Last Check Time
A developer recently added a large volume of passive checks. They all have the Unix Epoch as the Last Check Time, and the duration is currently 16658d 22h 34m 11s. He added some other checks today, and the time stamp is fine. Does anyone know how I can clean up this erroneous time stamp? Thanks.
- Box293
- Too Basu
- Posts: 5126
- Joined: Sun Feb 07, 2010 10:55 pm
- Location: Deniliquin, Australia
- Contact:
Re: Passive Checks Have 01-01-1970 00:00:08 as Last Check Ti
These are going to be in the retention.dat file, usually, /usr/local/nagios/var/retention.dat.
It will be in the last_check= field I think, I'm pretty sure it will be last_check=0.
You should be able to sed this file and replace the old value with a current, more realistic value.
I would stop the nagios service
Then this command should replace the value with a new one:
Then start nagios.
I would take a copy of retention.dat first and have a play with it to make sure I've given you a valid command.
It will be in the last_check= field I think, I'm pretty sure it will be last_check=0.
You should be able to sed this file and replace the old value with a current, more realistic value.
I would stop the nagios service
Then this command should replace the value with a new one:
Code: Select all
sed -i 's/^last_check=0/last_check=1439187434/g' /usr/local/nagios/var/retention.datI would take a copy of retention.dat first and have a play with it to make sure I've given you a valid command.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
-
BlancaBasura
- Posts: 2
- Joined: Wed May 13, 2015 11:19 am
Re: Passive Checks Have 01-01-1970 00:00:08 as Last Check Ti
Thank you so much! I will try this out.
Re: Passive Checks Have 01-01-1970 00:00:08 as Last Check Ti
Thank you. Please let us know what happens.BlancaBasura wrote:Thank you so much! I will try this out.
Former Nagios Employee.
me.
me.