Instalacao do java7 no Red Hat 6.4

Posted . Visible to the public.

Baixe o .rpm da ultima versao do java aqui (hoje a ultima versao é a 7u40 Show archive.org snapshot ): http://www.oracle.com/technetwork/java/javase/downloads/jdk7-downloads-1880260.html Show archive.org snapshot
wget http://download.oracle.com/otn-pub/java/jdk/7u40-b43/jdk-7u40-linux-x64.rpm jdk-7u40-linux-x64.rpm
Mude para o usuario root:
sudo -i
#ou
su -
Instale o pacote:
rpm -Uvh jdk-7u40-linux-x64.rpm
Configure a opção para utilizar o novo java:
alternatives --install /usr/bin/java java /usr/java/jdk1.7.0_40/jre/bin/java 20000
alternatives --install /usr/bin/javaws javaws /usr/java/jdk1.7.0_40/jre/bin/javaws 20000
alternatives --install /usr/bin/javac javac /usr/java/jdk1.7.0_40/bin/javac 20000
alternatives --install /usr/bin/jar jar /usr/java/jdk1.7.0_40/bin/jar 20000
Selecione o novo java para uso:
alternatives --config java
Execute java -version, devera aparecer algo como:
java version "1.7.0_40"

Victor Carvalho
Last edit
Tags
Posted by Victor Carvalho to ZeroGlosa (2013-09-18 21:30)