-
Notifications
You must be signed in to change notification settings - Fork 4.9k
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
coredns unable to resolve external DNS (NXDOMAIN) #4167
Comments
Seems this is documented here https://github.com/coredns/coredns/blob/master/plugin/loop/README.md in the last section |
I have the same problem here. The systemd-resolved just stop working. |
Where were you seeing that? |
I accessed the minikube VM and tried to ping google.com, it didn't work, then I changed the file /etc/systemd/resolved.com and added the line below
restarted systemd-resolved and it came back to work |
Same result for me, I first noticed that deployments were unable to pull images. I sshed into the minikube VM and checked
Adding:
to |
I created this script that is a workaround for minikube #!/bin/bash
kubectl -n kube-system get configmap coredns -o yaml | sed 's/\/etc\/resolv.conf/8.8.8.8/gi' | kubectl apply -f -
PODNAMES=(`kubectl -n kube-system get pods -o jsonpath='{.items[*].metadata.name}'`)
for name in ${PODNAMES[@]}; do
if echo "$name" | grep -q 'coredns-'; then
kubectl -n kube-system delete pods "$name"
fi
done note: it deletes coredns pods. they will be automatically created again with the new dns configurations |
While this does fix things, if you do a minikube stop and start, the /etc/systemd/resolved.com gets reset to default and everything is broken again. Rinse/Repeat. |
tried to change DNS to 223.5.5.5 (aliyun dns), and restarted
|
Hello @rodjjo, I see your code is works for coredns. I have same problem with kube-dns. Should I just replace coredns -> kube-dns and use your script? |
Issues go stale after 90d of inactivity. If this issue is safe to close now please do so with Send feedback to sig-testing, kubernetes/test-infra and/or fejta. |
/remove-lifecycle stale |
I'm closing this as it was opened a really long time ago (a year), and wasn't reproducible for me given the same information on minikube v1.9.2:
If you are still seeing this, |
/reopen |
@ulan-yisaev: You can't reopen an issue/PR unless you authored it or you are a collaborator. In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
Having an issue with 1.0.0 where it cannot resolve external DNS entries, causing
cert-manager
to return errors as it cannot locate the domain to issue a certificate against.By editing the configmap for
coredns
and updating to useIt can then resolve externally
Minikube version
Operating System
Deployed
command
Updated
command
The text was updated successfully, but these errors were encountered: