[ https://issues.apache.org/jira/browse/HDFS-1936?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13040364#comment-13040364 ]
Todd Lipcon commented on HDFS-1936: ----------------------------------- Wow, this is so much improved! - I'm curious why you've changed the test to no longer verify the contents of the filesystem after upgrade for the 0.22 case? The way I generated the 0.22 tarball attached above was to do an upgrade from the 0.14 one, so all of the checksums should be in tact. This will also help ensure that the DN upgrade process works with federation. - In this code, do we need the if statement? Seems like it would be an error to call this before the feature map is initialized. {code} + private static void specialInit(int lv, Feature f) { + EnumSet<Feature> set = map.get(lv); + if (set != null) { + set.add(f); + } + } {code} - Looks like some spurious changes to DataNode.java? - Indentation slightly off in loadLocalNameINodes - This diff looks not quite right - you're checking if FSConstants.LAYOUT_VERSION supports federation, but that's always true in trunk. So, this code will always run. I think you want to check {{!LayoutVersion.supports(Feature.FEDERATION, storage.getLayoutVersion())}} maybe? {code} - if (startOpt == StartupOption.UPGRADE - && storage.getLayoutVersion() > Storage.LAST_PRE_FEDERATION_LAYOUT_VERSION) { + if (startOpt == StartupOption.UPGRADE && + LayoutVersion.supports(Feature.FEDERATION, FSConstants.LAYOUT_VERSION)) { {code} > Updating the layout version from HDFS-1822 causes upgrade problems. > ------------------------------------------------------------------- > > Key: HDFS-1936 > URL: https://issues.apache.org/jira/browse/HDFS-1936 > Project: Hadoop HDFS > Issue Type: Bug > Components: name-node > Affects Versions: 0.22.0, 0.23.0 > Reporter: Suresh Srinivas > Assignee: Suresh Srinivas > Priority: Blocker > Fix For: 0.22.0, 0.23.0 > > Attachments: HDFS-1936.3.patch, HDFS-1936.trunk.patch, > hadoop-22-dfs-dir.tgz, hdfs-1936-with-testcase.txt > > > In HDFS-1822 and HDFS-1842, the layout versions for 203, 204, 22 and trunk > were changed. Some of the namenode logic that depends on layout version is > broken because of this. Read the comment for more description. -- This message is automatically generated by JIRA. For more information on JIRA, see: http://www.atlassian.com/software/jira