Good news that you seem to have solved this.
Managing PermGen is a little tricky. It's not always easy - in fact it's usually hard - to tell at a quick look whether the Java virtual machines is just running out of PermGen space because of normal usage or if there is a memory leak.
A reassuring test is to change the memory parameters as you have done, then run a long loop of whatever tasks exposed the original stack traces (for example, repetitive deployments if that seems to have triggered the problem in the first place) and not see the problem again.
Even more convincing is to use jconsole or some other memory usage monitor and watch the memory consumption during the long-running test. Often you will see a "sawtooth" or "shark fin" effect with the recurring pattern of usage ramping up to a point, then the garbage collector reclaiming a large chunk of memory. If the GC reclaims back to the same baseline each time and the peak usage does not increase over time, that's a good sign.
It's possible that there is a memory leak and that increasing the memory parameters has simply allowed you to run longer before encountering the problem.
- Tim
[Message sent by forum member 'tjquinn' (tjquinn)]
http://forums.java.net/jive/thread.jspa?messageID=344646