I'm investigating how exim deliver mails, and I came to the conclusion that when the server is going to send a email exim makes a nslookup and get the higher priority (lower value) MX record and tries to send the mail to the asigned address.I have my own domain and I always had my MX records pointing to outlook's SMTP, today I tried to add an MX record with higher priority pointing to my vps, I sent an email to that domain and I received it at my vps instead of at outlook, as I expected, alright.Then I stopped exim service in my vps, expecting that when I send the mail (from another vps) it would nslookup for the next MX record with higher priority, and I would receive that mail at outlook, and exactly, I did, alright.Then I started the exim service again, I sent another mail expecting that I would receive it at my vps, just like it did before, but no, I got it at outlook instead, even when my vps has higher priority, like if the sender vps would have blacklisted it since it failed because I stopped exim service, it didn't even tried to send it (according to /var/log/exim/mainlog), the nslookup directly returned the outlook MX record.So... has the exim service in sender vps blacklisted that mx record or something? In that case, how can I reverse it?Is there any way to receive mails in 2 servers? (my vps and outlook), I don't want to forward it, instead, I want the sender to send mails to 2+ servers with same mail address. (I think is not possible, but who knows?)UPDATE: I sent another mail and now I got it at my vps, but my question still up, and, in case it's blacklisted for many minutes... could I configure it?What happens if I set two or more MX Records with same priority? I tested it and I received the email at outlook, why? what is the procedure?
Exim dnslookup, priority and blacklist (not really blacklist)
smtp;exim;priority
Answering individual questions inline, but please keep in mind that Stack Exchange works best when you ask only one question per question.Then I started the exim service again, I sent another mail expecting that I would receive it at my vps, just like it did before, but no, I got it at outlook instead, even when my vps has higher priority, like if the sender vps would have blacklisted it since it failed because I stopped exim service, it didn't even tried to send it (according to /var/log/exim/mainlog), the nslookup directly returned the outlook MX record.So... has the exim service in sender vps blacklisted that mx record or something? In that case, how can I reverse it?The SMTP client is possibly caching (but not permanently blacklisting) the fact that an MX it previously attempted to use is not available. SMTP clients are free to do that. From the client's perspective, it can consider the responsibility for delivering the mail to be handed off as long as any one of the MXes for the target domain has accepted it.The target domain has expressed a preference for which MX should ideally receive the messages using MX priorities, but clients are not guaranteed to respect that. As the operator of a domain, you should take steps to make sure that the mail is ultimately delivered correctly no matter which one of your MX servers accepts it. This might be done with store-and-forward, or by having all MXes configured with the ability to access the same shared mail spool, or anything you want, really.Is there any way to receive mails in 2 servers?No. The SMTP client's responsibility is to deliver the mail to one MX. If you need the mail delivered to multiple places, then your MXes should fork it into multiple copies upon receipt and deliver each copy to the next hop.What happens if I set two or more MX Records with same priority?The SMTP clients are expected to treat the MXes as having equal priority. They may round-robin between them, load-balance between them, or just choose one at random from the list. The result is more or less the same as if you have a single MX but that MX has multiple A and/or AAAA records.