Probe Network Interfaces
After the canonical name, and any other names for the
local machine, have been placed in $=w
,
sendmail then searches
(probes) all the network interfaces to find any
additional names and addresses that might also need
to be added to $=w
. But note that if the DontProbeInterfaces
option (DontProbeInterfaces on
page 1023) is defined as true, this additional step
is skipped. Note also that if the DontProbeInterfaces
option is defined as the literal value localhost
, only the
loopback interface is
skipped, and all the other network interfaces are
included.
The list of network interfaces is obtained from your kernel using a system call appropriate for your operating system. The kernel generally returns a list composed of interface and IP address pairs. If you defined NETINET6 (NET... on page 126) when compiling, the list might contain IPv6 addresses. If you defined NETINET (NET... on page 126) when compiling, the list might contain IPv4 addresses.
For each address that is found, sendmail performs a reverse lookup using gethostbyaddr(3) or getipnodebyaddr(3). Each lookup (if successful) will return the hostname associated with the address.
Each address and hostname is appended to the class
$=w
. The names
and addresses added can be viewed with the -d0.4
debugging
command-line switch (-d0.4 on page
542), which also allows errors in this process to be
printed.
Get sendmail, 4th Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.