登入官網進行版本的jdk下載,別想太多,肯定得建立個賬號登入它才讓你下載。。。。老實搞吧
https://download.oracle.com/otn/java/jdk/8u361-b09/0ae14417abb444ebb02b9815e2103550/jdk-8u361-linux-x64.tar.gz
建議現在本地下載後,透過lrzsz上傳給伺服器,伺服器上使用wget方式下載特別慢
[root@app-bj-ali-ecs1 ~]# ls jdk-8u361-linux-x64.tar.gz [root@app-bj-ali-ecs1 ~]# tar -xzf jdk-8u361-linux-x64.tar.gz [root@app-bj-ali-ecs1 ~]# ls jdk1.8.0_361 jdk-8u361-linux-x64.tar.gz [root@app-bj-ali-ecs1 ~]# mv jdk1.8.0_361/ /usr/local/ [root@app-bj-ali-ecs1 ~]# tail /etc/profile [root@app-bj-ali-ecs1 ~]# tail /etc/profile # 追加這三行 export JAVA_HOME=/usr/local/jdk1.8.0_361 export JRE_HOME=${JAVA_HOME}/jre export PATH=$PATH:${JAVA_HOME}/bin:${JRE_HOME}/bin [root@app-bj-ali-ecs1 ~]# java -version java version "1.8.0_361" Java(TM) SE Runtime Environment (build 1.8.0_361-b09) Java HotSpot(TM) 64-Bit Server VM (build 25.361-b09, mixed mode)