Home > Grails > PermGen space in Grails

PermGen space in Grails

Hi ,

To resolve the permgen space in grails.

1) Open the Command prompt

2) fire the below command on cmd prompt.

set JAVA_OPTS=-XX:MaxPermSize=128m -XX:PermSize=128m -Xms1024m -Xmx1024m -XX:-UseGCOverheadLimit

3) Go to the project directory and fire run-app.

Advertisement
  1. Hardik Shah
    February 15, 2010 at 1:56 pm | #1

    nice Thought!

    You have solved my permgen issue in grails

  2. September 14, 2011 at 7:10 pm | #2

    Did not work for me… I even put 1024m and it still crashing.
    This ‘bug’ is making me so angry about grails development…

    • amitpatelinfo
      September 15, 2011 at 2:13 pm | #3

      Can you please try to add “-server” parameter in the argument? Also if possible then send me the trace so that I will check the issue.

      Thanks,
      Amit

  3. October 6, 2011 at 6:47 pm | #4

    Thanks it worked for me as stated.

  4. unknown
    October 17, 2011 at 8:50 am | #5

    Increasing MaxPermSize will only delay the problem. In production, the solution is to never hot-redeploy the app. Instead, always restart the server.

    In development, increasing MaxPermSize is a partial solution. You will be able to develop longer before having to restart the app server. You can turn on disable.auto.recompile, but that make development harder.

  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Connecting to %s

Follow

Get every new post delivered to your Inbox.