Helm "UPGRADE FAILED: post-upgrade hooks failed" in CI
A resource annotated as a post-upgrade hook (commonly a migration Job) failed or did not complete in time. Helm waits for hook success, then fails the upgrade and reports which hook did not finish.
What this error means
helm upgrade fails with "Error: UPGRADE FAILED: post-upgrade hooks failed: ... job failed: BackoffLimitExceeded" or a timeout on the hook resource.
helm
Error: UPGRADE FAILED: post-upgrade hooks failed: warning: Hook post-upgrade
my-app/templates/migrate-job.yaml failed: job failed: BackoffLimitExceededCommon causes
The hook Job itself errored
The migration or setup command in the hook Job exited non-zero, hit its backoffLimit, and Helm reported the hook as failed.
The hook did not finish before the timeout
A slow hook that exceeds --timeout is treated as failed even if it would eventually succeed.
How to fix it
Read the hook Job logs
- Find the hook Job and its pod in the release namespace.
- Read the pod logs to see the real command failure.
- Fix the underlying command (migration, credentials, connectivity), then re-run.
Terminal
kubectl get jobs -n prod
kubectl logs job/my-app-migrate -n prodRaise the timeout for slow hooks
If the hook is legitimately slow, increase the upgrade timeout so it has room to complete.
Terminal
helm upgrade --install my-app ./chart -n prod --timeout 10mHow to prevent it
- Make hook commands idempotent so retries are safe.
- Set a realistic
--timeoutfor migration and setup hooks. - Add
hook-delete-policyso old hook Jobs are cleaned up between runs.
Related guides
Helm "pre-install hooks failed" in CIFix Helm "Error: INSTALLATION FAILED: pre-install hooks failed" in CI - a resource annotated as a pre-install…
Helm "timed out waiting for the condition" (--wait) in CIFix Helm "Error: timed out waiting for the condition" with --wait in CI - Helm waited for resources to become…
Helm "UPGRADE FAILED: has no deployed releases" in CIFix Helm "Error: UPGRADE FAILED: "X" has no deployed releases" in CI - a release exists but every revision is…