List all indexes on ElasticSearch server?

前端 未结 23 1124
被撕碎了的回忆
被撕碎了的回忆 2020-12-12 09:55

I would like to list all indexes present on an ElasticSearch server. I tried this:

curl -XGET localhost:9200/

but it just gives me this:

23条回答
  •  暖寄归人
    2020-12-12 10:02

    For Elasticsearch 6.X, I found the following the most helpful. Each provide different data in the response.

    # more verbose
    curl -sS 'localhost:9200/_stats' | jq -C ".indices" | less
    
    # less verbose, summary
    curl -sS 'localhost:9200/_cluster/health?level=indices' | jq -C ".indices" | less
    

提交回复
热议问题