#upgrading hadoop from 0.2 to 2 #upgrade require re-kickstarts (3.2.21) #roll osg-6.1.1-2 (3.2.21) #upgrade roll (including creation of group zookeeper if needed) /opt/rocks/bin/rocks add attr OSG_zookeeperuid value=406 /opt/rocks/bin/rocks add attr OSG_zookeepergid value=406 groupadd -g 406 zookeeper rocks remove roll osg rocks add roll osg-6.1.1-2.x86_64.disk1.iso #include path if needed rocks enable roll osg cd /export/rocks/install rocks create distro #reinstall rocks-osg-command (make sure comes from latest roll version ) yum clean all yum install rocks-osg-command #if mounted hadoop dismount first rocks run host compute compute='umount /mnt/hadoop' #stop hadoop in all nodes (in particular namenode) rocks run host compute compute='service hadoop stop' #edit extend-compute.xml to turn off old hadoop services #rocks create distro if needed # backup '$HADOOP_SCRATCH/dfs/name' on namenode #re-kicksstart nodes #recover '$HADOOP_SCRATCH/dfs/name' on namenode #on namenode service hadoop-hdfs-namenode upgrade #only first time later start #on datanode service hadoop-hdfs-datanode start #on secondary #http://www.cloudera.com/content/cloudera/en/documentation/cdh4/v4-3-0/CDH4-Release-Notes/cdh4ki_topic_2_2.html mv /home/hadoop/current /home/hadoop/current_0.20bak mv $HADOOP_SCRATCH/current $HADOOP_SCRATCH/current_0.2bak service hadoop-hdfs-secondarynamenode start #not required, just in case to finalize upgrade (since $HADOOP_SCRATCH/dfs/name/previous does not exist) #hdfs dfsadmin -finalizeUpgrade #note:mar 24,2015 #after -finalizeUpgrade in production, I found that restarting nodes (hdfs-hadoop-datannode) give me back about 100Gb/node #data nodes had $HADOOP_SCRATCH/previuos dirs that were processed then removed. # for upgrades is a big deal this last command AND restart nodes.