Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to compile Hadoop

2025-01-20 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)05/31 Report--

This article introduces the relevant knowledge of "how to compile Hadoop". In the operation of actual cases, many people will encounter such a dilemma, so let the editor lead you to learn how to deal with these situations. I hope you can read it carefully and be able to achieve something!

Environment: ubuntu14.04 64-bit

The premise is that the system has installed jdk and the environment variables have been configured.

1. Download the hadoop source code wget http://mirror.esocc.com/apache/hadoop/common/hadoop-2.4.0/hadoop-2.4.0-src.tar.gz and decompress: tar-zxf hadoop-2.4.0-src.tar.gz

two。 Install maven: do not use apt-get to install, download the maven3.0.5 version directly to the official website and decompress it to / usr/lib/jvm/maven/, and edit ~ / .bashrc to configure the environment variables of maven:

Export M2_HOME=/usr/lib/jvm/maven

Export PATH=$M2_HOME/bin:$PATH

Source ~ / .bashrc to make the configuration effective

3. Install cmake,g++,pkgconfig:sudo apt-get install cmake gaming + pkg-config

4. Install protobuf:sudo apt-get install libprotobuf-dev protobuf-compiler

5. Install ant: sudo apt-get install ant

6. Install ssl: sudo apt-get install libssl-dev

Enter the extracted hadoop source directory and run: mvn package-Pdist,native-DskipTests-Dtar. After a long wait, the compilation is completed.

Note: since the jdk we installed before is 1.8, all kinds of errors will be reported when compiling. The current solution is to compile with 1.7 version first.

This is the end of "how to compile Hadoop". Thank you for reading. If you want to know more about the industry, you can follow the website, the editor will output more high-quality practical articles for you!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report