Mark et. al. -

It *is* possible, though, for qmail-remote to move slowly enough that it
appears to hang (yes, even for hours or days).  timeoutremote applies to
every read() and write() - in the very worst case, each of these system
calls might move only a single byte.

Consider a 5000 byte message and a timeoutremote set to 1200 seconds (the
default).  The worst case just for sending the data alone - not including
smtp overhead and reading responses from the remote server - is almost 70
days (1200 * 5000 / 60 / 60 / 24 ~= 69.44).

Granted, this is extremely unlikely, but you get the idea - some scenarios
can cause qmail-remote to move extraordinarily slowly, while still
functioning "correctly" - that is, within the limits imposed by
timeoutremote.

IMO, the best thing to look at from the people having this problem would
be the output from whatever your system call tracing software is (ktrace
for FreeBSD, truss for Solaris, strace for Linux...), run on the offending
qmail-remote process.  If there is no output for over 'timeoutremote'
seconds, there's almost certainly a TCP stack bug; otherwise, I'd tend to
blame the problem described above.

Thanks,
David Lowe

On 7 Jun 2001, Mark wrote:

> >  What are the probabilities of the Sendmail server being the one causing
> > the problems? What if the mail admin of mg.hk5.outblaze.com has used
> > some sort of patch that is causing qmail-remote's to hang? Has anyone
> > communicated with outblaze.com's postmaster?
> 
> There is nothing a remote system can do that will hang qmail-remote on
> a correctly functioning OS. If the local TCP stack has accepted data
> and indicated available via the select() return, then the remote
> system has no further say as the read() only fetches the data
> previously received.
> 
> I'll bet it's an OS bug - most likely in the TCP stack. Eg, it may be
> that the local TCP stack - in some circumstance - discards unread
> data, *then* marks the local socket as unreadable, rather than around
> the other way. That sort of window would wedge the select/read
> sequence in qmail-remote.
> 
> 
> Regards.
> 








Reply via email to