我正在使用elasticsearch 0.90.10。我使用mongodb river索引了mongodb中的文档。初始加载和索引工作正常。但是一段时间后,文档数量开始逐渐减少(丢失文档)。我正在使用mongodb-river版本1.7.4
这些是我的elasticsearch.yml中的配置。

集群属性

cluster.name: 192.168.31.50:9300
index.store.type: niofs
node.max_local_storage_nodes: 1
transport.tcp.port: 9300
http.port: 9200
path.logs: /home/test/Test/scripts/../logs/search
discovery.zen.ping.multicast.enabled: false

搜索池
threadpool.search.type: fixed
threadpool.search.size: 5
threadpool.search.queue_size: 200

散水池
threadpool.bulk.type: fixed
threadpool.bulk.size: 5
threadpool.bulk.queue_size: 300

索引池
threadpool.index.type: fixed
threadpool.index.size: 5
threadpool.index.queue_size: 200

指标设定
indices.memory.index_buffer_size: 30%
indices.memory.min_shard_index_buffer_size: 12mb
indices.memory.min_index_buffer_size: 96mb

快取大小
indices.fielddata.cache.size: 15%
indices.fielddata.cache.expire: 6h
indices.cache.filter.size: 15%
indices.cache.filter.expire: 6h

写入的索引设置
index.refresh_interval: 30s
index.translog.flush_threshold_ops: 50000

这些配置在我的生产环境中导致文档丢失。我该怎么做才能找出确切的问题?

提前致谢!

最佳答案

是否可以设置ttl属性?这是我听说过的“删除”文档的唯一内容。

http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/mapping-ttl-field.html

07-24 09:39
查看更多