see
http://stackoverflow.com/questions/88235/how-to-deal-with-java-lang-outofmemoryerror-permgen-space-error
and the links there. There seems to be no good solution :-/
The only reliable solution is restart, before you haven't enough
permgenspace (use jvisualvm to monitor)
And try to increase -XX:
the second time we had the error
java.lang.OutOfMemoryError: PermGen space
and solr stopped responding.
we use the default jetty installation with jdk1.6.0_21. after the last
time i tried to set the garbage collector "right"
these are my settings:
-D64 -server -Xms892m -Xmx2048m