GenweiWu / Blog

个人技术能力提升
MIT License
4 stars 0 forks source link

elastic search入门 #53

Closed GenweiWu closed 5 years ago

GenweiWu commented 5 years ago

测试es是否启动,以及查看版本信息

[root@10 ~]# curl 'http://127.0.0.1:9200'
{
  "name" : "AsEk_tQ",
  "cluster_name" : "elasticsearch",
  "cluster_uuid" : "UzVszIDyQSyob_TZWXUORA",
  "version" : {
    "number" : "5.5.0",
    "build_hash" : "260387d",
    "build_date" : "2017-06-30T23:16:05.735Z",
    "build_snapshot" : false,
    "lucene_version" : "6.6.0"
  },
  "tagline" : "You Know, for Search"
}

可看出,版本为5.5

GenweiWu commented 5 years ago

参考资料

https://www.elastic.co/guide/en/elasticsearch/reference/current/indices.html

GenweiWu commented 5 years ago

es5.5常用命令

列出所有index

curl 'http://127.0.0.1::9200/_cat/indices?v'

删除索引

curl -XDELETE 'http://127.0.0.1:9200/logstash-2017.07.*'