Compiling Hadoop 2.7 on CentOS

Source: Internet
Author: User

Hadoop execution run-report warning for download on official website:

WARN util. nativecodeloader:unable to load Native-hadoop library for your platform ... using Builtin-java classes where applicable
Put: './in ': No such file or directory


The main is Lib under the Native-hadoop is 32 bits, so here we ourselves on the 64-bit system to compile Hadoop


Environment Preparation:

1 Download Hadoop src source Bundle

2 Required Software: Java, SVN, autoconf, Automake, Libtool, Ncurses-devel, Openssl-devel, GCC, lzo-devel, Zlib-devel, Znt, maven, Proto BUF, CMake

Yum-y Install autoconf automake libtool ncurses-devel openssl-devel gcc lzo-devel, zlib-devel cmake

3 Installing the JDK

Download the JDK bin package and unzip it

Add JDK Environment variables

Add under the/etc/profile file


# # JAVA

Export JAVA_HOME=/USR/LOCAL/JAVA/JDK

Export classpath=.: $JAVA _home/lib/dt.jar: $JAVA _home/lib/tools.jar

# # PATH

Export Path= $JAVA _home/bin


Let the overloaded environment variable. /etc/profile


4 maven Installation

Download maven and unzip the Apache website and add its bin path to the environment variable

Mvn-version


5 PROTOBUF Installation

Search online for protobuf-2.5.0.tar.gz, download unzip,

./configure; Make Make install

Protoc--version


6 Ant Installation

Apache Download ANT Bin package to extract the bin path to the environment variable


7 Compiling Hadoop

MVN Package-pdist,native,docs-dskiptests-dtar

It takes one hours or more, and requires a networked download of dependent packages


The final file is in Hadoop-2.7.2-src/hadoop-dist/target.

Can directly take the hadoop-2.7.2 directory to deploy, there is a hadoop-2.7.2.tar.gz package


Compiling Hadoop 2.7 on CentOS

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.