Get the App
SLTechnology News&Howtos  ›  Internet Technology  › 

Example Analysis of elasticsearch Writing Optimization

Shulou Source: shulou.com Published: 2022-06-01 04:31:33 11月15日 Update

The editor today takes you to understand the example analysis of elasticsearch writing optimization, which is introduced in great detail in this article. Friends who feel helpful can browse the content of the article together with the editor, hoping to help more friends who want to solve this problem to find the answer to the problem. Follow the editor to learn more about "elasticsearch writing optimization example analysis".

For full dump data, the following optimizations can be made to optimize performance.

Slicing setting, not slicing

Http://localhost:9200/test_index/_settings/{ "index": {"number_of_replicas": 0}}

Refresh settings, do not refresh

Http://localhost:9200/test_index/_settings/{ "index": {"refresh_interval": "- 1"}}

Translog size setting, which is 512m by default.

Http://localhost:9200/test_index/_settings/{ "index.translog.flush_threshold_size": "1024mb"}

If it is a SSD hard disk, modify the segment merging rate

Http://localhost:9200/_cluster/settings/{ "persistent": {"indices.store.throttle.max_bytes_per_sec": "200mb"}} http://localhost:9200/_cluster/settings/{ "transient": {"indices.store.throttle.type": "none"}}

After full dump, restore it again

Shard settin

Http://localhost:9200/test_index/_settings/{ "index": {"number_of_replicas": 2}}

Refresh settings, do not refresh

Http://localhost:9200/test_index/_settings/{ "index": {"refresh_interval": "1s"}}

Translog size settin

Http://localhost:9200/test_index/_settings/{ "index.translog.flush_threshold_size": "512mb"}

Of course, bulk mode should be used, and the data submitted by elasticsearch should be less than 15m at a time.

Thank you for your reading, the above is the whole content of "sample Analysis of elasticsearch Writing Optimization", friends who learn to learn to hurry up to do it. I believe that the editor will certainly bring you better quality articles. Thank you for your support to the website!

Tags: Examples analysis friends content size data articles knowledge follow questions help that is performance more come on patterns knowledge points hard drives answers websites Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Linux Docker macOS Shulou Information MariaDB