Upgrading JRE for Railo on Centos

This is really a set of notes for me so I don’t forget all this in the future, but hopefully might help others.

If you look at the Railo wiki on github about this, it gives you great instructions about 6, but I found my experience slightly different for 7.

These are the steps to install JRE from Oracle on Centos 64bit; (for the purposes of this post, this is Version 7u25)

  1. Go to http://www.oracle.com/technetwork/java/javase/downloads/index.html
  2. Look for the JRE Download Link
  3. Save the jre-7u25-linux-x64.rpm to your local machine
  4. Upload it to your root or home folder on the server
  5. Assuming you’re logged in via SSH, run:
    rpm -i jre-7u25-linux-x64.rpm
  6. Shut down railo:
    /opt/railo/railo_ctl stop
  7. Backup / rename the old JRE:
    cp -R /opt/railo/jdk/ /opt/railo/jdk.bak 
    rm -f /opt/railo/jdk 
  8. Find the newly installed .rpm  – hint, probably:
  9. Rename to:
  10. Now, you can symlink this version to the Railo install:
    ln -s /usr/java /opt/railo/jdk
  11. Restart Railo:
    /opt/railo/railo_ctl start
  12. Login to Railo Server Admin and double check the JRE version running on the front page.
  13. Beer.

Thanks to  Scott at Viviotech for the hint about the .rpm and symlinking!