How do you install Sun Java on Fedora 14, instead of the default OpenJDK?

  1. Go to http://www.oracle.com/technetwork/java/javase/downloads/index.html
  2. Download JDK
  3. Choose Linux x64 for Platform
  4. Download the RPM jdk-6u23-linux-x64-rpm.bin
  5. sudo sh jdk-6u23-linux-x64-rpm.bin
  6. sudo /usr/sbin/alternatives --install /usr/bin/java java /usr/java/default/bin/java 20000

Sanity check:

[root@server ~]# java -version
java version "1.6.0_23"
Java(TM) SE Runtime Environment (build 1.6.0_23-b05)
Java HotSpot(TM) 64-Bit Server VM (build 19.0-b09, mixed mode)


  • Do I need to uninstall gcj, if so what is the best method? – fivetwentysix Apr 3 '11 at 3:08
  • No need as far as I know. Why should gcj be a problem? – Yuval A Apr 5 '11 at 10:05

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.