Re: [Exim] MX + Exim = relay_host?

Top Page
Delete this message
Reply to this message
Author: James P. Roberts
Date:  
To: Pablo Fischer, exim-users
Subject: Re: [Exim] MX + Exim = relay_host?
200.67.177.209

> Hi all!
>
> First of all, Im using Debian Woody, for my mail server im using: exim
> and ipopd-ssl.
>
> Ok, I have a domain: pablo.com.mx
>
> 1. I set up in the DNS a MX called: pablo.com.mx, pablo.com.mx its
> pointing to an IP (my server), so to send a mail to a user of
> pablo.com.mx, I need to mail to user@???, right?. And if the MX
> is mail.pablo.com.mx I need to send mail to user@???,
> right?


No, you would send mail to whatever is on the left hand side of the DNS MX
record. The right hand side of the MX record should point to the FQDN of your
SMTP server. That server is then resposible for routing to the correct
destination for each user.

BUT...

You do not have an MX record for pablo.com.mx, there is only an A record
pointing to 200.67.177.209.

Side note: I've never seen ".mx" as a TLD before. Interesting.

You should have a DNS "MX" record which points to the FQDN of your SMTP
server, and also an A record to return the IP address of the FQDN (host) named
in the MX record. Remember that the DNS MX record for a domain must be a
FQDN, not an IP. There must be an associated A (or a valid CNAME, I think?)
for the FQDN listed in the MX record.

Thus, when sending email to, say, anyone@???, the DNS MX record for
"pablo.com.mx" should return the name of your SMTP server (for example,
"mail.pablo.com.mx"). The IP of that server is then looked up. (I note at
this point that this example is not correct for your case, since there is
currently no DNS record for "mail.pablo.com.mx"; thus, your last example above
could not work outside your local network).

>
> 2. In my localnetwork, I can send mails to users with my smtp server, In
> computer A, I can mail to user2@??? and user2 can check his
> mail and receive the mail that user1 sent to him.
>
> So, my mail server its working fine for my local network. But the
> problem cames here:
>
> Every time I send mail to user@???, from hotmail (for example)
> in my mainlog of exim, I get this:
>
> refused relay (sender & host_accept_relay) to <pablo@???> from
> <tzimiscemx@???> H=f81.law12.hotmail.com (hotmail.com)
> [64.4.19.81]
>
> So I thing its a bad configuration of my exim, cause IM GETTING THE
> MAIL.. but...?. I repeat, this also happens If an external ISP try to
> send mails to me.
>
> However, my exim.conf its in:
> http://pablo.com.mx/exim.conf
>
> I hope to solve my problem with your help, thanks!
>
> Pablo Fischer
> --
> Pablo Fischer <exilion@???>
>


Now, also interesting is that the IP of pablo.com.mx (200.67.177.209) has a
reverse DNS entry which points to dsl-200-67-177-209.prodigy.net.mx. Somehow,
I suspect that is not your server, but is probably the server that your ISP
provides for SMTP services?

If you send email to your server, from a remote location (such as hotmail), if
you tell it (in your email client configuration) to send directly to your
correct server IP address, but you are addressing the mail to "pablo.com.mx",
it will appear to be a relay THROUGH your server, rather than directed to a
user ON your server, because the DNS record for pablo.com.mx points to your
ISP's server. On the other hand, if (as I suspect without having looked) that
you have specified pablo.com.mx as a local_domain, that could explain the
local delivery, too?

Not an Exim code expert, so I ask the list, would this analysis explain
Pablo's symptoms? Could such erroneous DNS records result in both a rejected
relay attempt, AND a local delivery? (As I understand his description of the
symptoms). Again, I only checked DNS records, not his exim.conf.

Jim Roberts
Punster Productions, Inc.