[
https://issues.apache.org/jira/browse/HDFS-1969?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13036668#comment-13036668
]
Todd Lipcon commented on HDFS-1969:
-----------------------------------
This issue seems to extend back a ways -- I just tried the same steps going
from 0.18.3 to 0.20.2 and saw essentially the same behavior.
I think what needs to happen is that, when you ask the NN to do a rollback, it
will only succeed if that NN's LAYOUT_VERSION constant matches the version of
the previous/ directory. Otherwise we should exit with an error message
indicating that you should run "rollback" using the old version of the software
instead of the new version.
> Running rollback on new-version namenode destroys namespace
> -----------------------------------------------------------
>
> Key: HDFS-1969
> URL: https://issues.apache.org/jira/browse/HDFS-1969
> Project: Hadoop HDFS
> Issue Type: Bug
> Components: name-node
> Affects Versions: 0.22.0
> Reporter: Todd Lipcon
> Priority: Blocker
> Fix For: 0.22.0
>
>
> The following sequence leaves the namespace in an inconsistent/broken state:
> - format NN using 0.20 (or any prior release, probably)
> - run hdfs namenode -upgrade on 0.22. ^C the NN once it comes up.
> - run hdfs namenode -rollback on 0.22 (this should fail but doesn't!)
> This leaves the name directory in a state such that the version file claims
> it's an 0.20 namespace, but the fsimage is in 0.22 format. It then crashes
> when trying to start up.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira