Reputation: 31
I am executing the below-mentioned command to install Prometheus.
helm install my-kube-prometheus-stack prometheus-community/kube-prometheus-stack
I am getting the below error message. Please advise.
Error: unable to build kubernetes objects from release manifest: error validating "": error validating data: [ValidationError(Alertmanager.spec): unknown field "alertmanagerConfigNamespaceSelector" in com.coreos.monitoring.v1.Alertmanager.spec, ValidationError(Alertmanager.spec): unknown field "alertmanagerConfigSelector" in com.coreos.monitoring.v1.Alertmanager.spec]
Upvotes: 3
Views: 2885
Reputation: 13898
Hello @saerma and welcome to Stack Overflow!
@rohatgisanat might be right but without seeing your current configs it's impossible to verify that. Please check if that was the case.
There are also two other things you should look for:
crd alertmanagerconfigs.monitoring.coreos.com
alertmanagers.monitoring.coreos.com
crd podmonitors.monitoring.coreos.com
crd probes.monitoring.coreos.com
crd prometheuses.monitoring.coreos.com
crd prometheusrules.monitoring.coreos.com
crd servicemonitors.monitoring.coreos.com
crd thanosrulers.monitoring.coreos.com
Also, check if there are any other Prometheus related config files with:
kubectl get configmap --all-namespaces
and also delete them.
Notice that deleting the CRDs will result in deleting any servicemonitors and so on, which have previously been created by other charts.
After that you can try to install again from scratch.
kubectl apply -f https://raw.githubusercontent.com/prometheus-operator/prometheus-operator/v0.45.0/example/prometheus-operator-crd/monitoring.coreos.com_alertmanagers.yaml
as CRD changed with the newer version and you need to use the updated ones.
Upvotes: 3
Reputation: 828
Looks like the indentation of alertmanagerConfigNamespaceSelector
is wrong. It should be on the same level as alertmanagerConfigSelector
. Check your values.yaml for the same.
Upvotes: 1