请问一下最后是怎么解决的
恩恩,原来是下错kafka了,感谢无名大神的细心指导啊。真心感谢
echo $JAVA_HOME 无值,还未生效。
/etc/profile
# System wide environment and startup programs, for login setup
# Functions and aliases go in /etc/bashrc
# It's NOT a good idea to change this file unless you know what you
# are doing. It's much better to create a custom.sh shell script in
# /etc/profile.d/ to make custom changes to your environment, as this
# will prevent the need for merging in future updates.
export JAVA_HOME=/usr/java/jdk1.7.0_79
export PATH=$JAVA_HOME/bin:$PATH
export CLASSPATH=.:$JAVA_HOME/lib/dt.jar:$JAVA_HOME/lib/tools.jar:$CLASSPATH
pathmung e() {
这是环境变量
[root@localhost Desktop]# echo $JAVA_HOME
[root@localhost Desktop]# java -version
java version "1.7.0_79"
Java(TM) SE Runtime Environment (build 1.7.0_79-b15)
Java HotSpot(TM) 64-Bit Server VM (build 24.79-b02, mixed mode)
[root@localhost Desktop]#
我echo $JAVA_HOME
的时候什么也不显示,版本显示64位的