[KLUG Members] Trying to understand why high number of Context Switches with the RHEL4.0 kernel versus the RHEL3.0.

Adam Tauno Williams awilliam at whitemice.org
Sun Aug 14 14:58:12 EDT 2005


I'd consider comparisons of statistics between 2.4 and 2.6 series
kernels to be apples and oranges.  2.6 has a different scheduling
mechanism, a different memory manager, and the thread management was
completely overhauled.  There are so many differences it would be
extremely difficult to ascertain the cause of this specific
manifestation.

> I have a non iteractive, java application  that uses 10 threads and does 

Can you measure the throughput of the process?  Has that changed up or
down?

> 1)When checking vmstat, I also noticed the following difference in the 
> memory buff and memory cache counters.
>     vmstat      mem buff      mem cache
> RHEL4.0     35508         155852
> RHEL3.0    75032          513936
> Why is it so different ?

This isn't surprising as you are running completely different versions
of all system binaries.

> 2) why are there so many Context switching (CS) happening, is it becasue 
> 2.6 kernel is preemptive, or does the Red hat distribution has some 
> other advanced scheduling algorithms that is causing it. If so, is there 
> someway to increase the timeslice on the fly ?  

Possibly a sysctl value,  but I don't know what it is off the top of my
head.

> 3) changing kernel to 2.4 by using LD_ASSUME_KERNEL  - why does that not 
> help if it is case of just the 2.6 kernel behavior

Setting that is for the sake of GLIBC, not the kernel.  It won't get you
back to older kernel behaviour.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
Url : http://www.kalamazoolinux.org/pipermail/members/attachments/20050814/4ee77a95/attachment.bin


More information about the Members mailing list