diff --git a/hbase-mapreduce/src/main/java/org/apache/hadoop/hbase/snapshot/ExportSnapshot.java b/hbase-mapreduce/src/main/java/org/apache/hadoop/hbase/snapshot/ExportSnapshot.java index 36b75c43dfd..198ae97f9b5 100644 --- a/hbase-mapreduce/src/main/java/org/apache/hadoop/hbase/snapshot/ExportSnapshot.java +++ b/hbase-mapreduce/src/main/java/org/apache/hadoop/hbase/snapshot/ExportSnapshot.java @@ -978,8 +978,8 @@ public class ExportSnapshot extends AbstractHBaseTool implements Tool { Path outputSnapshotDir = SnapshotDescriptionUtils.getCompletedSnapshotDir(targetName, outputRoot); Path initialOutputSnapshotDir = skipTmp ? outputSnapshotDir : snapshotTmpDir; LOG.debug("inputFs={}, inputRoot={}", inputFs.getUri().toString(), inputRoot); - LOG.debug("outputFs={}, outputRoot={}, outputFs.getUri().toString(), " + - "initialOutputSnapshotDir={}", outputRoot.toString(), skipTmp, initialOutputSnapshotDir); + LOG.debug("outputFs={}, outputRoot={}, skipTmp={}, initialOutputSnapshotDir={}", + outputFs, outputRoot.toString(), skipTmp, initialOutputSnapshotDir); // Find the necessary directory which need to change owner and group Path needSetOwnerDir = SnapshotDescriptionUtils.getSnapshotRootDir(outputRoot); diff --git a/hbase-mapreduce/src/test/java/org/apache/hadoop/hbase/snapshot/TestExportSnapshot.java b/hbase-mapreduce/src/test/java/org/apache/hadoop/hbase/snapshot/TestExportSnapshot.java index cfdca30f499..973e1821339 100644 --- a/hbase-mapreduce/src/test/java/org/apache/hadoop/hbase/snapshot/TestExportSnapshot.java +++ b/hbase-mapreduce/src/test/java/org/apache/hadoop/hbase/snapshot/TestExportSnapshot.java @@ -87,13 +87,15 @@ public class TestExportSnapshot { public static void setUpBaseConf(Configuration conf) { conf.setBoolean(SnapshotManager.HBASE_SNAPSHOT_ENABLED, true); conf.setInt("hbase.regionserver.msginterval", 100); + // If a single node has enough failures (default 3), resource manager will blacklist it. + // With only 2 nodes and tests injecting faults, we don't want that. + conf.setInt("mapreduce.job.maxtaskfailures.per.tracker", 100); + /* conf.setInt("hbase.client.pause", 250); conf.setInt(HConstants.HBASE_CLIENT_RETRIES_NUMBER, 6); conf.setBoolean("hbase.master.enabletable.roundrobin", true); conf.setInt("mapreduce.map.maxattempts", 10); - // If a single node has enough failures (default 3), resource manager will blacklist it. - // With only 2 nodes and tests injecting faults, we don't want that. - conf.setInt("mapreduce.job.maxtaskfailures.per.tracker", 100); + */ } @BeforeClass @@ -213,6 +215,7 @@ public class TestExportSnapshot { final RegionPredicate bypassregionPredicate, boolean success) throws Exception { URI hdfsUri = FileSystem.get(conf).getUri(); FileSystem fs = FileSystem.get(copyDir.toUri(), conf); + LOG.info("DEBUG FS {} {} {}, hdfsUri={}", fs, copyDir, copyDir.toUri(), hdfsUri); copyDir = copyDir.makeQualified(fs.getUri(), fs.getWorkingDirectory()); List opts = new ArrayList<>(); opts.add("--snapshot"); diff --git a/hbase-mapreduce/src/test/java/org/apache/hadoop/hbase/snapshot/TestExportSnapshotV1NoCluster.java b/hbase-mapreduce/src/test/java/org/apache/hadoop/hbase/snapshot/TestExportSnapshotV1NoCluster.java index 10d0167f04f..12a51abfbb9 100644 --- a/hbase-mapreduce/src/test/java/org/apache/hadoop/hbase/snapshot/TestExportSnapshotV1NoCluster.java +++ b/hbase-mapreduce/src/test/java/org/apache/hadoop/hbase/snapshot/TestExportSnapshotV1NoCluster.java @@ -112,7 +112,7 @@ public class TestExportSnapshotV1NoCluster { static Path getDestinationDir(HBaseCommonTestingUtility hctu, Path testDir) throws IOException { FileSystem fs = FileSystem.get(hctu.getConfiguration()); Path path = new Path(new Path(testDir, "export-test"), - "export-" + System.currentTimeMillis()).makeQualified(fs.getUri(), testDir); + "export-" + System.currentTimeMillis()).makeQualified(fs.getUri(), fs.getWorkingDirectory()); LOG.info("HDFS export destination path: " + path); return path; }