0

I try to install prometheus-community/kube-prometheus-stack

using below command

helm install stable prometheus-community/kube-prometheus-stack -n monitoring --debug

But it failed with issue: helm.go:88: [debug] failed pre-install: timed out waiting for the condition

I tried to figured out by googled it but cannot find the solution.

below full debug statement:

install.go:178: [debug] Original chart version: ""
install.go:199: [debug] CHART PATH: /Users/dmitryignatev/Library/Caches/helm/repository/kube-prometheus-stack-27.2.1.tgz

client.go:128: [debug] creating 1 resource(s)
install.go:151: [debug] CRD alertmanagerconfigs.monitoring.coreos.com is already present. Skipping.
client.go:128: [debug] creating 1 resource(s)
install.go:151: [debug] CRD alertmanagers.monitoring.coreos.com is already present. Skipping.
client.go:128: [debug] creating 1 resource(s)
install.go:151: [debug] CRD podmonitors.monitoring.coreos.com is already present. Skipping.
client.go:128: [debug] creating 1 resource(s)
install.go:151: [debug] CRD probes.monitoring.coreos.com is already present. Skipping.
client.go:128: [debug] creating 1 resource(s)
install.go:151: [debug] CRD prometheuses.monitoring.coreos.com is already present. Skipping.
client.go:128: [debug] creating 1 resource(s)
install.go:151: [debug] CRD prometheusrules.monitoring.coreos.com is already present. Skipping.
client.go:128: [debug] creating 1 resource(s)
install.go:151: [debug] CRD servicemonitors.monitoring.coreos.com is already present. Skipping.
client.go:128: [debug] creating 1 resource(s)
install.go:151: [debug] CRD thanosrulers.monitoring.coreos.com is already present. Skipping.
client.go:299: [debug] Starting delete for "stable-kube-prometheus-sta-admission" PodSecurityPolicy
client.go:128: [debug] creating 1 resource(s)
client.go:299: [debug] Starting delete for "stable-kube-prometheus-sta-admission" ServiceAccount
client.go:328: [debug] serviceaccounts "stable-kube-prometheus-sta-admission" not found
client.go:128: [debug] creating 1 resource(s)
client.go:299: [debug] Starting delete for "stable-kube-prometheus-sta-admission" ClusterRole
client.go:128: [debug] creating 1 resource(s)
client.go:299: [debug] Starting delete for "stable-kube-prometheus-sta-admission" ClusterRoleBinding
client.go:128: [debug] creating 1 resource(s)
client.go:299: [debug] Starting delete for "stable-kube-prometheus-sta-admission" Role
client.go:328: [debug] roles.rbac.authorization.k8s.io "stable-kube-prometheus-sta-admission" not found
client.go:128: [debug] creating 1 resource(s)
client.go:299: [debug] Starting delete for "stable-kube-prometheus-sta-admission" RoleBinding
client.go:328: [debug] rolebindings.rbac.authorization.k8s.io "stable-kube-prometheus-sta-admission" not found
client.go:128: [debug] creating 1 resource(s)
client.go:299: [debug] Starting delete for "stable-kube-prometheus-sta-admission-create" Job
client.go:328: [debug] jobs.batch "stable-kube-prometheus-sta-admission-create" not found
client.go:128: [debug] creating 1 resource(s)
client.go:528: [debug] Watching for changes to Job stable-kube-prometheus-sta-admission-create with timeout of 5m0s
client.go:556: [debug] Add/Modify event for stable-kube-prometheus-sta-admission-create: ADDED
client.go:595: [debug] stable-kube-prometheus-sta-admission-create: Jobs active: 1, jobs failed: 0, jobs succeeded: 0
Error: INSTALLATION FAILED: failed pre-install: timed out waiting for the condition
helm.go:88: [debug] failed pre-install: timed out waiting for the condition

Dmitriy_kzn
  • 518
  • 4
  • 16

2 Answers2

2

I fix it. Need to use not latest version. Just include tag in you image which is not the latest. I use version 18

helm install monitoring prometheus-community/kube-prometheus-stack \
--version 18.0.8 \
--namespace monitoring \
--create-namespace

     


Dmitriy_kzn
  • 518
  • 4
  • 16
  • Does not work for me. Getting: `Error: INSTALLATION FAILED: unable to build kubernetes objects from release manifest: [resource mapping not found for name: "prometheus-grafana" namespace: "" from "": no matches for kind "PodSecurityPolicy" in version "policy/v1beta1" ensure CRDs are installed first, resource mapping not found for name: "prometheus-grafana-test" namespace: "" from "": no matches for kind "PodSecurityPolicy" in version "policy/v1beta1"` CRDs are present btw. – Pedro Es Jul 07 '23 at 23:03
0

Delete kube-prometheus-s-admission-create job and kube-prometheus-s-admission-patch job that was "stuck", probably the readiness probe failing. After deleting them, process continues to success.

Delete the jobs from another session, it will move further

Shelten
  • 26
  • 2