[Dovecot] How to troubleshoot LDA or LMTP?
Please forgive me if these are silly questions. I am a normal user, not a system administrator. I am using Dovecot as a kind of IMAP caching proxy, i.e. reading IMAP mail via Gnus + Dovecot + Offlineimap. I am trying to enable sieve functionality.
*Desired behaviour* When Gnus (or whatever MUA) asks for new mail from Dovecot, that before Dovecot returns and answer, the sieve rules are executed. Please tell me if I completely misunderstand how the mail system works in this instance.
*Actual behaviour* As far as I can tell, not only are the sieve rules not executed, but also neither LDA or LMTP is invoked.
*What works* Running the scripts manually via sieve-filter
works
fine. The next time I read from my local dovecot server the mail is
all in the desired place.
Also, the LMTP service is running, listening on port 24.
*What doesn't work* I thought the next step would be to execute dovecot-lda manually (as is suggested on the wiki and in numerous newsgroup posts), but I can't figure out how to do this. When I execute it as root and provide my non-root username via the -u option, it hangs. I can see that it spawns a child process that executes as the non-root user (specified with the -u option). So, could someone tell how to execute dovecot-lda manually please?
Also, when does LMTP process messages? When sending mail via SMTP, or when reading mail via IMAP? I would prefer to use LMTP rather than LDA.
*My environment* Fedora 19 & sendmail. Is any other information relevant, apart from the dovecot configuration?
Thank you,
John
.2.4: /etc/dovecot/dovecot.conf # OS: Linux 3.10.4-300.fc19.x86_64 x86_64 Fedora release 19 (Schrödinger’s Cat) auth_socket_path = /var/run/dovecot/auth-userdb debug_log_path = /var/log/dovecot-debug.log disable_plaintext_auth = no hostname = falcon.novoalexandrovsk.ru info_log_path = /var/log/dovecot-info.log lda_mailbox_autocreate = yes lda_mailbox_autosubscribe = yes login_greeting = Dovecot ready, folks! mail_access_groups = mail mail_debug = yes mail_location = mbox:~/mail/mailboxes:DIRNAME=mBoX-MeSsAgEs:INDEX=~/mail/index:CONTROL=~/mail/control:INBOX=/var/spool/mail/%u managesieve_notify_capability = mailto managesieve_sieve_capability = fileinto reject envelope encoded-character vacation subaddress comparator-i;ascii-numeric relational regex imap4flags copy include variables body enotify environment mailbox date ihave mbox_write_locks = fcntl namespace inbox { inbox = yes location = mailbox Drafts { special_use = \Drafts } mailbox Junk { special_use = \Junk } mailbox Sent { special_use = \Sent } mailbox "Sent Messages" { special_use = \Sent } mailbox Trash { special_use = \Trash } prefix = } passdb { driver = pam } plugin { sieve = ~/.dovecot.sieve sieve_dir = ~/sieve sieve_global_dir = /var/lib/dovecot/sieve/global/ sieve_global_path = /var/lib/dovecot/sieve/default.sieve } postmaster_address = johnfrombluff@gmail.com protocols = imap lmtp sieve service auth { unix_listener auth-userdb { mode = 0600 user = mail } } service lmtp { executable = lmtp -L inet_listener lmtp { address = 192.168.0.101 127.0.0.1 ::1 port = 24 } user = mail } service managesieve-login { inet_listener sieve { port = 4190 } process_min_avail = 1 service_count = 1 vsz_limit = 64 M } service managesieve { process_limit = 10 } ssl = required ssl_cert =
On 8/5/2013 4:28 AM, John Williams wrote:
*Desired behaviour* When Gnus (or whatever MUA) asks for new mail from Dovecot, that before Dovecot returns and answer, the sieve rules are executed. Please tell me if I completely misunderstand how the mail system works in this instance.
Sieve is invoked by LDA or LMTP during delivery from the upstream MTA. The purpose of this is to sort the mail into the appropriate folder during delivery, and update the Dovecot indexes at this time.
...
*What doesn't work* I thought the next step would be to execute dovecot-lda manually (as is suggested on the wiki and in numerous newsgroup posts), but I can't figure out how to do this. When I execute it as root and provide my non-root username via the -u option, it hangs. I can see that it spawns a child process that executes as the non-root user (specified with the -u option). So, could someone tell how to execute dovecot-lda manually please?
I don't have the answer to this question. You desire to use Dovecot in a manner likely not anticipated by its designer. What you want may/not be possible.
Also, when does LMTP process messages?
When the upstream MTA connects and delivers a message. LMTP is identical to SMTP but for a few commands, thus transmission of messages occurs in an almost identical manner to SMTP, over a network socket. The socket connection can be local to a host, or over a network between two hosts.
-- Stan
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1
On Mon, 5 Aug 2013, John Williams wrote:
Please forgive me if these are silly questions. I am a normal user, not a system administrator. I am using Dovecot as a kind of IMAP caching proxy, i.e. reading IMAP mail via Gnus + Dovecot + Offlineimap. I am trying to enable sieve functionality.
Offlineimap is to replicate two IMAP instances, so it believes that the message had been already delivered (and filtered). Usually one would use fetchmail and stuffs the messages into a local MTA. But then, the message are gone from the upstream server.
Steffen Kaiser -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.11 (GNU/Linux)
iQEVAwUBUgD2UV3r2wJMiz2NAQL63gf7BrTcvMLWubqC/eYIgB88TJCA5l3uNzcV D0mklPNy05PiocFUqwIwTkq/1MNSg0yplO2zTHLLNwUiB9YIX1IBj8ojTN037LcE EYtwNGUR5eBYatw7z9w/uIzkHtJlTf+7jOtpOoqJbD19a0pujUxP5/rCtmLv/6br R0oK0IXHsLIxchA5sftWBSq+JLPcFQEbStWp+WPtJ4QJP3B2UCD7CHjqBMHhbA2g iQRZ8EfHKoc2g96DbGnTQvDNwNv/HaWeU345zMXuguKw2EhbH05/T3JaOm9BSFn1 MoHBkhmiIv2udU+x/ArqGpw0VCY2ssN+sYrJ2FGvj16qIyVGlR5edw== =3l4v -----END PGP SIGNATURE-----
participants (3)
-
John Williams
-
Stan Hoeppner
-
Steffen Kaiser