elasticsearch/es-cat-indices

List Indices

List all indices with details

elasticsearch
indices
list

Command

curl -X GET 'http://localhost:9200/_cat/indices?v'

Explanation

Returns a table view of all indices along with their status, health, document count, and storage size. Ideal for quick cluster overviews.

Common Use Cases

  • Viewing all existing indices
  • Checking index health and shard count
  • Identifying large indices for cleanup

Best Practices

  • Use pattern filters (e.g., logs-*) for better readability
  • Combine with `_cat/shards` to inspect shard distribution

Common Mistakes to Avoid

  • Omitting the `?v` flag, which hides headers
  • Not filtering by pattern, leading to large, unreadable outputs

Troubleshooting

Problem: Missing indices

Solution: Verify index creation or alias configuration.

Problem: Yellow health status

Solution: Check replica shard allocation and node availability.

Examples

List only logs-* indices

curl -X GET 'http://localhost:9200/_cat/indices/logs-*?v'