9 msgqueue behavior
3 msgX-Original-To inconsistency
5 msgSMTP Transaction logs?
2 msgbackup mail server problems
4 msgChange error messages
3 msgtransport_maps is ignored
8 msgmails from servers with no PTR
4 msgCustomize postfix's answers
6 msgsend mail to multiple users

transpot decision based on cyrus mailbox existence
\ Jack Bates (20 Jul 2007)
. \ mouss (20 Jul 2007)

2 msgforce a bounce on a message in the queue
5 msgWhat causes: 421 Error: timeout exceeded (in re...
3 msgPrevent specific user to authenticate in SASL/L...
2 msgPrevent specific user to authenticate in SASL/LDAP
12 msgLooking for a fail-over strategy for a mail server
7 msgpostfix/smtpd can works in tls wrapper mode,cou...
2 msgConnection timed out - Issue
4 msgpostfix and field 'Date' in message headers
4 msgbounce notification of relayhost
5 msgPostfix + SASL Problem
Subject:Re: transpot decision based on cyrus mailbox existence
Group:Postfix-users
From:mouss
Date:20 Jul 2007


 
Jack Bates wrote:
> How can Postfix determine if a Cyrus mailbox exists and deliver with
> Procmail if not?
>
> I'm setting up a mail system for a organization where some users want
> IMAP mailboxes and others want mail delivered with Procmail
> (campcoop.com)
>
> I installed Cyrus IMAP because it's the server with which I'm most
> familiar. First I confirmed delivery with Procmail works, then confirmed
> delivery to Cyrus with LMTP works. The challenge is using the
> appropriate transport depending on whether a Cyrus mailbox exists for
> the user.
>
> I've been over documentation for Postfix's numerous transport map
> features. I guess if we were using DBMail, for instance, we could use
> the MySQL transport map. We maintain user accounts in LDAP, so I tried
> at least getting LDAP users' mail delivered to Cyrus and local
> /etc/passwd users' mail delivered with Procmail by setting:
>
> fallback_transport = lmtp:unix:/var/run/cyrus/socket/lmtp
>
> However because NSS knows about LDAP users, even LDAP users' mail gets
> delivered with Procmail.
>
> Could we maybe use the LDAP transport map to check for the user in LDAP
> and deliver to Cyrus if so? Still this is sub-optimal since some LDAP
> users don't have Cyrus mailboxes. We could maybe define an LDAP
> attribute for the user's transport preference, but then we'd need to set
> this preference in addition to creating Cyrus mailboxes. The
> organization is quite small and wants maintaining the mail system to be
> as simple as possible.
>
> Ideally Postfix would be able to decide whether to deliver to Cyrus
> based on whether a Cyrus mailbox existed for the user. Is such thing
> possible?
>

use virtual_alias_maps and transport_maps (transport_maps are enough,
but you may have problems if the ldap server fails)

so first, use virtual_alias_maps to do this mapping:
foo foo
for users found in your directory.

then use transport_maps to deliver cyrus.example.com mail to cyrus. then
let procmail be the defautl LDA.



© 2004-2008 readlist.com