[Pkg-exim4-users] domain problem

Nik Cain nik.cain@neuf.fr
Thu, 21 Apr 2005 12:39:29 +0200


hi,

This is the first time I've set up a mail server, so go easy on me :-)

I've installed debian sarge, and in the install steps chose mail server 
and web server. During the debconf of exim4 I chose;
split files: yes
internet site
system mail name: cainmedical.com
IP addresses to listen on: left blank
Other destinations: left blank
domains to relay: left blank
machines to relay email for: 192.168.0.0/24
Dial on demand: no

The machine is called server (server.cainmedical.com), so /etc/hostname is:
server
and /etc/hosts has:
127.0.0.1       server.cainmedical.com  localhost       server

A further complication may be that I've got a dynamic IP, and I'm using 
dyndns.org to update DNS entries when I change IP (there's a DNS entry 
pointing to server.cainmedical.com and www.cainmedical.com). They also 
create an mx record.

sending doesn't seem to recognise that cainmedical.com is localhost, and 
goes to do a dnslookup which ends up with the 'lowest numbered MX record 
points to local host' error. Receiving suffers the same thing, and tries 
to relay the mail which fails of course;
2005-04-21 11:50:20 H=webmail3.spymac.net [195.225.149.203] 
F=<nikcain@spymac.com> rejected RCPT <ncain@cainmedical.com>: relay not 
permitted

Have I mis-installed debian or exim somehow so that my domain name isn't 
configured properly, or is the problem really elsewhere?

output from an exim4 -bt -d ncain is shown below.

regards,
Nicholas

server:/home/ncain# exim4 -bt -d ncain
Exim version 4.50 uid=0 gid=0 pid=31126 D=fbb95cfd
Berkeley DB: Sleepycat Software: Berkeley DB 4.2.52: (December  3, 2003)
Support for: iconv() IPv6 GnuTLS
Lookups: lsearch wildlsearch nwildlsearch iplsearch cdb dbm dbmnz 
dsearch nis nis0 passwd
Authenticators: cram_md5 plaintext
Routers: accept dnslookup ipliteral manualroute queryprogram redirect
Transports: appendfile/maildir/mailstore autoreply lmtp pipe smtp
Fixed never_users: 0
changed uid/gid: forcing real = effective
   uid=0 gid=0 pid=31126
   auxiliary group list: <none>
configuration file is /var/lib/exim4/config.autogenerated
log selectors = 00000ffc 00020800
trusted user
admin user
user name "root" extracted from gecos field "root"
originator: uid=0 gid=0 login=root name=root
sender address = root@cainmedical.com
Address testing: uid=0 gid=102 euid=0 egid=102
 >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
Testing ncain@cainmedical.com
 >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
Considering ncain@cainmedical.com
 >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
routing ncain@cainmedical.com
--------> hubbed_hosts router <--------
local_part=ncain domain=cainmedical.com
checking domains
expansion of "${if 
exists{/etc/exim4/hubbed_hosts}{partial-lsearch;/etc/exim4/hubbed_hosts}fail}" 
forced failure: assume not in this list
hubbed_hosts router skipped: domains mismatch
--------> dnslookup_relay_to_domains router <--------
local_part=ncain domain=cainmedical.com
checking domains
cainmedical.com in "@:localhost"? no (end of list)
cainmedical.com in ""? no (end of list)
cainmedical.com in "! +local_domains : +relay_to_domains"? no (end of list)
dnslookup_relay_to_domains router skipped: domains mismatch
--------> dnslookup router <--------
local_part=ncain domain=cainmedical.com
checking domains
cached no match for +local_domains
cached lookup data = NULL
cainmedical.com in "! +local_domains"? yes (end of list)
R: dnslookup for ncain@cainmedical.com
calling dnslookup router
dnslookup router called for ncain@cainmedical.com
   domain = cainmedical.com
DNS lookup of cainmedical.com (MX) succeeded
DNS lookup of cainmedical.com (AAAA) gave NO_DATA
returning DNS_NODATA
DNS lookup of cainmedical.com (A) succeeded
84.97.231.59 in "0.0.0.0 : 127.0.0.0/8 : 192.168.0.0/16 :172.16.0.0/12 : 
10.0.0.0/8 : 169.254.0.0/16"? no (end of list)
local host has lowest MX
fully qualified name = cainmedical.com
host_find_bydns yield = HOST_FOUND_LOCAL (3); returned hosts:
   cainmedical.com 84.97.231.59 MX=5
LOG: MAIN
   lowest numbered MX record points to local host: cainmedical.com 
(while routing <ncain@cainmedical.com>)
dnslookup router: defer for ncain@cainmedical.com
   message: lowest numbered MX record points to local host
ncain@cainmedical.com cannot be resolved at this time:
   lowest numbered MX record points to local host
search_tidyup called