Skip to main content

Check Hadoop Eco Information from CLI

You can check Hadoop Eco information in a CLI environment as follows.

Using WebHDFS
curl http://$(hostname -f):50070/webhdfs/v1/user/?op=LISTSTATUS

Check HDFS usage​

You can check the usage of each HDFS data node.

Check HDFS usage
hdfs dfsadmin -report

Image
Check HDFS usage

CodeDescription
Present CapacityTotal available HDFS capacity
DFS RemainingRemaining HDFS capacity
DFS UsedUsed HDFS capacity
Live datanodes (N)N data nodes are running
- Detailed usage per data node can be viewed

Use WebHDFS REST API​

You can use the curl command to access HDFS via REST API. Refer to the WebHDFS documentation for complete details.

Use WebHDFS REST API
curl -s http://$(hostname -f):50070/webhdfs/v1/user/?op=LISTSTATUS

Image
Using WebHDFS REST API

YARN​

CommandDescription
yarn node -listView the list of NodeManagers
yarn node -list -showDetailsView detailed information of NodeManagers
yarn topCheck the status of jobs
yarn application -listView the list of applications
yarn application -list -appStates RUNNINGView the list of applications filtered by their status
yarn application -status < Application ID >Check the status of a specific application by < Application ID >
yarn application -kill < Application ID >Terminate the application with < Application ID >
yarn logs -applicationId < Application ID >View the logs of the application with < Application ID >
mapred queue -listView the list of job queues
yarn queue -status < Queue Name >View the status of a specific queue by < Queue Name >

Check NodeManager status​

You can check the status of NodeManagers.

Check NodeManager status
yarn node -list -showDetails

Image
Check NodeManager status

Check job status​

You can check the current state of the resource manager, including vCore and memory usage.

Check job status
yarn top

Image
Check job status

View application list​

You can view the list of currently running applications.

View application list
yarn application -list

Image
View application list

CodeDescription
Application-IdApplication ID
Application-NameApplication name
Application-TypeType of application
UserUser
QueueQueue name
StateCurrent state
Final-StateFinal execution state
ProgressCompletion progress
Tracking-URLApplication Master URL

View application logs​

You can view logs for currently running applications.

View application logs
yarn logs -applicationId <Application Id>

Image
View application logs

View all queue list​

You can view the list of all queues.

View all queue list
mapred queue -list

Image
View all queue list

CodeDescription
CapacityAllocated queue capacity
MaximumCapacityMaximum capacity
CurrentCapacityCurrent usage

Check queue status​

You can check the status of a specific queue.

Check queue status
yarn queue -status <Queue Name>
CodeDescription
CapacityAllocated queue capacity
CurrentCapacityCurrent usage
MaximumCapacityMaximum capacity

Image
Check queue status