jun aoki created HDFS-6103: ------------------------------ Summary: FSImage file system image version check throw a (slightly) wrong parameter. Key: HDFS-6103 URL: https://issues.apache.org/jira/browse/HDFS-6103 Project: Hadoop HDFS Issue Type: Improvement Components: namenode Affects Versions: 2.2.0 Reporter: jun aoki Priority: Trivial
Trivial error message issue: When upgrading hdfs, say from 2.0.5 to 2.2.0, users will need to start namenode with "upgrade" option. e.g. {code} sudo service namenode upgrade {code} That said, the actual error while without the option said "-upgrade" (with a hyphen) {code} 2014-03-13 23:38:15,488 FATAL org.apache.hadoop.hdfs.server.namenode.NameNode: Exception in namenode join java.io.IOException: File system image contains an old layout version -40. An upgrade to version -47 is required. Please restart NameNode with -upgrade option. at org.apache.hadoop.hdfs.server.namenode.FSImage.recoverTransitionRead(FSImage.java:221) at org.apache.hadoop.hdfs.server.namenode.FSNamesystem.loadFSImage(FSNamesystem.java:787) at org.apache.hadoop.hdfs.server.namenode.FSNamesystem.loadFromDisk(FSNamesystem.java:568) at org.apache.hadoop.hdfs.server.namenode.NameNode.loadNamesystem(NameNode.java:443) at org.apache.hadoop.hdfs.server.namenode.NameNode.initialize(NameNode.java:491) at org.apache.hadoop.hdfs.server.namenode.NameNode.<init>(NameNode.java:684) at org.apache.hadoop.hdfs.server.namenode.NameNode.<init>(NameNode.java:669) at org.apache.hadoop.hdfs.server.namenode.NameNode.createNameNode(NameNode.java:1254) at org.apache.hadoop.hdfs.server.namenode.NameNode.main(NameNode.java:1320) 2014-03-13 23:38:15,492 INFO org.apache.hadoop.util.ExitUtil: Exiting with status 1 2014-03-13 23:38:15,493 INFO org.apache.hadoop.hdfs.server.namenode.NameNode: SHUTDOWN_MSG: /************************************************************ SHUTDOWN_MSG: Shutting down NameNode at nn1/192.168.2.202 ************************************************************/ ~ {code} I'm referring to 2.0.5 above, https://github.com/apache/hadoop-common/blob/branch-2.0.5/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/namenode/FSImage.java#L225 I haven't tried the trunk but it seems to return "UPGRADE" (all upper case) which again anther slightly wrong error description. https://github.com/apache/hadoop-common/blob/trunk/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/namenode/FSImage.java#L232 -- This message was sent by Atlassian JIRA (v6.2#6252)