hadoop-common-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From z..@apache.org
Subject hadoop git commit: HDFS-11709. StandbyCheckpointer should handle an non-existing legacyOivImageDir gracefully. Contributed by Erik Krogen.
Date Thu, 27 Apr 2017 16:53:42 GMT
Repository: hadoop
Updated Branches:
  refs/heads/branch-2 b500714e9 -> fc46f398d


HDFS-11709. StandbyCheckpointer should handle an non-existing legacyOivImageDir gracefully.
Contributed by Erik Krogen.

(cherry picked from commit d8a33098309f17dfb0e3a000934f68394de44bf7)


Project: http://git-wip-us.apache.org/repos/asf/hadoop/repo
Commit: http://git-wip-us.apache.org/repos/asf/hadoop/commit/fc46f398
Tree: http://git-wip-us.apache.org/repos/asf/hadoop/tree/fc46f398
Diff: http://git-wip-us.apache.org/repos/asf/hadoop/diff/fc46f398

Branch: refs/heads/branch-2
Commit: fc46f398d9192e83c7197115589eca7805c49943
Parents: b500714
Author: Zhe Zhang <zhz@apache.org>
Authored: Thu Apr 27 09:50:30 2017 -0700
Committer: Zhe Zhang <zhz@apache.org>
Committed: Thu Apr 27 09:51:04 2017 -0700

----------------------------------------------------------------------
 .../hadoop/hdfs/server/namenode/ha/StandbyCheckpointer.java   | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/hadoop/blob/fc46f398/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/namenode/ha/StandbyCheckpointer.java
----------------------------------------------------------------------
diff --git a/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/namenode/ha/StandbyCheckpointer.java
b/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/namenode/ha/StandbyCheckpointer.java
index 31fa5a2..5c09043 100644
--- a/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/namenode/ha/StandbyCheckpointer.java
+++ b/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/namenode/ha/StandbyCheckpointer.java
@@ -190,7 +190,12 @@ public class StandbyCheckpointer {
       // Save the legacy OIV image, if the output dir is defined.
       String outputDir = checkpointConf.getLegacyOivImageDir();
       if (outputDir != null && !outputDir.isEmpty()) {
-        img.saveLegacyOIVImage(namesystem, outputDir, canceler);
+        try {
+          img.saveLegacyOIVImage(namesystem, outputDir, canceler);
+        } catch (IOException ioe) {
+          LOG.error("Exception encountered while saving legacy OIV image; "
+                  + "continuing with other checkpointing steps", ioe);
+        }
       }
     } finally {
       namesystem.cpUnlock();


---------------------------------------------------------------------
To unsubscribe, e-mail: common-commits-unsubscribe@hadoop.apache.org
For additional commands, e-mail: common-commits-help@hadoop.apache.org


Mime
View raw message