Error: could not find a ready tiller pod

See if it has been tiller

root@nav8:~# kubectl get pods -n kube-system | grep tiller
tiller-deploy-65ff9d5d97-q5sl6             1/1     Running   0          21m

root@n:/usr/local/bin# helm version
Client: &version.Version{SemVer:"v2.14.1", GitCommit:"5270352a09c7e8b6e8c9593002a73535276507c0", GitTreeState:"clean"}
Error: could not find a ready tiller pod
  1. Corresponding to the pod has been running;
  2. apt-get install socat (ubuntu)
    yum install socat -y (centos)
[root@d]# helm version 
Client: &version.Version{SemVer:"v2.11.0", GitCommit:"2e55dbe1fdb5fdb96b75ff144a339489417b146b", GitTreeState:"clean"}
E1022 16:27:57.047815   28426 portforward.go:331] an error occurred forwarding 33023 -> 44134: error forwarding port 44134 to pod 612a0e878789aa021c80b3d2f7e7514fba75c908a0da285205c13c06b5605c02, uid : unable to do port forwarding: socat not found.
Error: cannot connect to Tiller

#############################################
$ Helm Version
If an error as follows:

 Client: &version.Version{SemVer:"v2.6.1", GitCommit:"bbc1f71dc03afc5f00c6ac84b9308f8ecb4f39ac", GitTreeState:"clean"}
E0921 16:19:09.448738   24295 portforward.go:331] an error occurred forwarding 39401 -> 44134: error forwarding port 44134 to pod 5b85aa2aa4347d59ea30edf466a7e01a198780151d30644a16b5cab4ceb2b83d, uid : unable to do port forwarding: socat not found.
Error: cannot connect to Tiller

Solution: Install ssocat can be solved in node node k8s of
$ sudo yum install socat

Another problem encountered, $ helm list -a, error Error: the server has asked for the client to provide credentials (get configmaps)

Solution:

.创建sericeaccount

  $kubectl create serviceaccount --namespace kube-system tiller

  $kubectl create clusterrolebinding tiller-cluster-rule --clusterrole=cluster-admin --serviceaccount=kube-system:tiller

  $kubectl patch deploy --namespace kube-system tiller-deploy -p '{"spec":{"template":{"spec":{"serviceAccount":"tiller"}}}}'

.run helm

  $helm init --service-account tiller --tiller-image 4admin2root/tiller:v2.6.0 --upgrade

Delete Tiller:

  $helm reset   或 $helm reset -f(强制删除k8s集群上的pod.)

When you want to remove the helm init directory and other data to create, execute helm reset --remove-helm-home

####################################################

unset HELM_HOST (before setting up HELM_HOST to 127.0.0.1:44134, but changed svc tiller-deploy as NodePort)

After uninstalling (removing the tiller related svc, deploy and /root/.helm directory), reinstall

  • Uninstall
    helm reset will remove the pod tiller created on a cluster k8s

When appears above context deadline exceeded, helm reset will also report the error. Execution heml reset -f force the deletion pod on k8s cluster.

When you want to remove the helm init directory and other data to create, execute helm reset --remove-helm-home

  • Supplementary
    version 2.5 installed tiller, in the context deadline exceeded appears, use the 2.4 version of the helm execution heml reset --remove-helm-home --force and configure the tiller can not remove the pod and created. This is the 2.4 version of the problem.
Published 33 original articles · won praise 0 · Views 3930

Guess you like

Origin blog.csdn.net/erhaiou2008/article/details/103908416