Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

安装过程中遇到的问题 #28

Closed
Cutie-Sakura opened this issue Dec 1, 2020 · 9 comments
Closed

安装过程中遇到的问题 #28

Cutie-Sakura opened this issue Dec 1, 2020 · 9 comments

Comments

@Cutie-Sakura
Copy link

正式安装前,在虚拟机中测试过多变,没有问题,在服务器中执行后,出现如下问题:
环境 centos7 安装gnome桌面,开发环境

fatal: [192.168.20.86]: FAILED! => {"changed": true, "cmd": "kubectl apply -f /etc/kubernetes/plugins/network-plugin/calico-typha.yaml", "delta": "0:00:00.485489", "end": "2020-12-01 09:57:47.017930", "msg": "non-zero return code", "rc": 1, "start": "2020-12-01 09:57:46.532441", "stderr": "unable to recognize "/etc/kubernetes/plugins/network-plugin/calico-typha.yaml": no matches for kind "CustomResourceDefinition" in version "apiextensions.k8s.io/v1"\nunable to recognize "/etc/kubernetes/plugins/network-plugin/calico-typha.yaml": no matches for kind "CustomResourceDefinition" in version "apiextensions.k8s.io/v1"\nunable to recognize "/etc/kubernetes/plugins/network-plugin/calico-typha.yaml": no matches for kind "CustomResourceDefinition" in version "apiextensions.k8s.io/v1"\nunable to recognize "/etc/kubernetes/plugins/network-plugin/calico-typha.yaml": no matches for kind "CustomResourceDefinition" in version "apiextensions.k8s.io/v1"\nunable to recognize "/etc/kubernetes/plugins/network-plugin/calico-typha.yaml": no matches for kind "CustomResourceDefinition" in version "apiextensions.k8s.io/v1"\nunable to recognize "/etc/kubernetes/plugins/network-plugin/calico-typha.yaml": no matches for kind "CustomResourceDefinition" in version "apiextensions.k8s.io/v1"\nunable to recognize "/etc/kubernetes/plugins/network-plugin/calico-typha.yaml": no matches for kind "CustomResourceDefinition" in version "apiextensions.k8s.io/v1"\nunable to recognize "/etc/kubernetes/plugins/network-plugin/calico-typha.yaml": no matches for kind "CustomResourceDefinition" in version "apiextensions.k8s.io/v1"\nunable to recognize "/etc/kubernetes/plugins/network-plugin/calico-typha.yaml": no matches for kind "CustomResourceDefinition" in version "apiextensions.k8s.io/v1"\nunable to recognize "/etc/kubernetes/plugins/network-plugin/calico-typha.yaml": no matches for kind "CustomResourceDefinition" in version "apiextensions.k8s.io/v1"\nunable to recognize "/etc/kubernetes/plugins/network-plugin/calico-typha.yaml": no matches for kind "CustomResourceDefinition" in version "apiextensions.k8s.io/v1"\nunable to recognize "/etc/kubernetes/plugins/network-plugin/calico-typha.yaml": no matches for kind "CustomResourceDefinition" in version "apiextensions.k8s.io/v1"\nunable to recognize "/etc/kubernetes/plugins/network-plugin/calico-typha.yaml": no matches for kind "CustomResourceDefinition" in version "apiextensions.k8s.io/v1"\nunable to recognize "/etc/kubernetes/plugins/network-plugin/calico-typha.yaml": no matches for kind "CustomResourceDefinition" in version "apiextensions.k8s.io/v1"\nunable to recognize "/etc/kubernetes/plugins/network-plugin/calico-typha.yaml": no matches for kind "CustomResourceDefinition" in version "apiextensions.k8s.io/v1"", "stderr_lines": ["unable to recognize "/etc/kubernetes/plugins/network-plugin/calico-typha.yaml": no matches for kind "CustomResourceDefinition" in version "apiextensions.k8s.io/v1"", "unable to recognize "/etc/kubernetes/plugins/network-plugin/calico-typha.yaml": no matches for kind "CustomResourceDefinition" in version "apiextensions.k8s.io/v1"", "unable to recognize "/etc/kubernetes/plugins/network-plugin/calico-typha.yaml": no matches for kind "CustomResourceDefinition" in version "apiextensions.k8s.io/v1"", "unable to recognize "/etc/kubernetes/plugins/network-plugin/calico-typha.yaml": no matches for kind "CustomResourceDefinition" in version "apiextensions.k8s.io/v1"", "unable to recognize "/etc/kubernetes/plugins/network-plugin/calico-typha.yaml": no matches for kind "CustomResourceDefinition" in version "apiextensions.k8s.io/v1"", "unable to recognize "/etc/kubernetes/plugins/network-plugin/calico-typha.yaml": no matches for kind "CustomResourceDefinition" in version "apiextensions.k8s.io/v1"", "unable to recognize "/etc/kubernetes/plugins/network-plugin/calico-typha.yaml": no matches for kind "CustomResourceDefinition" in version "apiextensions.k8s.io/v1"", "unable to recognize "/etc/kubernetes/plugins/network-plugin/calico-typha.yaml": no matches for kind "CustomResourceDefinition" in version "apiextensions.k8s.io/v1"", "unable to recognize "/etc/kubernetes/plugins/network-plugin/calico-typha.yaml": no matches for kind "CustomResourceDefinition" in version "apiextensions.k8s.io/v1"", "unable to recognize "/etc/kubernetes/plugins/network-plugin/calico-typha.yaml": no matches for kind "CustomResourceDefinition" in version "apiextensions.k8s.io/v1"", "unable to recognize "/etc/kubernetes/plugins/network-plugin/calico-typha.yaml": no matches for kind "CustomResourceDefinition" in version "apiextensions.k8s.io/v1"", "unable to recognize "/etc/kubernetes/plugins/network-plugin/calico-typha.yaml": no matches for kind "CustomResourceDefinition" in version "apiextensions.k8s.io/v1"", "unable to recognize "/etc/kubernetes/plugins/network-plugin/calico-typha.yaml": no matches for kind "CustomResourceDefinition" in version "apiextensions.k8s.io/v1"", "unable to recognize "/etc/kubernetes/plugins/network-plugin/calico-typha.yaml": no matches for kind "CustomResourceDefinition" in version "apiextensions.k8s.io/v1"", "unable to recognize "/etc/kubernetes/plugins/network-plugin/calico-typha.yaml": no matches for kind "CustomResourceDefinition" in version "apiextensions.k8s.io/v1""], "stdout": "configmap/calico-config created\nclusterrole.rbac.authorization.k8s.io/calico-kube-controllers created\nclusterrolebinding.rbac.authorization.k8s.io/calico-kube-controllers created\nclusterrole.rbac.authorization.k8s.io/calico-node created\nclusterrolebinding.rbac.authorization.k8s.io/calico-node created\nservice/calico-typha created\ndeployment.apps/calico-typha created\npoddisruptionbudget.policy/calico-typha created\ndaemonset.apps/calico-node created\nserviceaccount/calico-node created\ndeployment.apps/calico-kube-controllers created\nserviceaccount/calico-kube-controllers created", "stdout_lines": ["configmap/calico-config created", "clusterrole.rbac.authorization.k8s.io/calico-kube-controllers created", "clusterrolebinding.rbac.authorization.k8s.io/calico-kube-controllers created", "clusterrole.rbac.authorization.k8s.io/calico-node created", "clusterrolebinding.rbac.authorization.k8s.io/calico-node created", "service/calico-typha created", "deployment.apps/calico-typha created", "poddisruptionbudget.policy/calico-typha created", "daemonset.apps/calico-node created", "serviceaccount/calico-node created", "deployment.apps/calico-kube-controllers created", "serviceaccount/calico-kube-controllers created"]}

