GBL_MEM_UTIL data wrong

  • KM03138900
  • 06-Apr-2018
  • 06-Apr-2018

This document has not been formally reviewed for accuracy and is provided "as is" for your convenience.

Summary

Some Linux and SUSE Enterprise Servers with HP OVO 11.1x agents installed. The metric GBL_MEM_UTIL does not match with memory used by Operating System (Command SAR -r),

Question

Some Linux  and SUSE Enterprise Servers with HP OVO 11.1x agents installed. The metric GBL_MEM_UTIL does not match with memory used by Operating System (Command SAR -r),

 

Why this value is wrong. Both metrics Operating system and Performance agent do not match.

Answer

since PA and OA are together in OA 11.1x version. the metric for GBL_MEM_UTIL in the dictionary :

GBL_MEM_UTIL (eqn: ((phys mem - free) / phys mem) * 100)
----------------------------------
The percentage of physical memory in use during the interval. This
includes system memory (occupied by the kernel), buffer cache and user
memory.

On HP-UX 11iv3 and above, this includes file cache. This excludes file
cache when cachemem parameter in the parm file is set to free.

On HP-UX, this calculation is done using the byte values for physical
memory and used memory, and is therefore more accurate than comparing
the reported kilobyte values for physical memory and used memory.

On Linux, the value of this metric includes file cache when the cachemem
parameter in the parm file is set to user.

On SUN, high values for this metric may not indicate a true memory
shortage. This metric can be influenced by the VMM (Virtual Memory
Management) system. This excludes ZFS ARC cache when cachemem parameter
in the parm file is set to free.

On AIX, this excludes file cache when cachemem parameter in the parm
file is set to free.

Locality Domain metrics are available on HP-UX 11iv2 and above.
GBL_MEM_FREE and LDOM_MEM_FREE, as well as the memory utilization
metrics derived from them, may not always fully match. GBL_MEM_FREE
represents free memory in the kernel's reservation layer while
LDOM_MEM_FREE shows actual free pages. If memory has been reserved but
not actually consumed from the Locality Domains, the two values won't
match. Because GBL_MEM_FREE includes pre-reserved memory, the GBL_MEM_*
metrics are a better indicator of actual memory consumption in most
situations.

In all cases, customers should be made aware that the %memused in the SAR output is NOT the actual memory utilization by the applications on the system. And if the customer is looking for the exact metric which shows %memused from SAR, then OA doesn’t have that metric as of today as it doesn’t make sense to have the same.

If customers really want to get the actual utilization, then one must need to get the total memory (cat /proc/meminfo) then subtract the kbcached + kbbuffers memory(from SAR output) to see how much memory is actually being committed.

For example:
In this case, Memory utilization = (kbmemused-kbbuffers-kbcached)/sum(kbmemused,kbmemfree)

( 3496292 – 184164 – 2646104)/ (3496292 + 379696 )
666024 / 3875988 = 0.1718333493292549 = 17.18 %

OA calculates the Memory Utilization based on the values of /proc/meminfo.

E.g: egrep --color 'Mem
Cache
Swap' /proc/meminfo