Windows上的Hadoop-“错误设置JAVA_HOME错误." [英] Hadoop on Windows - "Error JAVA_HOME is incorrectly set."
问题描述
我正在尝试让Hadoop在Windows计算机上运行本地模式".我一直在使用此指南: http://hadoop.apache.org/docs/r1.2.1/single_node_setup.html
I'm trying to get Hadoop running 'Local Mode' on my Windows machine. I've been using this guide: http://hadoop.apache.org/docs/r1.2.1/single_node_setup.html
当我运行命令:bin/hadoop时,出现以下错误消息:
When I run the command: bin/hadoop, I get the following error message:
错误:JAVA_HOME设置错误.请更新C:... \ hadoop-2.7.1 \ conf \ hadoop-env.cmd
Error: JAVA_HOME is incorrectly set. Please update C:...\hadoop-2.7.1\conf\hadoop-env.cmd
在 hadoop-env.cmd
里面,我有一行: set JAVA_HOME =%JAVA_HOME%
当我在命令行中键入 echo%JAVA_HOME%
时,我得到: C:\ Java \ jdk1.0.8_51
When I type echo %JAVA_HOME%
at the command line I get:
C:\Java\jdk1.0.8_51
即使我将 hadoop-env.cmd
中的行更改为: set JAVA_HOME = C:\ Java \ jdk1.0.8_51
我收到同样的错误...
Even if I change the line in hadoop-env.cmd
to:
set JAVA_HOME=C:\Java\jdk1.0.8_51
I get the same error...
怎么可能我的 JAVA_HOME
设置不正确?
How could it be that my JAVA_HOME
is incorrectly set?
推荐答案
如果您的JAVA_HOME路径包含空格,则必须使用 Windows 8.3路径名
If your JAVA_HOME path contains spaces, you must use the Windows 8.3 Pathname
这篇关于Windows上的Hadoop-“错误设置JAVA_HOME错误."的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!