Results 1 to 4 of 4
Dear all,
I installed jre 1.6 in RHEL 5.
its installed successfully.but when i check the version of java by java -version command its shows only 1.4.
anything need to ...
- 08-26-2010 #1Just Joined!
- Join Date
- Jan 2009
- Posts
- 15
Problem in Installing JAVA in RHEL5
Dear all,
I installed jre 1.6 in RHEL 5.
its installed successfully.but when i check the version of java by java -version command its shows only 1.4.
anything need to be done to update this?
thanks in advance
- 08-26-2010 #2
Hi Hemant,
Although you had installed JRE 1.6, it is not defined the root PATH to access JRE 1.6.
When you execute - # java -version, it shows the version of that java, which is defined in your path and it is 1.4
Provide the location of JRE 1.6 in the PATH and then you will get the correct java version displayed
For Ex: If you had installed JRE 1.6 in /opt/java1.6, set the PATH in the .bash_profile file as follows :-
PATH=/opt/java1.6/bin:$PATH
After modifying the PATH in the .bash_profile, save the file and logout from the session, in which you were working earlier and login again.
Now, when you execute # java -version, you should see 1.6 version
Thanks,
Maruthi Vara Prasad Ch
- 08-26-2010 #3Just Joined!
- Join Date
- Aug 2010
- Posts
- 3
The easiest way to manage this is by configuring the alternatives. To do this
alternatives --install /usr/bin/java java /path/to/installed/jre/bin/java
alternatives --config java
you will be prompted to select the java version which you would like to use from now onwards.
- 08-27-2010 #4Just Joined!
- Join Date
- Jan 2009
- Posts
- 15
thanks
thanks a lot
now the version got changed.
thanks once again


Reply With Quote