[exim] exim-4.69 help routing local_domains messages back to…

Startseite
Nachricht löschen
Nachricht beantworten
Autor: David Favor
Datum:  
To: EXIM Users
Betreff: [exim] exim-4.69 help routing local_domains messages back to port 25
The setup I have has qpsmtpd listening on port 25.

All mail queued to exim for all domains I host *should*
be delivered to port 25 to run through qpsmtpd user filtering
and processing.

The dnslookup router finds the second MX (which should be used)
then fails to use it because it's been removed (removed hosts)
from the list of MX records to try for delivery:

    DNS lookup of net2.coolsurf.com (A) succeeded
    local host in host list - removed hosts:
      net2.coolsurf.com 69.94.137.128 20


I believe what's required is for me to list all my local domains:

    domainlist local_domains = ...


The setup a local_delivery router which routes all messages submitted
to my local_domains to a transport which delivers to port 25 in my
MX list for my local domains.

If someone can point me to a config file example, I'd appreciate
it much.

Thanks.
________

net2#dig davidfavor.com mx

; <<>> DiG 9.5.1-P2-RedHat-9.5.1-2.P2.fc10 <<>> davidfavor.com mx
;; global options: printcmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 63503
;; flags: qr aa rd ra; QUERY: 1, ANSWER: 2, AUTHORITY: 2, ADDITIONAL: 2

;; QUESTION SECTION:
;davidfavor.com.            IN    MX


;; ANSWER SECTION:
davidfavor.com.        86400    IN    MX    10 net1.coolsurf.com.
davidfavor.com.        86400    IN    MX    20 net2.coolsurf.com.


;; AUTHORITY SECTION:
davidfavor.com.        86400    IN    NS    net1.coolsurf.com.
davidfavor.com.        86400    IN    NS    net2.coolsurf.com.


;; ADDITIONAL SECTION:
net1.coolsurf.com.    86400    IN    A    69.94.137.125
net2.coolsurf.com.    86400    IN    A    69.94.137.128


;; Query time: 1 msec
;; SERVER: 127.0.0.1#53(127.0.0.1)
;; WHEN: Thu May 28 11:59:57 2009
;; MSG SIZE rcvd: 143
_______

net2#exim -d -odf -t david@??? </dev/null
Exim version 4.69 uid=0 gid=0 pid=8154 D=fbb95cfd
Berkeley DB: Berkeley DB 4.7.25: (July 9, 2008)
Support for: crypteq iconv() IPv6 PAM Perl Expand_dlfunc TCPwrappers
OpenSSL Content_Scanning Old_Demime
Lookups (built-in): lsearch wildlsearch nwildlsearch iplsearch cdb dbm
dbmnz dnsdb dsearch ldap ldapdn ldapm nis nis0 nisplus passwd sqlite
Authenticators: cram_md5 cyrus_sasl dovecot plaintext spa
Routers: accept dnslookup ipliteral manualroute queryprogram redirect
Transports: appendfile/maildir/mailstore/mbx autoreply lmtp pipe smtp
Fixed never_users: 0
Size of off_t: 8
changed uid/gid: forcing real = effective
uid=0 gid=0 pid=8154
auxiliary group list: <none>
configuration file is /etc/exim/exim.conf
log selectors = 0000dfff 006bb86b
Reset TZ to NULL: time is 2009-05-28 10:01:22
Loading lookup modules from /usr/lib/exim/4.69-7.fc10/lookups
Loaded 0 lookup modules
Total 17 lookups
LOG: MAIN
cwd=/common/cron 5 args: exim -d -odf -t david@???
trusted user
admin user
changed uid/gid: privilege not needed
uid=93 gid=93 pid=8154
auxiliary group list: 12 93
originator: uid=0 gid=0 login=root name=root
sender address = root@???
set_process_info: 8154 accepting a local non-SMTP message from
<root@???>
Sender: root@???
Recipients:
david@???
search_tidyup called
>>Headers received:


rewrite_one_header: type=F:
From: root <root@???>
search_tidyup called
>>Headers after rewriting and local additions:

I Message-Id: <E1M9iyo-00027W-7L@???>
F From: root <root@???>
Date: Thu, 28 May 2009 10:01:22 -0700

