Sendmail treating non-local domains as local

Sendmail treating non-local domains as local

Post by Darren Colema » Wed, 24 Jul 2002 19:00:08



Hi,

I'm having massive problems configuring Sendmail.  First, some background:

I have Sendmail installed on a Linux box that is a webserver/DB server for
two sites.  Email for these two websites is handled by a completely
different (Windows NTMail) machine.

The problem I've got is that sendmail seems to think both domains are local


everything I can possibly think of - DNS, sendmail files, system files, etc.

Here is the output from: sendmail -d0.4 -bv root

Version 8.12.5
 Compiled with: DNSMAP LOG MATCHGECOS MIME7TO8 MIME8TO7 NAMED_BIND
                NETINET NETUNIX NEWDB PIPELINING SCANF USERDB XDEBUG
Canonical name: freetrawl.com
 UUCP nodename: freetrawl.com
        a.k.a.: [212.113.198.51]
        a.k.a.: [127.0.0.1]
        a.k.a.: freetrawl
        a.k.a.: localhost.localdomain
        a.k.a.: [212.113.198.52]
        a.k.a.: www.policyplus.com
        a.k.a.: [212.113.198.50]
        a.k.a.: willow.jpci.net
        a.k.a.: www.freetrawl.com

============ SYSTEM IDENTITY (after readcf) ============
      (short domain name) $w = freetrawl
  (canonical domain name) $j = freetrawl.com
         (subdomain name) $m = com
              (node name) $k = freetrawl.com
========================================================

root... deliverable: mailer local, user root

/etc/mail/local-host-names =
lists.policyplus.com

/etc/hosts =
# Do not remove the following line, or various programs
# that require network functionality will fail.
127.0.0.1               freetrawl localhost.localdomain localhost

/etc/mail/relay-domains =
lists.policyplus.com

