<p>We're having a medium sized Kubernetes cluster. So imagine a situation where approximately 70 pods are being connecting to a one socket server. It works fine most of the time, however, from time to time one or two pods just fail to resolve k8s DNS, and it times out with the following error:</p>
<pre><code>Error: dial tcp: lookup thishost.production.svc.cluster.local on 10.32.0.10:53: read udp 100.65.63.202:36638-&gt;100.64.209.61:53: i/o timeout at
</code></pre>
<p>What we noticed is that this is not the only service that's failing intermittently. Other services experience that from time to time. We used to ignore it, since it was very random and rate, however in the above case that is very noticeable. The only solution is to actually kill the faulty pod. (Restarting doesn't help)</p>
<p>Has anyone experienced this? Do you have any tips on how to debug it/ fix?</p>
<p>It almost feels as if it's beyond our expertise and is fully related to the internals of the DNS resolver.</p>
<p>Kubernetes version: 1.23.4
Container Network: cilium</p>

user3677173
<p>this issue most probably will be related to the CNI.
I would suggest following the link to debug the issue:
<a href="https://kubernetes.io/docs/tasks/administer-cluster/dns-debugging-resolution/" rel="nofollow noreferrer">https://kubernetes.io/docs/tasks/administer-cluster/dns-debugging-resolution/</a></p>
<p>and to be able to help you we need more information:</p>
<ol>
<li><p>is this cluster on-premise or cloud?</p>
</li>
<li><p>what are you using for CNI?</p>
</li>
<li><p>how many nodes are running and are they all in the same subnet? if yes, dose they have other interfaces?</p>
</li>
<li><p>share the below command result.</p>
<p>kubectl get pods --namespace=kube-system -l k8s-app=kube-dns -o wide</p>
</li>
<li><p>when you restart the pod to solve the issue temp does it stay on the same node or does it change?</p>
</li>
</ol>
