Difference between revisions of "King0770-Notes-Download-JDK"

Line 61: Line 61:
[[Category:Community Sandbox]]
[[Category:Community Sandbox]]

Revision as of 15:03, 31 May 2009

If you ever see these types of messages from the command line, there maybe a possibility of JDK being corrupted.
As you can see, running commands like "zmhostname" and/or "zmlocalconfig" will produce the "NoClassDefFoundError" error.

Error occurred during initialization of VM
java/lang/NoClassDefFoundError: java/lang/Object

/opt/zimbra/bin/zmlocalconfig -q -m export
Error occurred during initialization of VM
java/lang/NoClassDefFoundError: java/lang/Object

To download JDK:

1) Go to http://java.sun.com/products/archive/

2) Pick "JDK/JRE - 5.0" then "5.0 Update 17", then click "Go"

3) On the next page click on the link that displays "Download JDK"

4) On the next page select your platform, select multi-language, and click on the "I agree" license
There's only two options for Linux:

32 Bit

64 Bit

5) Once you have downloaded the *.bin file, transfer it to the Zimbra machine in the /tmp directory.

To install JDK: (using jdk-1_5_0_17-linux-i586.bin as an example)

1) zmcontrol stop **run as zimbra**

2) mv /opt/zimbra/jdk1.5.0_17 /opt/zimbra/jdk1.5.0_17.OLD **run as root**

3) chown 755 /tmp/jdk-1_5_0_17-linux-i586.bin **run as root**

4) cd /opt/zimbra **run as root**

5) /tmp/jdk-1_5_0_17-linux-i586.bin
Note:This will basically extract JDK into the /opt/zimbra. IIRC, there is EULA where you'll have to use the space bar to get to the bottom of the EULA to indicate yes or no.

6) chown -R zimbra:zimbra jdk1.5.0_17

7) Test again with the zmhostname or zmlocalconfig commands.

8) zmcontrol start **run as zimbra**

My rationale for this page was that it took me a long time to figure out where to download the proper JDK file. Hopefully this will help those who are in need of installing JDK for linux, and are not quite savvy with Sun's website.

Special thanks to Thom O'Connor for the pointers!

Jump to: navigation, search