NCPA 1.7.2 CPU 100%

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
AMacintosh
Posts: 59
Joined: Mon Nov 07, 2011 12:26 pm

NCPA 1.7.2 CPU 100%

Post by AMacintosh »

We are seeing an incorrect CPU Usage result on a Windows 2008 R2 server. It keeps reporting 100% CPU usage however the server perf mon log and Task Manager do not show this issue. When I look at the Top Processes tab in the agent on that server, it keeps flashing CPU Load: 100%. If at the same time, I have task manager open, I don't see this spike. There only appears to be one CPU on this VM.
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: NCPA 1.7.2 CPU 100%

Post by lmiltchev »

Can you run the following commands and show us the output?

On the Windows box (from the CMD)

Code: Select all

wmic cpu get loadpercentage
On the Nagios XI server (from the CLI)

Code: Select all

/usr/local/nagios/libexec/check_ncpa.py -H <client ip> -t 'token' -P 5693 -M cpu/percent -w 80 -c 90
Be sure to check out our Knowledgebase for helpful articles and solutions!
AMacintosh
Posts: 59
Joined: Mon Nov 07, 2011 12:26 pm

Re: NCPA 1.7.2 CPU 100%

Post by AMacintosh »

Please see the results...

Load Percentage
5

[]# /usr/local/nagios/libexec/check_ncpa.py -H 10.0.0.0 -t 'token' -P 5693 -M cpu/percent -w 80 -c 90
CRITICAL: percent was 100% | 'percent_0'=100%;80;90;
[]# /usr/local/nagios/libexec/check_ncpa.py -H 10.0.0.0 -t 'token' -P 5693 -M cpu/percent -w 80 -c 90
OK: percent was 2% | 'percent_0'=2%;80;90;
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: NCPA 1.7.2 CPU 100%

Post by lmiltchev »

So, the first check "failed", but the second one didn't. What is the output when you try to increase verbosity?

Code: Select all

/usr/local/nagios/libexec/check_ncpa.py -H 10.0.0.0 -t 'token' -P 5693 -M cpu/percent -w 80 -c 90 -vvv
What is the value that you see in the API?

Code: Select all

https://clientip:5693/api/cpu/percent
Can you upload the "ncpa_listener.log" from the Windows box, so that we can take a look at it?
Be sure to check out our Knowledgebase for helpful articles and solutions!
AMacintosh
Posts: 59
Joined: Mon Nov 07, 2011 12:26 pm

Re: NCPA 1.7.2 CPU 100%

Post by AMacintosh »

I ran the checks immediately right after each other and it shows that the value for CPU load is flapping between 100%. I'll check the API and the command line check with -vv and get back to you.
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: NCPA 1.7.2 CPU 100%

Post by lmiltchev »

I'll check the API and the command line check with -vv and get back to you.
No problem.
Be sure to check out our Knowledgebase for helpful articles and solutions!
AMacintosh
Posts: 59
Joined: Mon Nov 07, 2011 12:26 pm

Re: NCPA 1.7.2 CPU 100%

Post by AMacintosh »

Please see the results of 3 fast command line checks.

[root@nastisrnagap01 ~]# /usr/local/nagios/libexec/check_ncpa.py -H 10.0.0.0 -t 'token' -P 5693 -M cpu/percent -w 80 -c 90 -vvv
CRITICAL: percent was 100% | 'percent_0'=100%;80;90;
[root@nastisrnagap01 ~]# /usr/local/nagios/libexec/check_ncpa.py -H 10.0.0.0 -t 'token' -P 5693 -M cpu/percent -w 80 -c 90 -vvv
CRITICAL: percent was 100% | 'percent_0'=100%;80;90;
[root@nastisrnagap01 ~]# /usr/local/nagios/libexec/check_ncpa.py -H 10.0.0.0 -t 'token' -P 5693 -M cpu/percent -w 80 -c 90 -vvv
OK: percent was 2% | 'percent_0'=2%;80;90;
AMacintosh
Posts: 59
Joined: Mon Nov 07, 2011 12:26 pm

Re: NCPA 1.7.2 CPU 100%

Post by AMacintosh »

The API is showing either 0% or 100% when refreshing.

Ideas?

Edit: NCPA listener log
Last edited by slansing on Wed Dec 03, 2014 10:17 am, edited 1 time in total.
Reason: Merged your posts, please edit your previous post rather than double posting.
slansing
Posts: 7698
Joined: Mon Apr 23, 2012 4:28 pm
Location: Travelling through time and space...

Re: NCPA 1.7.2 CPU 100%

Post by slansing »

Were you trying to attach your log? Does not look like it got through.
AMacintosh
Posts: 59
Joined: Mon Nov 07, 2011 12:26 pm

Re: NCPA 1.7.2 CPU 100%

Post by AMacintosh »

Yeah it won't allow me to upload the log. here are the latest entries.

Code: Select all

