HDFS-4732. Merge r1471090 from trunk

git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/branches/branch-2@1486146 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Suresh Srinivas 2013-05-24 18:17:52 +00:00
parent 4a16d5b759
commit f1f11999d9
3 changed files with 10 additions and 1 deletions

View File

@ -381,6 +381,9 @@ Release 2.0.5-beta - UNRELEASED
HDFS-4674. TestBPOfferService fails on Windows due to failure parsing
datanode data directory as URI. (Chris Nauroth via suresh)
HDFS-4732. Fix TestDFSUpgradeFromImage which fails on Windows due to
failure to unpack old image tarball that contains hard links.
(Chris Nauroth via szetszwo)
Release 2.0.4-alpha - 2013-04-25

View File

@ -252,8 +252,9 @@ public class TestDFSUpgradeFromImage {
// Now try to start an NN from it
MiniDFSCluster cluster = null;
try {
new MiniDFSCluster.Builder(conf).numDataNodes(0)
cluster = new MiniDFSCluster.Builder(conf).numDataNodes(0)
.format(false)
.manageDataDfsDirs(false)
.manageNameDfsDirs(false)
@ -264,6 +265,11 @@ public class TestDFSUpgradeFromImage {
if (!ioe.toString().contains("Old layout version is 'too old'")) {
throw ioe;
}
} finally {
// We expect startup to fail, but just in case it didn't, shutdown now.
if (cluster != null) {
cluster.shutdown();
}
}
}