Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Hadoop: Format aborted in /mnt/hdfs/1/namenode

Tags:

hadoop

I've created a few ebs filesystems on ec2 to use with hadoop. I've set the JAVE_HOME in the hadoop environment. But when I go to format the first volume it aborts with the following message

[root@hadoop-node01 conf]# sudo -u hdfs hadoop namenode -format
13/02/06 15:33:22 INFO namenode.NameNode: STARTUP_MSG:
/************************************************************ 
STARTUP_MSG: Starting NameNode
STARTUP_MSG:   host = hadoop-node01.mydomain.com/10.xx.xx.201
STARTUP_MSG:   args = [-format]
STARTUP_MSG:   version = 0.20.2-cdh3u5
STARTUP_MSG:   build = file:///data/1/tmp/topdir/BUILD/hadoop-0.20.2-cdh3u5 -r 30233064aaf5f2492bc687d61d72956876102109; compiled by 'root' on Fri Oct  5 18:45:46 PDT 2012
************************************************************/
Re-format filesystem in /mnt/hdfs/1/namenode ? (Y or N) y
Format aborted in /mnt/hdfs/1/namenode
13/02/06 15:33:27 INFO namenode.NameNode: SHUTDOWN_MSG:
/************************************************************
SHUTDOWN_MSG: Shutting down NameNode at hadoop-node01.mydomain.com/10.xx.xx.201
************************************************************/

This is my namenode configuration:

<?xml version="1.0"?>
<?xml-stylesheet type="text/xsl" href="configuration.xsl"?>

<!-- Put site-specific property overrides in this file. -->

<configuration>
  <property>
          <name>dfs.name.dir</name>          <value>/mnt/hdfs/1/namenode,/mnt/hdfs/2/namenode,/mnt/hdfs/3/namenode,/mnt/hdfs/4/namenode</value>
  </property>
  <property>
     <name>dfs.data.dir</name>
     <value>/mnt/hdfs/1/datanode,/mnt/hdfs/2/datanode,/mnt/hdfs/3/datanode,/mnt/hdfs/4/datanode</value>
 </property>
</configuration>

Does anyone have any idea why this error is happening or how to get around the problem?

like image 974
bluethundr Avatar asked Feb 06 '13 20:02

bluethundr


1 Answers

Unfortunately in 1.x the format command's prompt is case-sensitive. Answer with a capital Y instead and it won't abort.

like image 72
Magham Ravi Avatar answered Nov 03 '22 01:11

Magham Ravi