-----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 user1 at acme1.com and user1 at acme2.com goes in \var\spool\mail\acme1.com\user1 Note that there could be some users not equal between two domains. What is the best practice? 1) Alias at Postfix level 2) The same maildir path specified in MySQL record 3) ln -s between \var\spool\mail\acme1.com\user1 and \var\spool\mail\acme2.com\user1 4) Else? (Dovecot virtual mailbox) Thank you. Ciao, luigi - -- / +--[Luigi Rosa]-- \ Blessed are they who Go Around in Circles, for they Shall be Known as Wheels. -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iEYEARECAAYFAkpOGf8ACgkQ3kWu7Tfl6ZTJ1ACgp52Fy7PbGpnU9pFnvVioNcFO OO8AoJRGG2UkyPXczR/bkAXqwjmVtpyL =Loje -----END PGP SIGNATURE-----
I can't say it's best practice, it depends on your setting. I'm allowing IMAP login from both user1 at acme1.com and user1 at acme2.com, to some extent it's user1 at acme1.com & user2 at acme2.com to the same maildir location, and I'm taking the 2) approach.> 2) The same maildir path specified in MySQL recordHTH - Joseph On 3-Jul-09, at 10:47 AM, Luigi Rosa 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 user1 at acme1.com and user1 at acme2.com goes in > \var\spool\mail\acme1.com\user1 > > Note that there could be some users not equal between two domains. > > What is the best practice? > > 1) Alias at Postfix level > > 2) The same maildir path specified in MySQL record > > 3) ln -s between \var\spool\mail\acme1.com\user1 and \var\spool\mail > \acme2.com\user1 > > 4) Else? (Dovecot virtual mailbox) > > > > Thank you. > > > > > Ciao, > luigi > > - -- > / > +--[Luigi Rosa]-- > \ > > Blessed are they who Go Around in Circles, > for they Shall be Known as Wheels. > > -----BEGIN PGP SIGNATURE----- > Version: GnuPG v1.4.9 (GNU/Linux) > Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org > > iEYEARECAAYFAkpOGf8ACgkQ3kWu7Tfl6ZTJ1ACgp52Fy7PbGpnU9pFnvVioNcFO > OO8AoJRGG2UkyPXczR/bkAXqwjmVtpyL > =Loje > -----END PGP SIGNATURE-----
On Fri, Jul 3, 2009 at 5:47 PM, Luigi Rosa <lists at luigirosa.com> 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 user1 at acme1.com and user1 at acme2.com 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 userX at acme2.com but no userX at acme1.com? 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 johndoe at acme2.com and no account exists for johndoe at acme1.com then in the case of aliasing the mail to johndoe will fail!> What is the best practice? > > 1) Alias at Postfix levelI was going to say yes, but please note my explanation above.> > > 2) The same maildir path specified in MySQL recordNot 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
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On Fri, 3 Jul 2009, Luigi Rosa wrote: As Joseph said, it is a matter of taste.> > \var\spool\mail\acme1.com- > \user1 > \var\spool\mail\acme2.com- > \user1 > > > I want that the mail of user1 at acme1.com and user1 at acme2.com goes in > \var\spool\mail\acme1.com\user1 > > Note that there could be some users not equal between two domains. > > What is the best practice? > > 1) Alias at Postfix level > > 2) The same maildir path specified in MySQL record > > 3) ln -s between \var\spool\mail\acme1.com\user1 and \var\spool\mail\acme2.com\user1Hmm, personally I'd prefer 2) over 3), e.g. because there is no need for the symlinks, unless other tasks/services _rely_ on the existance of both dirs. Choosing between 1) vs. 2) I'd ask, who is going to login: If you have both user1 at acme1.com _and_ user1 at acme2.com login, use 2), 1) otherwise. But stick to one way for all for sake of maintainability. Variant 2) has the drawback, that you have two distinct user entries with a different password. However, I guess, you can manage to write a SQL query to map both users to one entry in Dovecot, but what about other services? Bye, - -- Steffen Kaiser -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.6 (GNU/Linux) iQEVAwUBSlHFmHWSIuGy1ktrAQL9eggApOuRt0NhnkZbG9hQcua3jJCBboLv08ox e+/fifUOFu4v084sgdRcjM4HwFPx99b4idVUr9TagTiPw6IEDO48EKAR/8oME+Qe +Kszm1raqi1ZRrAJ0UdTfox8+qPCtlFcmh8X6e/sD6nUifoowTKX54iwlKGuPk4J JJWLnC/crcJn8c033fOkjlREcWlkUOsnnM7mQxNGdLOKbtv3uP0fYscWnrrJaCbq Qx9+0SbdStwtifyTVO2s+vhwH5trpRU1TmxDD7kAH0MgZ+YRRABXI73hPloeXHzF ncdIAaWsW3GzSM+SxjDwTkoJMshrK8We8bR730QWRt8X/aSaI9iW+Q==UzXY -----END PGP SIGNATURE-----