当前位置:   article > 正文

Hdoop 启动:localhost: Error: JAVA_HOME is not set and could not be found._localhost: error: java home is not set and could n

localhost: error: java home is not set and could not be found.

参考教程:
http://hadoop.apache.org/docs/current/hadoop-project-dist/hadoop-common/SingleCluster.html

其中有

Prepare to Start the Hadoop Cluster

Unpack the downloaded Hadoop distribution. In the distribution, edit
the file etc/hadoop/hadoop-env.sh to define some parameters as
follows:
export JAVA_HOME=/usr/java/latest(原来是${JAVA_HOME},把这个改为相应的jdk真实路劲)
Try the following command:
bin/hadoop
This will display the usage documentation for the
hadoop script.

自己不按照文档说的来,因为在shell脚本中一般$${JAVA_HOME} 或者$JAVA_HOME
都是取变量的值,然后左边又有=等号,所以就自作聪明的认为没有必要了!
关于环境相关,以后还是就按照官方的来吧。。。。

现在还有极大的可能是,JAVA_HOME没有被 export

声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/Gausst松鼠会/article/detail/574534
推荐阅读
相关标签
  

闽ICP备14008679号