Hello,
We use «Nagios Core 4.2.4», plugin «check_nrpe 3.0.1» (in this case, with «check_eventlog» command) and «NSClient++ 0.5.0.62», on Windows servers, to check these servers System and Application Logs.
The issue is the following: in some situations, Status Information (in Nagios graphic interface) appears completely empty, as seen in Picture1 (at the end of this topic), that shows the result of a Nagios Availability Report.
We found that this happens when Nagios has to display a Windows System or Application Log event that contains at least one word with cedilla characters - ç - and/or characters with accent marks (acute, grave, circumflex accents or tilde) - like «á», «à», «ê», «ã», etc.
Here is an example (obtained from the command line) where the characters that cause the issue are «ç» and «ã» in the word «invocação» (highlighted in bold red):
# ./check_nrpe -H <hostname> -c check_eventlog -a "filter=level in ('error','critical') AND source IN ('SAPIntegrationServices') AND id IN (370)" "warn=count ge 1" "crit=count ge 1" "perf-config=*(ignored:true)" "empty-syntax=%(status): Eventlog check" "detail-syntax= ---INICIO--- log=%(log), level=%(level), source=%(source), eventid=%(id), written=%(written), message=%(message)(%(count))" log=system log=application "scan-range=-21h"
CRITICAL: 1 message(s) ---INICIO--- log=Application, level=error, source=SAPIntegrationServices, eventid=370, written=20:35, message=Internal errors: Erro na invoca▒▒o na logica SAP (...)
Can someone help us please?
Thanks in advance.
Empty Status Information in Nagios graphic interface
Re: Empty Status Information in Nagios graphic interface
Try leveraging the encoding parameter in your NSClient++ configuration:
https://docs.nsclient.org/reference/cli ... d-encoding
Set it to whatever encoding is being used on your Nagios Core machine.
An alternative would be to leverage some sort of wrapper script with either check_nrpe or the check_eventlog command to strip out problematic characters, but that's kinda lazy.
https://docs.nsclient.org/reference/cli ... d-encoding
Set it to whatever encoding is being used on your Nagios Core machine.
An alternative would be to leverage some sort of wrapper script with either check_nrpe or the check_eventlog command to strip out problematic characters, but that's kinda lazy.
Former Nagios employee
https://www.mcapra.com/
https://www.mcapra.com/
-
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: Empty Status Information in Nagios graphic interface
Thanks @mcapramcapra wrote:Try leveraging the encoding parameter in your NSClient++ configuration:
https://docs.nsclient.org/reference/cli ... d-encoding
Set it to whatever encoding is being used on your Nagios Core machine.
An alternative would be to leverage some sort of wrapper script with either check_nrpe or the check_eventlog command to strip out problematic characters, but that's kinda lazy.
Re: Empty Status Information in Nagios graphic interface
Hi mcapra!
Thanks a lot for your answer!
As soon as possible, we will create the conditions to try the solutions you suggested.
Thanks a lot for your answer!
As soon as possible, we will create the conditions to try the solutions you suggested.
-
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: Empty Status Information in Nagios graphic interface
Let us know how it turns outssm_mon wrote:Hi mcapra!
Thanks a lot for your answer!
As soon as possible, we will create the conditions to try the solutions you suggested.
Re: Empty Status Information in Nagios graphic interface
Hi mcapra!
We are very grateful for your help.
We have tried your first suggestion («Try leveraging the encoding parameter in your NSClient++ configuration: (…) Set it to whatever encoding is being used on your Nagios Core machine») and it worked fully!
Since UTF8 is the Nagios Core machine encoding (LANG=en_US.UTF-8), we added the following entry in the nsclient.ini file of a Windows machine with accented characters in its Application log events:
[/settings/default]
; NRPE PAYLOAD ENCODING
encoding = utf8
After restarting NSClient++ service on that Windows machine, Nagios began showing Status Information with accented characters instead of an empty one.
Thanks a lot again!
We are very grateful for your help.
We have tried your first suggestion («Try leveraging the encoding parameter in your NSClient++ configuration: (…) Set it to whatever encoding is being used on your Nagios Core machine») and it worked fully!
Since UTF8 is the Nagios Core machine encoding (LANG=en_US.UTF-8), we added the following entry in the nsclient.ini file of a Windows machine with accented characters in its Application log events:
[/settings/default]
; NRPE PAYLOAD ENCODING
encoding = utf8
After restarting NSClient++ service on that Windows machine, Nagios began showing Status Information with accented characters instead of an empty one.
Thanks a lot again!