Oracle released an optimized hard-float JVM for the ARM architecture and plattforms so i decided to run a grails application on my raspberry pi wich offers a REST api for some connected devices and sensors. I’m using raspbian linux distribution wich is a debian fork optimized for the raspberry pi.
Here are some steps how i got it working:
1. Install the Java SDK (Version 7, 8 ist not supported by grails now, but will be in future)
sudo apt-get install oracle-java7-sdk
2. Start the Grails application in client mode, not server mode (default), because otherwise you get the following error message:
Error occurred during initialization of VM Server VM is only supported on ARMv7+ VFP
…so change settings to client mode
export GRAILS_OPTS="-client -Xmx128M -Xms127M -XX:PermSize=128m -XX:MaxPermSize=128m -Dfile.encoding=UTF-8"
…and run grails in your project directory.
After some seconds should your grails application start and you can access it on http://localhost:8080.