创建部署问题时,请参考下面模板,你提供的信息越多,越容易及时获得解答。
你只花一分钟创建的问题,不能指望别人花上半个小时给你解答。
发帖前请点击 发表主题 右边的 预览(👀) 按钮,确保帖子格式正确。
操作系统信息
例如:虚拟机 Centos7.9 4C/8G
Kubernetes版本信息
例如:v1.20.15。一主三从。
容器运行时
例如,docker,版本: 20.10.9
KubeSphere版本信息
例如:v3.3.2。在线安装。已有K8s安装
问题是什么
启用多集群管理时失败,配置主集群参数后,启动ks-install,报错如下
关键报错信息
Post \\\"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s
完整报错信息
Start installing monitoring
Start installing multicluster
Start installing openpitrix
Start installing network
**************************************************
Waiting for all tasks to be completed ...
task network status is successful (1/4)
task openpitrix status is successful (2/4)
task monitoring status is successful (3/4)
task multicluster status is failed (4/4)
**************************************************
Collecting installation results ...
Task 'multicluster' failed:
******************************************************************************************************************************************************
{
"counter": 65,
"created": "2023-03-21T04:19:43.002351",
"end_line": 67,
"event": "runner_on_failed",
"event_data": {
"duration": 3126.285635,
"end": "2023-03-21T04:19:43.002208",
"event_loop": null,
"host": "localhost",
"ignore_errors": null,
"play": "localhost",
"play_pattern": "localhost",
"play_uuid": "b220dc5c-bcb3-72c3-01b0-000000000005",
"playbook": "/kubesphere/playbooks/multicluster.yaml",
"playbook_uuid": "852e640e-0f4e-4d8f-9d55-a5b9608c5b3f",
"remote_addr": "127.0.0.1",
"res": {
"_ansible_no_log": false,
"attempts": 10,
"changed": true,
"cmd": "/usr/local/bin/helm upgrade --install kubefed /kubesphere/kubesphere/kubefed/kubefed -f /kubesphere/kubesphere/kubefed/custom-values-kubefed.yaml --namespace kube-federation-system --wait --timeout 1800s\n",
"delta": "0:01:54.017540",
"end": "2023-03-21 12:19:42.920736",
"invocation": {
"module_args": {
"_raw_params": "/usr/local/bin/helm upgrade --install kubefed /kubesphere/kubesphere/kubefed/kubefed -f /kubesphere/kubesphere/kubefed/custom-values-kubefed.yaml --namespace kube-federation-system --wait --timeout 1800s\n",
"_uses_shell": true,
"argv": null,
"chdir": null,
"creates": null,
"executable": null,
"removes": null,
"stdin": null,
"stdin_add_newline": true,
"strip_empty_ends": true,
"warn": true
}
},
"msg": "non-zero return code",
"rc": 1,
"start": "2023-03-21 12:17:48.903196",
"stderr": "Error: UPGRADE FAILED: cannot patch \"clusterroles.rbac.authorization.k8s.io\" with kind FederatedTypeConfig: Internal error occurred: failed calling webhook \"federatedtypeconfigs.core.kubefed.io\": Post \"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s\": context deadline exceeded && cannot patch \"configmaps\" with kind FederatedTypeConfig: Internal error occurred: failed calling webhook \"federatedtypeconfigs.core.kubefed.io\": Post \"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s\": context deadline exceeded && cannot patch \"deployments.apps\" with kind FederatedTypeConfig: Internal error occurred: failed calling webhook \"federatedtypeconfigs.core.kubefed.io\": Post \"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s\": context deadline exceeded && cannot patch \"ingresses.networking.k8s.io\" with kind FederatedTypeConfig: Internal error occurred: failed calling webhook \"federatedtypeconfigs.core.kubefed.io\": Post \"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s\": context deadline exceeded && cannot patch \"jobs.batch\" with kind FederatedTypeConfig: Internal error occurred: failed calling webhook \"federatedtypeconfigs.core.kubefed.io\": Post \"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s\": context deadline exceeded && cannot patch \"namespaces\" with kind FederatedTypeConfig: Internal error occurred: failed calling webhook \"federatedtypeconfigs.core.kubefed.io\": Post \"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s\": context deadline exceeded && cannot patch \"replicasets.apps\" with kind FederatedTypeConfig: Internal error occurred: failed calling webhook \"federatedtypeconfigs.core.kubefed.io\": Post \"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s\": context deadline exceeded && cannot patch \"secrets\" with kind FederatedTypeConfig: Internal error occurred: failed calling webhook \"federatedtypeconfigs.core.kubefed.io\": Post \"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s\": context deadline exceeded && cannot patch \"serviceaccounts\" with kind FederatedTypeConfig: Internal error occurred: failed calling webhook \"federatedtypeconfigs.core.kubefed.io\": Post \"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s\": context deadline exceeded && cannot patch \"services\" with kind FederatedTypeConfig: Internal error occurred: failed calling webhook \"federatedtypeconfigs.core.kubefed.io\": Post \"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s\": context deadline exceeded && cannot patch \"kubefed\" with kind KubeFedConfig: Internal error occurred: failed calling webhook \"kubefedconfigs.core.kubefed.io\": Post \"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-kubefedconfig?timeout=10s\": context deadline exceeded",
"stderr_lines": [
"Error: UPGRADE FAILED: cannot patch \"clusterroles.rbac.authorization.k8s.io\" with kind FederatedTypeConfig: Internal error occurred: failed calling webhook \"federatedtypeconfigs.core.kubefed.io\": Post \"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s\": context deadline exceeded && cannot patch \"configmaps\" with kind FederatedTypeConfig: Internal error occurred: failed calling webhook \"federatedtypeconfigs.core.kubefed.io\": Post \"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s\": context deadline exceeded && cannot patch \"deployments.apps\" with kind FederatedTypeConfig: Internal error occurred: failed calling webhook \"federatedtypeconfigs.core.kubefed.io\": Post \"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s\": context deadline exceeded && cannot patch \"ingresses.networking.k8s.io\" with kind FederatedTypeConfig: Internal error occurred: failed calling webhook \"federatedtypeconfigs.core.kubefed.io\": Post \"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s\": context deadline exceeded && cannot patch \"jobs.batch\" with kind FederatedTypeConfig: Internal error occurred: failed calling webhook \"federatedtypeconfigs.core.kubefed.io\": Post \"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s\": context deadline exceeded && cannot patch \"namespaces\" with kind FederatedTypeConfig: Internal error occurred: failed calling webhook \"federatedtypeconfigs.core.kubefed.io\": Post \"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s\": context deadline exceeded && cannot patch \"replicasets.apps\" with kind FederatedTypeConfig: Internal error occurred: failed calling webhook \"federatedtypeconfigs.core.kubefed.io\": Post \"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s\": context deadline exceeded && cannot patch \"secrets\" with kind FederatedTypeConfig: Internal error occurred: failed calling webhook \"federatedtypeconfigs.core.kubefed.io\": Post \"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s\": context deadline exceeded && cannot patch \"serviceaccounts\" with kind FederatedTypeConfig: Internal error occurred: failed calling webhook \"federatedtypeconfigs.core.kubefed.io\": Post \"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s\": context deadline exceeded && cannot patch \"services\" with kind FederatedTypeConfig: Internal error occurred: failed calling webhook \"federatedtypeconfigs.core.kubefed.io\": Post \"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s\": context deadline exceeded && cannot patch \"kubefed\" with kind KubeFedConfig: Internal error occurred: failed calling webhook \"kubefedconfigs.core.kubefed.io\": Post \"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-kubefedconfig?timeout=10s\": context deadline exceeded"
],
"stdout": "",
"stdout_lines": []
},
"resolved_action": "command",
"role": "ks-multicluster",
"start": "2023-03-21T03:27:36.716573",
"task": "Kubefed | Initing kube-federation-system",
"task_action": "command",
"task_args": "",
"task_path": "/kubesphere/installer/roles/ks-multicluster/tasks/main.yml:51",
"task_uuid": "b220dc5c-bcb3-72c3-01b0-00000000001f",
"uuid": "45090cf4-d26b-4d5d-ba55-a66b44d5c50b"
},
"parent_uuid": "b220dc5c-bcb3-72c3-01b0-00000000001f",
"pid": 3087,
"runner_ident": "multicluster",
"start_line": 66,
"stdout": "fatal: [localhost]: FAILED! => {\"attempts\": 10, \"changed\": true, \"cmd\": \"/usr/local/bin/helm upgrade --install kubefed /kubesphere/kubesphere/kubefed/kubefed -f /kubesphere/kubesphere/kubefed/custom-values-kubefed.yaml --namespace kube-federation-system --wait --timeout 1800s\\n\", \"delta\": \"0:01:54.017540\", \"end\": \"2023-03-21 12:19:42.920736\", \"msg\": \"non-zero return code\", \"rc\": 1, \"start\": \"2023-03-21 12:17:48.903196\", \"stderr\": \"Error: UPGRADE FAILED: cannot patch \\\"clusterroles.rbac.authorization.k8s.io\\\" with kind FederatedTypeConfig: Internal error occurred: failed calling webhook \\\"federatedtypeconfigs.core.kubefed.io\\\": Post \\\"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s\\\": context deadline exceeded && cannot patch \\\"configmaps\\\" with kind FederatedTypeConfig: Internal error occurred: failed calling webhook \\\"federatedtypeconfigs.core.kubefed.io\\\": Post \\\"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s\\\": context deadline exceeded && cannot patch \\\"deployments.apps\\\" with kind FederatedTypeConfig: Internal error occurred: failed calling webhook \\\"federatedtypeconfigs.core.kubefed.io\\\": Post \\\"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s\\\": context deadline exceeded && cannot patch \\\"ingresses.networking.k8s.io\\\" with kind FederatedTypeConfig: Internal error occurred: failed calling webhook \\\"federatedtypeconfigs.core.kubefed.io\\\": Post \\\"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s\\\": context deadline exceeded && cannot patch \\\"jobs.batch\\\" with kind FederatedTypeConfig: Internal error occurred: failed calling webhook \\\"federatedtypeconfigs.core.kubefed.io\\\": Post \\\"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s\\\": context deadline exceeded && cannot patch \\\"namespaces\\\" with kind FederatedTypeConfig: Internal error occurred: failed calling webhook \\\"federatedtypeconfigs.core.kubefed.io\\\": Post \\\"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s\\\": context deadline exceeded && cannot patch \\\"replicasets.apps\\\" with kind FederatedTypeConfig: Internal error occurred: failed calling webhook \\\"federatedtypeconfigs.core.kubefed.io\\\": Post \\\"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s\\\": context deadline exceeded && cannot patch \\\"secrets\\\" with kind FederatedTypeConfig: Internal error occurred: failed calling webhook \\\"federatedtypeconfigs.core.kubefed.io\\\": Post \\\"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s\\\": context deadline exceeded && cannot patch \\\"serviceaccounts\\\" with kind FederatedTypeConfig: Internal error occurred: failed calling webhook \\\"federatedtypeconfigs.core.kubefed.io\\\": Post \\\"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s\\\": context deadline exceeded && cannot patch \\\"services\\\" with kind FederatedTypeConfig: Internal error occurred: failed calling webhook \\\"federatedtypeconfigs.core.kubefed.io\\\": Post \\\"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s\\\": context deadline exceeded && cannot patch \\\"kubefed\\\" with kind KubeFedConfig: Internal error occurred: failed calling webhook \\\"kubefedconfigs.core.kubefed.io\\\": Post \\\"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-kubefedconfig?timeout=10s\\\": context deadline exceeded\", \"stderr_lines\": [\"Error: UPGRADE FAILED: cannot patch \\\"clusterroles.rbac.authorization.k8s.io\\\" with kind FederatedTypeConfig: Internal error occurred: failed calling webhook \\\"federatedtypeconfigs.core.kubefed.io\\\": Post \\\"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s\\\": context deadline exceeded && cannot patch \\\"configmaps\\\" with kind FederatedTypeConfig: Internal error occurred: failed calling webhook \\\"federatedtypeconfigs.core.kubefed.io\\\": Post \\\"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s\\\": context deadline exceeded && cannot patch \\\"deployments.apps\\\" with kind FederatedTypeConfig: Internal error occurred: failed calling webhook \\\"federatedtypeconfigs.core.kubefed.io\\\": Post \\\"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s\\\": context deadline exceeded && cannot patch \\\"ingresses.networking.k8s.io\\\" with kind FederatedTypeConfig: Internal error occurred: failed calling webhook \\\"federatedtypeconfigs.core.kubefed.io\\\": Post \\\"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s\\\": context deadline exceeded && cannot patch \\\"jobs.batch\\\" with kind FederatedTypeConfig: Internal error occurred: failed calling webhook \\\"federatedtypeconfigs.core.kubefed.io\\\": Post \\\"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s\\\": context deadline exceeded && cannot patch \\\"namespaces\\\" with kind FederatedTypeConfig: Internal error occurred: failed calling webhook \\\"federatedtypeconfigs.core.kubefed.io\\\": Post \\\"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s\\\": context deadline exceeded && cannot patch \\\"replicasets.apps\\\" with kind FederatedTypeConfig: Internal error occurred: failed calling webhook \\\"federatedtypeconfigs.core.kubefed.io\\\": Post \\\"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s\\\": context deadline exceeded && cannot patch \\\"secrets\\\" with kind FederatedTypeConfig: Internal error occurred: failed calling webhook \\\"federatedtypeconfigs.core.kubefed.io\\\": Post \\\"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s\\\": context deadline exceeded && cannot patch \\\"serviceaccounts\\\" with kind FederatedTypeConfig: Internal error occurred: failed calling webhook \\\"federatedtypeconfigs.core.kubefed.io\\\": Post \\\"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s\\\": context deadline exceeded && cannot patch \\\"services\\\" with kind FederatedTypeConfig: Internal error occurred: failed calling webhook \\\"federatedtypeconfigs.core.kubefed.io\\\": Post \\\"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs?timeout=10s\\\": context deadline exceeded && cannot patch \\\"kubefed\\\" with kind KubeFedConfig: Internal error occurred: failed calling webhook \\\"kubefedconfigs.core.kubefed.io\\\": Post \\\"https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-kubefedconfig?timeout=10s\\\": context deadline exceeded\"], \"stdout\": \"\", \"stdout_lines\": []}",
"uuid": "45090cf4-d26b-4d5d-ba55-a66b44d5c50b"
}
******************************************************************************************************************************************************
单独起了一个busybox测试,访问不通。这一块不知道怎么处理。
$ kubectl exec -it busybox sh -nkube-federation-system
/ # curl https://kubefed-admission-webhook.kube-federation-system.svc:443/validate-federatedtypeconfigs
curl: (60) Cert verify failed: BADCERT_NOT_TRUSTED
More details here: https://curl.se/docs/sslcerts.html
curl failed to verify the legitimacy of the server and therefore could not
establish a secure connection to it. To learn more about this situation and