SlideShare a Scribd company logo
Hadoop Cluster
安裝
Intern Report
主要參考網頁
 http://bigdatahandler.com/hadoop-
hdfs/installing-single-node-hadoop-2-2-0-
on-ubuntu/
Software Versions
 Ubuntu Linux 12.04.4 LTS
 Hadoop 2.2.0
 If you are using putty to access your Linux
box remotely, please install openssh by
running this command, this also helps in
configuring SSH access easily in the later
part of the installation:
sudo apt-get install openssh-server
Prerequisites:
 Installing Java v1.7
 Adding dedicated Hadoop system user.
 Configuring SSH access.
1. Installing Java v1.7:
sudo add-apt-repository ppa:webupd8team/java
sudo apt-get update
sudo apt-get install oracle-java7-installer
export JAVA_HOME=/usr/lib/jvm/java-7-oracle
Hadoop cluster 安裝
2. Adding dedicated Hadoop
system user.
 a. Adding group:
sudo addgroup hadoop
 b. Creating a user and adding the user to
a group:
sudo adduser –ingroup hadoop hduser
Hadoop cluster 安裝
3. Configuring SSH access:
 su – hduser
 ssh-keyegen -t rsa -P "“
 cat $HOME/.ssh/id_rsa.pub >>
$HOME/.ssh/authorized_keys
 ssh hduser@localhost
Hadoop cluster 安裝
Hadoop Installation
 i. Run this following command to download
Hadoop version 2.2.0
wget http://mirrors.cnnic.cn/apache/hadoop/common/hadoop-
2.2.0/hadoop-2.2.0.tar.gz
 ii. Unpack the compressed hadoop file by using
this command:
tar -xvzf hadoop-2.2.0.tar.gz
 iii. move hadoop-2.2.0 to hadoop directory by
using give command
mv hadoop-2.2.0 hadoop
 iv. Move hadoop package of your choice
sudo mv hadoop /usr/local/
 v. Make sure to change the owner of all the files
to the hduser user and hadoop group by using
this command:
cd /usr/local/
sudo chown -R hduser:hadoop hadoop
Configuring Hadoop
 The following are the required files we will use
for the perfect configuration of the single
node Hadoop cluster.
a. yarn-site.xml:
b. core-site.xml
c. mapred-site.xml
d. hdfs-site.xml
e. Update $HOME/.bashrc
 We can find the list of files in Hadoop
directory which is located in
cd /usr/local/hadoop/etc/hadoop
a.yarn-site.xml:
<configuration>
<!-- Site specific YARN configuration properties --> <property>
<name>yarn.nodemanager.aux-services</name>
<value>mapreduce_shuffle</value>
</property>
<property>
<name>yarn.nodemanager.aux-
services.mapreduce.shuffle.class</name>
<value>org.apache.hadoop.mapred.ShuffleHandler
</value>
</property>
</configuration>
b. core-site.xml:
<configuration>
<property>
<name>fs.default.name</name>
<value>hdfs://localhost:9000</value>
</property>
</configuration>
c. mapred-site.xml:
<configuration>
property>
<name>mapreduce.framework.name
</name>
<value>yarn</value>
</property>
</configuration>
sudo mkdir -p
$HADOOP_HOME/yarn_data/hdfs/namenode
sudo mkdir -p
$HADOOP_HOME/yarn_data/hdfs/datanode
d. hdfs-site.xml:
<configuration>
<property>
<name>dfs.replication</name>
<value>1</value>
</property>
<property>
<name>dfs.namenode.name.dir</name>
<value>file:/usr/local/hadoop/yarn_data/hdfs/namenode</value>
</property>
<property>
<name>dfs.datanode.data.dir</name>
<value>file:/usr/local/hadoop/yarn_data/hdfs/datanode</value>
</property>
</configuration>
e. Update $HOME/.bashrc
 i. Go back to the root and edit
