Ok.. after searching through the logs for a bit, I have discovered the
following about some of the messages getting stuck in the queue..

This is the method I used to do this test, if it's wrong tell me, but
this is what I did.  First off I ran:

[root@mail qmail]# ps ax | grep qmail-remote | wc -l
     35

Not a problem.  So now I run: 
[root@mail qmail]# ps ax | grep qmail-remote
1822 ?        S      0:00 qmail-remote mindspring.com
[EMAIL PROTECTED] [EMAIL PROTECTED]
1826 ?        S      0:00 qmail-remote mindspring.com
[EMAIL PROTECTED]    [EMAIL PROTECTED]
1827 ?        S      0:00 qmail-remote mindspring.com
[EMAIL PROTECTED]    [EMAIL PROTECTED]
1833 ?        S      0:00 qmail-remote mindspring.com
[EMAIL PROTECTED]   [EMAIL PROTECTED]
1834 ?        S      0:00 qmail-remote mindspring.com
[EMAIL PROTECTED]   [EMAIL PROTECTED]
1836 ?        S      0:00 qmail-remote mindspring.com
[EMAIL PROTECTED]  [EMAIL PROTECTED]
1838 ?        S      0:00 qmail-remote mindspring.com
[EMAIL PROTECTED]    [EMAIL PROTECTED]
1839 ?        S      0:00 qmail-remote msn.com [EMAIL PROTECTED]
[EMAIL PROTECTED]
1841 ?        S      0:00 qmail-remote msn.com  [EMAIL PROTECTED]
1842 ?        S      0:00 qmail-remote mindspring.com mcculley@in-
prepaid.com [EMAIL PROTECTED]
1843 ?        S      0:00 qmail-remote mindspring.com
[EMAIL PROTECTED]    [EMAIL PROTECTED]
1844 ?        S      0:00 qmail-remote mindspring.com [EMAIL PROTECTED]
[EMAIL PROTECTED]
1846 ?        S      0:00 qmail-remote mindspring.com
[EMAIL PROTECTED]    [EMAIL PROTECTED]
1847 ?        S      0:00 qmail-remote mindspring.com
[EMAIL PROTECTED] [EMAIL PROTECTED]
1848 ?        S      0:00 qmail-remote microsoft.com  [EMAIL PROTECTED]
1850 ?        S      0:00 qmail-remote mindspring.com
[EMAIL PROTECTED]    [EMAIL PROTECTED]
1851 ?        S      0:00 qmail-remote mindspring.com
[EMAIL PROTECTED]
1852 ?        S      0:00 qmail-remote mindspring.com
[EMAIL PROTECTED]    [EMAIL PROTECTED]
1854 ?        S      0:00 qmail-remote mindspring.com
[EMAIL PROTECTED]    [EMAIL PROTECTED]
1855 ?        S      0:00 qmail-remote msn.com [EMAIL PROTECTED]
[EMAIL PROTECTED]
1856 ?        S      0:00 qmail-remote mindspring.com
[EMAIL PROTECTED]    [EMAIL PROTECTED]
1858 ?        S      0:00 qmail-remote mindspring.com
[EMAIL PROTECTED]    [EMAIL PROTECTED]
1859 ?        S      0:00 qmail-remote mindspring.com mcculley@in-
prepaid.com [EMAIL PROTECTED]
1860 ?        S      0:00 qmail-remote mindspring.com
[EMAIL PROTECTED]    [EMAIL PROTECTED]
1861 ?        S      0:00 qmail-remote mindspring.com
[EMAIL PROTECTED]   [EMAIL PROTECTED]
1862 ?        S      0:00 qmail-remote mindspring.com
[EMAIL PROTECTED]   [EMAIL PROTECTED]
1863 ?        S      0:00 qmail-remote mindspring.com
[EMAIL PROTECTED] [EMAIL PROTECTED]
1864 ?        S      0:00 qmail-remote mindspring.com
[EMAIL PROTECTED]    [EMAIL PROTECTED]
1865 ?        S      0:00 qmail-remote mindspring.com
[EMAIL PROTECTED]
1866 ?        S      0:00 qmail-remote mindspring.com [EMAIL PROTECTED]
[EMAIL PROTECTED]
1868 ?        S      0:00 qmail-remote mindspring.com
[EMAIL PROTECTED]    [EMAIL PROTECTED]
1869 ?        S      0:00 qmail-remote mindspring.com
[EMAIL PROTECTED]    [EMAIL PROTECTED]
1870 ?        S      0:00 qmail-remote mindspring.com
[EMAIL PROTECTED]   [EMAIL PROTECTED]
1871 ?        S      0:00 qmail-remote mindspring.com [EMAIL PROTECTED]
[EMAIL PROTECTED]
1872 ?        S      0:00 qmail-remote mindspring.com
[EMAIL PROTECTED]   [EMAIL PROTECTED]
[root@mail qmail]#

Nothing to weird here except all of the connections to mindspring.com.
So I go and do a mailq and look up the message id numbers.  Then I go
do:

