mickem / nscp

NSClient++
http://nsclient.org
GNU General Public License v2.0
244 stars 94 forks source link

Wrong RAM size reported #768

Open jackburton79 opened 2 years ago

jackburton79 commented 2 years ago

For some servers (the ones with big amount of RAM) NSClient++ reports a smaller amount of physical memory than the one installed. This server, for example, has 36GB image

But nsclient (when queried with check_nscp_api) reports only 30GB.

[stefano@monitoring ~]$ '/usr/lib64/nagios/plugins/check_nscp_api' '--password' '' '-H' '' '-P' '****' '-q' 'check_memory' check_memory WARNING: committed = 30.843GB, physical = 30.493GB | 'committed'=30.843372GB;31.999649;35.999605;0;39.999561 'committed %'=77%;80;90;0;100 'physical'=30.4934 08GB;28.799649;32.399605;0;35.999561 'physical %'=85%;80;90;0;100

If I remember correctly, when I was using check_nt it reported it correctly.

Details

jackburton79 commented 2 years ago

Note that also running check_memory from NSClient++ test mode returns the wrong amount of memory: check_memory L cli WARNING: WARNING: committed = 30.722GB, physical = 30.39GB L cli Performance data: 'committed'=30.72219GB;31.99964;35.9996;0;39.999 56 'committed %'=77%;80;90;0;100 'physical'=30.38951GB;28.79964;32.3996;0;35.999 56 'physical %'=84%;80;90;0;100

Here's also a screenshot of the VM definition image

jackburton79 commented 2 years ago

checkmem, instead, seems to return the full memory capacity, pagefile included:

checkmem D w32system Created command: "detail-syntax=%(type): Total: %(size) - Used: %( sed) (%(used_pct)%) - Free: %(free) (%(free_pct)%)" L cli WARNING: WARNING: committed: Total: 40GB - Used: 30.739GB (76%) - ree: 9.26GB (23%), physical: Total: 36GB - Used: 30.417GB (84%) - Free: 5.583GB (15%) L cli Performance data: 'committed'=30.73938GB;31.99964;35.9996;0;39.99 56 'committed %'=77%;80;90;0;100 'physical'=30.4166GB;28.79964;32.3996;0;35.999 6 'physical %'=84%;80;90;0;100