index.translog.durability
配置是否每次提交都同步到磁盘。
request
(default) fsync and commit after every request. In the event of hardware failure, all acknowledged writes will already have been committed to disk.
默认采用此配置所有的请求都会被记录到trans log 并落地到磁盘,当出现故障后 都可以通过trans log 恢复过来。
async
如果配置为 异步方式 就有可能丢失上次提交到故障期间的数据。
参考地址
https://www.elastic.co/guide/en/elasticsearch/reference/7.3/index-modules-translog.html
https://www.elastic.co/guide/cn/elasticsearch/guide/cn/translog.html
网友评论