从零开始的Linux运维屌丝之路,资源免费分享平台   运维人员首选:简单、易用、高效、安全、稳定、社区活跃的开源软件

JAVA手动安装步骤1.6 1.7 1.8 1.11

发布:蔺要红07-19分类: 运维


1.6手动安装
#     wget https://mirrors.linyaohong.com/src/tomcat/jdk-6u45-linux-x64.bin
#或者:wget http://mirrors.linuxeye.com/jdk/jdk-6u45-linux-x64.bin

chmod +x jdk-6u45-linux-x64.bin
./jdk-6u45-linux-x64.bin
mv jdk1.6.0_45/ /usr/local/

cat >>/etc/profile <<EOF
export JAVA_HOME=/usr/local/jdk1.6.0_45
export PATH=\$JAVA_HOME/bin:\$PATH
export CLASSPATH=.:\$JAVA_HOME/lib/dt.jar:\$JAVA_HOME/lib/tools.jar
EOF

source /etc/profile
java -version

1.7手动安装
#    : wget http://mirrors.linuxeye.com/jdk/jdk-7u80-linux-x64.tar.gz
#或者 : wget https://mirrors.linyaohong.com/src/tomcat/jdk-7u80-linux-x64.tar.gz

tar zxf jdk-7u80-linux-x64.tar.gz
mv jdk1.7.0_80/ /usr/local/

cat >>/etc/profile <<EOF
export JAVA_HOME=/usr/local/jdk1.7.0_80
export PATH=\$JAVA_HOME/bin:\$PATH
export CLASSPATH=.:\$JAVA_HOME/lib/dt.jar:\$JAVA_HOME/lib/tools.jar
EOF

source  /etc/profile
java -version


 1.8手动安装
wget http://mirrors.linuxeye.com/jdk/jdk-8u212-linux-x64.tar.gz
wget https://mirrors.linyaohong.com/src/tomcat/jdk-8u212-linux-x64.tar.gz

tar zxf jdk-8u212-linux-x64.tar.gz 
mv jdk1.8.0_212/ /usr/local/

cat >>/etc/profile <<EOF
export JAVA_HOME=/usr/local/jdk1.8.0_212
export PATH=\$JAVA_HOME/bin:\$PATH
export CLASSPATH=.:\$JAVA_HOME/lib/dt.jar:\$JAVA_HOME/lib/tools.jar
EOF

source /etc/profile
java -version

 1.11手动安装
wget http://mirrors.linuxeye.com/jdk/jdk-11.0.3_linux-x64_bin.tar.gz
wget https://mirrors.linyaohong.com/src/tomcat/jdk-11.0.3_linux-x64_bin.tar.gz

tar zxf jdk-11.0.3_linux-x64_bin.tar.gz 
mv jdk-11.0.3 /usr/local/

cat >>/etc/profile <<EOF
export JAVA_HOME=/usr/local/jdk-11.0.3
export PATH=\$JAVA_HOME/bin:\$PATH
export CLASSPATH=.:\$JAVA_HOME/lib/dt.jar:\$JAVA_HOME/lib/tools.jar
EOF

source /etc/profile
java -version
温馨提示如有转载或引用以上内容之必要,敬请将本文链接作为出处标注,如有侵权我会在24小时之内删除!

欢迎使用手机扫描访问本站