On Fri, Jul 3, 2009 at 5:47 PM, Luigi Rosa <[email protected]> wrote:

> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> Given a Linux mail server with Postfix+Dovecot using MySQL as userbase, a
> single
> Linux user for file system access, two mail domains configured (acme1.com
> acme2.com) and a maildir structure as follows
>
> \var\spool\mail\acme1.com-
>                         \user1
>                         \user2
>                         \user3
> \var\spool\mail\acme2.com-
>                         \user1
>                         \user2
>                         \user3
>
>
> I want that the mail of [email protected] and [email protected] goes in
> \var\spool\mail\acme1.com\user1
>

That's the job for your MTA. Simply make acme2.com and alias to acme1.com


>
> Note that there could be some users not equal between two domains.


You mean that there can be [email protected] but no [email protected]? Well, in
the case of aliasing, or address rewriting (BTW, I only know how to use Exim
so I am talking about the conceptualization here), if acme2.com is an alias
of acme1.com, then users only need to exist on acme1.com. Suppose there is
[email protected] and no account exists for [email protected] then in the
case of aliasing the mail to johndoe will fail!


> What is the best practice?
>
> 1) Alias at Postfix level


I was going to say yes, but please note my explanation above.


>
>
> 2) The same maildir path specified in MySQL record


Not really. Doesn't sound good. Deliver mail based on the existence/validity
of e-mail account.


>
> 3) ln -s between \var\spool\mail\acme1.com\user1 and \var\spool\mail\
> acme2.com\user1
>

Forget this.


>
> 4) Else? (Dovecot virtual mailbox)


I haven't tried this at all.




-- 
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254733744121/+254722743223
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
"If you have nothing good to say about someone, just shut up!."
              -- Lucky Dube

Reply via email to