#!/bin/blog

November 24, 2011

Dovecot LDA behind Procmail

Filed under: UNIX/Linux/BSD — Tags: , — martin @ 12:17 pm

I have millions of archived mails in my ~/Maildir/ and wanted to change local delivery from a fairly extensive Procmail configuration to the Dovecot LDA, in order to keep the Maildir properly indexed.

In order to do this, I globally enabled LDA and Sieve in the Dovecot configuration, migrated my ~/.procmailrc into a Sieve ruleset (manually, because the converters don’t cut it) and then replaced my trusty old ~/.procmailrc with:

DEFAULT=$HOME/Maildir/
LOGFILE=$DEFAULT/procmail.log
DELIVER="/usr/lib/dovecot/deliver"
DROPPRIVS="YES"
:0 w
| $DELIVER

This way, the global default of using Procmail remains unharmed, maintaining compatibility with other users. On delivery, all messages to me are redirected into the Dovecot delivery system, including Sieve filters.

Advertisements

2 Comments »

  1. Hi,

    are you using virtual-users? Do you have procmail defined in master.cf or as mailbox_command in main.cf?

    thanks!

    Comment by Jussi — February 14, 2013 @ 3:54 pm

    • No virtual users, and yes, mailbox_command = /usr/bin/procmail -p.

      Comment by martin — February 15, 2013 @ 1:06 pm


RSS feed for comments on this post. TrackBack URI

Leave a Reply

Please log in using one of these methods to post your comment:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Create a free website or blog at WordPress.com.

%d bloggers like this: