我正在尝试按照 Kelsey Hightower 的Kubernetes The Hard Way的指南来设置 kubernetes 集群的硬件
设置好后kube-scheduler
,当我启动调度程序时,我看到以下错误:
Jan 20 10:20:01 xyz.com kube-scheduler[12566]: F0120 10:20:01.025675 12566 helpers.go:119] **error: no kind "KubeSchedulerConfiguration" is registered for version** "kubescheduler.config.k8s.io/v1beta1"
Jan 20 10:20:01 xyz.com kube-scheduler systemd1: kube-scheduler.service: Main process exited, code=exited, status=255/n/a
Jan 20 10:20:01 xyz.com kube-scheduler systemd1: kube-scheduler.service: Unit entered failed state.
Jan 20 10:20:01 xyz.com kube-scheduler systemd1: kube-scheduler.service: Failed with result 'exit-code'.
Jan 20 10:20:06 xyz.com kube-scheduler systemd1: kube-scheduler.service: Service hold-off time over, scheduling restart.
有人可以提供一些关于正在发生的事情或我错过了什么的指示吗?我的kube-apiserver
和kube-controller-manager
活跃的。
我的kube-scheduler.yaml
内心/etc/kubernetes/config
是这样的。
apiVersion: kubescheduler.config.k8s.io/v1beta1
kind: KubeSchedulerConfiguration
clientConnection:
kubeconfig: "/var/lib/kubernetes/kube-scheduler.kubeconfig"
leaderElection:
leaderElect: true
更改
apiVersion
为kubescheduler.config.k8s.io/v1beta2
或kubescheduler.config.k8s.io/v1beta3
。Kubernetes 1.21v1beta1
不支持。您可以在此处(对于v1beta2)和此处(对于v1beta3)查看更多信息
在 kubernetes-the-hard-way repo ( #687 ) 中打开了一个问题,建议将 apiVersion 更改为
kubescheduler.config.k8s.io/v1alpha1