Data file written for message 1M9iyo-00027W-7L
*** No recipients
Child process 8155 for sending message
exec /usr/sbin/exim -d=0xfbb95cfd -odi -t -oem -oi -f <> -E1M9iyo-00027W-7L
Exim version 4.69 uid=93 gid=93 pid=8155 D=fbb95cfd
Berkeley DB: Berkeley DB 4.7.25: (July 9, 2008)
Support for: crypteq iconv() IPv6 PAM Perl Expand_dlfunc TCPwrappers
OpenSSL Content_Scanning Old_Demime
Lookups (built-in): lsearch wildlsearch nwildlsearch iplsearch cdb dbm
dbmnz dnsdb dsearch ldap ldapdn ldapm nis nis0 nisplus passwd sqlite
Authenticators: cram_md5 cyrus_sasl dovecot plaintext spa
Routers: accept dnslookup ipliteral manualroute queryprogram redirect
Transports: appendfile/maildir/mailstore/mbx autoreply lmtp pipe smtp
Fixed never_users: 0
Size of off_t: 8
changed uid/gid: forcing real = effective
uid=0 gid=93 pid=8155
auxiliary group list: <none>
configuration file is /etc/exim/exim.conf
log selectors = 0000dfff 006bb86b
Loading lookup modules from /usr/lib/exim/4.69-7.fc10/lookups
Loaded 0 lookup modules
Total 17 lookups
LOG: MAIN
cwd=/var/spool/exim 9 args: /usr/sbin/exim -d=0xfbb95cfd -odi -t -oem
-oi -f <> -E1M9iyo-00027W-7L
trusted user
admin user
changed uid/gid: privilege not needed
uid=93 gid=93 pid=8155
auxiliary group list: 12 93
originator: uid=93 gid=93 login=exim name=
sender address =
set_process_info: 8155 accepting a local non-SMTP message from <>
Sender:
search_tidyup called
>>Headers received:

Auto-Submitted: auto-replied
From: Mail Delivery System <Mailer-Daemon@???>
To: root@???
Subject: Mail failure - no recipient addresses

rewrite_one_header: type=F:
From: Mail Delivery System <Mailer-Daemon@???>
rewrite_one_header: type=T:
To: root@???
search_tidyup called
>>Headers after rewriting and local additions:

Auto-Submitted: auto-replied
F From: Mail Delivery System <Mailer-Daemon@???>
T To: root@???
Subject: Mail failure - no recipient addresses
I Message-Id: <E1M9iyo-00027X-85@???>
Date: Thu, 28 May 2009 10:01:22 -0700

Data file written for message 1M9iyo-00027X-85
>>Generated Received: header line

P Received: from exim by net2.coolsurf.com with local (Exim 4.69)
    id 1M9iyo-00027X-85
    for root@???; Thu, 28 May 2009 10:01:22 -0700
calling local_scan(); timeout=300
local_scan() returned 0 NULL
Writing spool header file
Size of headers = 383
LOG: MAIN
   <= <> R=1M9iyo-00027W-7L U=exim P=local S=683 T="Mail failure - no 
recipient addresses"
search_tidyup called
exec /usr/sbin/exim -d=0xfbb95cfd -odi -Mc 1M9iyo-00027X-85
Exim version 4.69 uid=93 gid=93 pid=8156 D=fbb95cfd
Berkeley DB: Berkeley DB 4.7.25: (July  9, 2008)
Support for: crypteq iconv() IPv6 PAM Perl Expand_dlfunc TCPwrappers 
OpenSSL Content_Scanning Old_Demime
Lookups (built-in): lsearch wildlsearch nwildlsearch iplsearch cdb dbm 
dbmnz dnsdb dsearch ldap ldapdn ldapm nis nis0 nisplus passwd sqlite
Authenticators: cram_md5 cyrus_sasl dovecot plaintext spa
Routers: accept dnslookup ipliteral manualroute queryprogram redirect
Transports: appendfile/maildir/mailstore/mbx autoreply lmtp pipe smtp
Fixed never_users: 0
Size of off_t: 8
changed uid/gid: forcing real = effective
   uid=0 gid=93 pid=8156
   auxiliary group list: <none>
configuration file is /etc/exim/exim.conf
log selectors = 0000dfff 006bb86b
Loading lookup modules from /usr/lib/exim/4.69-7.fc10/lookups
Loaded 0 lookup modules
Total 17 lookups
LOG: MAIN
   cwd=/var/spool/exim 5 args: /usr/sbin/exim -d=0xfbb95cfd -odi -Mc 
1M9iyo-00027X-85
trusted user
admin user
set_process_info:  8156 delivering specified messages
set_process_info:  8156 delivering 1M9iyo-00027X-85
reading spool file 1M9iyo-00027X-85-H
user=exim uid=93 gid=93 sender=
sender_local=0 ident=exim
Non-recipients:
Empty Tree
---- End of tree ----
recipients_count=1
body_linecount=9 message_linecount=9
Delivery address list:
   root@???
