HorizontalPodAutoscaler cannot access metric data because metrics-server is not running, pod metrics are incomplete, or the metrics API is not responding.
HPA queries the metrics API to fetch metric values (CPU, memory, custom). When the metrics API is unavailable, unresponsive, or has no data for the target, HPA cannot make scaling decisions. This blocks autoscaling completely—HPA will keep the current replica count and report "Unknown" status.
First diagnostic step
Second diagnostic step
Third diagnostic step
Fourth diagnostic step
Additional notes and platform-specific considerations.
Failed to connect to server: connection refused (HTTP/2)
How to fix "HTTP/2 connection refused" error in Kubernetes
missing request for cpu in container
How to fix "missing request for cpu in container" in Kubernetes HPA
error: invalid configuration
How to fix "error: invalid configuration" in Kubernetes
Fifth diagnostic step