Linux server performance issue

I have a server running cacti with 2 cpu & 2 gb memory. It is showing me 100% cpu utilized for some perl scripts getting information from storage luns. memory also 98-99 % utilized. I tried to tune vm.swappiness to 80, as i thought that the memory is less so swapping the pages out may help, but still the performance is killing. kindly let me know wht all parameters can be checked to tune the linux system. I am using nmon tool.
Who is Participating?
ssapkotaConnect With a Mentor Commented:
Okay it is clear that those perl-process are memory-hog.
In this case you might wanna tune following kernel-params:
increase vm.overcommit_ratio to somewhat like 80.

Regarding vm.swapiness. Remember "The higher the vm.swappiness value, the more the system will swap." And if the system swaps more, its obviously going to hit the system performance. Keep it low (20-40) if most of the memory is consumed by active process.

You might wanna go through the following articles:

And remember -- only modify one vm parameter at a time and monitor the performance.
I would check the perl scripts.  Seems like one of them might be in some kind of infinite loop.

pankajgadhariAuthor Commented:
These perl scripts are standard template. We are in a process of checking the scripts, but apart from that, is there any kernel parameters which we can tune to increase the performance based on output of iostat, vmstat or sar.
The new generation of project management tools

With’s project management tool, you can see what everyone on your team is working in a single glance. Its intuitive dashboards are customizable, so you can create systems that work for you.

pankajgadhariAuthor Commented:
[root@server ~]# sar -B 2 3
Linux 2.6.18-164.el5 (       08/19/2010

10:45:17 AM  pgpgin/s pgpgout/s   fault/s  majflt/s
10:45:19 AM   8450.25     38.19   8664.82    371.86
10:45:21 AM   8078.00    220.00   8401.50    367.00
10:45:23 AM   7990.00     82.00   8307.00    389.00
Average:      8172.29    113.52   8457.43    375.96
[root@server ~]# cat /proc/sys/vm/swappiness

Sar is showing that the system is swaping very much, i changed the value from 60 to 80 yesterday without reboot & today i changed it back to 60 without reboot, as I was not getting any performance gain. kindly suggest. Do i need to tune vm.swappiness & vm.overcommit_memory for performance gaining. kindly suggest
madunixConnect With a Mentor Chief Information Security Officer Commented:
you could  try some of the following settings (mentioned above)
vm.min_free_kbytes = 16384
vm.overcommit_memory = 2
vm.overcommit_ratio = 75
vm.lower_zone_protection = 100
vm.vfs_cache_pressure = 10000
Michael WorshamConnect With a Mentor Infrastructure / Solutions ArchitectCommented:
Also, as root, try flushing the pagecache and slabcache:

echo 3 > /proc/sys/vm/drop_caches

/etc/sysctl.conf configuration way:

vm.drop_caches = 3
pankajgadhariAuthor Commented:
Met the expectation
All Courses

From novice to tech pro — start learning today.