Setting link to newly installed Java version

Hi,
I have Solaris 8 wih Java 1.2.2 as default. I just upgraded it to Java 2 version 1.4. But when I do "java -version: I get following:

"Java version "1.2.2"
Solaris VM (build Solaris_JDK_1.2.2_05a, native threads, sunjwit)

How would I make solaris to look at my new java?

If I have to do the link then please tell me how to do that and if I have to set the PATH then tell me how to do that too...

Help is very much appreciated.

Thanks in advance!!

just u downlod pkg or patch from sunsolve.sun.com
add packages with pkgadd
and patches with patchadd <p.id>

second is the best option for update the any version in solaris..
best of luck.just u try it..
:slight_smile:

Yes, Thank you for the advice I used the pkgadd tool to upgrade the java version. The command "java -version" is still displaying the older version of java.

Is there a way I can reset the link "/usr/bin/java" to look at the new install directory "/usr/j2se/java"?
or
How would I set .cshrc to include "/usr/j2se/bin" in PATH as .cshrc is in "Read-only" file?

Which is the correct method from above?

If I do /usr/j2se/bin/java -fullversion" then it displays the correct version but I need "java -version" to display what I see when I type "java -version"

I am totally LOST here in solaris...

Thanks in advance for your help and advice!!!

type which java to get the current location of the link, remove the link with rm then recreate the link pointing to the new version.

#which java
/usr/bin/java
#ls -ld /usr/bin/java
lrwxrwxrwx 1 root other 16 Apr 8 12:41 /usr/bin/java -> ../java/bin/java
#rm /usr/bin/java
#ln -s /usr/bin/j2re1.4.2_17/bin/java /usr/bin/java
#ls -ld /usr/bin/java
lrwxrwxrwx 1 root other 30 May 28 15:30 /usr/bin/java -> /usr/bin/j2re1.4.2_17/bin/java

mr_crosby-----> U r the MAN!!!

It worked and now I am very greatfull that I ended up in the right place to solve my problem.

YOU guys ROCK!!!