Where does elastic search store it's data

社会主义新天地 提交于 2019-12-04 16:09:25

问题


So I have this elastic search installation, in insert data with logstash, visualize them with kibana.

Everything in the conf file is commented, so it's using the default folders which are relative to the elastic search folder.

1/ I store data with logstash
2/ I look at them with kibana
3/ I close the instance of elastic seach, kibana and logstash
4/ I DELETE their folders
5/ I re-extract everything and reconfigure them
6/ I go into kibana and the data are still there

How is this possible?

This command will however delete the data : curl -XDELETE 'http://127.0.0.1:9200/_all'

Thanks.

ps : forgot to say that I'm on windows


回答1:


If you've installed ES on Linux, the default data folder is in /var/lib/elasticsearch (CentOS) or /var/lib/elasticsearch/data (Ubuntu)

If you're on Windows or if you've simply extracted ES from the ZIP/TGZ file, then you should have a data sub-folder in the extraction folder.




回答2:


According to the documentation the data is stored in a folder called "data" in the elastic search root directory.




回答3:


If you run the Windows MSI installer (at least for 5.5.x), the default location for data files is:

C:\ProgramData\Elastic\Elasticsearch\data

The config and logs directories are siblings of data.




回答4:


Elastic search is storing data under the folder 'Data' as mentioned above answers. Is there any other elastic search instance available on your local network? If yes, please check the cluster name. If you use same cluster name in the same network it will share data.

Refer this link for more info.




回答5:


Have a look into the Nodes Stats and try

http://127.0.0.1:9200/_nodes/stats/fs?pretty

On Windows 10 with ElasticSearch 7 it shows:

"path" : "C:\\ProgramData\\Elastic\\Elasticsearch\\data\\nodes\\0"



回答6:


On centos:

/var/lib/elasticsearch



回答7:


It should be in your extracted elasticsearch. Something like es/data



来源:https://stackoverflow.com/questions/33303786/where-does-elastic-search-store-its-data

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!