hadoop(6)2.6.0 and Example

本文提供了一步一步指导如何在 Ubuntu 上安装和配置 Hadoop 2.6.0,包括 Protocol Buffer、JDK、MAVEN、Hadoop 源代码构建以及 SSH 配置等关键步骤。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

hadoop(6)2.6.0 and Example
 
1. Prepare
ProtocolBuffer Installation
> ./autogen.sh 
> ./configure --prefix=/home/carl/tool/protobuf-3.0.0
> make
> make check
> make install
 
Add that to path.
> protoc --version
libprotoc 3.0.0
 
Need to switch to 2.5.0 version
 
JDK Installation
> java -version
java version "1.6.0_45"
Java(TM) SE Runtime Environment (build 1.6.0_
 
MAVEN Installation
 
Unzip and place in the right directory, adding to path
> mvn --version
Apache Maven 3.2.5 (12a6b3acb947671f09b81f49094c53f426d8cea1; 2014-12-14T11:29:23-06:00)
Maven home: /opt/maven
 
Add this to stop the out of memory error
export MAVEN_OPTS= " -Xmx512m -XX:MaxPermSize=128m "
 
Hadoop Src Build
> mvn package -Pdist -DskipTests -Dtar
 
Find the release dist file  hadoop-2.6.0.tar.gz
 
I get “JAVA_HOME not set” Error message, I already have the JAVA_HOME in .profile, but I added it in 
/opt/hadoop/etc/hadoop/hadoop-env.sh as well.
export JAVA_HOME="/usr/lib/jvm/java-8-oracle"
 
Configure the SSH on master
> cat ~/.ssh/id_rsa.pub >> ~/.ssh/authorized_keys
 
Format file system
Format the filesystem
> hdfs namenode -format
 
All the configuration should take reference from 
 
It works. Change the etc/hadoop/slaves files to have a machine list there.
 
Command line to start the HDFS and YARN
> sbin/start-dfs.sh
> sbin/start-yarn.sh
 
 
Tips
Error Message:
autoreconf: not found
Solution:
> sudo apt-get install autoconf
 
Error Message:
Can't exec "libtoolize": No such file or directory at /usr/share/autoconf/Autom4te/FileUtils.pm line 345, <GEN7> line 6.
autoreconf: failed to run libtoolize: No such file or directory
autoreconf: libtoolize is needed because this package uses Libtool
Solution:
> sudo apt-get install libtool
 
Error Message:
checking how to run the C++ preprocessor... /lib/cpp
configure: error: in `/home/carl/install/protobuf':
configure: error: C++ preprocessor "/lib/cpp" fails sanity check
Solution:
> sudo apt-get install g++
 
Error Message:
protoc version is 'libprotoc 3.0.0', expected version is '2.5.0'
Solution:
Switch to 2.5.0
 
References:
http://sillycat.iteye.com/blog/1556106  Hadoop doc and Installation on ubuntu with an old version
http://sillycat.iteye.com/blog/1556107 cluster of the old version
http://sillycat.iteye.com/blog/2084169  yet another resource negotiator 2.4.0
 
 
 
 
 
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值