Open Zakariyya opened 4 years ago
wget http://download.oracle.com/otn-pub/java/jdk/8u181-b13/96a7b8442fe848ef90c96a2fad6ed6d1/jdk-8u181-linux-x64.tar.gz
tar -xvf jdk-8u181-linux-x64.tar.gz
vim /etc/profile
文末加上 ### JAVA_HOME export JAVA_HOME=/opt/jdk export PATH=$PATH:$JAVA_HOME/bin:$JAVA_HOME/jre/bin
source /etc/profile
javac
java -version
tar -xvf jdk-8u181-linux-x64.tar.gz
解压安装包vim /etc/profile
source /etc/profile
让 profile文件立即生效。javac
及java -version
命令来检查是否按照成功