tar -zxvf jdk-8u181-linux-x64.tar.gz
vim /etc/profile
# jdk
export JAVA_HOME=/usr/local/software/java/jdk1.8.0_181
export PATH=${JAVA_HOME}/bin:$PATH
source /etc/profile
tar -zxvf jdk-8u181-linux-x64.tar.gz
vim /etc/profile
# jdk
export JAVA_HOME=/usr/local/software/java/jdk1.8.0_181
export PATH=${JAVA_HOME}/bin:$PATH
source /etc/profile
转载于:https://www.cnblogs.com/ayong123/p/10642426.html