I'm not sure if anyone with the relevant expertise will see these but having a go.
I've set up pdnsd on a machine in my LAN (a machine called tiny-tim running Debian Jessie) to act as a DNS cache. It works pretty well, but there's one aspect of the config I can't get right.
In /etc/pdnsd.conf I've set global -> server_ip = eth0 so that the machine responds to DNS requests that arrive at its port 53. The default file also has a section like this:
The problem is that /etc/hosts says
For an "internal" cache this makes sense, as it resolves the hostname (tiny-tim.home) to the loopback.
The problem for me is if I ask it to resolve tiny-tim.home from another machine it gives me 127.0.1.1, which is obviously wrong as it should give me 192.168.1.122 in my particular case.
This must be a common problem but I can't work out the best fix. If I comment out that source block then the machine can no longer resolve its own hostname other than to 192.168.1.122, which works for my other machines but will that confuse anything "internally"? I really want it to resolve 127.x.x.x for request originating from itself and 192.168.1.122 otherwise.
I've set up pdnsd on a machine in my LAN (a machine called tiny-tim running Debian Jessie) to act as a DNS cache. It works pretty well, but there's one aspect of the config I can't get right.
In /etc/pdnsd.conf I've set global -> server_ip = eth0 so that the machine responds to DNS requests that arrive at its port 53. The default file also has a section like this:
Code:
source {
owner=localhost;
file="/etc/hosts";
}
Code:
127.0.0.1 localhost
127.0.1.1 tiny-tim.home tiny-tim
The problem for me is if I ask it to resolve tiny-tim.home from another machine it gives me 127.0.1.1, which is obviously wrong as it should give me 192.168.1.122 in my particular case.
This must be a common problem but I can't work out the best fix. If I comment out that source block then the machine can no longer resolve its own hostname other than to 192.168.1.122, which works for my other machines but will that confuse anything "internally"? I really want it to resolve 127.x.x.x for request originating from itself and 192.168.1.122 otherwise.