You are here

Servicechecks stuck on "Scheduled Downtime"

12 posts / 0 new
Last post
nayax
nayax's picture
Servicechecks stuck on "Scheduled Downtime"

Hi,

I'm having some weird issues lately with Opsview.

It seems that some of the servicechecks are stuck on "Scheduled Downtime" and I cant get rid of it.

See attached screens:

 

But as you can clearly see there's no "moon" sign so I cant delete it.

 

I have many of these and I'm not sure what to do. I even tried deleting it from the DB but after reloading Opsview it all came back.

Thanks

Gil

 

smarsh
smarsh's picture
Hi Gil,

Hi Gil,

There arent any screenshots - looks like an issue when you posted. Can you add to a site like imgur and re-post?

Cheers,

Sam

nayax
nayax's picture
Hi Sam,

Hi Sam,

here are the links:

http://i.imgur.com/eDjNUhv.png

http://i.imgur.com/GX28DwP.png

Thanks for your help

Gil

smarsh
smarsh's picture
Ah - its Core. To be honest

Ah - its Core. To be honest other than looking at the database for scheduled downtime, and reloading i dont know what to suggest - if it is a bug it'll have been fixed in the last 2 years. Any thoughts of upgrading to Atom so you can use 5.0?

smarsh
smarsh's picture
From the screenshots, also,

From the screenshots, also, it looks like the downtime is running until year '3156'? Have you looked at:

mysql> select * from nagios_scheduleddowntime;
Empty set (0.00 sec)

nayax
nayax's picture
I have,

I have,

and I deleted everything present in there but after reloading everything comes back...

 

I have over 25 hosts so I'm afraid I cant upgrade...

smarsh
smarsh's picture
Ive done some digging for you

Ive done some digging for you, apparently this is a known issue in older versions of Nagios Core (pre Nagios Core 4) where the date "too far in the future" wasnt saved correctly in the backend.

However, you can manually remove the downtime by editing 'retention.dat' at /usr/local/nagios/var/retention.dat. At startup (i.e. a reload), Opsview will read this file and then push it into the runtime database.

Hope this helps!

Sam

nayax
nayax's picture
Hey,

Hey,

Thanks for your help!

Even after deleting this file it's being re-generated with the old broken data.

I tried also altering the duration of each servicecheck that was there.

What am I doing wrong?

Thanks

 

nayax
nayax's picture
NAILED IT! :-D

NAILED IT! :-D

What eventually fixed this annoying issue was telling Nagios to save retention.dat as retention1.dat and restarting it's service.

Thank you so much for your help Sam!

Saved me a great deal of trouble.

 

nayax
nayax's picture
I'm afraid that didnt help eventually...:(

After a period of time the scheduled downtime resurfaced for some reason...

smarsh
smarsh's picture
And its not in retention.dat

And its not in retention.dat or the runtime table?

nayax
nayax's picture
Cross that,

Cross that,

after reading that Nagios first saves all settings when being shut down,

I deleted retention.dat AFTER closing the service and now everything's back on track.

Thank you again for your great help!

Gil