Hadoop 2 - Pseudo Node Installation
Hadoop 2 - Pseudo Node Installation
Getting Started
Note:In this document we have used only compatible versions of Hadoop ecosystem tools or
software downloaded from the official Apache hadoop website. Preferably use a stable
release of the particular tool.
Prerequisites:
1) Installing Java:
Hadoop is a framework written in Java for running applications on large clusters of commodity
hardware. Hadoop needs Java 6 or above to work.
Step 1: Download Jdk tar.gz file for linux-62 bit, extract it into “/usr/local”
boss@solaiv[]# cd /opt
boss@solaiv[]# cd /opt/jdk1.8.0_05
Step 2:
Open the “/etc/profile” file and Add the following line as per the version
set a environment for Java
Use the root user to save the /etc/proflie or use gedit instead of vi .
The 'profile' file contains commands that ought to be run for login shells
source /etc/profile
By default OS will have a open jdk. Check by “java -version”. You will be prompt
“openJDK”
If you also have openjdk installed then you'll need to update the java alternatives:
If your system has more than one version of Java, configure which one your system causes
by entering the following command in a terminal window
By default OS will have a open jdk. Check by “java -version”. You will be prompt “Java
HotSpot(TM) 64-Bit Server”
2) configure ssh
Hadoop requires SSH access to manage its nodes, i.e. remote machines
plus your local machine if you want to use Hadoop on it (which is what we
want to do in this short tutorial). For our single-node setup of Hadoop, we
therefore need to configure SSH access to localhost
The need to create a Password-less SSH Key generation based authentication is so
that the master node can then login to slave nodes (and the secondary
node) to start/stop them easily without any delays for authentication
If you skip this step, then have to provide password
Generate an SSH key for the user. Then Enable password-less SSH access to yo
sudo apt-get install openssh-server
--You will be asked to enter password,
root@solaiv[]# ssh localhost
root@solaiv[]# ssh-keygen
root@solaiv[]# ssh-copy-id -i localhost
3) Hadoop installation
Step 1: Download the tar.gz file of latest version Hadoop ( hadoop-2.7.x) from
the official site .
Step 2: Extract(untar) the downloaded file from this commands to /opt/bigdata
root@solaiv[]# cd /opt
root@solaiv[/opt]# sudo tar xvpzf /home/itadmin/Downloads/hadoop-2.7.0.tar.gz
root@solaiv[/opt]# cd hadoop-2.7.0/
source /etc/profile
boss@solaiv[]# cd $HADOOP_PREFIX
boss@solaiv[]# cd $HADOOP_PREFIX/etc/hadoop
boss@solaiv[]# vi hadoop-env.sh
export HADOOP_PREFIX=/opt/hadoop-2.7.0
boss@solaiv[]# vi core-site.xml
<configuration>
<property>
<name>fs.defaultFS</name>
<value>hdfs://localhost:9000</value>
</property>
</configuration>
boss@solaiv[]# vi hdfs-site.xml
<configuration>
<property>
<name>dfs.replication</name>
<value>1</value>
</property>
</configuration>
boss@solaiv[]# vi mapred-site.xml
<configuration>
<property>
<name>mapreduce.framework.name</name>
<value>yarn</value>
</property>
</configuration>
Modiy yarn-site.xml
boss@solaiv[]# vi yarn-site.xml
<configuration>
<property> <name>yarn.nodemanager.aux-
services</name>
<value>mapreduce_shuffle</value>
</property>
</configuration>
root@solaiv[]# sbin/start-yarn.sh
root@solaiv[]# sbin/stop-yarn.sh