Grails commands don't work

September 11, 2014 2k views

I installed grails on a new Ubuntu droplet using gvm. Doing gvm list grails shows that grails 2.3.8 is installed, as expected. Doing any grails commands causes the screen to refresh and does nothing else. Anyone else experience this?

2 Answers

Grails seems to be installed correctly. The only thing that I can think of is that Java is not installed. In fact, I just tested it. If I remove my Java installation, grails shows the same behavior that you're describing.

To install Java, run:

sudo apt-get install default-jdk
  • Could be something wrong with java installation. I do have java installed: which java produces /usr/bin/java. I set JAVA_HOME to /usr/bin/java and CLASSPATH to /usr/lib/jvm/java-1.7.0-openjdk-amd64 (I had installed a different java). Does that look correct?

  • JAVA_HOME is the install directory, not the location of the binary. On my system, it is:

    # echo $JAVA_HOME
  • Thanks! Setting JAVA_HOME to that lets my grails -version command work

Have another answer? Share your knowledge.