NIS domainname in $j

Situation:

On some LAN systems in our NIS environment, Sendmail will append the NIS domainname to unqualified destination hosts.

Problem:

Sendmail is populating $j--its fully-qualified domain name--with the NIS domainname since a fully-qualified DNS domain name is not listed in /etc/hosts.

Example:

A user or process will send mail to user@host instead of user@host.domain.com. If the fully-qualified domain name of the server is not listed in /etc/hosts, Sendmail may fully-qualify the recipient address as user@host.NIS_domainname.

Three solutions:

1. Add the FQDN to /etc/hosts. Send the Sendmail daemon a SIGHUP for changes to take effect.

2. Add define(`confDOMAIN_NAME', `FQDN')dnl to the Sendmail macro config (.mc) file. Build and install the Sendmail configuration file (.cf). Send the Sendmail daemon a SIGHUP for changes to take effect.

3. Manually change the Dj line in sendmail.cf to configure $j. Send the Sendmail daemon a SIGHUP for changes to take effect.

# my official domain name
# ... define this only if sendmail cannot automatically determine your domain
#Dj$w.Foo.COM
Djhost.domain.com

Back to brandonhutchinson.com.
Last modified: 04/24/2003