Bringing together the Apache Cassandra experts from the community and DataStax.

Want to learn? Have a question? Want to share your expertise? You are in the right place!

Not sure where to begin? Getting Started

 

question

dean_allsopp avatar image
dean_allsopp asked Erick Ramirez edited

Error installing K8ssandra with Helm: CassandraDatacenter "dc1" in namespace "default" exists

Error installing K8ssandra with Helm. Reproduced after uninstalling all Helm charts and checking the pods were gone.

$ helm install k8ssandra-cluster-a k8ssandra/k8ssandra-cluster --set ingress.traefik.enabled=true --set ingress.traefik.repair.host=repair.${ADDRESS} --set ingress.traefik.monitoring.grafana.host=grafana.${ADDRESS} --set ingress.traefik.monitoring.prometheus.host=prometheus.${ADDRESS}
Error: rendered manifests contain a resource that already exists. Unable to continue with install: CassandraDatacenter "dc1" in namespace "default" exists and cannot be imported into the current release: invalid ownership metadata; annotation validation error: key "meta.helm.sh/release-name" must equal "k8ssandra-cluster-a": 
current value is "k8ssandra-tools"
cass-operatork8ssandra
2 comments
10 |1000 characters needed characters left characters exceeded

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

I'm on the road so I've asked the authors of the cass-operator to respond to your question. Cheers!

0 Likes 0 ·
dean_allsopp avatar image dean_allsopp Erick Ramirez ♦♦ ·

Thanks Erick

0 Likes 0 ·

1 Answer

john.sanda_194109 avatar image
john.sanda_194109 answered dean_allsopp commented

It looks like you already have a CassandraDatacenter object in the default namespace from a previous installation. You can check to see what you have installed with this:

$ helm ls -n default

If there is another Helm release already installed, you can delete it with:

$ helm uninstall -n default <release-name>

Alternatively, you can install the chart into a different namespace if you want to keep the first cluster:

$ helm install k8ssandra-cluster-b k8ssandra/k8ssandra-cluster -n <another-namespace> --create-namespace

Hope that helps.

John

1 comment Share
10 |1000 characters needed characters left characters exceeded

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

Thanks for this. I'd already tried uninstalling the Helm releases.

Using the command to install into another namespace completes without an error.

It may not work with the Kubecon workshop though. Has anyone completed all the code steps successfully since the workshops in the last 24 hours?

0 Likes 0 ·