The Layer 7 Gateway provides an administrator with several tools for monitoring the utilization of system resources such as CPU and RAM. In some circumstances, an administrator or operator may review these tools and feel that the system RAM is being over-utilized and exhausted by the Gateway application. This article will prescribe the steps for verifying that the system RAM is exhausted.
There are three applications that provide a majority of the system monitoring capabilities with respect to CPU and RAM: free, vmstat, and top. Examples of RAM utilization from each of these applications is displayed below:
? ? ? ? ? ? ?total ? ? ? used ? ? ? free ? ? shared ? ?buffers ? ? cached
Mem: ? ? ? ? ?7938 ? ? ? 7424 ? ? ? ?513 ? ? ? ? 71 ? ? ? ? 48 ? ? ? ?929
-/+ buffers/cache: ? ? ? 6446 ? ? ? 1491
Swap: ? ? ? ? 8143 ? ? ? ?238 ? ? ? 7905
procs -----------memory---------- ---swap-- -----io---- -system-- ------cpu-----
r ?b ? swpd ? free ? buff ?cache ? si ? so ? ?bi ? ?bo ? in ? cs us sy id wa st
3 ?0 ? ?238 ? ?513 ? ? 48 ? ?929 ? ?0 ? ?0 ? ?19 ? ?16 ? 25 ? 27 ?3 ?4 92 ?0 ?0
KiB Mem: ? 8128888 total, ?7605692 used, ? 523196 free, ? ?49944 buffers
KiB Swap: ?8339452 total, ? 244700 used, ?8094752 free. ? 951476 cached Mem
Each of these applications indicates a significantly low amount of "free" memory. Each application indicates that approximately 513 of 7938 MB of RAM are free. That is a very low percentage when considered individually.
The values for "free" do not always indicate the true amount of system memory. The Linux kernel considers memory free if and only if it is not currently in use by a running application and it is not being held in the memory cache and buffer. This means that any memory used by a running application or stored in the memory cache and buffer will be considered "used." Cached and buffered RAM is still available for use by running applications. The full amount of available memory for applications is shown in the free column in -/+ buffers/cache line. In our example the amount is 1491 KB.
It is also expected that a small amount of swap space may be used on the Gateway. Values less than 5% are not unreasonable and that percentage decreases with the amount of memory on the system. If a Gateway is actively using more than 5% of the available swap space and the amount of free memory in the cache is consistently lower than 5% after a prolonged period then please run through this article and open a new support case with Layer 7 Support at CA Technologies