[ 
https://issues.apache.org/jira/browse/HADOOP-4542?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12650788#action_12650788
 ] 

Konstantin Shvachko commented on HADOOP-4542:
---------------------------------------------

Here is the exception thrown by 0.18 for TestDistributedUpgrade:
{code}
2008-11-25 22:50:18,060 ERROR fs.FSNamesystem (FSNamesystem.java:<init>(275)) - 
FSNamesystem initialization failed.
org.apache.hadoop.dfs.InconsistentFSStateException: Directory 
/home/shv/branch-0.18/build/test/dfs/name is in an inconsistent state: storage 
directory does not exist or is not accessible.
        at org.apache.hadoop.dfs.FSImage.recoverTransitionRead(FSImage.java:211)
        at org.apache.hadoop.dfs.FSDirectory.loadFSImage(FSDirectory.java:80)
        at org.apache.hadoop.dfs.FSNamesystem.initialize(FSNamesystem.java:294)
        at org.apache.hadoop.dfs.FSNamesystem.<init>(FSNamesystem.java:273)
        at org.apache.hadoop.dfs.NameNode.initialize(NameNode.java:148)
        at org.apache.hadoop.dfs.NameNode.<init>(NameNode.java:193)
        at org.apache.hadoop.dfs.NameNode.<init>(NameNode.java:179)
        at org.apache.hadoop.dfs.NameNode.createNameNode(NameNode.java:830)
        at org.apache.hadoop.dfs.MiniDFSCluster.<init>(MiniDFSCluster.java:264)
        at org.apache.hadoop.dfs.MiniDFSCluster.<init>(MiniDFSCluster.java:93)
        at 
org.apache.hadoop.dfs.TestDistributedUpgrade.startNameNodeShouldFail(TestDistributedUpgrade.java:54)
        at 
org.apache.hadoop.dfs.TestDistributedUpgrade.testDistributedUpgrade(TestDistributedUpgrade.java:97)
{code}
And here is the correct exception that should be thrown in this case and is 
thrown in 0.20
{code}
2008-11-25 22:53:37,165 ERROR namenode.FSNamesystem 
(FSNamesystem.java:<init>(282)) - FSNamesystem initialization failed.
java.io.IOException: 
File system image contains an old layout version -7.
An upgrade to version -18 is required.
Please restart NameNode with -upgrade option.
        at 
org.apache.hadoop.hdfs.server.namenode.FSImage.recoverTransitionRead(FSImage.java:312)
        at 
org.apache.hadoop.hdfs.server.namenode.FSDirectory.loadFSImage(FSDirectory.java:87)
        at 
org.apache.hadoop.hdfs.server.namenode.FSNamesystem.initialize(FSNamesystem.java:299)
        at 
org.apache.hadoop.hdfs.server.namenode.FSNamesystem.<init>(FSNamesystem.java:280)
        at 
org.apache.hadoop.hdfs.server.namenode.NameNode.initialize(NameNode.java:169)
        at 
org.apache.hadoop.hdfs.server.namenode.NameNode.<init>(NameNode.java:247)
        at 
org.apache.hadoop.hdfs.server.namenode.NameNode.createNameNode(NameNode.java:907)
        at org.apache.hadoop.hdfs.MiniDFSCluster.<init>(MiniDFSCluster.java:275)
        at org.apache.hadoop.hdfs.MiniDFSCluster.<init>(MiniDFSCluster.java:168)
        at 
org.apache.hadoop.hdfs.server.common.TestDistributedUpgrade.startNameNodeShouldFail(TestDistributedUpgrade.java:63)
        at 
org.apache.hadoop.hdfs.server.common.TestDistributedUpgrade.testDistributedUpgrade(TestDistributedUpgrade.java:110)
{code}

The problem is that in 0.18 {{MiniDFSCluster}} is configured with the storage 
being in {{/build/test/dfs/name}}, while TestDFSUpgradeFromImage unpacks it 
into  {{/build/test/data/dfs/name1}}. And this was fixed by HADOOP-3965 or 
HADOOP-3948. This should be controled by {{manageDfsDirs}} parameter.

> Fault in TestDistributedUpgrade
> -------------------------------
>
>                 Key: HADOOP-4542
>                 URL: https://issues.apache.org/jira/browse/HADOOP-4542
>             Project: Hadoop Core
>          Issue Type: Bug
>          Components: dfs, test
>    Affects Versions: 0.18.0
>            Reporter: Robert Chansler
>            Assignee: Raghu Angadi
>            Priority: Minor
>             Fix For: 0.18.3
>
>         Attachments: HADOOP-4542.patch
>
>
> A TestDistributedUpgrade subtest checks that the Name Node _does not_ start 
> when a distributed upgrade is required. In 0.18, the subtest fails when the 
> Name Node _does_ start. The fault is with the test, not HDFS. Not a problem 
> in 0.19.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to