Ubuntu: change the path from OpenJDK 6 to Oracle JDK 7

前端 未结 5 1184
花落未央
花落未央 2020-12-13 20:25

After downloading the latest .tar file I ran tar zxvf jdk-7u45-linux-x64.tar.gz to extract java files.

Set the path in .bashrc file (

5条回答
  •  自闭症患者
    2020-12-13 20:41

    You probably want to do

    export PATH=/usr/lib/jvm/jdk1.7.0_45/bin:$PATH
    

    OpenJDK is probably still in the path, and Linux will use the first java it finds.

    If you don't need it, I would recommend uninstalling OpenJDK.

提交回复
热议问题