nscp icon indicating copy to clipboard operation
nscp copied to clipboard

check_cpu return abnormal (negative billions) percentage

Open christophe-activiumid opened this issue 2 years ago • 4 comments

Issue and Steps to Reproduce

run "check_cpu" with "nscp.exe test" shell on a physical computer with 64+ logical processors(threads) and windows 2022 (running hyper-v) image

Expected Behavior

I should get something like this, with perfdata value between 0 and 100% image

Actual Behavior

I get this with extremly high negative number (around -32G%) image

Details

  • NSClient++ version: 0.5.2.41
  • OS and Version: Windows Server 2022
  • Checking from: Centreon and locally
  • Checking with: with 'nrpe test' and with restapi centreon

Additional Details

it only happens with physical server with more than 64 thread running hyper-v on 2022,

unfortunately I don't that many server to test if it's physical server, or more than XX threads, or non-hyper-v, this are the first servers with this kind of combo hard/os we had to provision

I do have some old windows 2016 with more than 32 threads and hyper-v that never add this issue, no way to test more broadly I can just confirm a 2x20core/80threads and a 2x18/72 server (HPe, DL380Gen10 intel xeon)

christophe-activiumid avatar Dec 12 '22 16:12 christophe-activiumid

Also have exact issue after upgrading to windows server 2022 on a physical server with 96 cores.

check_cpu shows right CPU load when the actual cpu load is below ~40% and negative billons percentage when cpu load is higher.

Details NSClient++ version: 0.5.2.41 OS and Version: Windows Server 2022 Checking from: locally Checking with: 'nrpe test'

dragonuaix avatar Jan 03 '23 12:01 dragonuaix

I have the same issue on Windows 2022. It worked fine on Windows 2019.

tjcolby13 avatar Jan 21 '23 23:01 tjcolby13

Deprecated API functions https://learn.microsoft.com/en-us/windows/win32/procthread/numa-support

Workaround - to restrict nscp to only one processor node group by setting cpu affinity (for example, in task manager - rightclick on process, select "set affinity", set to allow to run on only one processor group). However, it will monitor only this cpu node group.

dragonuaix avatar Jan 27 '23 13:01 dragonuaix

Also have exact issue but only occure on google cloud compute engine with windows 2016 std

NSClient++ version: 0.5.2.35 OS and Version: Windows Server 2016 on google cloud

sharbui avatar Feb 14 '23 01:02 sharbui