Closed jakeslee closed 4 years ago
Hi, @jakeslee.
I'm not able to reproduce your issue. Here is what I did:
helm install --name etcd bitnami/etcd --namespace kv
export POD_NAME=$(kubectl get pods --namespace kv -l "app.kubernetes.io/name=etcd,app.kubernetes.io/instance=etcd" -o jsonpath="{.items[0].metadata.name}")
export ETCD_ROOT_PASSWORD=$(kubectl get secret --namespace kv etcd -o jsonpath="{.data.etcd-root-password}" | base64 --decode)
kubectl exec -n kv -it $POD_NAME -- etcdctl put /message Hello
{"level":"warn","ts":"2019-11-18T07:46:41.037Z","caller":"clientv3/retry_interceptor.go:61","msg":"retrying of unary invoker failed","target":"endpoint://client-7f90cfad-318d-46a4-8fd9-28d08d6eba21/127.0.0.1:2379","attempt":0,"error":"rpc error: code = InvalidArgument desc = etcdserver: user name is empty"}
Error: etcdserver: user name is empty
command terminated with exit code 1
kubectl exec -n kv -ti $POD_NAME -- etcdctl --user root:$ETCD_ROOT_PASSWORD put /message Hello
OK
kubectl exec -n kv -it $POD_NAME -- etcdctl --user root:$ETCD_ROOT_PASSWORD get /message
/message
Hello
Is it possible that your namespace had some old data that is causing the authentication to fail?
I am sorry for that. I can't reproduce the issue again, too. Maybe the old data caused the problem. Thanks for your attention. I'll close the issue.
Posting as this might help somebody else.
I'm still getting this but it's a bit of an edge case. When I do helm install ...
on a brand new cluster with the defaults on a custom namespace, the first time everything is fine. The problem is when I helm uninstall
and the helm install ...
again.
To reproduce do:
helm install
helm uninstall
helm install
The issue is that helm uninstall
does not delete PVCs (see here).
So if you manually delete the PVC after helm uninstall
and then try helm install
again it works.
I'm getting this while automating some integration tests so it's not a big deal for me at the moment since I can just purge the PVCs after the uninstall but hopefully this post could save some a headache :sweat_smile:
Also, given that we're talking about integration tests it is super easy for me to replicate this, so if somebody wants to look into it regardless I'd be happy to share my tests.
I was facing simillar issue for ytt / carvel install of etcd. Deleting PVC was a good solution worked for me!
I found that Chart installed in specific namespace(no default) still has the problem, thought I passed
--user root:$ETCD_ROOT_PASSWORD
option.helm install --name etcd bitnami/etcd
--namespace kvOriginally posted by @jakeslee in https://github.com/bitnami/charts/issues/1454#issuecomment-554648417