Mailing List Archive

[Bug 2599] delivery of local emails is slow when multiple recipients are used, some being remote
https://bugs.exim.org/show_bug.cgi?id=2599

Jeremy Harris <jgh146exb@wizmail.org> changed:

What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |ASSIGNED

--- Comment #1 from Jeremy Harris <jgh146exb@wizmail.org> ---
An interesting combination. To confirm - the penalty count isn't directly part
of the issue, but having a remote recipient getting a delay during the callout
is? And a similar delay for non-"hold" callouts has no effect on the local
recipients?

Can you tell which phase of the SMTP call is getting the delay? Eg.
TCP-connect,
or an SMTP command once connected?

Does your config explicitly code only doing the callout for the remote, and not
for the local recipients?

As for whether it's a bug: I'd say yes.
The "up to 30 minutes" aspect would imply that you are running the queue every
30m.

--
You are receiving this mail because:
You are on the CC list for the bug.
--
## List details at https://lists.exim.org/mailman/listinfo/exim-dev Exim details at http://www.exim.org/ ##
[Bug 2599] delivery of local emails is slow when multiple recipients are used, some being remote [ In reply to ]
https://bugs.exim.org/show_bug.cgi?id=2599

--- Comment #2 from martynas@mc2.dev ---
Yes, the delay is :)

It sends emails immediately to remote recipients. In queue it shows D for all
remote recipients, and nothing for local ones (as if it'd never tried to
deliver).

Example:
2020-04-09 09:43:49 cwd=/var/spool/exim 13 args: /usr/sbin/exim -MCP -MCS -MCt
51.2.249.58 34962 TLS1.2:ECDHE-RSA-AES256-GCM-SHA384:256 -MC remote_smtp
mx02.server.com 84.80.245.138 1 1jMTiu-00AGk7-WB
2020-04-09 09:43:49 1jMTiu-00AGk7-WB <= k.butler@localsender.nl
H=83-161-11-170.ip.dc.nl ([IPv6:::ffff:10.2.0.1]) [82.161.114.170] P=esmtpa
A=plain:k.butler@localsender.nl S=74569 T="Test: topic" from
<k.butler@localsender.nl> for shendrix@remotedomain.com
b.vanderschalie@localdomain.nl m.nobel@localdomain.nl
2020-04-09 09:43:49 1jMTiu-00AGk7-WB => shendrix@remotedomain.com
F=<k.butler@localsender.nl> R=lookuphost T=remote_smtp S=76487
H=mx02.server.com [84.80.245.138] X=TLS1.2:ECDHE-RSA-AES256-GCM-SHA384:256
CV=no C="250 Ok: queued as 8C53F288006"
2020-04-09 10:34:41 1jMTiu-00AGk7-WB => b.vanderschalie
<b.vanderschalie@localdomain.nl> F=<k.butler@localsender.nl>
R=spamcheck_director T=spamcheck S=74933
2020-04-09 10:34:41 1jMTiu-00AGk7-WB -> m.nobel <m.nobel@localdomain.nl>
F=<k.butler@localsender.nl> R=spamcheck_director T=spamcheck S=74933
2020-04-09 10:34:41 1jMTiu-00AGk7-WB Completed

An email was sent from k.butler@localsender.nl to shendrix@remotedomain.com
With a cc to b.vanderschalie@localdomain.nl and m.nobel@localdomain.nl

As you see, there is almost immediate delivery to remote server, while the
local one is delayed a lot.

If SMTP call is needed - please let me know, I'll try to strace it down (or try
catching it in exim debug mode).

The whole condition where we 'drop' it:
drop authenticated = *
condition = ${if !eq{$acl_m_bc_skip}{1}}
!verify =
recipient/defer_ok/callout=3s,maxwait=5s,connect=2s,defer_ok,use_sender,hold
ratelimit = BC_LIM / BC_PERIOD / per_rcpt / user-$acl_m_user
continue =
${perl{append_record}{$spool_directory/blocked_authenticated_users}{$acl_m_user}}
continue = ${perl{block_cracking_notify}{smtp}}
message = Account $acl_m_user has been blocked for sending to too many
invalid recipients
logwrite = $acl_m_user has been added to
$spool_directory/blocked_authenticated_users

Called in acl_smtp_rcpt.

The following isn't there:
domains = !+local_domains

Of coure we may add it to it, as this might workaround the issue if it's
related to "verify" call for the local domain while remote times out.. (I don't
think that's the case, but there is such a possibility).

If anything else needed - just let me know.

Thank you!

--
You are receiving this mail because:
You are on the CC list for the bug.
--
## List details at https://lists.exim.org/mailman/listinfo/exim-dev Exim details at http://www.exim.org/ ##
[Bug 2599] delivery of local emails is slow when multiple recipients are used, some being remote [ In reply to ]
https://bugs.exim.org/show_bug.cgi?id=2599

--- Comment #3 from Jeremy Harris <jgh146exb@wizmail.org> ---
I see that a TLS proxy process is also involved. Initial testing with non-TLS
to
the remote does not replicate the problem. I'd like to see a debug run; could
you add this:

warn senders = k.butler@localsender.nl
control = debug/opts=-d+all

to the top of your mail ACL, run another message test through, and grab the
debuglog file from your log directory? We don't need to wait on the eventual
delivery to the local recipients. Then either attach the file to this bug, or
mail it to me at jgh@exim.org

--
You are receiving this mail because:
You are on the CC list for the bug.
--
## List details at https://lists.exim.org/mailman/listinfo/exim-dev Exim details at http://www.exim.org/ ##
[Bug 2599] delivery of local emails is slow when multiple recipients are used, some being remote [ In reply to ]
https://bugs.exim.org/show_bug.cgi?id=2599

--- Comment #4 from martynas@mc2.dev ---
It happened on 04-09 for this client and he did not want us to connect to his
server again to check it (as we placed a mentioned workaround there)... We had
many reports on this, so, when next client opens a ticket we'll try to collect
more info, unless you find the root cause until that time :) Thanks.

--
You are receiving this mail because:
You are on the CC list for the bug.
--
## List details at https://lists.exim.org/mailman/listinfo/exim-dev Exim details at http://www.exim.org/ ##