Exim - mail delivery on a LAN
Apologies in advance for a long post.
I have a two machine home network using 192.168.1.X static addresses,
both running Debian potato and using Exim as the MTA. Both machines on
that network can reach the Internet through a hardware router/firewall
(Linksys BEFSR41), and then a cable modem.
The router has port forwarding capability, so I have incoming smtp (port
25) forwarded to one of the machines, and I can send and receive mail
to/from that machine to/from anywhere on the Internet. To make that
work, I use a dynamic dns service so that my Internet email machine has
a fully qualified domain name that is Internet visible. Local mail
delivery also works fine on both machines (user to user on each host).
So far so good.
What I can't figure out is how to configure Exim to send mail from one
machine to the other on the LAN. And I suspect there is some basic
fundamental of email/networking that I don't understand that is blocking
the way.
My home network setup is very simple:
- I call the network 'home' (192.168.1.0)
- each host obviously has it's own hostname
- so I have newdebian.home and olddebian.home
- and those names/addresses are in /etc/hosts on each machine
- I don't run a local name server - I use my IPS's name servers
- and those IP addresses are in /etc/resolv.conf.
- other services such as telnet, ftp, ping work fine using hostnames
But I can't get email to work between the two hosts. When I try, Exim
just returns it to the same machine, with this message included:
A message that you sent could not be delivered to one or more of its
recipients. The following address(es) failed:
tompfr@newdebian.home:
unrouteable mail domain "newdebian.home"
The problem based on the error message, is that Exim doesn't know about
*.home hostnames. My question is: How do I get it to know about them?
I have run eximconfig on both machines, choosing option #1 which is
"Internet machine". That sets up 2 default router entries in
/etc/exim.config as shown at the end of this post. I understand that for
non-local mail, a router has to be configured in /etc/exim.conf, which
then hands it off to a transport, which I assume would be "remote-smtp".
Or no?
I've been going through the Exim documentation, but it sorely lacks for
some SFE (Simple F**king Examples) for those of us with simple needs.
Any pointers in the right direction would be much appreciated, as would
anyone who can straighten out any misunderstanding(s) I have that are
obvious from reading this post <BG>. Thanks.
Here's the routers section on both machines:
######################################################################
# ROUTERS CONFIGURATION #
# Specifies how remote addresses are handled #
######################################################################
# ORDER DOES MATTER #
# A remote address is passed to each in turn until it is accepted. #
######################################################################
# Remote addresses are those with a domain that does not match any item
# in the "local_domains" setting above.
# This router routes to remote hosts over SMTP using a DNS lookup with
# default options.
lookuphost:
driver = lookuphost
transport = remote_smtp
# This router routes to remote hosts over SMTP by explicit IP address,
# given as a "domain literal" in the form [nnn.nnn.nnn.nnn]. The RFCs
# require this facility, which is why it is enabled by default in Exim.
# If you want to lock it out, set forbid_domain_literals in the main
# configuration section above.
literal:
driver = ipliteral
transport = remote_smtp
end
Reply to: