John Peacock wrote:
However, when I originally surveyed the contents of the tmp/ directory, there were files there with a variety of dates and times, some in the middle of the night, when I would normally not be restarting qpsmtpd. So there is some uncommon failure path which we are not seeing, where the spool file is not being deleted.

I may have found a possible cause of the phantom spool files. I've got two files in my spool dir that are partial (headers only and clearly the same message being retried) and I see this in the log:

@4000000043e129212a22ef14 15590 spooling message to disk
@4000000043e12b220342117c 15590 max_size: 0 / size: 4197
@4000000043e12b2203425f9c 15590 trying to get config for me
@4000000043e12b220342770c 15590 451 Incomplete DATA

In Qpsmtpd::SMTP::data(), there are these lines:

  # if we get here without seeing a terminator, the connection is
  # probably dead.
  $self->respond(451, "Incomplete DATA"), return 1 unless $complete;

Now, if the remote server *is* gone, that respond() isn't going to go anywhere (indeed it should generate a $SIG{PIPE} if I'm not mistaken). Should we be doing:

        $SIG{PIPE} = 'IGNORE';

or something? It appears that the alarm is never firing, since I'm not seeing a "Connection Timed Out" in the logs.

Thoughts?

John

Reply via email to