弹性搜索中如何物理存储数据? [英] How data is stored physically in elastic search?
问题描述
如果我导航到弹性搜索的数据目录:
If I navigate to Data directory of elastic search :
/ nodes / 0 / indices / gb
/nodes/0/indices/gb
树命令显示如下:
├── 0
│ ├── index
│ │ ├── segments_6
│ │ └── write.lock
│ ├── _state
│ │ └── state-6.st
│ └── translog
│ ├── translog-1.ckp
│ ├── translog-2.ckp
│ ├── translog-3.ckp
│ ├── translog-4.ckp
│ ├── translog-5.ckp
│ ├── translog-5.tlog
│ ├── translog-6.ckp
│ ├── translog-6.tlog
│ ├── translog-7.tlog
│ └── translog.ckp
├── 1
│ ├── index
│ │ ├── _0_1.liv
│ │ ├── _0.cfe
│ │ ├── _0.cfs
│ │ ├── _0.si
│ │ ├── _1.cfe
│ │ ├── _1.cfs
│ │ ├── _1.si
│ │ ├── segments_9
│ │ └── write.lock
│ ├── _state
│ │ └── state-6.st
│ └── translog
│ ├── translog-2.ckp
│ ├── translog-3.ckp
│ ├── translog-4.ckp
│ ├── translog-5.ckp
│ ├── translog-9.tlog
│ └── translog.ckp
├── 2
│ ├── index
│ │ ├── _0.cfe
│ │ ├── _0.cfs
│ │ ├── _0.si
│ │ ├── segments_7
│ │ └── write.lock
│ ├── _state
│ │ └── state-6.st
│ └── translog
│ ├── translog-2.ckp
│ ├── translog-3.ckp
│ ├── translog-4.ckp
│ ├── translog-5.ckp
│ ├── translog-6.ckp
│ ├── translog-6.tlog
│ ├── translog-7.ckp
│ ├── translog-7.tlog
│ ├── translog-8.tlog
│ └── translog.ckp
├── 3
│ ├── index
│ │ ├── _0.cfe
│ │ ├── _0.cfs
│ │ ├── _0.si
│ │ ├── segments_7
│ │ └── write.lock
│ ├── _state
│ │ └── state-6.st
│ └── translog
│ ├── translog-2.ckp
│ ├── translog-3.ckp
│ ├── translog-4.ckp
│ ├── translog-5.ckp
│ ├── translog-6.ckp
│ ├── translog-6.tlog
│ ├── translog-7.ckp
│ ├── translog-7.tlog
│ ├── translog-8.tlog
│ └── translog.ckp
├── 4
│ ├── index
│ │ ├── _0.cfe
│ │ ├── _0.cfs
│ │ ├── _0.si
│ │ ├── segments_7
│ │ └── write.lock
│ ├── _state
│ │ └── state-6.st
│ └── translog
│ ├── translog-2.ckp
│ ├── translog-3.ckp
│ ├── translog-4.ckp
│ ├── translog-5.ckp
│ ├── translog-6.ckp
│ ├── translog-6.tlog
│ ├── translog-7.ckp
│ ├── translog-7.tlog
│ ├── translog-8.tlog
│ └── translog.ckp
└── _state
└── state-8.st
哪个文件包含实际数据?我怎么能看到呢?
Which of the file contains actual data ? How can I see That ?
推荐答案
所有这些文件都包含数据,每个文件都包含特定类型的数据(倒排索引,字段数据,文档值等)。 索引
子文件夹中的文件为由Lucene创建的文件,用于存储所有需要的数据:
All those files contain data and each contains a specific type of data (inverted index, field data, document values, etc). The files in the index
sub-folder are files created by Lucene in order to store all the needed data:
cfe
andcfs
files are compound filesliv
files are live document filessi
files are segment info files- ...
还有更多可用的文件类型(术语频率,术语接近度等)正如我在上面给出的第一个链接中所见。所有这些文件都是二进制文件,您不能简单地使用文本编辑器进行查看。您可以使用Lucene工具箱中的 Luke工具来查看这些文件的内容。
There are many more file types available (term frequency, term proximity, etc) as can be seen in the first link I gave above. All those files are binary files that you cannot simply view with a text editor. You can use the Luke tool from the Lucene Toolbox in order to view the content of those files.
这篇关于弹性搜索中如何物理存储数据?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!