Ashish Doneriya
Ashish Doneriya

Reputation: 1863

Rest Api for getting dfs used for individual nodes in hadoop

Is there any rest API or Hadoop metrics for getting dfs used for individual nodes. Currently, I'm getting dfs used for individual nodes by executing the below command manually

hdfs dfsadmin -report

Upvotes: 0

Views: 1154

Answers (1)

tk421
tk421

Reputation: 5957

It's not a REST API but you should be able to use the NameNode's JMX interface to pull this info.

http://NAMENODE:DFSPORT/jmx?qry=Hadoop:service=NameNode,name=NameNodeInfo

This contains the same information as:

hdfs dfsadmin -report

which is also published on:

http://NAMENODE:DFSPORT/dfshealth.html#tab-datanode

Upvotes: 1

Related Questions