PHP mailer and domains with MX not on local server

Some thoughts:

Editing previous posts is very helpful to the community at large, which may find a specific individual post through Googling.

All MTAs (exim is an MTA, a Mail Transport Agent) that I know of deliver local mail locally rather than by IP.

Simply because if you try to deliver by IP the mail continues to loop.

Think about it.

Exim gets an email for your.example.com and delivers it by IP#. lt gets it again, and delivers it by IP# again.

Ad infinitum, ad nauseum.

I suppose we could try to figure out where the mail came from, but that would be very hard to do. Perhaps impossible to determine with certainty, if exim was expected to deliver locally or relay (deliver by IP#) unless you looked it up in a table. How else would you determine if the server was responsible for local delivery or not?

Jeff
 
Some thoughts:

Editing previous posts is very helpful to the community at large, which may find a specific individual post through Googling.

All MTAs (exim is an MTA, a Mail Transport Agent) that I know of deliver local mail locally rather than by IP.

Simply because if you try to deliver by IP the mail continues to loop.

Think about it.

Exim gets an email for your.example.com and delivers it by IP#. lt gets it again, and delivers it by IP# again.

Ad infinitum, ad nauseum.

I suppose we could try to figure out where the mail came from, but that would be very hard to do. Perhaps impossible to determine with certainty, if exim was expected to deliver locally or relay (deliver by IP#) unless you looked it up in a table. How else would you determine if the server was responsible for local delivery or not?

Jeff
You do have a point there, but it should not be to hard to check the MX-records of the domain the mail was sent to and grep them from a local file / ifconfig to see if the mail should be delivered on the local server.

I know this has 'impact' on the performance but I doubt if it is that much to do a sort of grep on a local file. It already does this for the local domains before doing the query for mx-records, so what is the diffence if you do it afterwards (except for the domains that should have local delivery)?


@floyd, you just couldn't resist to reply, could you? :p
 
You don't have to quote the entire previous message every time. There is no need for that.

@floyd, you just couldn't resist to reply, could you?

I hate for people to remain ignorant when I have knowledge that could help them no matter how bad their attitude is. I would want someone to do the same for me.

grep them from a local file / ifconfig to see if the mail

I don't see how ifconfig will help. Please enlighten us.

After reading everything so far here and without you asking the exim group, I still think the solution in post #7 is the best. It will continually check to see which domains should be delivered locally and which ones should not and remove the ones that should not from the local domains file and it will add them back in automatically if the MX record changes back to local.

Its certainly faster than trying to get exim to change the way it works. I am not certain why you are opposed to the above. It works well and fast.
 
I don't see how ifconfig will help. Please enlighten us.

After reading everything so far here and without you asking the exim group, I still think the solution in post #7 is the best. It will continually check to see which domains should be delivered locally and which ones should not and remove the ones that should not from the local domains file and it will add them back in automatically if the MX record changes back to local.

Its certainly faster than trying to get exim to change the way it works. I am not certain why you are opposed to the above. It works well and fast.
Well, a script would be an option yes.. But it feels more like an external workaround then a real 'solution'..

What I meant was.. When a mail will be sent through Exim, that exim check MX-records of the domain. If the domain points to a domain which is at one of the local lan adapters, and ifconfig would be an option to check that, then do local delivery. If not, then connect to mail host of MX-records.

But I already accepted the way Exim works, it is obviously no point in changing this as it has always been this way, but there are always things to 'improve'.. Anyway.. I was just curious why Jeff thought it was not posible cause in my eyes it should not be that difficult or have a big performance impact, although it will never be implemented this way..
 
Stop.

This thread is going nowhere.

@Mr_Q,
You may certainly write an MTA (Mail Transport Agent) that does it anyway you like. Please let us know when it's done and as mature and bug-free as is exim, so we may look at it and decide if we want to change everything to use it.

Until you finish that we'll most likely continue to use exim, the way it was meant to be used by its author, Dr. Philip Hazel.

In the event that there's something more constructive to be said, this thread currently remains open.

It could be closed or even deleted at any time.

Jeff
 
Jeff,

May I ask, because I really want to know, is exim.pl a workaround of some sort or is it included in all the distributions of exim?

Could code be put into exim.pl to do what Mr_Q wants?
 
Jeff,

May I ask, because I really want to know, is exim.pl a workaround of some sort or is it included in all the distributions of exim?
Read from the horses' mouths:

Google the exim.org site for exim.pl:

http://www.google.com/#hl=en&source=...ite:exim.org
Could code be put into exim.pl to do what Mr_Q wants?
I wouldn't know without doing some research. It may even be doable by rewriting exim.conf. I wouldn't do it because it would change the way exim is meant to work. So I've never searched further.

To me it makes no sense to search multiple files and do multiple DNS lookups to find out something that's in an automatically configured file.

Anyone can do any rewriting of exim, or exim.conf, or exim.pl, they want.

Jeff
 
Back
Top