Craig White wrote:
On Fri, 2005-10-28 at 06:18 +0200, Alexander Dalloz wrote:
Am Fr, den 28.10.2005 schrieb Philip Prindeville um 4:26:
I'm running FC3 (updated) on a handful of machines.
I have a single IP address, with a NATing router set to that
address. I have a domain, and an MX which points through
the router at my mail server (or rather, the router is configured
to port-forward 25, 143, etc to the mail server).
I also have several mail clients on my 192.168.1.x network.
The issues are the following:
* the clients have a smart host (DS) defined as the mail relay,
but they canonical its name and then look it up in the DNS,
trying to contact it on the external IP address (and not its
internal 192.168.1.x address in the /etc/hosts file). My
/etc/nsswitch.conf file is unmodified.
* the clients then try to relay the email with a sender's envelope
address as user@xxxxxxxxxxxxxx, which the relay rejects
because "host.my-domain" doesn't resolve in the DNS.
* I should probably have define(`LOCAL_RELAY', `:$S') to
handle forwarding everything to the mail server.
I used to know all of this stuff once upon a time...
-Philip
Reading this I have the strong feeling it was you I was talking to in
#sendmail on freenode this evening (night) :)
I would vote for running a local DNS (bind) service, in conjunction with
DHCP and dynamic zone updates. That would be ideal. And for unqualified
sender addresses use the masquerading features of Sendmail.
On the other hand you may go this route: do not run local Sendmail
daemons, but use the submission process to directly feed outgoing mail
from inner clients to the central mail hub. Have a look at
/etc/mail/submit.mc. Comment out (remove the leading "dnl") for
define(`confDIRECT_SUBMISSION_MODIFIERS',`C')
and even add a line
FEATURE(`nocanonify', `canonify_hosts')
and finally change the IP in
FEATURE(`msp', `[127.0.0.1]')dnl
to the one of the central mail hub.
Please see http://www.sendmail.org/m4/msp.html or better the current
cf/README coming with your Sendmail on Fedora. Many discussion about
this topic to be found through
http://groups.google.com/groups?hl=en&lr=&c2coff=1&sa=X&oi=groupst&q=Sendmail+confDIRECT_SUBMISSION_MODIFIERS
Hope it helps.
----
the alternative to running local dns is to use /etc/hosts to define a
locally available name that doesn't resolve properly via dns isn't it?
It would strike me as simpler to add the name to /etc/hosts but I still
prefer just using the ip address in sendmail.mc
Craig
That's what I thought too, but it turns out you can't have "name"
in the /etc/hosts file... Or rather, you need both "name" and "name."
in there, since sendmail likes to put a "rooting" dot on the end of
domain names.
-Philip