简体   繁体   English

运行`helm version`时`错误:找不到分蘖`

[英]`Error: could not find tiller` when running `helm version`

I have minikube and kubectl installed:我安装了minikubekubectl

$ 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/ :然后我按照https://helm.sh/docs/using_helm/的说明进行操作:

  1. I have downloaded https://get.helm.sh/helm-v2.13.1-linux-amd64.tar.gz我已经下载了 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版本,我会得到:

$ 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 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?如何让helm正确初始化?

The current helm version does not work with kubernetes version 1.16.0当前 helm 版本不适用于 kubernetes 版本 1.16.0

You can downgrade kubernetes to version 1.15.3您可以将 kubernetes 降级到 1.15.3 版本

minikube start --kubernetes-version 1.15.3
helm init 

or use my solution to fix it at version 1.16.0或使用我的解决方案在版本 1.16.0 修复它

You have to create tiller Service Account and ClusterRoleBinding .您必须创建分蘖服务帐户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 -

I met with the same problem, @shawndodo showed me this https://github.com/helm/helm/issues/6374#issuecomment-533427268我遇到了同样的问题,@shawndodo 向我展示了这个https://github.com/helm/helm/issues/6374#issuecomment-533427268

helm init --service-account tiller --override spec.selector.matchLabels.'name'='tiller',spec.selector.matchLabels.'app'='helm' --output yaml | sed 's@apiVersion: extensions/v1beta1@apiVersion: apps/v1@' | kubectl apply -f -

you can try this one.你可以试试这个。 (Posted on this question ) (发布在这个问题上)

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 配置:错误:找不到库的版本 - configure: error: Could not find a version of the library Monogame运行时“找不到字体文件” - Monogame "Could not find font file" when running 错误:从Linux命令行运行时找不到或加载主类Main- - Error: Could not find or load main class Main - when running from Linux command line docker 错误:找不到满足要求 apturl==0.5.2 的版本 - docker ERROR: Could not find a version that satisfies the requirement apturl==0.5.2 错误:找不到 R 版本 2.15.2 的函数 install_github - error: could not find function install_github for R version 2.15.2 构建 Root 时出现错误“找不到 PythonLibs” - Error "Could NOT find PythonLibs" when building Root 通过命令行运行时找不到或加载主类 - Could not find or load main class when running through command line 找不到主类:运行Java Jar时? - Could not find the main class: when running Java Jar? Postgres更新-运行命令时版本不匹配错误 - Postgres Update - version mismatch error when running commands 错误:找不到满足 tensorflow==2.1.0 要求的版本,并且未找到 tensorflow==2.1.0 的匹配分布 - ERROR: Could not find a version that satisfies the requirement tensorflow==2.1.0 and No matching distribution found for tensorflow==2.1.0
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM