Good morning all,
in order to compute statistics on host/service availability, I need to optimize nagios logging.
Currently, all checks on host and services are stored in logs, i.e. all 5 minutes if OK and all 1 minutes if DOWN. If my service is ok during the day I have 288 state OK stored in my log. If the state is DOWN, I have 1440 down.
Do you know how to configure nagios to store only state change in my log ?
Thank you in advance for your help,
Best regards,
Benoit Village
Store only host/service state change in nagios log
-
benoitvillage
- Posts: 2
- Joined: Tue Oct 04, 2016 3:27 am
Store only host/service state change in nagios log
Last edited by dwhitfield on Fri Oct 07, 2016 9:33 am, edited 1 time in total.
Reason: marking with green check mark
Reason: marking with green check mark
Re: Store only host/service state change in nagios log
Just to clarify, is this for Nagios Core, Nagios XI, or Nagios Logserver? I ask because you posted in the Logserver forum, but you are referencing Core or XI functionality.
If this is for Core/XI, it almost sounds like you have state stalking enabled:
https://assets.nagios.com/downloads/nag ... lking.html
Is that the case? If so, that might explain why your logs are growing so large.
If this is for Core/XI, it almost sounds like you have state stalking enabled:
https://assets.nagios.com/downloads/nag ... lking.html
Is that the case? If so, that might explain why your logs are growing so large.
Former Nagios employee
-
benoitvillage
- Posts: 2
- Joined: Tue Oct 04, 2016 3:27 am
Re: Store only host/service state change in nagios log
Dear tmcdonald,
Thank you very much for your answer and link, it's absolutly what I need ! Log size change from 90 to 8MB !
Have a nice weekend,
Benoit Village
Thank you very much for your answer and link, it's absolutly what I need ! Log size change from 90 to 8MB !
Have a nice weekend,
Benoit Village
-
dwhitfield
- Former Nagios Staff
- Posts: 4583
- Joined: Wed Sep 21, 2016 10:29 am
- Location: NoLo, Minneapolis, MN
- Contact:
Re: Store only host/service state change in nagios log
Glad to hear it is resolved. I am going to lock the thread. Please feel free to post again if you have you another issue. Thank you for using the Nagios forums!