[leafnode-list] Re: hostname

James Cloos cloos+leafnode at jhcloos.com
Tue Aug 2 01:17:02 CEST 2011


It turns out that leafnode checks the output of gethostname(2) for a
fqdn before doing anything else, so the hostname in the config file
provides no help in avoiding that failure.

I don't have a good explanation for why the value reported by glibc's
implementation of gethostname(2) has changed on this box.  I've always
set the node name to an unqualified hostname, as doing otherwise causes
name lookups to check the request in the node name's domain name before
checking in ., which is a(n often painful) waste of time.

For now I kludged a fix in miscutil.c:whoami() to set the real hostname
before calling is_validfqdn().

Longer term leafnode needs to honour the hostname setting in the config file.

-JimC
-- 
James Cloos <cloos at jhcloos.com>         OpenPGP: 1024D/ED7DAEA6



More information about the leafnode-list mailing list