2.2. Installing and configuring Hadoop

To install hadoop in a node, first is needed to set rocks attr BIGTOP_HADOOP to true, then run the command shown below (or reinstall).

After installation run the rocks command to configure it. Below is an example for setting a datanode.

$ su - root
##
## Set flag to hadoop installation (once)
##
#  rocks set host attr compute-0-2 BIGTOP_HADOOP True
##
## Run rocks commands to install and configure hadoop
##
#  rocks sync host bigtop hadoop install compute-0-2
#  rocks sync host bigtop hadoop config compute-0-2
##
## Set services on boot
##
#  rocks run host compute-0-2 command='systemctl enable hadoop-hdfs-datanode'
##
## Start hadoop service
##
#  rocks run host compute-0-2 command='systemctl start hadoop-hdfs-datanode'

Example of installation by forcing node reinstall

$ su - root
##
## Set flags to hadoop installation (not needed if already set)
##
#  rocks set host attr compute-0-2 BIGTOP_HADOOP True
#  rocks set host attr compute-0-2 BIGTOP_Hadoop_StartDaemonDataNode True
##
## Reinstall 
##
#  rocks set host boot compute-0-2 action=install
#  ssh compute-0-2 "shutdown -r now"