{"id":"IL-0046","org":"UK Ministry of Justice","date":"2024-04-15","docs":[],"title":{"en":"Prometheus restarted again and again because its WAL replay took longer than the startup probe allowed","ko":"계획된 재시작 뒤 Prometheus 가 WAL 을 다 읽기 전에 startupProbe 에 걸려 재시작을 반복했고 지표가 빠졌다"},"domain":["kubernetes","aws","observability"],"impact":{"scope":"Prometheus unavailable; the Cloud Platform lost monitoring and metrics for the period","users":"unknown","region":"unknown"},"review":{"written_by":"session","reviewed_at":null,"reviewed_by":null},"lessons":null,"related":[],"sources":[{"url":"https://runbooks.cloud-platform.service.justice.gov.uk/incidents/2024-04-15-prometheus.html","kind":"runbook","license":"unknown","archived":null}],"summary":{"en":"A planned change on the Ministry of Justice Cloud Platform restarted Prometheus. The WAL count was high, so the WAL reload took longer than the startup probe allowed; the report gives the default as 15 minutes. The startup probe failed before the reload finished, the container was restarted, and the next start went the same way. Reverting the planned change to rule it out did not help.\n\nAt 15:21 the team decided to raise the startupProbe to 30 minutes and applied it at 15:53. The WAL reload then completed and Prometheus became available, 3h 21m after it was first seen down. Users were updated at 13:00 and 16:00. The incident was closed on 2024-04-18 at 16:13, once the team had found and recorded why the reload took longer.","ko":"영국 법무부 Cloud Platform 팀의 Prometheus 장애다. 2024-04-15 에 계획된 변경으로 Prometheus 를 재시작했을 때 WAL 수가 평소보다 많아 다시 읽기에 오래 걸렸다. 기본 15분인 startupProbe 허용 시간으로는 다시 읽기를 끝낼 수 없었고, startupProbe 가 실패하면서 파드가 다시 읽기 도중에 재시작했다. 재시작이 여러 번 되풀이되는 동안 Prometheus 를 쓸 수 없었고 플랫폼의 모니터링과 지표가 비었다.\n\n12:32 에 처음 감지했고 13:00 에 사용자들에게 Prometheus 문제를 알렸으며 14:43 에 장애를 선언했다. 계획된 변경을 되돌렸지만 도움이 되지 않았고, 13:46 에 로그에서 startupProbe 실패 이벤트를 찾았다. 15:21 에 startupProbe 허용 시간을 30분으로 늘리기로 했고, 15:53 에 적용하자 WAL 다시 읽기가 끝나 Prometheus 가 다시 정상으로 돌아왔다. 복구에 3시간 21분이 걸렸다. 16:00 에 사용자들에게 Prometheus 상태를 알렸다. 팀은 2024-04-18 16:13 에 WAL 다시 읽기가 길어진 이유를 찾아 기록하고 장애를 종결했다."},"trigger":{"en":"A planned change restarted Prometheus at a time when the WAL count was high.","ko":"계획된 변경으로 Prometheus 를 재시작했는데 그때 WAL 수가 평소보다 많아, WAL 다시 읽기가 startupProbe 기본 허용 시간인 15분 안에 끝나지 않았다."},"severity":"unknown","symptoms":["monitoring-down","readiness-probe-failures"],"timeline":{"detected_after":null,"resolved_after":"3h21m"},"date_kind":"incident","detection":{"en":"The team saw that the Prometheus pod had restarted several times after the planned change.","ko":"계획된 Prometheus 변경 뒤 팀이 prometheus 파드가 여러 번 재시작한 것을 보고 알았다. 처음 감지한 시각은 2024-04-15 12:32 였다."},"components":["prometheus"],"root_cause":"capacity","remediation":[{"text":{"en":"raised the Prometheus startupProbe threshold to 30 minutes","ko":"startupProbe 허용 시간을 기본값 15분에서 30분으로 늘려 WAL 다시 읽기가 끝날 때까지 기다리게 했다."}}],"action_items":[{"text":{"en":"Perform planned Prometheus restarts when the WAL count is lower","ko":"팀은 계획된 Prometheus 재시작을 WAL 수가 적을 때 해서 재시작 시간을 줄이는 방안을 논의했다."}},{"text":{"en":"Set the default CPU and memory requests to meet maximum usage","ko":"Prometheus 의 기본 CPU 와 메모리 요청값을 최대 사용량에 맞춰 설정했다."}},{"text":{"en":"Create a test setup that recreates the live WAL count","ko":"운영 환경의 WAL 수를 재현하는 테스트 환경을 만든다."}},{"text":{"en":"Explore the memory-snapshot-on-shutdown and auto-gomaxprocs feature flags","ko":"memory-snapshot-on-shutdown 과 auto-gomaxprocs 기능 플래그를 검토한다."}},{"text":{"en":"Explore storing WAL files remotely in a different location","ko":"WAL 파일을 다른 위치의 원격 저장소에 두는 방법을 검토한다."}},{"text":{"en":"Look into a blue-green Prometheus to test changes on a live-like setup before applying them to live","ko":"운영과 같은 구성의 블루그린 Prometheus 를 만들어 운영에 적용하기 전에 변경을 시험하는 방안을 알아본다."}},{"text":{"en":"Spike into Amazon Managed Prometheus","ko":"Amazon Managed Prometheus 를 간단히 조사한다."}}],"contributing":["default-config-unchanged","limit-unknown"],"recurrence_of":null,"symptoms_text":{"en":"At 12:32 Prometheus on the Cloud Platform was not available after a planned change, and the Prometheus pod had restarted several times. The platform lost its monitoring and had missing metrics for the period.\n\nBy 12:52 the team found that Prometheus never finished reloading its write-ahead log (WAL), the on-disk log of recent samples it replays at startup: the pod was restarted before the reload completed. Reverting the planned change at 12:57 to rule it out did not help. At 13:46 the logs showed a startupProbe failed event.","ko":"2024-04-15 12:32 에 계획된 Prometheus 변경을 적용한 뒤 Prometheus 를 쓸 수 없게 되었다. 팀은 prometheus 파드가 여러 번 재시작한 것을 보았다. 그동안 Cloud Platform 에는 모니터링이 없었고 지표가 빠졌다.\n\n12:52 에 팀은 WAL 을 다시 읽는 도중에 재시작이 일어나 다시 읽기가 끝나지 못한다는 것을 알아냈다. WAL 은 Prometheus 가 디스크에 쓰는 선행 기록 로그이고, Prometheus 는 시작할 때 이것을 다시 읽는다. 12:57 에 계획된 변경을 되돌려 원인 후보에서 빼려 했지만 소용없었다. 13:46 에 로그를 살펴 startupProbe 실패 이벤트를 확인했다."},"updated_at":"2026-11-10T00:00:38.614423Z","url":"https://benchlet.com/incidentlib/app/cases/IL-0046","org_slug":"uk-ministry-of-justice"}