2014-12-03 08:15:13,773:INFO:handler:NagiosIP - - [2014-12-03 08:15:13] "GET /api/disk/logical/D:|/used_percent/?token=token&warning=85&critical=95&check=1 HTTP/1.0" 200 325 0.000000
2014-12-03 08:15:14,319:DEBUG:handler:Initializing WebSocket
2014-12-03 08:15:14,319:DEBUG:handler:Validating WebSocket request
2014-12-03 08:15:14,319:DEBUG:__init__:Getting accessor: disk/logical/C:|/used_percent/
2014-12-03 08:15:14,319:INFO:handler:NagiosIP - - [2014-12-03 08:15:14] "GET /api/disk/logical/C:|/used_percent/?token=token&warning=85&critical=95&check=1 HTTP/1.0" 200 327 0.000000
2014-12-03 08:15:14,756:DEBUG:handler:Initializing WebSocket
2014-12-03 08:15:14,756:DEBUG:handler:Validating WebSocket request
2014-12-03 08:15:14,756:DEBUG:__init__:Getting accessor: memory/swap/percent/
2014-12-03 08:15:14,756:INFO:handler:NagiosIP - - [2014-12-03 08:15:14] "GET /api/memory/swap/percent/?token=token&warning=85&critical=95&check=1 HTTP/1.0" 200 317 0.000000
2014-12-03 08:15:20,357:DEBUG:handler:Initializing WebSocket
2014-12-03 08:15:20,357:DEBUG:handler:Validating WebSocket request
2014-12-03 08:15:20,357:DEBUG:__init__:Getting accessor: memory/virtual/percent/
2014-12-03 08:15:20,357:INFO:handler:NagiosIP - - [2014-12-03 08:15:20] "GET /api/memory/virtual/percent/?token=token&warning=85&critical=95&check=1 HTTP/1.0" 200 317 0.000000
2014-12-03 08:15:44,898:DEBUG:handler:Initializing WebSocket
2014-12-03 08:15:44,898:DEBUG:handler:Validating WebSocket request
2014-12-03 08:15:44,914:DEBUG:__init__:Getting accessor: cpu/percent/
2014-12-03 08:15:45,927:INFO:handler:NagiosIP - - [2014-12-03 08:15:45] "GET /api/cpu/percent/?token=token&warning=85&critical=95&check=1 HTTP/1.0" 200 315 1.030000
2014-12-03 08:20:13,782:DEBUG:handler:Initializing WebSocket
2014-12-03 08:20:13,782:DEBUG:handler:Validating WebSocket request
2014-12-03 08:20:13,782:DEBUG:__init__:Getting accessor: disk/logical/D:|/used_percent/
2014-12-03 08:20:13,782:INFO:handler:NagiosIP - - [2014-12-03 08:20:13] "GET /api/disk/logical/D:|/used_percent/?token=token&warning=85&critical=95&check=1 HTTP/1.0" 200 325 0.000000
2014-12-03 08:20:14,641:DEBUG:handler:Initializing WebSocket
2014-12-03 08:20:14,641:DEBUG:handler:Validating WebSocket request
2014-12-03 08:20:14,641:DEBUG:__init__:Getting accessor: disk/logical/C:|/used_percent/
2014-12-03 08:20:14,641:INFO:handler:NagiosIP - - [2014-12-03 08:20:14] "GET /api/disk/logical/C:|/used_percent/?token=token&warning=85&critical=95&check=1 HTTP/1.0" 200 327 0.000000
2014-12-03 08:20:14,984:DEBUG:handler:Initializing WebSocket
2014-12-03 08:20:14,984:DEBUG:handler:Validating WebSocket request
2014-12-03 08:20:14,984:DEBUG:__init__:Getting accessor: memory/swap/percent/
2014-12-03 08:20:14,984:INFO:handler:NagiosIP - - [2014-12-03 08:20:14] "GET /api/memory/swap/percent/?token=token&warning=85&critical=95&check=1 HTTP/1.0" 200 317 0.000000
2014-12-03 08:20:20,553:DEBUG:handler:Initializing WebSocket
2014-12-03 08:20:20,553:DEBUG:handler:Validating WebSocket request
2014-12-03 08:20:20,553:DEBUG:__init__:Getting accessor: memory/virtual/percent/
2014-12-03 08:20:20,553:INFO:handler:NagiosIP - - [2014-12-03 08:20:20] "GET /api/memory/virtual/percent/?token=token&warning=85&critical=95&check=1 HTTP/1.0" 200 317 0.000000
2014-12-03 08:20:44,891:DEBUG:handler:Initializing WebSocket
2014-12-03 08:20:44,891:DEBUG:handler:Validating WebSocket request
2014-12-03 08:20:44,891:DEBUG:__init__:Getting accessor: cpu/percent/
2014-12-03 08:20:45,905:INFO:handler:NagiosIP - - [2014-12-03 08:20:45] "GET /api/cpu/percent/?token=token&warning=85&critical=95&check=1 HTTP/1.0" 200 315 1.014000
Locked