locking /var/spool/exim/db/retry.lockfile
locked /var/spool/exim/db/retry.lockfile
EXIM_DBOPEN(/var/spool/exim/db/retry)
returned from EXIM_DBOPEN
opened hints database /var/spool/exim/db/retry: flags=O_RDONLY

>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>

Considering: root@???
unique = root@???
dbfn_read: key=R:coolsurf.com
dbfn_read: key=R:root@???
dbfn_read: key=R:root@???:<>
no domain retry record
no address retry record
root@???: queued for routing
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>

routing root@???
--------> dnslookup router <--------
local_part=root domain=coolsurf.com
calling dnslookup router
dnslookup router called for root@???
domain = coolsurf.com
DNS lookup of coolsurf.com (MX) succeeded
DNS lookup of net1.coolsurf.com (AAAA) gave NO_DATA
returning DNS_NODATA
DNS lookup of net1.coolsurf.com (A) succeeded
DNS lookup of net2.coolsurf.com (AAAA) gave NO_DATA
returning DNS_NODATA
DNS lookup of net2.coolsurf.com (A) succeeded
local host in host list - removed hosts:
net2.coolsurf.com 69.94.137.128 20
fully qualified name = coolsurf.com
host_find_bydns yield = HOST_FOUND (2); returned hosts:
net1.coolsurf.com 69.94.137.125 MX=10
set transport remote_smtp
queued for remote_smtp transport: local_part = root
domain = coolsurf.com
errors_to=NULL
domain_data=NULL localpart_data=NULL
routed by dnslookup router
envelope to: root@???
transport: remote_smtp
host net1.coolsurf.com [69.94.137.125] MX=10
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>

After routing:
   Local deliveries:
   Remote deliveries:
     root@???
   Failed addresses:
   Deferred addresses:
search_tidyup called

>>>>>>>>>>>>>>>> Remote deliveries >>>>>>>>>>>>>>>>

--------> root@??? <--------
search_tidyup called
set_process_info: 8156 delivering 1M9iyo-00027X-85: waiting for a
remote delivery subprocess to finish
selecting on subprocess pipes
changed uid/gid: remote delivery to root@??? with
transport=remote_smtp
uid=93 gid=93 pid=8157
auxiliary group list: <none>
set_process_info: 8157 delivering 1M9iyo-00027X-85 using remote_smtp
remote_smtp transport entered
root@???
coolsurf.com in queue_smtp_domains? no (option unset)
checking status of net1.coolsurf.com
locking /var/spool/exim/db/retry.lockfile
locked /var/spool/exim/db/retry.lockfile
EXIM_DBOPEN(/var/spool/exim/db/retry)
returned from EXIM_DBOPEN
opened hints database /var/spool/exim/db/retry: flags=O_RDONLY
dbfn_read: key=T:net1.coolsurf.com:69.94.137.125
dbfn_read: key=T:net1.coolsurf.com:69.94.137.125:1M9iyo-00027X-85
no message retry record
host retry time not reached: checking ultimate address timeout
now=1243530082 first_failed=1243527716 next_try=1243530118 expired=0
address match: subject=*@net1.coolsurf.com pattern=*
net1.coolsurf.com in "*"? yes (matched "*")
*@net1.coolsurf.com in "*"? yes (matched "*")
received_time=1243530082 diff=0 timeout=345600
net1.coolsurf.com [69.94.137.125] status = unusable
all IP addresses skipped or deferred at least one address
updating wait-remote_smtp database
locking /var/spool/exim/db/wait-remote_smtp.lockfile
locked /var/spool/exim/db/wait-remote_smtp.lockfile
EXIM_DBOPEN(/var/spool/exim/db/wait-remote_smtp)
returned from EXIM_DBOPEN
opened hints database /var/spool/exim/db/wait-remote_smtp: flags=O_RDWR
dbfn_read: key=net1.coolsurf.com
dbfn_write: key=net1.coolsurf.com
added to list for net1.coolsurf.com
Leaving remote_smtp transport
set_process_info: 8157 delivering 1M9iyo-00027X-85 (just run
remote_smtp for root@??? in subprocess)
search_tidyup called
reading pipe for subprocess 8157 (not ended)
read() yielded 75
Z0 item read
remote delivery process 8157 ended
set_process_info: 8156 delivering 1M9iyo-00027X-85
post-process root@??? (1)
LOG: retry_defer MAIN
== root@??? R=dnslookup T=remote_smtp defer (-53): retry
time not reached for any host
>>>>>>>>>>>>>>>> deliveries are done >>>>>>>>>>>>>>>>

