Apache thrashing swap. Look inside
Greetings,
Recently, we've seen an increase in the use of our swap for example, from top:
Memory: 8192M real, 6107M free, 10G swap in use, 88M swap free
And a lot of Apache's children.
I've tried tuning the MaxClients directive from Apache, right now it's at 156, I set it down to 50 and it would take a lot less swap, but the websites sometimes wouldn't load.
Any suggestions? ideas? I'm at a loss here. Thank you.
# 1
> Greetings,
>
> Recently, we've seen an increase in the use of our
> swap for example, from top:
>
> Memory: 8192M real, 6107M free, 10G swap in use, 88M
> swap free
>
> And a lot of Apache's children.
Is that a problem?
Forked processes that don't modify the pages from their parent need to reserve memory (in case the page is modified in the future). That reservation appears in 'swap -s' output, and will count against any paging files before it counts against RAM. This is usually a Good Thing (TM).
--
Darren
# 3
That's not necessarily the cause. Low swap availability isn't always associated with a problem.
You'll need to look further. Are the servers executing? Are they blocked on I/O? Any errors in the logs? You might use 'prstat -m' and see what states the servers are in.
--
Darren