Refer this for more info
http://hadoop.apache.org/docs/current/hadoop-project-dist/hadoop-common/SingleCluster.html

Install ubuntu in vmware player

install JDK/JRE using command line
https://www.digitalocean.com/community/tutorials/how-to-install-java-on-ubuntu-with-apt-get
For JDK
http://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html
For JRE
http://www.oracle.com/technetwork/java/javase/downloads/jre8-downloads-2133155.html

Bydefault
JDK is installed in /usr/lib/jvm
for check wheather JDK is installed or not write java -version
http://www.howtogeek.com/191427/how-to-find-out-if-java-is-installed-in-ubuntu-and-how-to-install-it/

Download hadoop from this link
http://www.eu.apache.org/dist/hadoop/common/

Create hadoop folder in home directory and extract hadoop.tar in this folder

write sudo gedit /etc/profile
add this line in last of this file

JAVA_HOME=/usr/local/java/jdk1.8.0-60
PATH=$PATH:$JAVA_HOME/bin
JRE_HOME=/usr/local/java/jre1.8.0-60
PATH=$PATH:$JRE_HOME/bin
HADOOP_INSTALL=/home/hadoop/hadoop-1.2.1
PATH=$PATH:$HADOOP_INSTALL/bin
export JAVA_HOME
export JRE_HOME
export PATH

sudo update-alternatives –install “/usr/local/java” “java” “/usr/local/java/default-java/bin/java” 1

bin/hadoop jar hadoop-examples-*.jar grep input output ‘dfs[a-z.]+’

For remove JDK
http://ajgupta.github.io/ubuntu/2014/09/18/Completely-uninstall-Java-from-Ubuntu-14.04/
sudo apt-get install ssh

open conf/core-site.xml
<configuration>
<property>
<name>fs.default.name</name>
<value>hdfs://localhost:9000</value>
</property>
</configuration>

hdfs-site.xml
<configuration>
<property>
<name>dfs.replication</name>
<value>1</value>
</property>
</configuration>

mapred-site.xml
<configuration>
<property>
<name>mapred.job.tracker</name>
<value>localhost:9001</value>
</property>
</configuration>

open hadoop-env.sh
change JAVA_HOME /usr/local/java/jdk1.8.0_60
make sure # must be removed

install ssh and rsync

setup password key and run two command from first link of thisa artical

goto hadoop folder and write
bin/hadoop namenode format

for start all node and process regarding hadoop
bin/start-all.sh

jps is used for show the running process
jps is a command

bin/hadoop fs -put conf input

for install cludera installtion
http://pyfunc.blogspot.in/2012/05/hadoop-pseudo-cluster-installation.html

for kill the process on port
sudo kill `sudo lsof -t -i:9000`

netstat -nlp
for show the process

Advertisements