'Dev'에 해당되는 글 1건

  1. 2013.03.15 Grails and Tomcat 7: Out of Memory (PermGen)
posted by Kyleslab 2013. 3. 15. 11:52


Deploying a Grails application to Tomcat 7 for the first time you may encounter the following error:
java.lang.OutOfMemoryError: PermGen space
Assumption: Windows Service

To correct the problem, just adjust the default memory and Perm Gen space allocated in Tomcat 7.

Start the service config tool "tomcat7w.exe:


Change the Java Options:

Switch to the Java tab:
  • Change the “Initial Memory pool” to 128
  • Change the “Maximum memory pool”  to 512
Perm Gen settings: 
Add the follow two lines to the Java options
--XX:PermSize=256m
--XX:MaxPermSize=265m
  

Restart the service.
Test your application

References:
  • http://www.grails.org/FAQ
  • http://tomcat.apache.org/tomcat-7.0-doc/windows-service-howto.html