Freeze index API
editFreeze index API
editDeprecated in 7.14.
Frozen indices are no longer useful due to recent improvements in heap memory usage.
Freezes an index.
Request
editPOST /<index>/_freeze
Prerequisites
edit-
If the Elasticsearch security features are enabled, you must have the
manage
index privilege for the target index or index alias.
Description
editA frozen index has almost no overhead on the cluster (except for maintaining its metadata in memory) and is read-only. Read-only indices are blocked for write operations, such as docs-index_ or force merges. See Unfreeze index.
The current write index on a data stream cannot be frozen. In order to freeze the current write index, the data stream must first be rolled over so that a new write index is created and then the previous write index can be frozen.
Freezing an index will close the index and reopen it within the same API call. This causes primaries to not be allocated for a short amount of time and causes the cluster to go red until the primaries are allocated again. This limitation might be removed in the future.
Path parameters
edit-
<index>
- (Required, string) Identifier for the index.
Examples
editThe following example freezes and unfreezes an index:
POST /my-index-000001/_freeze POST /my-index-000001/_unfreeze