我正在尝试通过RBAC运行Minikube,但无法创建集群:
使用此:
minikube start --memory=8192 --cpus=4 --vm-driver=virtualbox --extra-config=apiserver.Authorization.Mode=RBAC
错误:
E0113 13:02:54.464971 65250 start.go:343] Error starting cluster: kubeadm init error
sudo /usr/bin/kubeadm init --config /var/lib/kubeadm.yaml --ignore-preflight-errors=DirAvailable--etc-kubernetes-manifests --ignore-preflight-errors=DirAvailable--data-minikube --ignore-preflight-errors=Port-10250 --ignore-preflight-errors=FileAvailable--etc-kubernetes-manifests-kube-scheduler.yaml --ignore-preflight-errors=FileAvailable--etc-kubernetes-manifests-kube-apiserver.yaml --ignore-preflight-errors=FileAvailable--etc-kubernetes-manifests-kube-controller-manager.yaml --ignore-preflight-errors=FileAvailable--etc-kubernetes-manifests-etcd.yaml --ignore-preflight-errors=Swap --ignore-preflight-errors=CRI
running command: : Process exited with status 1
================================================================================
An error has occurred. Would you like to opt in to sending anonymized crash
information to minikube to help prevent future errors?
To opt out of these messages, run the command:
minikube config set WantReportErrorPrompt false
================================================================================
Please enter your response [Y/n]: %
答案 0 :(得分:0)
问题是:-extra-config = apiserver.Authorization.Mode = RBAC
应为:-extra-config = apiserver.authorization-mode = RBAC
示例:
minikube start \
--kubernetes-version v1.13.7 \
--vm-driver=kvm2 \
--memory=4096 \
--cpus=2 \
--disk-size=60G \
--extra-config=apiserver.authorization-mode=RBAC