the .bashrc file.
vi .bashrc
e. Update $HOME/.bashrc
#Set Hadoop-related environment variables
export HADOOP_PREFIX=/usr/local/hadoop
export HADOOP_HOME=/usr/local/hadoop
export HADOOP_MAPRED_HOME=${HADOOP_HOME}
export HADOOP_COMMON_HOME=${HADOOP_HOME}
export HADOOP_HDFS_HOME=${HADOOP_HOME}
export YARN_HOME=${HADOOP_HOME}
export HADOOP_CONF_DIR=${HADOOP_HOME}/etc/hadoop
#Native Path
export HADOOP_COMMON_LIB_NATIVE_DIR=${HADOOP_PREFIX}/lib/native
export HADOOP_OPTS="-Djava.library.path=$HADOOP_PREFIX/lib"
#Java path
export JAVA_HOME='/usr/lib/jvm/java-7-oracle'
#Add Hadoop bin/ directory to PATH
export
PATH=$PATH:$HADOOP_HOME/bin:$JAVA_PATH/bin:$HADOOP_HOME/sbi
n
Formatting and Starting/Stopping
the HDFS filesystem via the
NameNode
 i. The first step to starting up your Hadoop
installation is formatting the Hadoop
filesystem which is implemented on top of
the local filesystem of your cluster. You
need to do this the first time you set up a
Hadoop cluster. Do not format a running
Hadoop filesystem as you will lose all the
data currently in the cluster (in HDFS).
hadoop namenode -format
 ii. Start Hadoop Daemons by running the
following commands:
 Name node:
hadoop-daemon.sh start namenode
 Data node:
hadoop-daemon.sh start datanode
 Resource Manager:
yarn-daemon.sh start resourcemanager
 Node Manager:
yarn-daemon.sh start nodemanager
 Job History Server:
mr-jobhistory-daemon.sh start historyserver
 Stop Hadoop by running the following
command
stop-dfs.sh
stop-yarn.sh
 Start and stop hadoop daemons all at
once.
start-all.sh
stop-all.sh
Hadoop cluster 安裝
Hadoop cluster 安裝
Thanks for listening

More Related Content

What's hot (18)

KEY
Nginx - Tips and Tricks.
Harish S
 
PPTX
Drupal performance optimization Best Practices
Ratnesh kumar, CSM
 
PPTX
Drupal, varnish, esi - Toulouse November 2
Marcus Deglos
 
PDF
under the covers -- chef in 20 minutes or less
sarahnovotny
 
PPT
QNAP QTS 4.0 Overview
qnapchris
 
PDF
StackiFest16: Building a Cart
StackIQ
 
ODP
The secret life of a dispatcher (Adobe CQ AEM)
Venugopal Gummadala
 
PPT
Speeding Up The Snail
Marcus Deglos
 
PDF
PuppetConf 2016: An Introduction to Measuring and Tuning PE Performance – Cha...
Puppet
 
PDF
Nginx Essential
Gong Haibing
 
PPTX
Configuration Management in the Cloud - Cloud Phoenix Meetup Feb 2014
Miguel Zuniga
 
PDF
Setting up a local WordPress Environment
Chris La Nauze
 
ODP
Introduction to Nginx
Knoldus Inc.
 
PDF
Metal as a Server
Fadwa Gmiden
 
PDF
Nginx dhruba mandal
Dhrubaji Mandal ♛
 
PDF
HTTP cache @ PUG Rome 03-29-2011
Alessandro Nadalin
 
PPTX
How to reduce database load using Memcache
valuebound
 
PPTX
Apache Performance Tuning: Scaling Up
Sander Temme
 
Nginx - Tips and Tricks.
Harish S
 
Drupal performance optimization Best Practices
Ratnesh kumar, CSM
 
Drupal, varnish, esi - Toulouse November 2
Marcus Deglos
 
under the covers -- chef in 20 minutes or less
sarahnovotny
 
QNAP QTS 4.0 Overview
qnapchris
 
StackiFest16: Building a Cart
StackIQ
 
The secret life of a dispatcher (Adobe CQ AEM)
Venugopal Gummadala
 
Speeding Up The Snail
Marcus Deglos
 
PuppetConf 2016: An Introduction to Measuring and Tuning PE Performance – Cha...
Puppet
 
Nginx Essential
Gong Haibing
 
Configuration Management in the Cloud - Cloud Phoenix Meetup Feb 2014
Miguel Zuniga
 
Setting up a local WordPress Environment
Chris La Nauze
 
Introduction to Nginx
Knoldus Inc.
 
Metal as a Server
Fadwa Gmiden
 
Nginx dhruba mandal
Dhrubaji Mandal ♛
 
HTTP cache @ PUG Rome 03-29-2011
Alessandro Nadalin
 
How to reduce database load using Memcache
valuebound
 
Apache Performance Tuning: Scaling Up
Sander Temme
 

Similar to Hadoop cluster 安裝 (20)

PDF
Hadoop installation and Running KMeans Clustering with MapReduce Program on H...
Titus Damaiyanti
 
DOCX
Hadoop installation
habeebulla g
 
PDF
Hadoop 2.0 cluster setup on ubuntu 14.04 (64 bit)
Nag Arvind Gudiseva
 
PPTX
Hadoop single cluster installation
Minh Tran
 
PDF
Hadoop single node installation on ubuntu 14
jijukjoseph
 
PDF
02 Hadoop deployment and configuration
Subhas Kumar Ghosh
 
PPTX
Hadoop installation on windows
habeebulla g
 
PDF
Deploy hadoop cluster
Chirag Ahuja
 
PPTX
Implementing Hadoop on a single cluster
Salil Navgire
 
PPTX
Hadoop installation
Ankit Desai
 
PPTX
Hadoop 2.4 installing on ubuntu 14.04
baabtra.com - No. 1 supplier of quality freshers
 
DOCX
Single node setup
KBCHOW123
 
DOCX
Run wordcount job (hadoop)
valeri kopaleishvili
 
PDF
Hadoop completereference
arunkumar sadhasivam
 
PDF
Hadoop installation steps
Mayank Sharma
 
PPTX
Exp-3.pptx
PraveenKumar581409
 
ODT
Hadoop on aws amazon
Sandish Kumar H N
 
ODT
Hadoop on aws amazon
Sandish Kumar H N
 
PPTX
Configuring Your First Hadoop Cluster On EC2
benjaminwootton
 
PPTX
Learn Hadoop Administration
Edureka!
 
Hadoop installation and Running KMeans Clustering with MapReduce Program on H...
Titus Damaiyanti
 
Hadoop installation
habeebulla g
 
Hadoop 2.0 cluster setup on ubuntu 14.04 (64 bit)
Nag Arvind Gudiseva
 
Hadoop single cluster installation
Minh Tran
 
Hadoop single node installation on ubuntu 14
jijukjoseph
 
02 Hadoop deployment and configuration
Subhas Kumar Ghosh
 
Hadoop installation on windows
habeebulla g
 
Deploy hadoop cluster
Chirag Ahuja
 
Implementing Hadoop on a single cluster
Salil Navgire
 
Hadoop installation
Ankit Desai
 
Hadoop 2.4 installing on ubuntu 14.04
baabtra.com - No. 1 supplier of quality freshers
 
Single node setup
KBCHOW123
 
Run wordcount job (hadoop)
valeri kopaleishvili
 
Hadoop completereference
arunkumar sadhasivam
 
Hadoop installation steps
Mayank Sharma
 
Exp-3.pptx
PraveenKumar581409
 
Hadoop on aws amazon
Sandish Kumar H N
 
Hadoop on aws amazon
Sandish Kumar H N
 
Configuring Your First Hadoop Cluster On EC2
benjaminwootton
 
Learn Hadoop Administration
Edureka!
 
Ad

Recently uploaded (20)

PDF
Brief History of Internet - Early Days of Internet
sutharharshit158
 
PDF
A Strategic Analysis of the MVNO Wave in Emerging Markets.pdf
IPLOOK Networks
 
PDF
RAT Builders - How to Catch Them All [DeepSec 2024]
malmoeb
 
PDF
NewMind AI Weekly Chronicles – July’25, Week III
NewMind AI
 
PPTX
Agile Chennai 18-19 July 2025 | Emerging patterns in Agentic AI by Bharani Su...
AgileNetwork
 
PDF
Research-Fundamentals-and-Topic-Development.pdf
ayesha butalia
 
PDF
Researching The Best Chat SDK Providers in 2025
Ray Fields
 
PDF
How Open Source Changed My Career by abdelrahman ismail
a0m0rajab1
 
PPTX
Introduction to Flutter by Ayush Desai.pptx
ayushdesai204
 
PPTX
Simple and concise overview about Quantum computing..pptx
mughal641
 
PPTX
AI in Daily Life: How Artificial Intelligence Helps Us Every Day
vanshrpatil7
 
PDF
GDG Cloud Munich - Intro - Luiz Carneiro - #BuildWithAI - July - Abdel.pdf
Luiz Carneiro
 
PPTX
Farrell_Programming Logic and Design slides_10e_ch02_PowerPoint.pptx
bashnahara11
 
PDF
Tea4chat - another LLM Project by Kerem Atam
a0m0rajab1
 
PDF
AI Unleashed - Shaping the Future -Starting Today - AIOUG Yatra 2025 - For Co...
Sandesh Rao
 
PDF
Build with AI and GDG Cloud Bydgoszcz- ADK .pdf
jaroslawgajewski1
 
PDF
Economic Impact of Data Centres to the Malaysian Economy
flintglobalapac
 
PDF
Generative AI vs Predictive AI-The Ultimate Comparison Guide
Lily Clark
 
PDF
Responsible AI and AI Ethics - By Sylvester Ebhonu
Sylvester Ebhonu
 
PDF
Per Axbom: The spectacular lies of maps
Nexer Digital
 
Brief History of Internet - Early Days of Internet
sutharharshit158
 
A Strategic Analysis of the MVNO Wave in Emerging Markets.pdf
IPLOOK Networks
 
RAT Builders - How to Catch Them All [DeepSec 2024]
malmoeb
 
NewMind AI Weekly Chronicles – July’25, Week III
NewMind AI
 
Agile Chennai 18-19 July 2025 | Emerging patterns in Agentic AI by Bharani Su...
AgileNetwork
 
Research-Fundamentals-and-Topic-Development.pdf
ayesha butalia
 
Researching The Best Chat SDK Providers in 2025
Ray Fields
 
How Open Source Changed My Career by abdelrahman ismail
a0m0rajab1
 
Introduction to Flutter by Ayush Desai.pptx
ayushdesai204
 
Simple and concise overview about Quantum computing..pptx
mughal641
 
AI in Daily Life: How Artificial Intelligence Helps Us Every Day
vanshrpatil7
 
GDG Cloud Munich - Intro - Luiz Carneiro - #BuildWithAI - July - Abdel.pdf
Luiz Carneiro
 
Farrell_Programming Logic and Design slides_10e_ch02_PowerPoint.pptx
bashnahara11
 
Tea4chat - another LLM Project by Kerem Atam
a0m0rajab1
 
AI Unleashed - Shaping the Future -Starting Today - AIOUG Yatra 2025 - For Co...
Sandesh Rao
 
Build with AI and GDG Cloud Bydgoszcz- ADK .pdf
jaroslawgajewski1
 
Economic Impact of Data Centres to the Malaysian Economy
flintglobalapac
 
Generative AI vs Predictive AI-The Ultimate Comparison Guide
Lily Clark
 
Responsible AI and AI Ethics - By Sylvester Ebhonu
Sylvester Ebhonu
 
Per Axbom: The spectacular lies of maps
Nexer Digital
 
Ad

Hadoop cluster 安裝