Glenn English <g...@slsware.net> writes: > 'hostname -f' isn't rocket science -- it's just a small lookup. I > suspect it goes to ifconfig for the IP then in hosts for the FQDN that > matches the IP, or, apparently, resolv.conf and hostname.
You shouldn't suspect, it's in the Fine Manual. It calls into the C library name/address resolution functions, so it uses whatever is configured in nsswitch.conf; that means /etc/hosts first on a default install. No need to call in an external resolver for that. Mart -- "We will need a longer wall when the revolution comes." --- AJS, quoting an uncertain source.