Building Hadoop on Windows 7

I followed this tutorial to create Apache Hadoop in a Windows 7 environment. Shorten a long story shortly. I can compile Hadoop with the command mvn compileand create packages withmvn -package -DskipTests

However, I cannot. mvn package -Pdist,native-win -DskipTests -Dtar I receive I / O exceptions and cannot resolve these exceptions. I do not get these exceptions when creating Hadoop without a parameter-Dtar

Can someone help me resolve these exceptions?

[INFO] Executing tasks
main:
      [get] Destination already exists (skipping): C:\hadoop\hadoop-hdfs-    project\hadoop-hdfs-httpfs\downloads\tomcat.tar.gz
    [mkdir] Created dir: C:\hadoop\hadoop-hdfs-project\hadoop-hdfs-httpfs\target\tomcat.exp
 [exec] tar (child): C\:hadoophadoop-hdfs-projecthadoop-hdfs-httpfs/downloads/tomcat.tar.gz: Cannot open: I/O error
 [exec] tar (child): Error is not recoverable: exiting now
 [exec]
 [exec] gzip: stdin: unexpected end of file
 [exec] tar: Child returned status 2
 [exec] tar: Error exit delayed from previous errors
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary:
[INFO]
[INFO] Apache Hadoop Main ................................ SUCCESS [  1.018 s]
[INFO] Apache Hadoop Project POM ......................... SUCCESS [  1.653 s]
[INFO] Apache Hadoop Annotations ......................... SUCCESS [  2.181 s]
[INFO] Apache Hadoop Assemblies .......................... SUCCESS [  0.200 s]
[INFO] Apache Hadoop Project Dist POM .................... SUCCESS [  2.889 s]
[INFO] Apache Hadoop Auth ................................ SUCCESS [  1.957 s]
[INFO] Apache Hadoop Auth Examples ....................... SUCCESS [  1.570 s]
[INFO] Apache Hadoop Common .............................. SUCCESS [ 50.085 s]
[INFO] Apache Hadoop Common Project ...................... SUCCESS [  0.090 s]
[INFO] Apache Hadoop HDFS ................................ SUCCESS [ 35.510 s]
[INFO] Apache Hadoop HttpFS .............................. FAILURE [  5.155 s]
[INFO] Apache Hadoop HDFS Project ........................ SKIPPED
[INFO] hadoop-yarn ....................................... SKIPPED
[INFO] hadoop-yarn-api ................................... SKIPPED
[INFO] hadoop-yarn-common ................................ SKIPPED
[INFO] hadoop-yarn-server ................................ SKIPPED
[INFO] hadoop-yarn-server-common ......................... SKIPPED
[INFO] hadoop-yarn-server-nodemanager .................... SKIPPED
[INFO] hadoop-yarn-server-web-proxy ...................... SKIPPED
[INFO] hadoop-yarn-server-resourcemanager ................ SKIPPED
[INFO] hadoop-yarn-server-tests .......................... SKIPPED
[INFO] hadoop-yarn-client ................................ SKIPPED
[INFO] hadoop-mapreduce-client ........................... SKIPPED
[INFO] hadoop-mapreduce-client-core ...................... SKIPPED
[INFO] hadoop-yarn-applications .......................... SKIPPED
[INFO] hadoop-yarn-applications-distributedshell ......... SKIPPED
[INFO] hadoop-yarn-site .................................. SKIPPED
[INFO] hadoop-yarn-project ............................... SKIPPED
[INFO] hadoop-mapreduce-client-common .................... SKIPPED
[INFO] hadoop-mapreduce-client-shuffle ................... SKIPPED
[INFO] hadoop-mapreduce-client-app ....................... SKIPPED
[INFO] hadoop-mapreduce-client-hs ........................ SKIPPED
[INFO] hadoop-mapreduce-client-jobclient ................. SKIPPED
[INFO] hadoop-mapreduce-client-hs-plugins ................ SKIPPED
[INFO] Apache Hadoop MapReduce Examples .................. SKIPPED
[INFO] hadoop-mapreduce .................................. SKIPPED
[INFO] Apache Hadoop MapReduce Streaming ................. SKIPPED
[INFO] Apache Hadoop Distributed Copy .................... SKIPPED
[INFO] Apache Hadoop Archives ............................ SKIPPED
[INFO] Apache Hadoop Rumen ............................... SKIPPED
[INFO] Apache Hadoop Gridmix ............................. SKIPPED
[INFO] Apache Hadoop Data Join ........................... SKIPPED
[INFO] Apache Hadoop Extras .............................. SKIPPED    
[INFO] Apache Hadoop Pipes ............................... SKIPPED
[INFO] Apache Hadoop Tools Dist .......................... SKIPPED
[INFO] Apache Hadoop Tools ............................... SKIPPED
[INFO] Apache Hadoop Distribution ........................ SKIPPED
[INFO] Apache Hadoop Client .............................. SKIPPED
[INFO] Apache Hadoop Mini-Cluster ........................ SKIPPED
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 01:43 min
[INFO] Finished at: 2014-05-19T11:24:25+00:00
[INFO] Final Memory: 49M/179M
[INFO] ------------------------------------------------------------------------
[WARNING] The requested profile "native-win" could not be activated because it does not 
exist.
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-antrun-plugin:1.6:run      dist) on project hadoop-hdfs-httpfs: An Ant BuildExcept ion has occured: exec returned: 2 -    > [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-hdfs-httpfs
c:\hadoop>
+4
source share
1 answer

Hadoop i.e. Hadoop-2.6, 2.7 2.8, Hadoop-src Windows Hadoop. GitHub, winutils Hadoop.

Hadoop-src maven, .

Download Java c:/java/

(, , java , hasoop-env.cmd java-)

Hadoop.

( Hadoop-2.8.1)

:

JAVA_HOME = "c:/Java"
HADOOP_HOME="<your hadoop home>"
Path= "JAVA_HOME/bin"
Path = "HADOOP_HOME/bin" 

Hadoop , Hadoop-src maven in . Hadoop-src () Hadoop, Windows .

, winutils of Hadoop distribution. GitHub, winutils Hadoop.

( , , , Hadoop - )

, :/bin/

.xml - JAVA_HOME hadoop-env.cmd

cmd :

<HADOOP_HOME>/bin/> hdfs namenode -format
<HADOOP_HOME>/sbin> start-all.cmd

, .

0

Source: https://habr.com/ru/post/1541100/


All Articles