How To - SMTP Relay from Subnet

In a testing lab environment, we have a LAN setup without external connectivity / services. We wanted to create monitoring / alerts that would email users about various conditions. Option 1 was to deploy a system that "straddled" the networks. Option 2 was to use an existing internal host with sendmail and open a port in the firewall. Using a static route, I was able to force a connection to the internal mail server through the specific rule in the firewall. The trickier part was the sendmail configuration.

The test network only had local zone DNS. I created an entry in the mailertable for my email domain to route to the IP specified in my static route. However messages just hung...

p3KH3f7X004338*      58 Wed Apr 20 13:04 
                 (host map: lookup ( deferred)

While I new DNS would bomb for, my mailertable entry should have forwarded that domain to a specific IP. The following seemed to indicate it should work:

[root@localhost root]# sendmail -d60.5 -bv
map_lookup(dequote, localuser, %0=localuser) => NOT FOUND (0)
map_lookup(host,, => NOT FOUND (75)
map_lookup(host, tempfail: errno=0
map_lookup(mailertable,, => smtp:[XXX.XXX.XXX.XXX] (0) deliverable: mailer smtp, host [XXX.XXX.XXX.XXX], user

Eventually I ended up adding "FEATURE(`nocanonify')" to my file and that did the trick. Not entirely sure why that worked or how it may affect an existing sendmail server... but I am happy at the moment.