How to handle high cpu usage due to Kswapd process
Hi,
We have a server running SAP applications. Recently kswapd used 99% sys and load was around 130 and machine hanged completely.
RHEL 5.8 64 Bit
RAM is 28 GB, SWAP is 20 GB
Out of this 17 GB RAM was used and 9 GB cache was still present. SWAP usage was 3 GB. But there was no pages in/out and swap in/out at that time.
Only thing was there were many SAP application processes in running state continuously. And to fix the issue, server was rebooted.
Please share details on swap fine tuning
Thanks
Iyappan V
Responses
Tuning Swap/memory can definitely be tricky. If you have not done so, I would recommend coordinating with SAP support for their best-practices and then validate them against other suggestions you might find from forums or Red Hat.
Are you using Huge Pages?
What is your vm.swappiness value?
What does the memory look like when the system has become operational under normal load?
grep -i huge /proc/meminfo
sysctl -a | grep swap
free -m
Then - I would investigate what your storage stack looks like (I/O buffers may be consuming resources)
iotop
dstat
grep [a-z] /sys/block/sd*/queue/scheduler
Basic RHEL tuning example for SAP
http://scn.sap.com/thread/1670476
Disk Scheduler
http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/b02e7988-4e9d-2910-2994-d8b2cf021f12?QuickLink=index&overridelayout=true&11385958302359
Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.
