LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Email forwarding delay (https://www.linuxquestions.org/questions/linux-newbie-8/email-forwarding-delay-900796/)

okomba 09-02-2011 08:07 PM

Email forwarding delay
 
Hello.

I host a website on one server and have configured some email forwarders from that server to another one.

I am able to receive emails (emails send directly) on both servers without problem.

Problem I am facing is that email are being delayed when being forwarded from server 1 to server 2. The delay ranges from 1 hour to as long as 12 hours. What could be causing this?

I have read this article http://www.fastsecurecontactform.com...-email-delayed but it only talks about all emails being delayed. My problem is that only forwarded emails are delayed. All other emails are being received without problem.

Please help.

Thanks in advance.

Mugoma.

tbrand 09-02-2011 09:46 PM

Please provide more information. Answers to the following questions would be most helpful:

1) What e-mail software are you using (qmail? sendmail? postfix?)

2) Are the two servers on the same network?

3) Do you have your own DNS? If so, how is it configured?

4) Do you have access to the SMTP logs?


And any other relevant information you see fit.

okomba 09-02-2011 10:09 PM

Email forwarding delay
 
Hi,

1. Email software is: Exim 4.69
2. Servers on different networks, different data centers
3. DNS provided by the data centers. Have private name servers on both.
4. Have no access to SMTP logs.

This problem started about a four days ago. Otherwise email forwarding has been working for more than a year without a problem.

Thanks.

Mugoma.



Quote:

Originally Posted by tbrand (Post 4460114)
Please provide more information. Answers to the following questions would be most helpful:

1) What e-mail software are you using (qmail? sendmail? postfix?)

2) Are the two servers on the same network?

3) Do you have your own DNS? If so, how is it configured?

4) Do you have access to the SMTP logs?


And any other relevant information you see fit.


tbrand 09-02-2011 10:30 PM

I'm not familiar with Exim but from my experience these type of delays (a couple of hours) are usually caused by problems with DNS queries regardless of the type of e-mail server. (I'm assuming that server 2 is always up since it is under your control).

You may find utilities ``dig'' or ``nslookup'' useful to try to narrow down which DNS queries are being delayed. My bet would be that the delays are caused by reverse lookup DNS queries on server 1. But don't let that limit your investigation it is just a guess.

If the delays are not caused by DNS queries but by SMTP related problems you will have to get access to the content of the SMTP logs, somehow.

okomba 09-03-2011 03:25 AM

Hi,

I am not sure whether it's DNS. An email send from server 1 (to server 2) is received at server 2 instantly. An email send from server 2 (to server 1) is received at server 1 instantly.

It's only email forwarding that has problem. BY 'email forwarding' I mean an email send to a mailbox at server 1 is copied (forwarded) automatically to another a mailbox at server 2.

The original email is received without problem. Problem is with the forwarded ('copied') email. This is delayed for hours.

Thanks.

Mugoma.

tbrand 09-03-2011 08:47 AM

Hi Mugoma,

you make a fair point but I still suspect DNS. I'm assuming that server 1 is configured to RELAY e-mails addressed to the server 2 domain. As I said, I'm not familiar with Exim specifically but I suspect DNS exactly because your servers can receive e-mails without a problem. From my experience with other e-mail servers I come to the conclusion as follows:

You experience delays, not failures. That means that server 1, when it attempts to RELAY an e-mail to server 2, is seeing errors that it considers temporary and places the e-mails on the deferral queue to be sent later rather than rejecting them outright.

Temporary errors can be roughly divided into three types:

1) temporary SMTP errors (e.g. mailbox full)

2) SMTP connection dropped or timed out, for example, because server 2 is too busy

3) temporary inability to make an SMTP connection

I consider 1) and 2) less likely because you would probably already know about those problems even though it would still be very useful for you to have access to the SMTP logs to be able to rule out those problems (and many others) with confidence.

That makes problems of type 3) the most likely reasons for your delays. Type 3) problems could also be caused by some very severe network problems but, again, I'm sure you would be already aware of them.

When an e-mail server is asked to RELAY an e-mail, it does more than just receive it and send it. Since RELAY is frequently abused by spammers the e-mail server performs various checks on the originating domain and that involves making DNS queries (it may also perform a black list check but that would result in permanent failures not delays).

Those DNS queries may be failing because of DNS misconfiguration, overloaded DNS servers or because the e-mail server is unable to handle some results of those queries.

If the query failures are due to some internal problem with the e-mail server (some servers have a problem handling results of the ANY queries) you will, again, need access to the SMTP logs to prove it.

If the query failures are due to the DNS server themselves you should be able to duplicate it using the ``dig'' or ``nslookup'' tools running on server 1.

okomba 09-03-2011 09:17 AM

Hi,

I don't have much knowledge on how SMTP routing works. I assumed that a mail server will handle an email meant for forwarding the same way it handles an email meant for direct delivery.

I thought it's something I could figure out without involving administrator on server 1. But looks I will have to forward the issue there.

Thanks a lot for your assistance.

Best regards,

Mugoma.


All times are GMT -5. The time now is 07:55 AM.