我正在使用具有以下三个节点的自我管理的裸机kubernetes集群:
NAME STATUS ROLES AGE VERSION
ruby0 Ready master 17h v1.18.5
ruby1 Ready <none> 17h v1.18.5
ruby2 Ready <none> 17h v1.18.5
它们托管在具有以下内核(uname -a
)的三个相同的debian系统上:
Linux ruby0 4.19.0-9-amd64 #1 SMP Debian 4.19.118-2+deb10u1 (2020-06-07) x86_64 GNU/Linux
要设置节点,请遵循Imixs-Cloud的基本安装指南。如本教程中所述,我已经部署了Pod网络flannel。我完成了traefik入口控制器的部署,完成了安装过程,其说明here。为了简单起见,我省略了011-persistencevolume.yaml。
之后,我得到了以下traefik服务和pod(以及部署和副本集):
NAMESPACE NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE
kube-system service/traefik LoadBalancer 10.110.149.28 192.168.10.127 80:31298/TCP,443:32383/TCP,8100:31372/TCP 68m
NAMESPACE NAME READY STATUS RESTARTS AGE
kube-system pod/traefik-b9b444b89-w9b6h 1/1 Running 0 68m
当尝试通过浏览器或curl在给定端口之一上访问traefik服务时,出现超时错误,但没有响应。给定的traefik窗格显示了以下错误:
Trace[1402685037]: [30.000537725s] [30.000537725s] END
E0707 08:08:49.147428 1 reflector.go:153] pkg/mod/k8s.io/client-go@v0.17.3/tools/cache/reflector.go:105: Failed to list *v1.Service: Get "https://10.96.0.1:443/api/v1/services?limit=500&resourceVersion=0": dial tcp 10.96.0.1:443: i/o timeout
I0707 08:08:49.148535 1 trace.go:116] Trace[84373527]: "Reflector ListAndWatch" name:pkg/mod/k8s.io/client-go@v0.17.3/tools/cache/reflector.go:105 (started: 2020-07-07 08:08:19.148006738 +0000 UTC m=+4340.222316899) (total time: 30.000486829s):
Trace[84373527]: [30.000486829s] [30.000486829s] END
E0707 08:08:49.148560 1 reflector.go:153] pkg/mod/k8s.io/client-go@v0.17.3/tools/cache/reflector.go:105: Failed to list *v1.Secret: Get "https://10.96.0.1:443/api/v1/secrets?limit=500&resourceVersion=0": dial tcp 10.96.0.1:443: i/o timeout
I0707 08:08:49.149667 1 trace.go:116] Trace[1117097236]: "Reflector ListAndWatch" name:pkg/mod/k8s.io/client-go@v0.17.3/tools/cache/reflector.go:105 (started: 2020-07-07 08:08:19.149071171 +0000 UTC m=+4340.223381353) (total time: 30.000553113s):
Trace[1117097236]: [30.000553113s] [30.000553113s] END
E0707 08:08:49.149693 1 reflector.go:153] pkg/mod/k8s.io/client-go@v0.17.3/tools/cache/reflector.go:105: Failed to list *v1.Endpoints: Get "https://10.96.0.1:443/api/v1/endpoints?limit=500&resourceVersion=0": dial tcp 10.96.0.1:443: i/o timeout
I0707 08:08:49.150743 1 trace.go:116] Trace[1553411795]: "Reflector ListAndWatch" name:pkg/mod/k8s.io/client-go@v0.17.3/tools/cache/reflector.go:105 (started: 2020-07-07 08:08:19.150285239 +0000 UTC m=+4340.224595418) (total time: 30.000416845s):
Trace[1553411795]: [30.000416845s] [30.000416845s] END
E0707 08:08:49.150770 1 reflector.go:153] pkg/mod/k8s.io/client-go@v0.17.3/tools/cache/reflector.go:105: Failed to list *v1alpha1.TraefikService: Get "https://10.96.0.1:443/apis/traefik.containo.us/v1alpha1/traefikservices?limit=500&resourceVersion=0": dial tcp 10.96.0.1:443: i/o timeout
10.244.1.1 - - [07/Jul/2020:08:08:53 +0000] "GET /ping HTTP/1.1" 200 2 "-" "-" 873 "ping@internal" "-" 0ms
10.244.1.1 - - [07/Jul/2020:08:08:56 +0000] "GET /ping HTTP/1.1" 200 2 "-" "-" 874 "ping@internal" "-" 0ms
10.244.1.1 - - [07/Jul/2020:08:09:03 +0000] "GET /ping HTTP/1.1" 200 2 "-" "-" 875 "ping@internal" "-" 0ms
10.244.1.1 - - [07/Jul/2020:08:09:06 +0000] "GET /ping HTTP/1.1" 200 2 "-" "-" 876 "ping@internal" "-" 0ms
由于某些原因,traefik无法访问kubernetes API:
NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE
service/kubernetes ClusterIP 10.96.0.1 <none> 443/TCP 18h
例如,当我安装MetalLB并尝试通过kubernetes API访问configmap时,我已经在群集上看到了这种行为。