Hadoop Learning Notes (iv)--eclipse+maven+hadoop2.5.2 source code

Source: Internet
Author: User

Use Maven to import Hadoop source in eclipse

1) Install and configure the MAVEN environment variables

m2_home:d:\profession\hadoop\apache-maven-3.3.3

PATH:%m2_home%\bin;

2) Verification: mvn–version

3) Download protobuf-2.5.0.tar.gz and Protoc-2.5.0-win32.zip

4) Copy the Protoc.exe in the Protoc-2.5.0-win32 to the C:\Windows\System32

5) Copy the Protoc.exe file to the extracted xxx\protobuf-2.5.0\src directory

6) Enter the Xxx\protobuf-2.5.0\java directory

Execute the "mvn package" command to edit the bundle to generate the Protobuf-java-2.5.0.jar file (located in the target directory).

(Note: It is possible to report a lot of error, you can delete files, re-unzip, re-execute "MVN package" command is OK)

Output information: [INFO] BUILD SUCCESS

7) Verification: protoc–version

8) Configure the path path of the Protoc.exe and restart the computer

9) Download maven package hadoop-2.5.2-src.tar.gz

) cmd into the Hadoop-maven-plugins directory,

Run MVN Install

Output information: [INFO] BUILD SUCCESS

) cmd into the hadoop-2.5.2-src directory,

Run MVN eclipse:eclipse–dskiptests

Output information: [INFO] BUILD SUCCESS

Eclipse, select Import Maven projects, click Browse ... Select the Hadoop source root directory and import individual projects

13) A large cone error, right-click, maven,disabledependency Management, enable dependency management, then only the remaining common packet error

project->buildautomacilly, remove Maven auto-compile synchronization

)                                   q:failed to execute goal Org.apache.hadoop:hadoop-maven-plugins:2.5.2:protoc (COMPILE-PROTOC) on Project hadoop- Common:org.apache.maven.plugin.MojoExecutionException: ' Protoc--version ' did notreturn a ver Sion

A: This should be divided into two cases, the first situation may be due to no installation or installation of unsuccessful PROTOBUF program caused, the second case, has successfully installed the PROTOBUF program, PROTOC-–version also successfully returned the version number, but still the newspaper Typically caused by a path path that is not configured with PROTOC.

16) Since the release of the Hadoop version of the 2.5.2 After the tragedy, the online can be used for reference to the information of the few, all on their own groping, so we later choose the version of the time or choose a mature version of the public more easily

Hadoop Learning Notes (iv)--eclipse+maven+hadoop2.5.2 source code

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.