0
votes

I am trying to upgrade Grails 1.3.7 to Grails 2.0.3 in Linux. And I am getting the message as follows: Error occurred during initialization of VM when typing the command grails -version

This is what I did

  1. wget http://dist.springframework.org.s3.amazonaws.com/release/GRAILS/grails-2.0.3.zip
  2. unzip grails-2.0.3.zip
  3. mv grails-2.0.3 /usr/share
  4. in /etc/profile GRAILS_HOME=/usr/share/grails-2.0.3 followed by export GRAILS_HOME, followed by addition to PATH env variable.
  5. Closed the session
  6. Restarted the session. Typed grails -version
  7. Error occurred during initialization of VM Could not reserve enough space for object heap

Any ideas?

1

1 Answers

1
votes

I have solved it by creating a GRAILS_OPTS environment variable as follows and added it to the /etc/profile:

export GRAILS_OPTS="-server -Xmx512M -XX:MaxPermSize=512m -Dfile.encoding=UTF-8"