0

I am running into issues where by my grails web-app is unable to start in geronimo. These are the version I am running with - Grails version 1.3.7 - Geronimo version 2.1.1 whatever I do application fails to start with varied exceptions mostly tied to perm-gen errors

Some of the exceptions I end up getting are

09:43:27,733 ERROR [ReloadAwareAutowireCapableBeanFactory] Destroy method on bean with name 'eventTriggeringInterceptor' threw an exception
java.lang.OutOfMemoryError: PermGen space
    at java.lang.ClassLoader.defineClass1(Native Method)
    at java.lang.ClassLoader.defineClassCond(ClassLoader.java:632)
    at java.lang.ClassLoader.defineClass(ClassLoader.java:616)
    at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:141)
    at org.apache.geronimo.kernel.classloader.JarFileClassLoader.access$200(JarFileClassLoader.java:52)
    at org.apache.geronimo.kernel.classloader.JarFileClassLoader$6.run(JarFileClassLoader.java:308)

I really need some help here, I am stuck what to do next or how to resolve. I used

set JAVA_OPTS= -Xmx1024m -XX:MaxPermSize=256m in geronimo.bat 

but that didn't help either

Amit
  • 2,080
  • 3
  • 19
  • 24

1 Answers1

0

changing the options to

set JAVA_OPTS=-verbose:gc -Xmx756m -XX:MaxPermSize=256m

did the trick for me.

Amit
  • 2,080
  • 3
  • 19
  • 24
  • I'm confused, so you didn't increase the perm gen at all, just set the garbage collection output to verbose? How did that fix anything? – grantmcconnaughey Jul 22 '14 at 04:33
  • No I changed the max heap i.e. reduced from 1GB to 756M. Since OOM error was from PermGen space and not really heap memory. Reducing heap to 756 allowed more process memory to be available for native heap. Look at this SO for details regarding PermGen http://stackoverflow.com/questions/1279449/what-is-perm-space – Amit Jul 23 '14 at 02:01