Slow SMTP

keefe007

Verified User
Joined
Dec 25, 2004
Messages
276
I've noticed that SMTP has been extremely slow on my system for an unknown reason. When a user tries sending an email the message will sit in the outbox for roughly 60 seconds or so before being sent. I've also noticed this behavior in squirrelmail as well. Upon hitting send in squirrelmail the page will site on 'loading' for roughly 60 seconds before sending the message. Any ideas on why this is occurring? I should mention that this happens both when sending messages to email accounts on this server and other remote servers.
 
Sounds like a timeout issue. Check to see if the first nameserver listed in your /etc/resolv.conf file is working.

Jeff
 
The resolv.conf seems to look fine. The first two name servers point back to this server and the third is a public one.
 
Did you actually try it:
Code:
$ dig @localhost earthlink.net
and
Code:
$ dig @ip.num.ber.from.file earthlink.net

If either doesn't work, then that's the problem.

Jeff
 
Check your logs to see if exim is busy (tail the /var/log/exim/mainlog for a while), and check top to see if you're using a lot of swap memory.

Jeff
 
I did actually noticed that this is only occurring with emails sent to other accounts on this same server. When I send to an external account it goes through right away.
 
Last edited:
I don't know if this will help or not but what I've found is that it takes a really long time to even show the initial entry in the mainlog like so:

2007-05-28 23:56:06 1Hstkc-0008JR-1V <= [email protected] H=localhost (www.mydomain.com) [127.0.0.1] P=esmtp S=15204 [email protected] T="11111111111111111111111111111111111111111111111" from <[email protected]> for [email protected]

Once that first entry hits spamd scans the mails and it is completed in a second or two. What happens prior to this first entry?

When I send to an external address such as my gmail account that first entry shows up almost instantaneous.
 
Last edited:
Alright, using telnet I've been able to better narrow down where exactly the delay occurs.

The delay is occurring when I issue the RCPT TO:[email protected] command. The telnet window sits for a minute or so and finally says "250 Accepted." When sending a message to an external email address the "250 Accepted" comes up right away.

Any ideas?
 
Alright, so after going through the RCPT ACLs in the exim.conf file I realized that ordb.org was still being called for and that apparently they went under six months ago. I commented out the lines and now email is flowing much faster.

Now, jlasman, in this post you mention that the timeout should be 2 seconds. For some reason mine was almost a minute. Where is this setting stored?
 
I mean the resolver timeout if you're looking at a broken DNS server. I don't know why your resolver is waiting longer; what happens when you try:

Feel free to copy this exactly at a shell prompt and notice the difference between the two datestamps (67.112.189.216 is the address of a router without a dns server installed):
Code:
$ date ; dig @67.112.189.216 nobaloney.net ; date
On my desktop system the delay was 15 seconds. Later today I'll release a new version of SpamBlocker2 and pass it on to John. It'll have some better blocklist solutions.

Jeff
 
I'm going to try to get a new copy of SB2 released today. It won't just be plugin compatible; the references to example.com will still have to be changed. When I've got it ready I'll announce it in a new post on these forums and also let John know so DA can move it to their files server and announce it on the DA announcement mailing list.

Jeff
 
Back
Top