{"id":"IL-0513","org":"Python Software Foundation","date":"2022-10-24","docs":[],"title":{"en":"PyPI backends on Kubernetes were unreachable over HTTPS for 20 minutes when the Ingress ELB lost its HTTPS listener","ko":"쿠버네티스 노드 순차 재시작 중 Ingress 가 관리하는 ELB 의 HTTPS 리스너가 꺼져 PyPI 백엔드에 HTTPS 로 닿지 못했다"},"domain":["kubernetes","aws","networking"],"impact":{"scope":"PyPI backends over HTTPS: CDN page fetches, uploads to uploads.pypi.org and the legacy file redirect service","users":"unknown","region":"unknown"},"review":{"written_by":"session","reviewed_at":null,"reviewed_by":null},"lessons":{"en":"When every resource is managed through the Kubernetes API, drift between the desired state and reality is less likely to build up and then surface during later maintenance.","ko":"자원을 모두 쿠버네티스 API 로 관리하면 원하는 상태와 실제 상태가 어긋나는 일이 줄고, 그런 어긋남이 다음 유지 보수 때 장애로 드러날 가능성도 줄어든다고 PSF 인프라 팀은 정리했다."},"related":[],"sources":[{"url":"https://status.python.org/incidents/77qzc7qsb5wb","kind":"official-status","archived":"https://web.archive.org/web/20240720010055/https://status.python.org/incidents/77qzc7qsb5wb"}],"summary":{"en":"PyPI and several ancillary services run as Deployments in a Kubernetes cluster and are exposed through Ingress with the AWS Elastic Load Balancer (ELB) integration. The ELB's TLS certificate is managed in Amazon's Certificate Manager (ACM), and the Ingress had been set up with an existing ACM certificate. After the previous rolling upgrade, PyPI's Ingress needed an additional hostname, so PyPI administrators created a new ACM certificate with that hostname and updated the Ingress-managed ELB to use it by hand in the AWS console, while the Ingress configuration still named the old certificate.\n\nOn 24 October 2022 a rolling restart of all nodes brought up new Kubernetes API servers. They re-validated the Ingress configurations, could not find the old ACM certificate, and disabled the HTTPS listener for the Ingress serving PyPI. Once the cause was found, the administrators pointed the Ingress configuration at the new ACM certificate, Kubernetes restored the HTTPS listener on the ELB, and access came back at 15:03 UTC.","ko":"PyPI 서비스는 쿠버네티스 클러스터에서 Deployment 로 돌고, AWS Elastic Load Balancer 통합을 쓰는 Ingress 로 외부에 노출된다. 이 로드 밸런서가 쓰는 TLS 인증서는 Amazon Certificate Manager, 곧 ACM 이 관리한다. 클러스터를 처음 배포할 때 Ingress 가 관리하는 ELB 는 기존 ACM 인증서를 쓰도록 설정됐다. 지난번 순차 업그레이드 뒤에 PyPI 의 Ingress 에 호스트 이름이 하나 더 필요해졌고, PyPI 관리자들이 그 이름을 담은 새 ACM 인증서를 만들어 ELB 가 새 인증서를 쓰도록 바꿨다. 이 변경은 Ingress 설정에는 반영되지 않았다.\n\n2022-10-24 정기 유지 보수로 모든 노드를 순차 재시작하던 중, 새 쿠버네티스 API 서버가 올라오며 Ingress 설정을 다시 검증하고 갱신했다. 새 API 서버는 Ingress 설정이 가리키는 이전 ACM 인증서를 찾지 못했고, PyPI 와 관련 서비스를 내보내는 Ingress 의 HTTPS 리스너를 껐다. 14:43 UTC 부터 15:03 UTC 까지 PyPI 백엔드에 HTTPS 로 닿을 수 없어 CDN 의 페이지 가져오기, uploads.pypi.org 업로드, 옛 파일 리디렉션 서비스가 멈췄다. 원인을 찾은 PyPI 관리자들이 Ingress 설정을 새 ACM 인증서로 바꾸자 쿠버네티스가 HTTPS 리스너를 되살렸고 모든 서비스가 돌아왔다."},"trigger":{"en":"Regular maintenance did a rolling restart of every node in the cluster to roll out upgrades and new configuration; as the new Kubernetes API server hosts came up, Kubernetes validated and refreshed the Ingress configurations.","ko":"업그레이드와 새 설정을 모든 노드에 나눠 주려고 쿠버네티스 클러스터의 모든 노드를 순차 재시작했다. 새 쿠버네티스 API 서버가 올라오면서 기존에 정의한 Ingress 설정을 다시 검증하고 갱신했다."},"severity":"unknown","symptoms":["service-unavailable"],"timeline":{"detected_after":null,"resolved_after":"20m"},"date_kind":"incident","detection":null,"components":["ingress","cloud-load-balancer"],"root_cause":"config-change","remediation":[{"text":{"en":"Pointed the Ingress configuration at the new ACM TLS certificate, and Kubernetes restored the HTTPS listener on the ELB","ko":"PyPI 관리자들이 Ingress 설정을 새 ACM TLS 인증서를 가리키도록 고쳤다. 쿠버네티스가 Ingress 가 관리하는 ELB 에 HTTPS 리스너를 되살렸고 모든 서비스에 다시 접속할 수 있게 됐다."}}],"action_items":[{"text":{"en":"Investigate managing the hostnames on the ACM TLS certificates for PyPI's Ingress through Kubernetes resources instead of the AWS console","ko":"PyPI Ingress 설정에 필요한 ACM TLS 인증서의 호스트 이름을 AWS 콘솔에서 손으로 관리하지 않고 쿠버네티스 자원으로 관리할 방법을 찾는다."}}],"contributing":["config-not-in-code","delayed-effect-change"],"recurrence_of":null,"symptoms_text":{"en":"From 14:43 to 15:03 UTC on 24 October 2022, during regular maintenance of the Kubernetes cluster that hosts PyPI, PyPI's backends could not be reached over HTTPS. The CDN could not fetch pages, uploads to uploads.pypi.org were impossible, and other services such as the legacy file redirect service were interrupted.\n\nThe HTTPS listener of the AWS Elastic Load Balancer that the Kubernetes Ingress manages had been disabled for the Ingress serving PyPI and its associated services. The status page listed pypi.org backends, files.pythonhosted.org redirects and the redirects backends as affected.","ko":"2022-10-24 14:43 UTC 부터 15:03 UTC 까지 PyPI 백엔드에 HTTPS 로 접속할 수 없었다. CDN 이 페이지를 가져오지 못했고, uploads.pypi.org 로 올리기가 막혔으며, 옛 파일 리디렉션 서비스도 끊겼다.\n\n상태 페이지는 14:51 UTC 에 PyPI 와 관련 서비스가 도는 백엔드에 큰 장애가 났다고 알렸다. 영향을 받은 항목은 pypi.org 의 Backends, files.pythonhosted.org 의 Redirects 와 Redirects Backends 였다.\n\n장애는 정기 유지 보수로 클러스터의 모든 노드를 순차 재시작하던 중에 났다. 새 쿠버네티스 API 서버가 올라오면서 PyPI 와 관련 서비스를 내보내는 Ingress 에서 ELB 의 HTTPS 리스너를 껐다."},"updated_at":"2026-11-14T12:34:15.732568Z","url":"https://benchlet.com/incidentlib/app/cases/IL-0513","org_slug":"python-software-foundation"}