Repository: hadoop
Updated Branches:
  refs/heads/branch-2 95b59c17a -> 623678215


HDFS-7166. SbNN Web UI shows #Under replicated blocks and #pending deletion 
blocks. Contributed by Wei-Chiu Chuang.


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

Branch: refs/heads/branch-2
Commit: 6236782151a8fdd507ba25a9303376015f824233
Parents: 95b59c1
Author: Haohui Mai <whe...@apache.org>
Authored: Sun Mar 20 17:21:25 2016 -0700
Committer: Haohui Mai <whe...@apache.org>
Committed: Sun Mar 20 17:21:53 2016 -0700

----------------------------------------------------------------------
 .../hadoop-hdfs/src/main/webapps/hdfs/dfshealth.html   | 13 +++++++++----
 1 file changed, 9 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/hadoop/blob/62367821/hadoop-hdfs-project/hadoop-hdfs/src/main/webapps/hdfs/dfshealth.html
----------------------------------------------------------------------
diff --git 
a/hadoop-hdfs-project/hadoop-hdfs/src/main/webapps/hdfs/dfshealth.html 
b/hadoop-hdfs-project/hadoop-hdfs/src/main/webapps/hdfs/dfshealth.html
index 7ad38d7..3d9ca42 100644
--- a/hadoop-hdfs-project/hadoop-hdfs/src/main/webapps/hdfs/dfshealth.html
+++ b/hadoop-hdfs-project/hadoop-hdfs/src/main/webapps/hdfs/dfshealth.html
@@ -106,7 +106,8 @@
 </div>
 {/if}
 
-{@if cond="{NumberOfMissingBlocks} > 0"}
+{@eq key=nnstat.State value="active"}
+  {@if cond="{NumberOfMissingBlocks} > 0"}
 <div class="alert alert-dismissable alert-warning">
   <button type="button" class="close" data-dismiss="alert" 
aria-hidden="true">&times;</button>
 
@@ -119,7 +120,8 @@
   </div>
   <p>Please check the logs or run fsck in order to identify the missing 
blocks.{@if cond="{NumberOfSnapshottableDirs} > 0"} Please run fsck with 
-includeSnapshots in order to see detailed reports about snapshots.{/if} See 
the Hadoop FAQ for common causes and potential solutions.</p>
 </div>
-{/if}
+  {/if}
+{/eq}
 {/nn}
 
 <div class="page-header"><h1>Overview {#nnstat}<small>'{HostAndPort}' 
({State})</small>{/nnstat}</h1></div>
@@ -173,10 +175,13 @@
   <tr><th><a href="#tab-datanode">Dead Nodes</a></th><td>{NumDeadDataNodes} 
(Decommissioned: {NumDecomDeadDataNodes})</td></tr>
   <tr><th><a href="#tab-datanode">Decommissioning 
Nodes</a></th><td>{NumDecommissioningDataNodes}</td></tr>
   <tr><th><a href="#tab-datanode-volume-failures">Total Datanode Volume 
Failures</a></th><td>{VolumeFailuresTotal} 
({EstimatedCapacityLostTotal|fmt_bytes})</td></tr>
-  <tr><th title="Excludes missing blocks.">Number of Under-Replicated 
Blocks</th><td>{UnderReplicatedBlocks}</td></tr>
-  <tr><th>Number of Blocks Pending 
Deletion</th><td>{PendingDeletionBlocks}</td></tr>
+  {@eq key=nnstat.State value="active"}
+    <tr><th title="Excludes missing blocks.">Number of Under-Replicated 
Blocks</th><td>{UnderReplicatedBlocks}</td></tr>
+    <tr><th>Number of Blocks Pending 
Deletion</th><td>{PendingDeletionBlocks}</td></tr>
+  {/eq}
   <tr><th>Block Deletion Start 
Time</th><td>{BlockDeletionStartTime|date_tostring}</td></tr>
 {/fs}
+
 </table>
 
 <div class="page-header"><h1>NameNode Journal Status</h1></div>

Reply via email to