I had similar problem as issue https://jira.jboss.org/browse/JBAS-6549
But using JDK 1.6.0_16 and 1.6.0_17 doesn't help (I was using 1.6.0_20), not sure if anyone met same problem, below is my finding:
(These values changed every time server started, range around 2.5G - 2.9G for VSZ)
The value was taken after deployment was finished and server was started, use "ps aux".
The wars deployed in 4 and 5 are not the same, because I precompiled jsp, and 5 uses new jar to compile.
[Found a way to cut down]:
I heard that VFS in JBoss 5 may introduce some overhead, so I tried the options it provided, and found if I set jboss.vfs.forceCopy to false:
I'm confused, according to the document, when setting forceCopy to false, JBoss will use much more memory, but now seems not.
Now our QA is doing performance and pressure testings based on this configuration, will know the result soon.
The heap usuage is normal, I've checked via JMX console. And it should be normal since I've limited the Xms and Xmx.
The more memory usuage should be introduced by JBoss, maybe via JNI.
By using pmap and comparing the result, I found the main differences between JBoss 4, 5 and 5 (forceCopy=false) is: in 5, there are many 1M block reserved, in 5 (forceCopy=false), less block, in 4, hardly fine, here is example of the 1M block:
3d000000 996K rwx-- [ anon ]
3d0f9000 28K ----- [ anon ]
3d100000 996K rwx-- [ anon ]
3d1f9000 28K ----- [ anon ]
3d200000 1016K rwx-- [ anon ]
3d2fe000 8K ----- [ anon ]
3d300000 1012K rwx-- [ anon ]
3d3fd000 12K ----- [ anon ]
I've attached the pmap log.
Memory leak in JBoss due to VFS?