Repository: hadoop Updated Branches: refs/heads/branch-2 1436e89fb -> 1ef616ceb
HDFS-7333. Improve logging in Storage.tryLock(). Contributed by Konstantin Shvachko. Project: http://git-wip-us.apache.org/repos/asf/hadoop/repo Commit: http://git-wip-us.apache.org/repos/asf/hadoop/commit/1ef616ce Tree: http://git-wip-us.apache.org/repos/asf/hadoop/tree/1ef616ce Diff: http://git-wip-us.apache.org/repos/asf/hadoop/diff/1ef616ce Branch: refs/heads/branch-2 Commit: 1ef616ceb7b1aa998d46928d6cc1943610327a69 Parents: 1436e89 Author: Konstantin V Shvachko <s...@apache.org> Authored: Wed Nov 5 09:50:48 2014 -0800 Committer: Konstantin V Shvachko <s...@apache.org> Committed: Wed Nov 5 09:50:48 2014 -0800 ---------------------------------------------------------------------- hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt | 2 ++ .../java/org/apache/hadoop/hdfs/server/common/Storage.java | 7 ++++--- 2 files changed, 6 insertions(+), 3 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/hadoop/blob/1ef616ce/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt ---------------------------------------------------------------------- diff --git a/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt b/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt index fb42f46..f420e2e 100644 --- a/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt +++ b/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt @@ -84,6 +84,8 @@ Release 2.7.0 - UNRELEASED HDFS-7335. Redundant checkOperation() in FSN.analyzeFileState(). (Milan Desai via shv) + HDFS-7333. Improve logging in Storage.tryLock(). (shv) + OPTIMIZATIONS BUG FIXES http://git-wip-us.apache.org/repos/asf/hadoop/blob/1ef616ce/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/common/Storage.java ---------------------------------------------------------------------- diff --git a/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/common/Storage.java b/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/common/Storage.java index 14b52ce..7b8f150 100644 --- a/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/common/Storage.java +++ b/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/common/Storage.java @@ -716,12 +716,13 @@ public abstract class Storage extends StorageInfo { } catch(OverlappingFileLockException oe) { // Cannot read from the locked file on Windows. String lockingJvmName = Path.WINDOWS ? "" : (" " + file.readLine()); - LOG.error("It appears that another namenode" + lockingJvmName - + " has already locked the storage directory"); + LOG.error("It appears that another node " + lockingJvmName + + " has already locked the storage directory: " + root, oe); file.close(); return null; } catch(IOException e) { - LOG.error("Failed to acquire lock on " + lockF + ". If this storage directory is mounted via NFS, " + LOG.error("Failed to acquire lock on " + lockF + + ". If this storage directory is mounted via NFS, " + "ensure that the appropriate nfs lock services are running.", e); file.close(); throw e;