Using Procmail, Sendmail with Cyrus

gui gui at
Thu Nov 17 16:33:55 EST 2005

Andrzej Adam Filip wrote:

> gui wrote:
>> I'm trying to use Procmail on my Sendmail/Cyrus server.
>> I'm using cyrus-imapd-2.2.12 and Sendmail 8.13.3on Freebsd 5.4, and 
>> want to use procmail-3.22_6.
>> I couldn't find much information on the web on how to use procmail. 
>> My main objective is to get bsd vacation working - and this requires 
>> procmail.
>> I need vacation because my webmail Horde needs it (cannot use sieve).
>> The only information I can find is :  
>> And the O'Rielly IMAP Management book.  But both are not very clear. 
>> Has anybody installed and configured Procmail on a Sendmail/Cyrus 
>> server?
>> Care to share your experience and a How-To?
>> Thank you very much in anticipation.
> The simplest method is to make sendmail deliver messages via standard 
> local mailer and use ~/.procmailrc to redirect messages to cyrus using 
> "deliver" program from cyrus package.
> There are multitude of cyrus&sendmail integration methods.
> A few are described at:
> e.g. it is possible to select cyrus mailer *after* alias and 
> ~/.forward expansion. It will allow users with OS account to use 
> procmail for processing recived messages. Users without ~/.forward 
> file and existing corresponding cyrus mailobx will get their mail 
> delivered to cyrus mailbox.
hi Andrzej and Everybody

Thank you for the reply.

This is what I did.

Installed procmail.

In my file, I  added 
define(`confLOCAL_MAILER', `cyrusv2')
define(`CYRUS_MAILER_FLAGS','A5 at W')

In my /usr/share/sendmail/cf/mailer/cyrusv2.m4 file,
I modified ifdef(`CYRUSV2_MAILER_ARGS',, `define(`CYRUSV2_MAILER_ARGS', 
`FILE /var/imap/socket/lmtp')')
ifdef(`CYRUSV2_MAILER_ARGS',, `define(`CYRUSV2_MAILER_ARGS', `procmail 
-p /usr/local/etc/procmailrc CYR

and modified
 Mcyrusv2,       P=/usr/local/bin/procmail, 
LAGS), `CYRUSV2'), ....

After doing a make, make install in /etc/mail.
my /etc/mail/ file has this
Mcyrusv2,       P=/usr/local/bin/procmail, F=lsDFMnqXzA@/:|m,
                S=EnvFromSMTP/HdrFromL, R=EnvToL/HdrToL, E=\r\n,
                A=procmail -p /usr/local/etc/procmailrc CYRUSUSER=$u

My /usr/local/etc/procmailrc file reads:
/usr/local/cyrus/bin/deliver -a $CYRUSUSER -m user.$CYRUSUSER

But I cannot send anything to my users.
Got this message in the /var/log/maillog

Nov 17 21:30:21 servername sm-mta[9341]: jAI5UL89009341: 
from=<username at>, size=655, class=0, nrcpts=1, 
msgid=<437CF677.2090901 at>, proto=ESMTP, daemon=IPv4, 
Nov 17 21:30:21 servername sm-mta[9343]: NOQUEUE: Warning: mailer 
cyrusv2: LMTP flag (F=z) turned off
Nov 17 21:30:22 servername sm-mta[9343]: jAI5UL89009341: 
to=<username at>, delay=00:00:01, 
xdelay=00:00:01, mailer=cyrusv2, pri=30655, dsn=2.0.0, stat=Sent

My Sendmail/Cyrus was working fine before I did all this procmail 

Can anybody help?

Thank you very much in anticipation.


More information about the Info-cyrus mailing list