停滞した ILM ステップを診断して再試行する (_ilm/explain、_ilm/retry)
Elasticsearchインデックスのライフサイクルコマンド
# Indices waiting in an error step:
GET log-*/_ilm/explain?only_errors=true
# Phase/action/step state and failure reason for one index:
GET log-000003/_ilm/explain?filter_path=indices.*.phase,indices.*.action,indices.*.step,indices.*.failed_step,indices.*.step_info,indices.*.is_auto_retryable_error
# After fixing the cause (example: missing rollover alias setting):
PUT log-000003/_settings
{
"index.lifecycle.rollover_alias": "log"
}
POST log-000003/_ilm/retry
# Is ILM running (if STOPPED, POST _ilm/start):
GET _ilm/status概要
ERROR ステップで待機しているインデックス、それらが停滞しているフェーズ / アクション / ステップ、失敗理由 (step_info) を表示する。原因を修正した後、失敗したステップを再実行する。
使用する場面
ロールオーバーが行われない場合、古いインデックスが削除されない場合、または ILM が削除すべきインデックスでディスクが埋まる場合。
注意
_ilm/retry は ERROR ステップにあるインデックスでのみ機能し、それ以外では 'has not encountered an error' を返す。よくある原因: rollover_alias 設定がない、またはエイリアスの is_write_index が別のインデックスにある、shrink のための単一ノード上のディスクが不足している、割り当てルール (_tier_preference) を満たせない。ポリシーを削除しても、インデックスの ILM 管理は解除されない。先にインデックスからポリシーの設定を削除する。