changed uid/gid: post-delivery tidying
uid=93 gid=93 pid=8156
auxiliary group list: <none>
set_process_info: 8156 tidying up after delivering 1M9iyo-00027X-85
Processing retry items
Succeeded addresses:
Failed addresses:
Deferred addresses:
root@???: no retry items
end of retry processing
delivery deferred: update_spool=1 header_rewritten=0
Writing spool header file
Size of headers = 383
end delivery of 1M9iyo-00027X-85
search_tidyup called
search_tidyup called
>>>>>>>>>>>>>>>> Exim pid=8156 terminating with rc=0 >>>>>>>>>>>>>>>>

search_tidyup called
>>>>>>>>>>>>>>>> Exim pid=8155 terminating with rc=0 >>>>>>>>>>>>>>>>

search_tidyup called
>>>>>>>>>>>>>>>> Exim pid=8154 terminating with rc=1 >>>>>>>>>>>>>>>>

_______
net2#exim -bP
Loading lookup modules from /usr/lib/exim/4.69-7.fc10/lookups
Loaded 0 lookup modules
no_accept_8bitmime
acl_not_smtp =
acl_not_smtp_mime =
acl_not_smtp_start =
acl_smtp_auth =
acl_smtp_connect =
acl_smtp_data =
acl_smtp_etrn =
acl_smtp_expn =
acl_smtp_helo =
acl_smtp_mail =
acl_smtp_mailauth =
acl_smtp_mime =
acl_smtp_notquit =
acl_smtp_predata =
acl_smtp_quit =
acl_smtp_rcpt =
acl_smtp_starttls =
acl_smtp_vrfy =
admin_groups =
no_allow_domain_literals
no_allow_mx_to_ip
no_allow_utf8_domains
auth_advertise_hosts = *
auto_thaw = 0s
av_scanner = sophie:/var/run/sophie
bi_command =
bounce_message_file =
bounce_message_text =
bounce_return_body
bounce_return_message
bounce_return_size_limit = 100K
bounce_sender_authentication =
callout_domain_negative_expire = 3h
callout_domain_positive_expire = 1w
callout_negative_expire = 2h
callout_positive_expire = 1d
callout_random_local_part = $primary_hostname-$tod_epoch-testing
check_log_inodes = 0
check_log_space = 0
check_rfc2047_length
check_spool_inodes = 0
check_spool_space = 0
daemon_smtp_ports = smtp
daemon_startup_retries = 9
daemon_startup_sleep = 30s
delay_warning = 1d
delay_warning_condition = ${if or {{
!eq{$h_list-id:$h_list-post:$h_list-subscribe:}{} }{
match{$h_precedence:}{(?i)bulk|list|junk} }{
match{$h_auto-submitted:}{(?i)auto-generated|auto-replied} }} {no}{yes}}
no_deliver_drop_privilege
deliver_queue_load_max =
delivery_date_remove
no_disable_ipv6
dns_again_means_nonexist =
dns_check_names_pattern = (?i)^(?>(?(1)\.|())[^\W_](?>[a-z0-9/-]*[^\W_])?)+$
dns_csa_search_limit = 5
dns_csa_use_reverse
dns_ipv4_lookup =
dns_retrans = 0s
dns_retry = 0
no_drop_cr
dsn_from = Mail Delivery System <Mailer-Daemon@$qualify_domain>
envelope_to_remove
errors_copy =
errors_reply_to =
exim_group = exim
exim_path = /usr/sbin/exim
exim_user = exim
extra_local_interfaces =
extract_addresses_remove_arguments
finduser_retries = 0
freeze_tell = postmaster
gecos_name =
gecos_pattern =
gnutls_require_kx =
gnutls_require_mac =
gnutls_require_protocols =
header_line_maxsize = 0
header_maxsize = 1048576
headers_charset = UTF-8
helo_accept_junk_hosts =
helo_allow_chars =
helo_lookup_domains = @ : @[]
helo_try_verify_hosts =
helo_verify_hosts =
hold_domains =
host_lookup =
host_lookup_order = bydns:byaddr
host_reject_connection =
hosts_connection_nolog =
hosts_treat_as_local =
ignore_bounce_errors_after = 2d
ignore_fromline_hosts =
no_ignore_fromline_local
keep_malformed = 4d
ldap_default_servers =
ldap_version = -1
local_from_check
local_from_prefix =
local_from_suffix =
local_interfaces = <; ::0 ; 0.0.0.0
local_scan_path =
local_scan_timeout = 5m
no_local_sender_retain
localhost_number =
log_file_path = /var/log/exim/%s.log
log_selector = +address_rewrite +all_parents +arguments
+connection_reject +delay_delivery +delivery_size +dnslist_defer
+incoming_interface +incoming_port +lost_incoming_connection +queue_run
+received_sender +received_recipients +retry_defer +sender_on_delivery
+size_reject +skip_delivery +smtp_confirmation +smtp_connection
+smtp_protocol_error +smtp_syntax_error +subject +tls_cipher +tls_peerdn
no_log_timezone
lookup_open_max = 25
max_username_length = 0
no_message_body_newlines
message_body_visible = 500
message_id_header_domain =
message_id_header_text =
message_logs
message_size_limit = 50M
no_mua_wrapper
mysql_servers =
never_users =
percent_hack_domains =
no_perl_at_start
perl_startup =
pgsql_servers =
pid_file_path = /var/run/exim.pid
pipelining_advertise_hosts = *
no_preserve_message_logs
primary_hostname = net2.coolsurf.com
no_print_topbitchars
process_log_path =
prod_requires_admin
qualify_domain = coolsurf.com
qualify_recipient = coolsurf.com
queue_domains =
queue_list_requires_admin
no_queue_only
queue_only_file =
queue_only_load =
queue_only_load_latch
queue_only_override
no_queue_run_in_order
queue_run_max = 5
queue_smtp_domains =
receive_timeout = 0s
received_header_text = Received: ${if def:sender_rcvhost {from
$sender_rcvhost\n\t}{${if def:sender_ident {from
${quote_local_part:$sender_ident} }}${if def:sender_helo_name
{(helo=$sender_helo_name)\n\t}}}}by $primary_hostname ${if
def:received_protocol {with $received_protocol}} ${if def:tls_cipher
{($tls_cipher)\n\t}}(Exim $version_number)\n\t${if def:sender_address
{(envelope-from <$sender_address>)\n\t}}id $message_exim_id${if
def:received_for {\n\tfor $received_for}}
received_headers_max = 30
recipient_unqualified_hosts =
recipients_max = 0
no_recipients_max_reject
remote_max_parallel = 2
remote_sort_domains =
retry_data_expire = 1w
retry_interval_max = 1d
return_path_remove
rfc1413_hosts = *
rfc1413_query_timeout = 5s
sender_unqualified_hosts =
smtp_accept_keepalive
smtp_accept_max = 20
smtp_accept_max_nonmail = 10
smtp_accept_max_nonmail_hosts = *
smtp_accept_max_per_connection = 1000
smtp_accept_max_per_host =
smtp_accept_queue = 0
smtp_accept_queue_per_connection = 10
smtp_accept_reserve = 0
smtp_active_hostname =
smtp_banner = $smtp_active_hostname ESMTP Exim $version_number $tod_full
smtp_check_spool_space
smtp_connect_backlog = 20
smtp_enforce_sync
smtp_etrn_command =
smtp_etrn_serialize
smtp_load_reserve =
smtp_max_synprot_errors = 3
smtp_max_unknown_commands = 3
smtp_ratelimit_hosts =
smtp_ratelimit_mail =
smtp_ratelimit_rcpt =
smtp_receive_timeout = 5m
smtp_reserve_hosts =
no_smtp_return_error_details
spamd_address = 127.0.0.1 783
split_spool_directory
spool_directory = /var/spool/exim
sqlite_lock_timeout = 5
no_strict_acl_vars
no_strip_excess_angle_brackets
no_strip_trailing_dot
syslog_duplication
syslog_facility =
syslog_processname = exim
syslog_timestamp
system_filter =
system_filter_directory_transport =
system_filter_file_transport =
system_filter_group =
system_filter_pipe_transport =
system_filter_reply_transport =
system_filter_user =
tcp_nodelay
timeout_frozen_after = 1w
timezone =
tls_advertise_hosts =
tls_certificate =
tls_crl =
tls_dhparam =
tls_on_connect_ports =
tls_privatekey =
no_tls_remember_esmtp
tls_require_ciphers =
tls_try_verify_hosts =
tls_verify_certificates =
tls_verify_hosts =
trusted_groups =
trusted_users =
unknown_login =
unknown_username =
untrusted_set_sender =
uucp_from_pattern =
^From\s+(\S+)\s+(?:[a-zA-Z]{3},?\s+)?(?:[a-zA-Z]{3}\s+\d?\d|\d?\d\s+[a-zA-Z]{3}\s+\d\d(?:\d\d)?)\s+\d\d?:\d\d?
uucp_from_sender = $1
warn_message_file =
write_rejectlog


--
Love feeling your best ever, all day, every day?
Click http://RadicalHealth.com for the easy way!