When you want to monitor your Elasticsearch cluster or debug an issue, you have a number of choices. You can use the various _cat and stats APIs to pull information out of the cluster. You can monitor and profile the JVM itself. These options can be cumbersome, and they lack visual displays. While you could push _cat and stats data back into Elasticsearch and visualize with Kibana, sometimes you want a more lightweight method.
Open Distro for Elasticsearch ships with two components that combine to give you the lightweight tool you need to quickly retrieve and display core metrics. Performance Analyzer is an agent and REST API that allows you to query numerous performance metrics for your cluster, including aggregations of those metrics, independent of the Java Virtual Machine (JVM). Performance Analyzer runs on and collects metrics from the same nodes that you use to run Elasticsearch.
PerfTop is a lightweight, command-line tool patterned after Linux's top command. You use simple JSON to define dashboards; PerfTop displays these dashboards in your favorite terminal application.
PerfTop CLI can be downloaded from https://opendistro.github.io/for-elasticsearch/downloads.html
Login to one of the client nodes. As part of the CloudFormation, we have already installed PerfTop CLI on the client nodes under /home/ubuntu
Run the below commands
./perf-top-linux --dashboard ClusterOverview