1.下載JDK.binjava
2.運行./JDK.binbash
3.移動JDK目錄到/usr/local/code
4.編輯環境變量io
vi /etc/profile export JAVA_HOME=/usr/local/JDK export PATH=$JAVA_HOME/bin:$PATH
5.更新環境變量class
source /etc/profile
6.查看JDK變量
java -version