Pod无法访问coredns

下游集群信息

  • Kubernetes 版本: rke2 1.21.12
  • 操作系统: CentOS 8
  • 网络: 大部分节点的IP地址为172.16.40.xxx,有一个节点的IP地址为192.168.xxx.xxx。

问题描述:

安装Isitio,如果ingressgateway被安装在192.168.xxx.xxx的节点则安装失败并出现下列错误信息:

2022-05-13T12:54:03.837051Z     warn    sds     failed to warm certificate: failed to generate workload certificate: create certificate: rpc error: code = Unavailable desc = connection error: desc = "transport: Error while dialing dial tcp: lookup istiod.istio-system.svc on 10.43.0.10:53: read udp 10.42.4.3:45065->10.43.0.10:53: i/o timeout"
kubectl get svc -n kube-system
NAME                        TYPE        CLUSTER-IP    EXTERNAL-IP   PORT(S)         AGE
rke2-coredns-rke2-coredns   ClusterIP   10.43.0.10    <none>        53/UDP,53/TCP   116m
rke2-metrics-server         ClusterIP   10.43.37.48   <none>        443/TCP         115m

rke2-coredns-rke2-coredns的pod位于172.16.40.xxx的节点。如果ingressgateway被安装在172.16.40.xxx的节点,则一切正常。