Sidestep Slow Hosts

A slow host is one that requires more than a few seconds to accept delivery of a modestly sized email message. To illustrate, consider the following example produced by a verbose transaction of sending email to such a slow host:

% /usr/sbin/sendmail -v -Rslowhost.com -q
Running /var/spool/mqueues/q.2/df/f0DHnvO02567 (sequence 1 of 1)
bob@slowhost.com... Connecting to mx.slowhost.com. via esmtp...
220 mx.slowhost.com ESMTP Sendmail 8.10.1/8.10.1; Fri, 13 Dec 2002 10:50:20 -0700 
(MST)
>>> EHLO mx.slowhost.com
250-mx.slowhost.com Hello you@yourhost.com [123.45.678.9], pleased to meet you
250-ENHANCEDSTATUSCODES
250-8BITMIME
250-SIZE
250-DSN
250-ONEX
250-ETRN
250-XUSR
250 HELP
>>> MAIL From:<you@yourhost.com> SIZE=16
...
You wait 2 minutes for slowhost to look you up.
...

This situation can get worse, especially if the slow site runs slow antispam software, because that site can take 9 or 10 minutes to validate you. This can cause sendmail to seem to hang for 9 or 10 minutes, then suddenly to continue with:

250 2.1.0 <you@yourhost.com>... Sender ok
>>> RCPT To:<bob@slowhost.com>
250 2.1.5 <bob@slowhost.com>... Recipient ok
>>> DATA
354 Enter mail, end with "." on a line by itself
>>> .

Furthermore, some mail transfer agents (MTAs) start to place a message on disk only after all the data has been received, so writing to an NFS-mounted disk can appear to hang for several seconds:

250 2.0.0 f0DHoNh91321 Message accepted for delivery bob@slowhost.com... Sent (f0DHoNh91321 ...

Get Sendmail, 3rd Edition now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.