- Download
hadoop-3.1.1.tar.gz
(https://www.apache.org/dyn/closer.cgi/hadoop/common/hadoop-3.1.1/hadoop-3.1.1.tar.gz) - Put it to the project root folder
- Build image:
docker build -t proteinby/hadoop-3 .
- Create docker network for cluster:
docker network create --driver=bridge hadoop
- Run
start.sh
- Get into hadoop-master:
docker exec -it hadoop-master bash
- Run
start-hadoop.sh
there - Run
run-wordcount.sh
to run Word Count job
- This cluster consists of one master node and two slaves
- You can add more slaves. You only need to updated
start.sh
andstop.sh
and add new slaves to theconfig/workers
file - This setup uses ssh to run slave daemons
- You might have to change resource configs. Current config uses 4 cores and 4 Gb RAM
If you want to see web UI you have to add hadoop-master
, hadoop-slaveN
IPs to your /etc/hosts
file. Then you can go to:
http://hadoop-master:9870
HDFS Web UIhttp://hadoop-master:8088
YARN Web UIhttp://hadoop-master:19888
MapReduce JobHistory Web UI