jdk

Ling Yu
Ling Yu

安装包安装方式

下载

wget https://download.java.net/java/GA/jdk11/9/GPL/openjdk-11.0.2_linux-x64_bin.tar.gz
tar -zxvf openjdk-11.0.2_linux-x64_bin.tar.gz

编辑环境变量

vim /etc/profile
 
# profile
export JAVA_HOME=/usr/local/jdk-11.0.2
export JRE_HOME=$JAVA_HOME/jre
export CLASSPATH=.:$JAVA_HOME/lib:$JRE_HOME/lib
export PATH=$JAVA_HOME/bin:$PATH
 
source /etc/profile