Hoping someone could help me find my mistake. I adjusting my config to deliver mail using dovecot_lmtp. I have two routers, almost identical. The one for lmtp doesn't match at all while the one without (uses dovecot-lda) matches. The virtual_domains_lmtp comes before the virtual_domains router in the config.
1. LMTP router virtual_domains_lmtp: driver = accept domains = +local_domains condition = ${if < {SPAMREJECT}{1000}} address_data = ${lookup mysql{ \ select smtp, username, users.sa_tag*10 AS sa_tag, users.on_spamassassin AS on_spamassassin, \ domains.spamassassin AS spamassassin, \ users.uid AS uid, users.gid AS gid, users.quota AS quota from users,domains \ where localpart = '${quote_mysql:$local_part}' \ and domain = '${quote_mysql:$domain}' \ and domains.enabled = '1' \ and users.enabled = '1' \ and users.domain_id = domains.domain_id}{$value}fail} # data = ${extract{smtp}{$address_data}} # data = ${extract{username}{$address_data}} # headers_remove to remove subject if spam or X-Spam-Report if not spam and SPAMHEADERTYPE=0. headers_remove = ${if and {{ >={$acl_m_spamscore}{${extract{sa_tag}{$address_data}}}} \ {eq {1}{${extract{on_spamassassin}{$address_data}}}} \ {eq {1}{${extract{spamassassin}{$address_data}}}}} \ {Subject}{${if eq{SPAMHEADERTYPE}{0}{X-Spam-Report}}} \ } # headers_add to rewrite subject and set X-Spam-Report=YES if spam and set X-Spam-Report=NO if not spam. headers_add = ${if and {{ >= {$acl_m_spamscore}{${extract{sa_tag}{$address_data}}}} \ {eq {1}{${extract{on_spamassassin}{$address_data}}}} \ {eq {1}{${extract{spamassassin}{$address_data}}}}} \ {X-Spam-Flag: YES\nSubject: [SPAMTAGTEXT] $h_Subject:\n}{X-Spam-Flag: NO\n} \ } transport = dovecot_virtual_delivery_lmtp retry_use_local_part local_part_suffix = +* local_part_suffix_optional check_local_user cannot_route_message = Unknown user 2. LDA router virtual_domains: driver = redirect domains = +local_domains condition = ${if < {SPAMREJECT}{1000}} address_data = ${lookup mysql{ \ select smtp, username, users.sa_tag*10 AS sa_tag, users.on_spamassassin AS on_spamassassin, \ domains.spamassassin AS spamassassin, \ users.uid AS uid, users.gid AS gid, users.quota AS quota from users,domains \ where localpart = '${quote_mysql:$local_part}' \ and domain = '${quote_mysql:$domain}' \ and domains.enabled = '1' \ and users.enabled = '1' \ and users.domain_id = domains.domain_id}{$value}fail} data = ${extract{smtp}{$address_data}} # data = ${extract{username}{$address_data}} # headers_remove to remove subject if spam or X-Spam-Report if not spam and SPAMHEADERTYPE=0. headers_remove = ${if and {{ >={$acl_m_spamscore}{${extract{sa_tag}{$address_data}}}} \ {eq {1}{${extract{on_spamassassin}{$address_data}}}} \ {eq {1}{${extract{spamassassin}{$address_data}}}}} \ {Subject}{${if eq{SPAMHEADERTYPE}{0}{X-Spam-Report}}} \ } # headers_add to rewrite subject and set X-Spam-Report=YES if spam and set X-Spam-Report=NO if not spam. headers_add = ${if and {{ >= {$acl_m_spamscore}{${extract{sa_tag}{$address_data}}}} \ {eq {1}{${extract{on_spamassassin}{$address_data}}}} \ {eq {1}{${extract{spamassassin}{$address_data}}}}} \ {X-Spam-Flag: YES\nSubject: [SPAMTAGTEXT] $h_Subject:\n}{X-Spam-Flag: NO\n} \ } # file_transport = virtual_delivery file_transport = dovecot_virtual_delivery # transport = dovecot_virtual_delivery_lmtp reply_transport = address_reply pipe_transport = address_pipe retry_use_local_part allow_fail local_part_suffix = +* local_part_suffix_optional -- Best regards, Odhiambo WASHINGTON, Nairobi,KE +254 7 3200 0004/+254 7 2274 3223 In an Internet failure case, the #1 suspect is a constant: DNS. "Oh, the cruft.", egrep -v '^$|^.*#' ¯\_(ツ)_/¯ :-) [How to ask smart questions: http://www.catb.org/~esr/faqs/smart-questions.html] -- ## subscription configuration (requires account): ## https://lists.exim.org/mailman3/postorius/lists/exim-users.lists.exim.org/ ## unsubscribe (doesn't require an account): ## exim-users-unsubscr...@lists.exim.org ## Exim details at http://www.exim.org/ ## Please use the Wiki with this list - http://wiki.exim.org/