AppD reporting gateway JVM memory hitting 80%. The SWAP memory increase during this timeframe going to 70 % usage
Why is SWAP being used ?
Gateway 11.1.1
The default setting for swappiness in the OVA and must linux systems is = 60.
This value means that the swap file will be used fairly often if the memory usage above 60 (over half of the system memory)
AppD shows Gateway are hitting 60 - 80% - the kernel will move memory to SWAP at times, NOTE there is no system/memory manager for this space it will not recover unless the specific APP using swap is restarted or the system rebooted
Swappiness setting of zero means that the disk will be avoided unless absolutely necessary (you run out of memory), while a swappiness setting of 100 means that programs will be swapped to disk almost instantly.
The default GW OVA configured with swappiness of 60
# cat /proc/sys/vm/swappiness
60
# sysctl vm.swappiness
vm.swappiness = 60
Set SWAPPINESS to 10 to limit it’s usage for GW App
# sysctl vm.swappiness=10
OR disable SWAP
# sysctl vm.swappiness=0
Recommended adding column in “top” to see what application uses SWAP most
* SWAP = Swapped Size (KiB)
* COMMAND = Command Name/Line
top - 07:30:03 up 70 days, 17:56, 1 user, load average: 0.00, 0.02, 0.05
Tasks: 152 total, 1 running, 151 sleeping, 0 stopped, 0 zombie
%Cpu(s): 0.3 us, 0.2 sy, 0.0 ni, 99.2 id, 0.2 wa, 0.0 hi, 0.0 si, 0.0 st
KiB Mem : 6109252 total, 133868 free, 4954256 used, 1021128 buff/cache
KiB Swap: 2097148 total, 1300732 free, 796416 used. 790080 avail Mem
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ SWAP COMMAND
6569 mysql 20 0 2968356 562928 10964 S 1.0 9.2 1486:58 274112 mysqld
14555 gateway 20 0 7450880 3.5g 10488 S 0.7 60.3 1029:28 242364 java