The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Wrong Java version showing after Upgrading

Discussion in 'General Discussion' started by intertac, Feb 13, 2008.

  1. intertac

    intertac Registered

    Joined:
    Mar 16, 2006
    Messages:
    1
    Likes Received:
    0
    Trophy Points:
    1
    When I issue a java -version cmd, I get version 1.4.2. I just recently manually upgraded to 1.6..04 so I am at a loss as to why the system is telling me it still has 1.4.2

    In searching/google I came a cross a few things such as modifying the /etc/profile and putting in the following lines:

    export PATH=$PATH:/usr/java/jdk1.6.0_04/bin:/usr/java/jdk1.6.0_04/jre/bin
    export JAVA_HOME=/usr/java/jdk1.6.0_04
    export CLASSPATH="./:/usr/java/jdk1.6.0_04/lib:/usr/java/jdk1.6.0_04/jre/lib

    then issuing the cmd: source /etc/profile

    but I still get the old version.

    What am I doing wrong? Is this a cPanel quirk and I need to change something else??
    I am at a loss.

    Any pointers/ideas would be much appreciated.
    Thanks
    tom
     
  2. jayh38

    jayh38 Well-Known Member

    Joined:
    Mar 3, 2006
    Messages:
    1,215
    Likes Received:
    0
    Trophy Points:
    36
    Remove the old java rpm/s
    rpm -qa | grep java

    Then reinstall the new bin if needed.
     
  3. cPanelKenneth

    cPanelKenneth cPanel Development
    Staff Member

    Joined:
    Apr 7, 2006
    Messages:
    4,458
    Likes Received:
    22
    Trophy Points:
    38
    cPanel Access Level:
    Root Administrator
    You can also use the update-alternatives command to switch to the different Java version.
     
Loading...

Share This Page