How did GPCC calculate buffer/cache usage in cluster metrics page.
We may notice buffer/cache usage is near 100%, while memory used is less than 10% in GPCC cluster metrics page.
Product Version: 7.0
Here is how GPCC calculate the buffer/cache usage.
+ get the Buffers from /proc/meminfo. + get the Cached from /proc/meminfo. + get the SReclaimable (if it exists) from /proc/meminfo. + get the MemTotal from /proc/meminfo . + store the Cached +SReclaimable in mem_cached column of “gpmetics.gpcc_system_history” table. + store the Buffers in mem_buffers column of “gpmetics.gpcc_system_history” table. + store the MemTotal in mem_total column of “gpmetics.gpcc_system_history” table. + the web page will show avg(mem_buffers + mem_cached) / avg(mem_total)) as the “buffer/cache” over the time.