elasticsearch disk_error ai_generated true

ClusterBlockException: index [my_index] blocked by: [FORBIDDEN/12/index read-only / allow delete (api)]

ID: elasticsearch/index-read-only

Also available as: JSON · Markdown
90%Fix Rate
90%Confidence
3Evidence
2023-01-01First Seen

Version Compatibility

VersionStatusIntroducedDeprecatedNotes
8 active

Root Cause

Elasticsearch set index to read-only because disk usage exceeded flood-stage watermark (95% by default).

generic

Workarounds

  1. 95% success Free disk space, then unblock the index
    Free disk, then: PUT _all/_settings with index.blocks.read_only_allow_delete set to null

    Sources: https://www.elastic.co/guide/en/elasticsearch/reference/current/

  2. 88% success Delete old indices using ILM or curator
    DELETE /old-index-2024.*  # or configure ILM delete phase
  3. 82% success Add more disk space or data nodes

Dead Ends

Common approaches that don't work:

  1. Delete the index to free space 82% fail

    You lose all data. Free disk space first, then unblock the index.

  2. Increase the watermark thresholds 65% fail

    Only delays the problem. When disk is truly full, the cluster will crash.