You are viewing a plain text version of this content. The canonical link for it is here.
Posted to server-dev@james.apache.org by "Stefano Bagnara (JIRA)" <se...@james.apache.org> on 2005/03/16 12:05:20 UTC
[jira] Created: (JAMES-358) Too many RemoteDelivery attempts with many mx and many ip
Too many RemoteDelivery attempts with many mx and many ip
---------------------------------------------------------
Key: JAMES-358
URL: http://issues.apache.org/jira/browse/JAMES-358
Project: James
Type: Improvement
Components: Remote Delivery
Versions: 2.2.0
Reporter: Stefano Bagnara
Priority: Minor
Take a domain with 5 mx servers each one with 6 associated ips. James currently try to connect to each MX server even if the first server say "5.1.1 user unknown", but even worst, james try to connect to each IP of each MX server.
I think that james should only check each MX server once, at a random IP address from the IP list for that mx hostname.
The permanent user error issue would be only a further optimization but the IP issue is probably against the RFC specifications.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
If you want more information on JIRA, or have a bug to report see:
http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org
[jira] Commented: (JAMES-358) Too many RemoteDelivery attempts with many mx and many ip
Posted by "Stefano Bagnara (JIRA)" <se...@james.apache.org>.
[ http://issues.apache.org/jira/browse/JAMES-358?page=comments#action_60960 ]
Stefano Bagnara commented on JAMES-358:
---------------------------------------
I forgot to paste the interesting paragraph about multihomed mx addressed:
"The question of whether a sender should attempt retries using the different addresses of a multihomed host has been controversial. The main argument for using the multiple addresses is that it maximizes the probability of timely delivery, and indeed sometimes the probability of any delivery; the counter-argument is that it may result in unnecessary resource use."
> Too many RemoteDelivery attempts with many mx and many ip
> ---------------------------------------------------------
>
> Key: JAMES-358
> URL: http://issues.apache.org/jira/browse/JAMES-358
> Project: James
> Type: Improvement
> Components: Remote Delivery
> Versions: 2.2.0
> Reporter: Stefano Bagnara
> Priority: Minor
>
> Take a domain with 5 mx servers each one with 6 associated ips. James currently try to connect to each MX server even if the first server say "5.1.1 user unknown", but even worst, james try to connect to each IP of each MX server.
> I think that james should only check each MX server once, at a random IP address from the IP list for that mx hostname.
> The permanent user error issue would be only a further optimization but the IP issue is probably against the RFC specifications.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
If you want more information on JIRA, or have a bug to report see:
http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org
[jira] Updated: (JAMES-358) Too many RemoteDelivery attempts with many mx and many ip
Posted by "Stefano Bagnara (JIRA)" <se...@james.apache.org>.
[ http://issues.apache.org/jira/browse/JAMES-358?page=all ]
Stefano Bagnara updated JAMES-358:
----------------------------------
Component: DNSServer
(was: Remote Delivery)
type: Improvement (was: Bug)
Fix Version: 2.2.1
Description:
Take a domain with 5 mx servers each one with 6 associated ips. James currently try to connect to each MX server even if the first server say "5.1.1 user unknown", but even worst, james try to connect to each IP of each MX server.
I think that james should only check each MX server once, at a random IP address from the IP list for that mx hostname.
The permanent user error issue would be only a further optimization but the IP issue is probably against the RFC specifications.
was:
Take a domain with 5 mx servers each one with 6 associated ips. James currently try to connect to each MX server even if the first server say "5.1.1 user unknown", but even worst, james try to connect to each IP of each MX server.
I think that james should only check each MX server once, at a random IP address from the IP list for that mx hostname.
The permanent user error issue would be only a further optimization but the IP issue is probably against the RFC specifications.
Environment:
> Too many RemoteDelivery attempts with many mx and many ip
> ---------------------------------------------------------
>
> Key: JAMES-358
> URL: http://issues.apache.org/jira/browse/JAMES-358
> Project: James
> Type: Improvement
> Components: DNSServer
> Versions: 2.2.0
> Reporter: Stefano Bagnara
> Assignee: Stefano Bagnara
> Priority: Minor
> Fix For: 2.2.1
> Attachments: DNSServer.java.singleIPperMX.diff, james-config.xml.singleIPperMX.diff
>
> Take a domain with 5 mx servers each one with 6 associated ips. James currently try to connect to each MX server even if the first server say "5.1.1 user unknown", but even worst, james try to connect to each IP of each MX server.
> I think that james should only check each MX server once, at a random IP address from the IP list for that mx hostname.
> The permanent user error issue would be only a further optimization but the IP issue is probably against the RFC specifications.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org
[jira] Commented: (JAMES-358) Too many RemoteDelivery attempts with many mx and many ip
Posted by "Noel J. Bergman (JIRA)" <se...@james.apache.org>.
[ http://issues.apache.org/jira/browse/JAMES-358?page=comments#action_12312566 ]
Noel J. Bergman commented on JAMES-358:
---------------------------------------
I disagree with this patch, and feel that it has gone in the wrong direction, particularly in light of the RFC's clear intent. The correct solution is to detect the permanent failure and abort the delivery.
Please look at implementing that patch, instead. :-)
> Too many RemoteDelivery attempts with many mx and many ip
> ---------------------------------------------------------
>
> Key: JAMES-358
> URL: http://issues.apache.org/jira/browse/JAMES-358
> Project: James
> Type: Bug
> Components: Remote Delivery
> Versions: 2.2.0
> Reporter: Stefano Bagnara
> Priority: Minor
> Attachments: DNSServer.java.singleIPperMX.diff, james-config.xml.singleIPperMX.diff
>
> Take a domain with 5 mx servers each one with 6 associated ips. James currently try to connect to each MX server even if the first server say "5.1.1 user unknown", but even worst, james try to connect to each IP of each MX server.
> I think that james should only check each MX server once, at a random IP address from the IP list for that mx hostname.
> The permanent user error issue would be only a further optimization but the IP issue is probably against the RFC specifications.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org
[jira] Updated: (JAMES-358) Too many RemoteDelivery attempts with many mx and many ip
Posted by "Stefano Bagnara (JIRA)" <se...@james.apache.org>.
[ http://issues.apache.org/jira/browse/JAMES-358?page=all ]
Stefano Bagnara updated JAMES-358:
----------------------------------
Attachment: DNSServer.java.singleIPperMX.diff
james-config.xml.singleIPperMX.diff
The <singleIPperMX> support.
This should be backward compatible.
I think that we should make "true" the default one.
PS: feel free to change my config comments, configuration names because I know my english is really poor ;-)
> Too many RemoteDelivery attempts with many mx and many ip
> ---------------------------------------------------------
>
> Key: JAMES-358
> URL: http://issues.apache.org/jira/browse/JAMES-358
> Project: James
> Type: Bug
> Components: Remote Delivery
> Versions: 2.2.0
> Reporter: Stefano Bagnara
> Priority: Minor
> Attachments: DNSServer.java.singleIPperMX.diff, james-config.xml.singleIPperMX.diff
>
> Take a domain with 5 mx servers each one with 6 associated ips. James currently try to connect to each MX server even if the first server say "5.1.1 user unknown", but even worst, james try to connect to each IP of each MX server.
> I think that james should only check each MX server once, at a random IP address from the IP list for that mx hostname.
> The permanent user error issue would be only a further optimization but the IP issue is probably against the RFC specifications.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org
[jira] Commented: (JAMES-358) Too many RemoteDelivery attempts with many mx and many ip
Posted by "Stefano Bagnara (JIRA)" <se...@james.apache.org>.
[ http://issues.apache.org/jira/browse/JAMES-358?page=comments#action_12312567 ]
Stefano Bagnara commented on JAMES-358:
---------------------------------------
I think this should be configurable because the RFC states this:
"The question of whether a sender should attempt retries using the different addresses of a multihomed host has been controversial. The main argument for using the multiple addresses is that it maximizes the probability of timely delivery, and indeed sometimes the probability of any delivery; the counter-argument is that it may result in unnecessary resource use."
Most server will report duplicate IPs in different MX servers, I often saw:
mx1 => IP1, IP2, IP3, IP4
mx2 => IP5, IP6, IP7, IP8
mx3 => iP1, IP3, IP5, IP7
mx4 => iP2, IP4, IP6, IP8
Trying all the IPs will be a lot of work.
-----
I already patched the Permanent error issue but in my own RemoteDelivery that is totally different from the one in trunk.
My "new" RemoteDelivery will be part of my DSN support.
> Too many RemoteDelivery attempts with many mx and many ip
> ---------------------------------------------------------
>
> Key: JAMES-358
> URL: http://issues.apache.org/jira/browse/JAMES-358
> Project: James
> Type: Bug
> Components: Remote Delivery
> Versions: 2.2.0
> Reporter: Stefano Bagnara
> Priority: Minor
> Attachments: DNSServer.java.singleIPperMX.diff, james-config.xml.singleIPperMX.diff
>
> Take a domain with 5 mx servers each one with 6 associated ips. James currently try to connect to each MX server even if the first server say "5.1.1 user unknown", but even worst, james try to connect to each IP of each MX server.
> I think that james should only check each MX server once, at a random IP address from the IP list for that mx hostname.
> The permanent user error issue would be only a further optimization but the IP issue is probably against the RFC specifications.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org
[jira] Commented: (JAMES-358) Too many RemoteDelivery attempts with many mx and many ip
Posted by "Stefano Bagnara (JIRA)" <se...@james.apache.org>.
[ http://issues.apache.org/jira/browse/JAMES-358?page=comments#action_60959 ]
Stefano Bagnara commented on JAMES-358:
---------------------------------------
I've just read point 5 from RFC 2821:
"To provide reliable mail transmission, the SMTP client MUST be able to try (and retry) each of the relevant addresses in this list in order, until a delivery attempt succeeds. However, there MAY also be a configurable limit on the number of alternate addresses that can be tried. In any case, the SMTP client SHOULD try at least two addresses."
>From a previous paragraph it seems that it is correct to try every IP address resolved from an MX server.
So this "Improvement" should be reformulated: why don't we add a configurable limit for the remotedelivery? I think that the sentence "the SMTP client SHOULD try at least two addresses" is the lower limit and RemoteDelivery is currently working on the upper limit. I use james for high volume mailing lists and it seems that for ML usage a lower limit would be better.
> Too many RemoteDelivery attempts with many mx and many ip
> ---------------------------------------------------------
>
> Key: JAMES-358
> URL: http://issues.apache.org/jira/browse/JAMES-358
> Project: James
> Type: Improvement
> Components: Remote Delivery
> Versions: 2.2.0
> Reporter: Stefano Bagnara
> Priority: Minor
>
> Take a domain with 5 mx servers each one with 6 associated ips. James currently try to connect to each MX server even if the first server say "5.1.1 user unknown", but even worst, james try to connect to each IP of each MX server.
> I think that james should only check each MX server once, at a random IP address from the IP list for that mx hostname.
> The permanent user error issue would be only a further optimization but the IP issue is probably against the RFC specifications.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
If you want more information on JIRA, or have a bug to report see:
http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org
[jira] Commented: (JAMES-358) Too many RemoteDelivery attempts with many mx and many ip
Posted by "Arjan Veenstra (JIRA)" <se...@james.apache.org>.
[ http://issues.apache.org/jira/browse/JAMES-358?page=comments#action_12330658 ]
Arjan Veenstra commented on JAMES-358:
--------------------------------------
RFC 3974 suggest these step:
(6) For each of the addresses, loop over steps (7) to (9).
(7) Try to make a TCP connection to the destination's SMTP port
(25). The client needs to follow timeouts documented in RFC
2821 section 4.5.3.2. If successful, go to step (9).
(8) If unsuccessful and there is another available address, try the
next available address. Go to step (7). If all addresses are
not reachable and if a list of MX records is being traversed,
try the next MX record (go to step (3)). If there is no list of
MX records, or if the end of the list of MX records has been
reached, raise a temporary email delivery failure. Finish.
(9) Attempt to deliver the email over the connection established, as
specified in RFC 2821. If a transient failure condition is
reported, try the next MX record (go to step (3)). If an error
condition is reported, raise a permanent email delivery error,
and do not try further MX records. Finish. If successful, SMTP
delivery has succeeded. Finish.
Never trying more then one IP adress per MX is likely to cause a few extra failures, especialy when delivering to domains with just 1 MX. And even more (in the future) when both IPv6 and IPv4 are used. A situation where a host has both IPv4 and IPv6 adresses in DNS is not unlikely, running into a situation where just one of then is actually reachable over the net is not very unlikely as well. So i think the above steps are sensible.
The actual 'load' of just trying to connect is not high at all, running sufficient delivery threads should keep mail delivery going even when one of them is waiting for a connection to time-out.
Moving on to the next MX on a temporary failure is extremely logical when multiple adresses for a host all point to the same machine, your example above allready shows this is not allways true. Perhaps it's possible to maintain a list af actual addresses tried so they can be skipped when they show up a second time?
}
> Too many RemoteDelivery attempts with many mx and many ip
> ---------------------------------------------------------
>
> Key: JAMES-358
> URL: http://issues.apache.org/jira/browse/JAMES-358
> Project: James
> Type: Improvement
> Components: DNSServer
> Versions: 2.2.0
> Reporter: Stefano Bagnara
> Assignee: Stefano Bagnara
> Priority: Minor
> Fix For: 2.3.0
> Attachments: DNSServer.java.singleIPperMX.diff, james-config.xml.singleIPperMX.diff
>
> Take a domain with 5 mx servers each one with 6 associated ips. James currently try to connect to each MX server even if the first server say "5.1.1 user unknown", but even worst, james try to connect to each IP of each MX server.
> I think that james should only check each MX server once, at a random IP address from the IP list for that mx hostname.
> The permanent user error issue would be only a further optimization but the IP issue is probably against the RFC specifications.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org
[jira] Commented: (JAMES-358) Too many RemoteDelivery attempts with many mx and many ip
Posted by "Stefano Bagnara (JIRA)" <se...@james.apache.org>.
[ http://issues.apache.org/jira/browse/JAMES-358?page=comments#action_12330659 ]
Stefano Bagnara commented on JAMES-358:
---------------------------------------
You are reporting only a part of the RFC you are referring to. I can bring a different example from the same RFC:
---
The algorithm for a dual-stack SMTP sender is basically the same as
that for an IPv4-only sender, but it now includes AAAA lookups of MX
records for SMTP-over-IPv6 delivery. IPv4/v6 dual stack destinations
should be treated just like multihomed destinations, as described in
RFC 2821 [Klensin], section 5.
----
Let's go to RFC 2821, section 5:
----
Although the capability to try multiple alternative addresses is
required, specific installations may want to limit or disable the use
of alternative addresses. The question of whether a sender should
attempt retries using the different addresses of a multihomed host
has been controversial. The main argument for using the multiple
addresses is that it maximizes the probability of timely delivery,
and indeed sometimes the probability of any delivery; the counter-
argument is that it may result in unnecessary resource use. Note
that resource use is also strongly determined by the sending strategy
discussed in section 4.5.4.1.
----
PLEASE NOTE that I simply would like to add an OPTIONAL configuration to let an user to specify this behaviour.
Running a server that sends millions of mails per day I really know that when a server for a big domain is down the timeouts will consume most of the delivery time delaying a lot the whole delivery process for the "working" domains.
I think we should be RFC compliant, and the RFC is clear enough about this issue: "The question .. has been controversial". If the question has been controversial for the RFC writers I think we should no more discuss about this and simply let the users decide the behaviour they prefer.
> Too many RemoteDelivery attempts with many mx and many ip
> ---------------------------------------------------------
>
> Key: JAMES-358
> URL: http://issues.apache.org/jira/browse/JAMES-358
> Project: James
> Type: Improvement
> Components: DNSServer
> Versions: 2.2.0
> Reporter: Stefano Bagnara
> Assignee: Stefano Bagnara
> Priority: Minor
> Fix For: 2.3.0
> Attachments: DNSServer.java.singleIPperMX.diff, james-config.xml.singleIPperMX.diff
>
> Take a domain with 5 mx servers each one with 6 associated ips. James currently try to connect to each MX server even if the first server say "5.1.1 user unknown", but even worst, james try to connect to each IP of each MX server.
> I think that james should only check each MX server once, at a random IP address from the IP list for that mx hostname.
> The permanent user error issue would be only a further optimization but the IP issue is probably against the RFC specifications.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org
[jira] Assigned: (JAMES-358) Too many RemoteDelivery attempts with many mx and many ip
Posted by "Stefano Bagnara (JIRA)" <se...@james.apache.org>.
[ http://issues.apache.org/jira/browse/JAMES-358?page=all ]
Stefano Bagnara reassigned JAMES-358:
-------------------------------------
Assign To: Stefano Bagnara
> Too many RemoteDelivery attempts with many mx and many ip
> ---------------------------------------------------------
>
> Key: JAMES-358
> URL: http://issues.apache.org/jira/browse/JAMES-358
> Project: James
> Type: Bug
> Components: Remote Delivery
> Versions: 2.2.0
> Reporter: Stefano Bagnara
> Assignee: Stefano Bagnara
> Priority: Minor
> Attachments: DNSServer.java.singleIPperMX.diff, james-config.xml.singleIPperMX.diff
>
> Take a domain with 5 mx servers each one with 6 associated ips. James currently try to connect to each MX server even if the first server say "5.1.1 user unknown", but even worst, james try to connect to each IP of each MX server.
> I think that james should only check each MX server once, at a random IP address from the IP list for that mx hostname.
> The permanent user error issue would be only a further optimization but the IP issue is probably against the RFC specifications.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org
[jira] Commented: (JAMES-358) Too many RemoteDelivery attempts with
many mx and many ip
Posted by "Norman Maurer (JIRA)" <se...@james.apache.org>.
[ http://issues.apache.org/jira/browse/JAMES-358?page=comments#action_12416755 ]
Norman Maurer commented on JAMES-358:
-------------------------------------
We use james now in a enviroment which sends about 100000 Emails per day ( For testing). Without this patch it is a really a porblem. We should at least add it as optional configValue.
+1
For include this patch as new feature and optinal configvalue
> Too many RemoteDelivery attempts with many mx and many ip
> ---------------------------------------------------------
>
> Key: JAMES-358
> URL: http://issues.apache.org/jira/browse/JAMES-358
> Project: James
> Type: Improvement
> Components: DNSServer
> Versions: 2.3.0a1, 2.2.0
> Reporter: Stefano Bagnara
> Assignee: Stefano Bagnara
> Priority: Minor
> Attachments: DNSServer.java.singleIPperMX.diff, james-config.xml.singleIPperMX.diff
>
> Take a domain with 5 mx servers each one with 6 associated ips. James currently try to connect to each MX server even if the first server say "5.1.1 user unknown", but even worst, james try to connect to each IP of each MX server.
> I think that james should only check each MX server once, at a random IP address from the IP list for that mx hostname.
> The permanent user error issue would be only a further optimization but the IP issue is probably against the RFC specifications.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org
[jira] Resolved: (JAMES-358) Too many RemoteDelivery attempts with
many mx and many ip
Posted by "Stefano Bagnara (JIRA)" <se...@james.apache.org>.
[ http://issues.apache.org/jira/browse/JAMES-358?page=all ]
Stefano Bagnara resolved JAMES-358.
-----------------------------------
Fix Version/s: 3.0
Resolution: Fixed
Applied the patch.
> Too many RemoteDelivery attempts with many mx and many ip
> ---------------------------------------------------------
>
> Key: JAMES-358
> URL: http://issues.apache.org/jira/browse/JAMES-358
> Project: James
> Issue Type: Improvement
> Components: DNSServer
> Affects Versions: 2.3.0a1, 2.2.0
> Reporter: Stefano Bagnara
> Assigned To: Stefano Bagnara
> Priority: Minor
> Fix For: 3.0
>
> Attachments: DNSServer.java.singleIPperMX.diff, james-config.xml.singleIPperMX.diff
>
>
> Take a domain with 5 mx servers each one with 6 associated ips. James currently try to connect to each MX server even if the first server say "5.1.1 user unknown", but even worst, james try to connect to each IP of each MX server.
> I think that james should only check each MX server once, at a random IP address from the IP list for that mx hostname.
> The permanent user error issue would be only a further optimization but the IP issue is probably against the RFC specifications.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org
[jira] Commented: (JAMES-358) Too many RemoteDelivery attempts with many mx and many ip
Posted by "Stefano Bagnara (JIRA)" <se...@james.apache.org>.
[ http://issues.apache.org/jira/browse/JAMES-358?page=comments#action_12312534 ]
Stefano Bagnara commented on JAMES-358:
---------------------------------------
I added a patch to DNSServer that allow a new configuration:
<singleIPperMX> true </singleIPperMX>
so that james will try a single IP for each multihomed MX host instead of trying them all (relaxed RFC interpretation, IMHO more compliant with the multihome purpose).
> Too many RemoteDelivery attempts with many mx and many ip
> ---------------------------------------------------------
>
> Key: JAMES-358
> URL: http://issues.apache.org/jira/browse/JAMES-358
> Project: James
> Type: Bug
> Components: Remote Delivery
> Versions: 2.2.0
> Reporter: Stefano Bagnara
> Priority: Minor
> Attachments: DNSServer.java.singleIPperMX.diff, james-config.xml.singleIPperMX.diff
>
> Take a domain with 5 mx servers each one with 6 associated ips. James currently try to connect to each MX server even if the first server say "5.1.1 user unknown", but even worst, james try to connect to each IP of each MX server.
> I think that james should only check each MX server once, at a random IP address from the IP list for that mx hostname.
> The permanent user error issue would be only a further optimization but the IP issue is probably against the RFC specifications.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org
[jira] Commented: (JAMES-358) Too many RemoteDelivery attempts with many mx and many ip
Posted by "Arjan Veenstra (JIRA)" <se...@james.apache.org>.
[ http://issues.apache.org/jira/browse/JAMES-358?page=comments#action_12330697 ]
Arjan Veenstra commented on JAMES-358:
--------------------------------------
I do understand the optional part, and i don't really object against this patch.
I was mainly trying to find optimal instead of optional. And I do believe there is room for improvement (not that it should stop this from getting implemented), e.g. having a setting like <maxIPsPerMX>2</maxIPsPerMX> whould provide a bit better fine-tuning.
But finding ways to not connect to adresses wich allready have been tried whould be even better. Also finding ways to delivery going even when some mails stall might solve the performance problem without reducing the change of succesfull delivery. I was thinking in the direction of more parralelization and perhaps some kind of a 'this address fails' cache.
Having said that, the above patch is the only thing wich improves the situation and is easy to implement, all other options will require way more work and i do understand you don't want to wait for that. Actually, IMHO, having ideas should never block working code, but working code should also never stop idea's ;-)
> Too many RemoteDelivery attempts with many mx and many ip
> ---------------------------------------------------------
>
> Key: JAMES-358
> URL: http://issues.apache.org/jira/browse/JAMES-358
> Project: James
> Type: Improvement
> Components: DNSServer
> Versions: 2.2.0
> Reporter: Stefano Bagnara
> Assignee: Stefano Bagnara
> Priority: Minor
> Fix For: 2.3.0
> Attachments: DNSServer.java.singleIPperMX.diff, james-config.xml.singleIPperMX.diff
>
> Take a domain with 5 mx servers each one with 6 associated ips. James currently try to connect to each MX server even if the first server say "5.1.1 user unknown", but even worst, james try to connect to each IP of each MX server.
> I think that james should only check each MX server once, at a random IP address from the IP list for that mx hostname.
> The permanent user error issue would be only a further optimization but the IP issue is probably against the RFC specifications.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org
[jira] Updated: (JAMES-358) Too many RemoteDelivery attempts with many mx and many ip
Posted by "Danny Angus (JIRA)" <se...@james.apache.org>.
[ http://issues.apache.org/jira/browse/JAMES-358?page=history ]
Danny Angus updated JAMES-358:
------------------------------
type: Bug (was: Improvement)
For James to retry other MX servicing the same domain after receiving a bona fide 5xy permanent error seems to me to be a defect:
[rfc 2821]
5yz Permanent Negative Completion reply
The command was not accepted and the requested action did not
occur. The SMTP client is discouraged from repeating the exact
request (in the same sequence). Even some "permanent" error
conditions can be corrected, so the human user may want to direct
the SMTP client to reinitiate the command sequence by direct
action at some point in the future (e.g., after the spelling has
been changed, or the user has altered the account status).
> Too many RemoteDelivery attempts with many mx and many ip
> ---------------------------------------------------------
>
> Key: JAMES-358
> URL: http://issues.apache.org/jira/browse/JAMES-358
> Project: James
> Type: Bug
> Components: Remote Delivery
> Versions: 2.2.0
> Reporter: Stefano Bagnara
> Priority: Minor
>
> Take a domain with 5 mx servers each one with 6 associated ips. James currently try to connect to each MX server even if the first server say "5.1.1 user unknown", but even worst, james try to connect to each IP of each MX server.
> I think that james should only check each MX server once, at a random IP address from the IP list for that mx hostname.
> The permanent user error issue would be only a further optimization but the IP issue is probably against the RFC specifications.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
If you want more information on JIRA, or have a bug to report see:
http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org
[jira] Updated: (JAMES-358) Too many RemoteDelivery attempts with
many mx and many ip
Posted by "Stefano Bagnara (JIRA)" <se...@james.apache.org>.
[ http://issues.apache.org/jira/browse/JAMES-358?page=all ]
Stefano Bagnara updated JAMES-358:
----------------------------------
Fix Version: (was: 2.3.0a1)
Version: 2.3.0a1
> Too many RemoteDelivery attempts with many mx and many ip
> ---------------------------------------------------------
>
> Key: JAMES-358
> URL: http://issues.apache.org/jira/browse/JAMES-358
> Project: James
> Type: Improvement
> Components: DNSServer
> Versions: 2.3.0a1, 2.2.0
> Reporter: Stefano Bagnara
> Assignee: Stefano Bagnara
> Priority: Minor
> Attachments: DNSServer.java.singleIPperMX.diff, james-config.xml.singleIPperMX.diff
>
> Take a domain with 5 mx servers each one with 6 associated ips. James currently try to connect to each MX server even if the first server say "5.1.1 user unknown", but even worst, james try to connect to each IP of each MX server.
> I think that james should only check each MX server once, at a random IP address from the IP list for that mx hostname.
> The permanent user error issue would be only a further optimization but the IP issue is probably against the RFC specifications.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org
[jira] Commented: (JAMES-358) Too many RemoteDelivery attempts with many mx and many ip
Posted by "Noel J. Bergman (JIRA)" <se...@james.apache.org>.
[ http://issues.apache.org/jira/browse/JAMES-358?page=comments#action_12312568 ]
Noel J. Bergman commented on JAMES-358:
---------------------------------------
Re-reading RemoteDelivery, it occurs to me that this may be a very simple fix. We handle SendFailedExceptions at two layers in the code. The inner one effects the right loop for the MX records, and has:
if (sfe.getValidSentAddresses() == null
|| sfe.getValidSentAddresses().length < 1) {
if (isDebug) log("Send failed, continuing with any other servers");
lastError = sfe;
continue;
} else {
// If any mail was sent then the outgoing
// server config must be ok, therefore rethrow
throw sfe;
}
The outer one has comments that I had added after learning some not entirely well-documented things about JavaMail, which should make this a relatively easy change. Note the comments, which say in part:
* sfe.getInvalidAddresses() should be considered permanent.
* sfe.getValidUnsentAddresses() should be considered temporary.
* JavaMail v1.3 properly populates those collections based upon the 4xx and 5xx response codes.
So the inner code should check to see if there ARE any valid unsent addresses, and if not, then we should abort the loop.
> Too many RemoteDelivery attempts with many mx and many ip
> ---------------------------------------------------------
>
> Key: JAMES-358
> URL: http://issues.apache.org/jira/browse/JAMES-358
> Project: James
> Type: Bug
> Components: Remote Delivery
> Versions: 2.2.0
> Reporter: Stefano Bagnara
> Priority: Minor
> Attachments: DNSServer.java.singleIPperMX.diff, james-config.xml.singleIPperMX.diff
>
> Take a domain with 5 mx servers each one with 6 associated ips. James currently try to connect to each MX server even if the first server say "5.1.1 user unknown", but even worst, james try to connect to each IP of each MX server.
> I think that james should only check each MX server once, at a random IP address from the IP list for that mx hostname.
> The permanent user error issue would be only a further optimization but the IP issue is probably against the RFC specifications.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org
[jira] Commented: (JAMES-358) Too many RemoteDelivery attempts with many mx and many ip
Posted by "Stefano Bagnara (JIRA)" <se...@james.apache.org>.
[ http://issues.apache.org/jira/browse/JAMES-358?page=comments#action_12317914 ]
Stefano Bagnara commented on JAMES-358:
---------------------------------------
Ok, I think we should split this issue in 2 different issue.
I think the one about 5xx errors has already been resolved a month ago by Noel patches on RemoteDelivery.
I still think that we should add an option for the multihomed mx hosts.
The RFC states that this issue has been controversial so I think that adding an OPTIONAL flag to avoid the attempts on all the IPs of a single MX host would be a great thing. I would not change the standard behaviour and the "new" behaviour would still be RFC compliant.
Noel: can you confirm/update your "I disagree with this patch" removing considerations about the 5xx error that is already been resolved? I'm new to the "new feature" workflow for the apache projects: perhaps we need to vote about this?
> Too many RemoteDelivery attempts with many mx and many ip
> ---------------------------------------------------------
>
> Key: JAMES-358
> URL: http://issues.apache.org/jira/browse/JAMES-358
> Project: James
> Type: Bug
> Components: Remote Delivery
> Versions: 2.2.0
> Reporter: Stefano Bagnara
> Priority: Minor
> Attachments: DNSServer.java.singleIPperMX.diff, james-config.xml.singleIPperMX.diff
>
> Take a domain with 5 mx servers each one with 6 associated ips. James currently try to connect to each MX server even if the first server say "5.1.1 user unknown", but even worst, james try to connect to each IP of each MX server.
> I think that james should only check each MX server once, at a random IP address from the IP list for that mx hostname.
> The permanent user error issue would be only a further optimization but the IP issue is probably against the RFC specifications.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org