Java upgrade notes

To 1.7

Simply download the latest JDK7 RPM from the Oracle website, install on all nodes (check that "/usr/java/latest" and "/usr/java/default" now point to the right directory, and restart "infinit.e-index-engine" and "tomcat6-interface-engine" services (the latter only on API nodes, the former typically on both)

To 1.8

Using scp within cygwin, scp the rpm file over to the target machine,e.g.

scp /home/jfreydank/jfreydank_win/Downloads/jdk-8u25-linux-x64.rpm ec2-user@dev.ikanow.com:~
 
Install the rpm: 
sudo rpm -i jdk-8u25-linux-x64.rpm

Check if java is installed correctly:

[ec2-user@ip-10-113-42-186 java]$ java -version
java version "1.8.0_25"
Java(TM) SE Runtime Environment (build 1.8.0_25-b17)
Java HotSpot(TM) 64-Bit Server VM (build 25.25-b02, mixed mode)

Keeping Hadoop in sync

After upgrading to a version with a differerent JDK (eg elasticsearch 1.3+) requires JDK7, it will likely be necessary to modify the Hadoop configuration to use a compatible JRE.

Go the "mapreduce" service configuration pages (described here), and in the "MapReduce Service Environment Safety Valve" text box, add the line (eg):

JAVA_HOME="/usr/java/JDK_VERSION/jre/"

on a separate line, where JDK_VERSION is the desired JRE, eg "jdk1.7.0_60"

Copyright © 2012 IKANOW, All Rights Reserved | Licensed under Creative Commons