/etc/mail/sendmail.mc =
divert(-1)
#
# PolicyPlus / FreeTrawl Sendmail configuration
# Created: 28/06/2001
# To compile into .cf:
#       m4 /etc/mail/sendmail.mc > /etc/sendmail.cf
#
divert(0)
include(`/usr/share/sendmail-cf/m4/cf.m4')

dnl **Globals**
VERSIONID(`PolicyPlus/FreeTrawl Sendmail')
OSTYPE(linux)dnl
DOMAIN(generic)dnl
#DAEMON_OPTIONS(`Name=lists.policyplus.com, Addr=212.113.198.52')
#DAEMON_OPTIONS(`Name=localhost.localdomain, Addr=127.0.0.1')

dnl **Defines**
define(`ALIAS_FILE', `/etc/aliases')dnl
define(`ALIAS_FILE', `/etc/majordomo.aliases')dnl
define(`STATUS_FILE', `/var/log/sendmail.st')dnl
#define(`confDOMAIN_NAME',`lists.policyplus.com')

dnl **Features**
dnl FEATURE(`smrsh',`/usr/sbin/smrsh')dnl
FEATURE(`mailertable',`hash -o /etc/mail/mailertable')dnl
FEATURE(`virtusertable',`hash -o /etc/mail/virtusertable')dnl
FEATURE(use_cw_file)dnl
FEATURE(use_ct_file)dnl
FEATURE(relay_hosts_only)dnl
FEATURE(access_db)dnl
FEATURE(blacklist_recipients)dnl

dnl **Mailers**
MAILER(local)dnl
MAILER(smtp)dnl

dnl **Trusted Users**
Tmajordomo

(The commented fields I have been messing about with to try and get it
working, to no avail)

In short, there is no reference to "freetrawl.com" and "policyplus.com" in
any of the Sendmail configuration files, so one presumes it is simply
picking this up from DNS because 212.113.198.51 and 212.113.198.52 are bound
to the machine (as its the webserver).

I have tried manually adding the correct SMTP server for the two domains in
mailertable as follows:

freetrawl.com     smtp:[mail.jpci.net]
policyplus.com    smtp:[mail.jpci.net]

..but this only seems to work - bizarrely - for some addresses at the


before.

Basically the only domain sendmail should consider to be local is
"lists.policyplus.com" (its also running Majordomo), and obviously the
various localhost permutations.  Everything else should be deemed foreign
and handled accordingly.

Can anyone give any assistance on this?

Regards,

Darren

 
 
 

Sendmail treating non-local domains as local

Post by Andrzej Fili » Wed, 24 Jul 2002 22:01:00



> I'm having massive problems configuring Sendmail.  First, some background:

> I have Sendmail installed on a Linux box that is a webserver/DB server for
> two sites.  Email for these two websites is handled by a completely
> different (Windows NTMail) machine.

> The problem I've got is that sendmail seems to think both domains are local


> everything I can possibly think of - DNS, sendmail files, system files, etc.

> Here is the output from: sendmail -d0.4 -bv root

> Version 8.12.5
> [...]

Sendmail adds automatically some names to list of local email domains ($=w).

To get effective list of local email domains use:
echo '$=w' | sendmail -bt

To stop sendmail from modifying $=w you specified set DontProbeInterfaces
option to true and specify local email domains yourself as described in
http://www.sendmail.org/faq/section4.html#4.5

*.mc file fix:
define(`confDONT_PROBE_INTERFACES',`True')

--

366A 5DD7 7707 379C 9251   32AE C948 0BD2 7D99 688A   expires: 2003-01-25
I may disagree with the following *random epigram* :
O imitators, you slavish herd!
                -- Quintus Horatius Flaccus (Horace)

 
 
 

Sendmail treating non-local domains as local

Post by Neil W Ricker » Wed, 24 Jul 2002 22:20:32



>I have Sendmail installed on a Linux box that is a webserver/DB server for
>two sites.  Email for these two websites is handled by a completely
>different (Windows NTMail) machine.
>The problem I've got is that sendmail seems to think both domains are local


>everything I can possibly think of - DNS, sendmail files, system files, etc.

Try setting DontProbeInterfaces=True
 
 
 

Sendmail treating non-local domains as local

Post by Darren Colema » Thu, 25 Jul 2002 00:45:01


Tried that, didn't do anything.

Doing a query on $w still showed all of the IPs (and resolved domains) bound
to the machine, even with DontProbeInterfaces set to true (ie.
"define(`confDONT_PROBE_INTERFACES',true)dnl").  In the end I've fixed the
problem by renaming the machine itself.

Not a great solution, but it'll do.

Daz




> >I have Sendmail installed on a Linux box that is a webserver/DB server
for
> >two sites.  Email for these two websites is handled by a completely
> >different (Windows NTMail) machine.

> >The problem I've got is that sendmail seems to think both domains are
local

or

amending
> >everything I can possibly think of - DNS, sendmail files, system files,
etc.

> Try setting DontProbeInterfaces=True

 
 
 

Sendmail treating non-local domains as local

Post by Weldon Whippl » Thu, 25 Jul 2002 01:58:19



> Tried that, didn't do anything.

> Doing a query on $w still showed all of the IPs (and resolved domains) bound
> to the machine, even with DontProbeInterfaces set to true (ie.
> "define(`confDONT_PROBE_INTERFACES',true)dnl").  In the end I've fixed the
> problem by renaming the machine itself.

There have been times when I have had to just rename the machine. I used
to object to it, but after thinking about it, decided it was no big
deal. With http virtual hosts, the "actual" name of a machine is
unimportant (and rarely needs to match any of the hosted domains).

I've often thought that a nice feature to add to sendmail would be a
list of domains/host names for sendmail to DELETE (unconditionally) from
$=w ... if present. That would have solved so many problems in the past
(which were all fixed by just renaming the box ...)

(Perhaps a more generic FEATURE would be a list of values to DELETE
(unconditionally) from a specified class. Now that would be cool ...)

Weldon Whipple

 
 
 

1. How to treat local and non-local mail separately?

How would I alter sendmail.cf so that any local mail delivery is immediately
attempted, but delivery to another machine is only attempted when the queue
is run?

Thanks in advance for your help. Please respond via e-mail.

Thanks,
Jason
--
Jason Saunders
Kempo Ju-Jitsu Coventry (UK) - email for details

2. How to get TrueType file name?

3. Forwarding non-local user to non-local domain?

4. FDD dirve letter change

5. Sendmail is processing non-local messages as local ones

6. scrolling controls on a form

7. Sendmail and distinction local/non-local

8. AAaargh.. conflict b/w Pana 7503b and Teac 532s

9. Sendmail treats local domain as remote

10. Mail to Local and Non-Local Hosts - Please Help

11. local/non-local delivery for email addresses with the same hostname

12. Ruleset for different addresses for local/non-local mail