Packaging/Java Installation

From GEANT2-JRA1 Wiki

Contents

Introduction

The installation of Java JDK is described here. Some distributions support OpenJDK or IcedTea. These Java versions should work, but are not supported by the perfSONAR project.

Installation instructions

Red Hat Enterprise 5.1

  • Enable the supplemental software repository
  • as root run:
yum install java-1.5.0-sun tomcat5
  • if can't enable the supplemental repository you can follow the instructions below.


Fedora 8 / Fedora 9 / CentOS 5.1

sh jdk-6u6-linux-i586-rpm.bin
  • now install the compat package:
yum install libxslt jpackage-utils
yum localinstall java-1.6.0-sun-compat-1.6.0.06-1jpp.i586.rpm
  • now you can switch between different JRE's using the alternatives command:
/usr/sbin/alternatives --config java
/usr/sbin/alternatives --config javac

Debian 4.0

  • First you need to enable the non-free debian repository. Edit the file /etc/apt/sources.lst.
  • Find the line that looks like:
deb http://ftp.debian.org etch main contrib
  • Maybe the hostname is different because you are using a mirror, this doesn't matter. Add 'non-free' at the end. After that it should look something like this:
deb http://ftp.debian.org etch main contrib non-free
  • as root run:
apt-get update
apt-get install sun-java5-jdk
  • now you can switch between different JDK's using the alternatives command:
update-alternatives --config java
update-alternatives --config javac

Ubuntu 7.10 / 8.04 LTS

  • Run this command:
sudo apt-get install sun-java6-jdk
  • now you can switch between different JDK's using the alternatives command:
update-alternatives --config java
update-alternatives --config javac
Personal tools