Help us improve your experience.

Let us know what you think.

Do you have time for a two-minute survey?

 
 

OpenSearch Debugging Commands

This topic lists commonly used commands to debug and view OpenSearch status.

Health Check

Use the paragon-utils curl http://opensearch-cluster-master.common:9200/_cat/health?v command to view the overall status of OpenSearch.

The database is considered healthy if the status is green. A green status indicates that all shards are assigned to nodes. A yellow status indicates that primary shards are assigned to nodes, but some replicas are not. A red status indicates that at the least one primary shard is not assigned to a node.

List Indices

Use the paragon-utils curl -s http://opensearch-cluster-master.common:9200/_cat/indices?v command to list all OpenSearch indices and their sizes.

Check Shards Status

Use the paragon-utils curl http://opensearch-cluster-master:9200/_cat/shards?v command to check OpenSearch primary and replica shards status, nodes to which they are assigned and their IP addresses.

Consequently, if a shard status is not STARTED, use the explain API command to debug the reason.

Increase OpenSearch Memory

The value for Dynamic Memory Configuration for OpenSearch JVM options such as heap size setting is stored in opensearch_java_opts in the config.yml file. Bu default, the value is set to opensearch_java_opts: "-Xmx4096M -Xms4096M". To increase OpenSearch memory:

  1. Log in to a cluster node.

  2. Type configure to enter configuration mode in Paragon Shell.

  3. Use the following command to increase memory and enter the required memory value.

  4. Commit the configuration and exit configuration mode.

  5. Regenerate the configuration files.

  6. Redeploy OpenSearch.