On Saturday 29 April 2006 16:55, Rick Rineholt wrote:
> I received the below error on  builds ..    added the following javac
> arguments to mvn.bat to resolve: -XX:MaxPermSize=128m -XX:PermSize=64m
> Don't ask me what, or why answer provided via Googling.  YMMV
> [INFO] Compilation failure
>
> Failure executing javac, but could not parse the error:
>
> The system is out of resources.
> Consult the following stack trace for details.
> java.lang.OutOfMemoryError: PermGen space

We've hit this with Celtix on all our 64bit platforms.   There are two 
basic approaches to fixing/working around it:

1) Fork everything.  Setup both javac and surefire to fork.   By default, 
both of them run in the same vm as maven.  Also, update   There are two 
issues with this:    
  a)  Forking javac doesn't seem to always work on the mac.   It sometime 
cannot find javac.   No idea why.  (that was with Maven 2.0.2 though, it 
may be fixed)
  b)  The system classpath is different with surefire forked.   If a test 
relies on a system classpath item, it may break.  However, if a test 
relies on that, its a bad test and deserves to break.  :-)


2) The MaxPermSize flag changes you mentioned.   Usually, we set them in 
MAVEN_OPTS variable in our .bashrc files.

Enjoy!
-- 
J. Daniel Kulp
Principal Engineer
IONA
P: 781-902-8727  C: 508-380-7194
[EMAIL PROTECTED]

Reply via email to