在Windows上构建的Hadoop 2.2 [英] build hadoop 2.2 on windows

查看:872
本文介绍了在Windows上构建的Hadoop 2.2的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我试图在Windows上安装Hadoop的,实在是太麻烦至今。

这里的错误,我不断收到

项目Hadoop的共同EXEC(编译MS-winutils):

  [错误]未能执行目标组织codehaus.mojo:EXEC-Maven的插件:1.2:命令执行失败。无法运行程序的MSBuild(在目录C:\\ HDFS \\ Hadoop的共同项目\\ Hadoop的共同):CreateProcess的错误= 2,系统找不到指定的文件 - > [求助1]
[错误]
[错误]要查看错误的完整堆栈跟踪,重新运行Maven与-e开关。
[错误]使用-X开关启用完全调试日志记录重新运行Maven。
[错误]
[错误]有关错误和可能的解决方案,请阅读以下文章了解更多信息:
[错误] [说明1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
[错误]
[错误]纠正问题后,您可以使用以下命令恢复建设
[错误] MVN<目标> -rf:Hadoop的共同

我有msbuild.exe,窗户sdk7.1,cygwin64,maven3.0.5,JDK7都设立了环境在我的Windows 7 x64系统中。

这是Hadoop的2.2.0 SRC这是我从Apache的网站上下载。

系统环境下,我已设置

  C:\\ WINDOWS \\ Microsoft.NET \\ Framework64 \\ v4.0.30319

这是路径的MSBuild,但仍然不能正常工作,没有人知道如何解决这一问题?

感谢

更新:
我在Hadoop的共同项目\\ Hadoop的共同改变的pom.xml一点从

 <可执行指令GT;的MSBuild< /可执行>

 <可执行指令GT; msbuild.exe< /可执行>

现在,我收到以下错误

项目Hadoop的共同EXEC(编译MS-winutils):

  [错误]未能执行目标组织codehaus.mojo:EXEC-Maven的插件:1.2:命令执行失败。退出过程中有错误:1(出口值:1) - > [求助1]
[错误]
[错误]要查看错误的完整堆栈跟踪,重新运行Maven与-e开关。
[错误]使用-X开关启用完全调试日志记录重新运行Maven。
[错误]
[错误]有关错误和可能的解决方案,请阅读以下文章了解更多信息:
[错误] [说明1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
[错误]
[错误]纠正问题后,您可以使用以下命令恢复建设
[错误] MVN<目标> -rf:Hadoop的共同


解决方案

我找到了解决这一问题。我有VS 2012的Windows 8.1
面对这个确切的问题。我检查了下pom.xml中Hadoop的常见
该执行ID和运行以下命令

  F:\\ HDP>的MSBuild F:\\ HDP \\ Hadoop的共同项目\\ Hadoop的共同的\\ src \\主\\ winutils \\ winutils.sln / NOLOGO / P:配置=释放; OUTDIR =斌

它给了我下面的异常

  C:\\ Program Files文件(x86)的\\的MSBuild \\ Microsoft.Cpp \\ V4.0 \\ V110 \\ Microsoft.Cpp.Platform.targets(42,5):错误MSB8020:该建立为Visual Studio 2010工具(平台工具集='V100')无法找到。
要建立使用V100的构建工具,可以单击项目菜单或右键单击该解决方案,然后选择更新VC ++项目......。安装Visual Studio 2010中使用Visual Studio 2010的构建工具来构建。
[F:\\ HDP \\ Hadoop的共同项目\\ Hadoop的共同的\\ src \\主\\ winutils \\ libwinutils.vcxproj]

由于我没有Visual Studio 2010中我的机器上,这个问题必须是
在该溶液中。我在VS 2012年开业的解决方案,并编译一次吧。
执行行家再次给了我另外一个错误,但这次指向
Hadoop的共同的\\ src \\主\\本地\\ native.sln。我打开了对VS 2012和太
没有错误。

希望这有助于

谢谢
罗希特

I am trying to install hadoop on windows, it is so troublesome so far.

here is error i keep getting

[ERROR] Failed to execute goal org.codehaus.mojo:exec-maven-plugin:1.2:exec (compile-ms-winutils) on project hadoop-common: Command execution failed. Cannot run program "msbuild" (in directory "C:\hdfs\hadoop-common-project\hadoop-common"): CreateProcess error=2, The system cannot find the file specified -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
[ERROR]
[ERROR] After correcting the problems, you can resume the build with the command
[ERROR]   mvn <goals> -rf :hadoop-common

I have msbuild.exe, windows sdk7.1, cygwin64, maven3.0.5, jdk7 all set up in environment on my windows 7 x64 box.

This is hadoop 2.2.0 src which i downloaded from apache website.

under system environment, i have set

C:\Windows\Microsoft.NET\Framework64\v4.0.30319

this is the path to msbuild, but still doesn't work, does anyone know how to fix this?

thanks

update: I changed pom.xml at hadoop-common-project\hadoop-common a little from

<executable>msbuild</executable>

to

<executable>msbuild.exe</executable>

Now, I'm getting following error

[ERROR] Failed to execute goal org.codehaus.mojo:exec-maven-plugin:1.2:exec (compile-ms-winutils) on project hadoop-common: Command execution failed. Process exited with an error: 1(Exit value: 1) -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
[ERROR]
[ERROR] After correcting the problems, you can resume the build with the command
[ERROR]   mvn <goals> -rf :hadoop-common

解决方案

I found the solution to this problem. I have VS 2012 on Windows 8.1 and faced this exact issue. I checked out the pom.xml under hadoop-common for that execution id and ran the following command

F:\HDP>msbuild F:\HDP\hadoop-common-project\hadoop-common\src\main\winutils\winutils.sln /nologo/p:Configuration=Release;OutDir=bin

It gave me the following exception

C:\Program Files(x86)\MSBuild\Microsoft.Cpp\v4.0\V110\Microsoft.Cpp.Platform.targets(42,5): error MSB8020: The builds tools for Visual Studio 2010 (Platform Toolset ='v100') cannot be found.
To build using the v100 build tools, either click the Project menu or right-click the solution, and then select "Update VC++ Projects...". Install Visual Studio 2010 to build using the Visual Studio 2010 build tools.
[F:\HDP\hadoop-common-project\hadoop-common\src\main\winutils\libwinutils.vcxproj]

Since I do not have Visual Studio 2010 on my machine, the problem had to be in the solution. I opened the solution in VS 2012 and compiled it once. Executing maven again gave me another error but this time pointing to hadoop-common\src\main\native\native.sln. I opened that on VS 2012 too and no error.

Hope this helps

Thanks Rohit

这篇关于在Windows上构建的Hadoop 2.2的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