赞
踩
rpm -qa |grep java
rpm -qa |grep jdk
rpm -qa |grep gcj
rpm -qa | grep java | xargs rpm -e --nodeps
yum list java*
yum list java-1.8*
yum install java-1.8.0-openjdk* -y
java -version
- /usr/bin 目录下已经有java执行文件了,无需在配置
vi /etc/profile
#set java environment
#JAVA_HOME=/usr/lib/jvm/java-1.8.0-openjdk-1.8.0.332.b09-1.el7_9.x86_64
#PATH=$PATH:$JAVA_HOME/bin
#CLASSPATH=.:$JAVA_HOME/lib/dt.jar:$JAVA_HOME/lib/tools.jar
#export JAVA_HOME CLASSPATH PATH
source /etc/profile
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。