EN :
I have a problem concerning DNS, I set up a GLUE record at OVH and set up the DNS config as specified in the docs.
However, when I ping google.com on my server, I get this output (let’s say my domain is mydomain.tld and my public ip is 0.0.0.0):
$ ping google.com
PING google.com.mydomain.tld (0.0.0.0) 56(84) bytes of data.
64 bytes from 0.0.0.0: icmp_seq=1 ttl=64 time=0.033 ms
As I’m a total noob about DNS configuration (I mean, I never set up a local DNS server), any help would be greatly appreciated.
FR :
J’ai un problème à propos de la configuration DNS, j’ai mis en place un GLUE record chez OVH et modifié la config DHCP comme expliqué dans la doc.
Maintenant, quand je ping google.com sur mon serveur, j’ai cette sortie (disons que mon domaine est mydomain.tld et mon ip public 0.0.0.0):
$ ping google.com
PING google.com.mydomain.tld (0.0.0.0) 56(84) bytes of data.
64 bytes from 0.0.0.0: icmp_seq=1 ttl=64 time=0.033 ms
Comme je suis un gros noob en ce qui concerne la config des DNS (je comprend le bousin, par contre je n’ai jamais déployé de DNS en local), toute aide serait la bienvenue…
I’m also quite noob with DNS, but I would naively think you configured some other service on your server which is messing up the dns resolution (maybe Bind ?) ?
Be careful that there is a difference between a) Having a DNS record somewhere so that your domain name points to your ip address (which I guess is what you want), and b) Running your own DNS server/resolver (which I guess you ain’t interested in ?). For a) to work, you should only have to configure your glue record on OVH and that should do it. You can check that it’s working by trying host domain.tld on a linux machine, or a ping does the job also.
OK, I finally found the problem, dnsmasq wasn’t reading /etc/resolv.conf as it was supposed to.
Adding following line to /etc/dnsmasq.conf solved the problem
For people experiencing same issue, here are an excerpt from my /etc/dnsmasq.conf and from /etc/dhcp/dhclient (I just removed commented lines, you should keep them). These edits saved my life.
/etc/dnsmasq.conf :
domain-needed
resolv-file=/etc/resolv.conf
interface=eth0
interface=tun0 #also listen for openvpn connections
listen-address=127.0.0.1
listen-address=10.8.0.1 #also listen for openvpn connections
cache-size=150
log-queries
log-facility=/var/log/dnsmasq.log #for debuging purpose only
/etc/dhcp/dhclient important lines are marked with ###important!!! :