Write curl code in Larval or Linux terminal

write want this codes in terminal or laravel

  PUT _settings
    {
    "index": {
    "blocks": {
    "read_only_allow_delete": "false"
    }
    }
    }
    PUT your_index_name/_settings
    {
    "index": {
    "blocks": {
    "read_only_allow_delete": "false"
    }
    }
    }

Use curl or send a simple HTTP request. The documentation generally provide you with a way to copy the commands as curl requests.

1 Like

How're you?

with this

curl -XPUT -H "Content-Typhttp://localhost:9200/_all/_settings -d '{"index.blocks.read_only_allow_delete": false}'

But the problem is that it returns to its original state after a minute

That typically means you are running out of disk space and it is more than 95% full. You will need to fix that, either by deleting indices or adding storage.

okey