Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

`Error: could not find tiller` when running `helm version`

I have minikube and kubectl installed:

$ minikube version
minikube version: v1.4.0
commit: 7969c25a98a018b94ea87d949350f3271e9d64b6

$ kubectl version
Client Version: version.Info{Major:"1", Minor:"16", GitVersion:"v1.16.0", GitCommit:"2bd9643cee5b3b3a5ecbd3af49d09018f0773c77", GitTreeState:"clean", BuildDate:"2019-09-18T14:36:53Z", GoVersion:"go1.12.9", Compiler:"gc", Platform:"linux/amd64"}
Server Version: version.Info{Major:"1", Minor:"16", GitVersion:"v1.16.0", GitCommit:"2bd9643cee5b3b3a5ecbd3af49d09018f0773c77", GitTreeState:"clean", BuildDate:"2019-09-18T14:27:17Z", GoVersion:"go1.12.9", Compiler:"gc", Platform:"linux/amd64"}

I have then followed the instructions from https://helm.sh/docs/using_helm/:

  1. I have downloaded https://get.helm.sh/helm-v2.13.1-linux-amd64.tar.gz

  2. I have run

$ tar -xzvf Downloads/helm-v2.13.1-linux-amd64.tar.gz linux-amd64/
linux-amd64/LICENSE
linux-amd64/tiller
linux-amd64/helm
linux-amd64/README.md

But now, if I check my helm version, I get this:

$ helm version
Client: &version.Version{SemVer:"v2.13.1", GitCommit:"618447cbf203d147601b4b9bd7f8c37a5d39fbb4", GitTreeState:"clean"}
Error: could not find tiller

I have tried running helm init, but get the following:

$ helm init
$HELM_HOME has been configured at /home/SERILOCAL/<my-username>/.helm.
Error: error installing: the server could not find the requested resource

How can I get helm to initialise correctly?

like image 621
EuRBamarth Avatar asked Sep 25 '19 10:09

EuRBamarth


People also ask

How do I check helm tiller version?

Easy In-Cluster Installation Once it connects, it will install tiller into the kube-system namespace. After helm init , you should be able to run kubectl get pods --namespace kube-system and see Tiller running. Once Tiller is installed, running helm version should show you both the client and server version.

Is Tiller required for Helm 3?

In helm 3 there is no tiller component. Helm client directly interacts with the kubernetes API for the helm chart deployment. So from wherever you are running the helm command, you should have kubectl configured with cluster-admin permissions for helm to execute the manifests in the chart.

Is Tiller required for Helm?

Without Tiller, Helm needs a way to track the state of the different releases in the cluster. Helm 2 had the option of using secrets for release objects; now it's the default.


1 Answers

The current helm version does not work with kubernetes version 1.16.0

You can downgrade kubernetes to version 1.15.3

minikube start --kubernetes-version 1.15.3
helm init 

or use my solution to fix it at version 1.16.0

You have to create tiller Service Account and ClusterRoleBinding.

You can simply do that by using those commands:

kubectl --namespace kube-system create sa tiller
kubectl create clusterrolebinding tiller --clusterrole cluster-admin --serviceaccount=kube-system:tiller

And simply create tiller

helm init --override spec.selector.matchLabels.'name'='tiller',spec.selector.matchLabels.'app'='helm' --output yaml | sed 's@apiVersion: extensions/v1beta1@apiVersion: apps/v1@' | kubectl apply -f -
like image 63
Jakub Avatar answered Sep 22 '22 12:09

Jakub