@TimeBye
Copy link
Owner

TimeBye commented Dec 2, 2020

你好,请问安装时是否修改了默认k8s安装版本?

@Cutie-Sakura
Copy link
Author

你好,请问安装时是否修改了替代k8s安装版本?

修改成了1.14.8,在虚拟机中完全没有问题, 部署成功过的

@TimeBye
Copy link
Owner

TimeBye commented Dec 2, 2020

近期提交有更新 calico 的版本,请在第一台master执行执行以下语句手动修复一下即可。建议安装最新1.19.4版本kubernetes

sed -i 's apiextensions.k8s.io/v1 apiextensions.k8s.io/v1beta1 g' /etc/kubernetes/plugins/network-plugin/calico-typha.yaml
kubectl apply -f /etc/kubernetes/plugins/network-plugin/calico-typha.yaml

@TimeBye
Copy link
Owner

TimeBye commented Dec 17, 2020

https://github.com/TimeBye/kubeadm-ha#%E5%B7%B2%E7%9F%A5%E9%97%AE%E9%A2%98

由于各插件(Network plugin、Ingress controller)版本更新以及高版本 kubernetes 有些 apiVersion 弃用等原因,可能导致部署低版本 kubernetes 时各插件部署报错等问题。在此建议安装本项目默认或者最新版本 kubernetes。

@TimeBye TimeBye closed this as completed Dec 17, 2020
@Huavey
Copy link

Huavey commented Jan 25, 2021

你好,通关脚本安装的k8s,使用nfs动态存储创建的pvc一直处于Pending状态
helm install --set nfs.server=172.27.225.182 --set storageClass.name=gitlab-nfs-storage --set nfs.path=/data/nfs/k8s/gitlab -n gitlab gitlab-nfs apphub/nfs-client-provisioner
nfs-client pod状态正常
使用自建的k8s,使用nfs动态存储创建pvc则正常

@TimeBye
Copy link
Owner

TimeBye commented Jan 25, 2021

尝试将nfs-client-provisioner镜像更换为

registry.cn-shanghai.aliyuncs.com/c7n/nfs-client-provisioner:v3.1.0-k8s1.20

看是否恢复正常

@Huavey
Copy link

Huavey commented Jan 26, 2021

尝试将nfs-client-provisioner镜像更换为

registry.cn-shanghai.aliyuncs.com/c7n/nfs-client-provisioner:v3.1.0-k8s1.20

看是否恢复正常

更换镜像后,重新部署nfs-client-provisoner, pvc已经正常。谢谢了❤。

@Huavey
Copy link

Huavey commented Mar 2, 2021

你好,这次在测试ceph分布式存储,也出现了创建的pvc一直处于Pending状态
ceph集群正常,storageclass对象状态正常
使用的rook-ceph的1.4.8版本

@TimeBye
Copy link
Owner

TimeBye commented Mar 2, 2021

rook我这边没有使用,建议到 https://github.com/rook/rook/issues 进行提问

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants