I have a small isolated group of servers. I don't want to set up DNS
infrastructure for this.
I have an /etc/hosts file that looks like:
<snip>
127.0.0.1 localhost.localdomain localhost
192.168.50.70 tec-puppet.tec.cwa.co.nz tec-puppet
</snip>
I can ping tec-puppet fine:
root@tec-lb1:/etc# ping tec-puppet
PING tec-puppet.tec.cwa.co.nz (192.168.50.70) 56(84) bytes of data.
64 bytes from tec-puppet.tec.cwa.co.nz (192.168.50.70): icmp_seq=1 ttl=64
time=0.077 ms
I can ping the FQDN just fine:
root@tec-lb1:/etc# ping tec-puppet.tec.cwa.co.nz
PING tec-puppet.tec.cwa.co.nz (192.168.50.70) 56(84) bytes of data.
64 bytes from tec-puppet.tec.cwa.co.nz (192.168.50.70): icmp_seq=1 ttl=64
time=0.068 ms
I have this in /etc/puppet/puppet.conf:
<snip>
[puppetd]
server=tec-puppet.tec.cwa.co.nz
runinterval=300
</snip>
I have this in /etc/nsswitch.conf:
<snip>
hosts: files
networks: files
</snip>
and this in /etc/host.conf:
<snip>
order hosts
</snip>
They do have an /etc/resolv.conf file and they should (and normally do) use
DNS for queries outside their little world; I just made these nsswitch.conf
and host.conf refer exclusively to /etc/hosts files in order to prove that
something seems to be ignoring the resolver library configuration.
When I run puppetd -vt I get:
<quote>
dnsdomainname: Unknown host
</quote>
something seems wrong...
This is all running under Debian Lenny.
root@tec-lb1:/etc# puppetd --version
dnsdomainname: Unknown host
0.24.5
So.. from the 'dnsdomainname' ref there, it would seem to my untrained eye
that despite my best efforts in nsswitch.conf and host.conf, puppet is
trying DNS anyway...?
--
Please remember that an email is just like a postcard; it is not
confidential nor private nor secure and can be read by many other people
than the intended recipient. A postcard can be read by anyone at the mail
sorting office and expecting what is written on it to be private and secret
is not realistic. Please hold no higher expectation of email.
If you need to send confidential information in an email you need to use
encryption. PGP is Pretty good for this.
I just got the lenny-backport package.
Same problem:
root@tec-lb1:/etc/apt# puppetd --version
dnsdomainname: Unknown host
0.24.8
Ah well
It turned out that although the message was displaying on the *client* it
was coming from the *server*.
The server had a slightly incorrect /etc/hosts file.