In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-09-23 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >
Share
Shulou(Shulou.com)06/03 Report--
ES cluster modifies the number of index copies. Error: index read-only / allow delete (api)
Reason:
The growth rate of es cluster data is too fast, resulting in disk utilization of individual es node nodes above 80%, close to 90%. Due to insufficient data storage space in the data directory of the new ES node, it fails to receive synchronous data from the master master node. In order to protect the data, the ES cluster automatically sets the index shard index to read-only read-only.
Troubleshooting methods:
1: add nodes to the cluster, simple and rough
2: reduce the number of cluster index replicas
3: others: add disks, delete historical data, etc.
We adopt scenario 2 as a temporary response. After the cluster can write normal data, we will point to the operation of step 1 or 3 to completely solve the problem.
Procedure:
1: execute in Dev Tools, the development tool of Kibana (or initiate a PUT request on the server through the curl tool, the same below)
Modify the number of index copies to 1
PUT 48_hot_v1/_settings {"index": {"number_of_replicas": "1"}} reported an error as follows:
The api interface performs the operation
{"type": "cluster_block_exception", "reason": "blocked by: [FORBIDDEN/12/index read-only / allow delete (api)];"} error reason:
If the es disk is full and more documents cannot be indexed, elasticsearch will switch to read-only. It ensures the availability of read-only queries. Elasticsearch does not switch back automatically. You can switch back to normal mode by using the following methods:
Curl-XPUT-H "Content-Type: application/json" http://localhost:9200/_all/_settings-d'{"index.blocks.read_only_allow_delete": null}'
Or, execute it in Dev Tools, the development tool of Kibana
PUT _ settings {"index": {"blocks": {"read_only_allow_delete": "false"} Verification: view the setting information of the specified index GET 48_hot_v1/_settings search content is as follows:}, "blocks": {"read_only_allow_delete": "false"} After the configuration takes effect, the cluster starts to delete index replica data. The datanode node disk space is gradually freed.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
The market share of Chrome browser on the desktop has exceeded 70%, and users are complaining about
The world's first 2nm mobile chip: Samsung Exynos 2600 is ready for mass production.According to a r
A US federal judge has ruled that Google can keep its Chrome browser, but it will be prohibited from
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
About us Contact us Product review car news thenatureplanet
More Form oMedia: AutoTimes. Bestcoffee. SL News. Jarebook. Coffee Hunters. Sundaily. Modezone. NNB. Coffee. Game News. FrontStreet. GGAMEN
© 2024 shulou.com SLNews company. All rights reserved.