linux配置java环境变量

  • jdk安装路径
    /usr/local/etc/java/jdk1.8.0_181
export JAVA_HOME=/usr/local/etc/java/jdk1.8.0_181
export JRE_HOME=${JAVA_HOME}/jre  
export PATH=${JAVA_HOME}/bin:$PATH
export CLASSPATH=.:${JAVA_HOME}/lib:${JRE_HOME}/lib
export JAVA_HOME=/usr/lib/jvm/java-1.8.0-openjdk-amd64
export JRE_HOME=${JAVA_HOME}/jre  
export CLASSPATH=.:${JAVA_HOME}/lib:${JRE_HOME}/lib  
export PATH=${JAVA_HOME}/bin:$PATH

你可能感兴趣的:(linux配置java环境变量)