Nithin Chandy
Nithin Chandy

Reputation: 707

How to speed up Elasticsearch reindex operation?

Can we speed up elasticsearch (v 5.3) reindex operation by setting replicas to zero and increasing the refresh interval or is it already taken care internally?

Upvotes: 3

Views: 8638

Answers (1)

Ivan Mamontov
Ivan Mamontov

Reputation: 2924

In order to improve indexing speed you can use the following:

  • Use bulk requests
  • Use multiple workers/threads to send data to Elasticsearch
  • Increase the refresh interval
  • Disable refresh and replicas for initial loads
  • Use auto-generated ids
  • Increase indexing buffer size

Related to you question - ElasticSearch is designed for continuous log processing that's why all these actions are not automatic. In case of bulk reindexings you have to change all these settings manually and restore them at the end:

  • refresh interval for Lucene index writer
  • replication factor for distributed processor
  • index buffer size for merge scheduler

Upvotes: 5

Related Questions