[Exim] PSH flag problems

Top Page
Delete this message
Reply to this message
Author: John Dalbec
Date:  
To: Exim Users Mailing List
Subject: [Exim] PSH flag problems
On Linux (Red Hat kernel 2.4.9-31), exim 3.34 deadlocks when sending
SMTP messages of 1448 or 2896 bytes (including headers) to VM/ESA 2.4
SMTP. Exim uses the write() call to send SMTP DATA. If all packets in
the write() are of the maximum size, the Linux kernel does not set the
PUSH bit on the last packet. The VM/ESA TCP/IP stack buffers data up to
4096 bytes, so if only one or two packets are sent, the data never
reaches the SMTP application. Eventually the connection times out and
VM/ESA resets it.

Red Hat claims that the RFCs do not require it to send a PUSH bit on the
last packet of a write() to a socket. IBM seems to feel that the RFCs
do not require that the *receiving* TCP not buffer data indefinitely.
AFAICT they're both right. However (RFC 1122):

            An application program is logically required to set the PUSH
            flag in a SEND call whenever it needs to force delivery of
            the data to avoid a communication deadlock.  However, a TCP
            SHOULD send a maximum-sized segment whenever possible, to
            improve performance (see Section 4.2.3.4).


According to the man page, the results of write() to a special file are
not portable, so IMO exim should not assume that write() sends a PUSH
bit and should take additional steps to ensure that a PUSH bit is sent.

John