[root@mail send]# grep 112603 * | /usr/local/bin/tai64nlocal
2001-08-08 17:42:58.097835500.s:@400000003b71ba7b2578952c starting
delivery        38: msg 112603 to remote [EMAIL PROTECTED]
2001-08-08 20:42:43.879282500.s:@400000003b71d96719f67df4 starting
delivery        44: msg 112603 to remote [EMAIL PROTECTED]
2001-08-08 20:42:43.879282500.s:@400000003b71dec231dccf04 starting
delivery        129: msg 112603 to remote [EMAIL PROTECTED]
2001-08-09 10:17:31.319774500.s:@400000003b72a32e0b08b30c starting
delivery        26: msg 112603 to remote [EMAIL PROTECTED]
2001-08-09 13:41:28.533103500.s:@400000003b72c36a2839ff1c starting
delivery        366: msg 112603 to remote [EMAIL PROTECTED]
[root@mail send]#

Ok.. so as someone pointed out I have to now search by the deliver
number.. So I ran:

[root@mail send]# grep "delivery 366" * | /usr/local/bin/tai64nlocal
2001-08-09 13:41:28.533103500.s:@400000003b72c36a2839ff1c starting
delivery        366: msg 112603 to remote [EMAIL PROTECTED]
[root@mail send]#

Ok.. so the last attempt started at 1:41PM..
So what happened to the one before it?

[root@mail send]# grep "delivery 26:" * | /usr/local/bin/tai64nlocal
2001-08-09 10:17:31.319774500.s:@400000003b72a32e0b08b30c starting
delivery        26: msg 112603 to remote [EMAIL PROTECTED]
2001-08-09 13:41:28.533103500.s:@400000003b72c33a3620be2c delivery 26:
deferral: qmail-remote_crashed./
[root@mail send]#

Ok.. so qmail-remote crashed.. but why?
It had also been running for over 3 hours?

Well to test it out I did the following:

[root@mail qmail]# telnet mx09.mindspring.com 25
Trying 207.69.200.36...
Connected to mx09.mindspring.com.
Escape character is '^]'.
220 pickering.mail.mindspring.net EL_3_4_0 /EL_3_4_0  ESMTP Earthlink
Mail Service Thu, 9 Aug 2001 16:20:40 -0400 (EDT)
helo mail.highspd.net
250 pickering.mail.mindspring.net Hello mail.highspd.net
[208.62.90.230], please to meet you
mail from: [EMAIL PROTECTED]
250 [EMAIL PROTECTED] Sender ok
rcpt to: [EMAIL PROTECTED]
250 <[EMAIL PROTECTED]>... Recipient ok
data
354 Enter mail, end with "." on a line by itself
this is a test.
please disregard
.
250 tn5s62.1dc.37kbi14 Message accepted for delivery
quit
221 pickering.mail.mindspring.net closing connection
Connection closed by foreign host.

Ok.. so I can send mail directly just fine.. So what in the heck is
going on here?  This is what is puzzling me the most..?

BTW.. this was happening with "stock" qmail also before I patched it
with the qmail-queue patch for qmailscanner.

Any ideas?

Ed McLain

-----Original Message-----
From: MarkD [mailto:[EMAIL PROTECTED]] 
Sent: Thursday, August 09, 2001 2:04 PM
To: Edward McLain
Cc: [EMAIL PROTECTED]
Subject: Re: qmail-queue question

On Thu, Aug 09, 2001 at 12:39:28PM -0500, Edward McLain allegedly wrote:
> 
> 
> -----Original Message-----
> From: MarkD [mailto:[EMAIL PROTECTED]] 
> Sent: Thursday, August 09, 2001 12:23 PM
> To: [EMAIL PROTECTED]
> Subject: Re: qmail-queue question
> 
> >> 3. When the queue shows the message arriving on 30 Jul 2001
15:08:23
> I
> >> tend to think that it actually arrive at 3:08 on Jul 30 of 2001,
that
> is
> >> unless qmail is doing something funking with date and time stamps.
;)
> 
> >But you didn't show the log entry that corresponds to this message.
As
> >a consultant with 8 years experience you have probably deduced that
> >*all* messages inserted into the queue create a "new msg" log
> >entry. Where is it?
> 
> There was no "new msg" log entry.  Best I can tell the logs only go
back
> maybe 3 or 4 days and the messages originated 9 days ago.. Thus the
> problem.

It probably would have been helpful if you'd told us about this at the
start. It seemed like you were trying to suggest that the log entry
never existed. I guess that's a lesson for next time.

> I took Richard's advice and added the socket keep-alive patch and that
> actually seems to have fixed the problem.  The old messages seemed to
> have mysteriously disappeared after replacing the qmail-remote exec.  

Mysteriously? Since we've stressed the importance of looking at logs
for answers, I'm sure you've checked the logs to solve the
"mystery". What did they say? I'm sure if you bother, you'll see that
it's not a "mystery" at all. Unless of course you kill -9 qmail-send,
but no one or no docs have ever told you to do this, right?

In any event, as I said in the the last post; queuelifetime applies
*after* the last delivery attempt has exited. It's almost certainly
the case that you killed qmail-remote (or it exited of its own accord)
at which point qmail-send would notice that queuelifetime is exceeded
and bounce the mail. The logs show this stuff by the way.

> Not to start anything else, but is there any better way to stop qmail
> when using tcp-daemonts than svc -d /service/qmail-send ?
> 
> This doesn't seem to always work and I can't ever seem to get all the

It always works. But qmail-send won't exit until all current
deliveries have exited - in fact it logs an entry each time an
outstanding delivery completes.  Did you see different when you
checked the logs? If so, show us.

Edward, for someone with 8 years experience, you should rejoice that
so many of your mysteries and misunderstandings can be solved by
examining and understanding the logs. If the log messages are a
mystery to you, there are plenty of archived posts explaining the
messages.


Regards.

Reply via email to