IMPORTANT: No additional bug fixes or documentation updates
will be released for this version. For the latest information, see the
current release documentation.
Full Policy
editFull Policy
editThis functionality is in beta and is subject to change. The design and code is less mature than official GA features and is being provided as-is with no warranties. Beta features are not subject to the support SLA of official GA features.
With all of these actions, we can support complex management strategies for our indices. This policy will define an index that will start in the hot phase, rolling over every 50 GB or 7 days. After 30 days it enters the warm phase and increases the replicas to 2, force merges and shrinks. After 60 days it enters the cold phase and allocates to "cold" nodes, and after 90 days the index is deleted.
PUT _ilm/policy/full_policy { "policy": { "phases": { "hot": { "actions": { "rollover": { "max_age": "7d", "max_size": "50G" } } }, "warm": { "min_age": "30d", "actions": { "forcemerge": { "max_num_segments": 1 }, "shrink": { "number_of_shards": 1 }, "allocate": { "number_of_replicas": 2 } } }, "cold": { "min_age": "60d", "actions": { "allocate": { "require": { "type": "cold" } } } }, "delete": { "min_age": "90d", "actions": { "delete": {} } } } } }