nagios 4.x showlog

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
Locked
freddy00
Posts: 8
Joined: Mon Dec 14, 2015 10:33 am

nagios 4.x showlog

Post by freddy00 »

Hello.

I recently upgraded nagios from 3.5.1 to 4.1.1.
Those "core workers" are a great thing for sure, many thanks for that great feature!

The only problem is that a lot of informational messages about workers are logged in the "nagios.log" file and now that file is like 50x the size it was with nagios 3.x.
This makes the browser hangs for a few seconds when accessing the "showlog.cgi". that's very annoying.

I'm currently monitoring a few thousands hosts with a few ten-thousands services, so it happens that sometimes a few of them are down/critical.
In that case I get a lot of these msgs every second:

Code: Select all

Informational Message[18-04-2016 15:16:48] wproc: early_timeout=1; exited_ok=0; wait_status=0; error_code=62;
Informational Message[18-04-2016 15:16:48] wproc: host=V000CAM012; service=(null);
Informational Message[18-04-2016 15:16:48] wproc: CHECK job 8 from worker Core Worker 306 timed out after 30.00s
Informational Message[18-04-2016 15:16:48] wproc: Core Worker 306: job 8 (pid=365) timed out. Killing it
is there a way to tell nagios not to log those info events? or to log them in a separate file than "nagios.log"?

I've started to change a few things in the source files...
-lib/worker.c
-base/workers.c

commenting out "wlog" strings and recompiling the program reduced the logging about wprocs, but I don't like doing that.
The best way would be an option in the nagios.cfg file, something like "workers_logging_level = [none,info,warning,critical,debug]..."

please let me know if there's a solution for that. your help is very appreciated.

regards,
Federico
tmcdonald
Posts: 9117
Joined: Mon Sep 23, 2013 8:40 am

Re: nagios 4.x showlog

Post by tmcdonald »

The best place to voice these requests is on our GitHub page:

https://github.com/NagiosEnterprises/nagioscore

File it as an Issue and it'll be on the dev radar a lot sooner, as they generally don't patrol the forums. If you don't have a GitHub account I can make one on your behalf instead.
Former Nagios employee
freddy00
Posts: 8
Joined: Mon Dec 14, 2015 10:33 am

Re: nagios 4.x showlog

Post by freddy00 »

thanks tmcdonald for the reply.
I wrote here in the forum because I don't exactly know if mine is really a feature request or the option to disable/filter worker logs is doable already (I've read the dox, but perhaps I missed some pages?)...
I see nagios 4.x is around since years already, so I find quite strange it's only me who noticed that accessing "event log" is not as fast as it was before.
however: yes, I'll write to the dev team as you suggested. :)
greetings, Federico
tmcdonald
Posts: 9117
Joined: Mon Sep 23, 2013 8:40 am

Re: nagios 4.x showlog

Post by tmcdonald »

I checked for the word "log" in the Core main config doc, couldn't find anything relating to those messages specifically, so it will probably need to be added in.

Please link to this forum thread in your report for visibility :)
Former Nagios employee
Locked