On 8/16/2010 10:45 AM, Christopher Koeber wrote:
Well, maybe it will help to describe what I am trying to do.
I have a list of folks in my OpenLDAP server that I would like
accounts for. These accounts are for the 'students.wesleyseminary.edu
<http://students.wesleyseminary.edu>' domain.
I also have folks in a 'wesleyministrynetwork.com
<http://wesleyministrynetwork.com>' domain that I would like mail to
be sent to. These folks are going to be in a different organizational
unit.
Obviously, I also will need to have the postmaster/mailerdaemon/etc.
accounts working as well.
Now, from the documentation that I looked at, the virtual maps/alias
settings that I loaded in seemed like the best bet.
Is that correct, or do I need to go in a different direction?
I believe you are heading in the right direction, but you must
understand my comments.
When a bare username is retrieved from a map, $myorigin is appended to
it automatically.
$myorigin defaults to $myhostname
(http://www.postfix.org/postconf.5.html#myorigin)
virtual_ALIAS_maps apply to ALL mail passed through the system and are
applied before delivery.
virtual_MAILBOX_maps validate *and* point to the mailbox (when using the
virtual(8) delivery) for users that are included in the domains for
virtual_MAILBOX_domains
If you do not need to apply alternate names (aka aliases) to users, do
not use virtual_ALIAS_maps.
It is recommended to use virtual_ALIAS_maps for the accounts you pointed
out above and *not* include normal users that virtual_MAILBOX_maps will
do for you.
When you do have a virtual_ALIAS_maps match, make sure it is fully
qualified:
Example:
postmas...@wts-zimbra.wesleysem.edu real.u...@wts-zimbra.wesleysem.edu
I am willing to make any change on the Postfix settings or the server
as necessary.
I will also go through the suggestions as you mentioned below.
Thank you for the help.
Regards,
Christopher Koeber
On Mon, Aug 16, 2010 at 9:01 AM, Brian Evans - Postfix List
<grkni...@scent-team.com <mailto:grkni...@scent-team.com>> wrote:
On 8/15/2010 4:47 PM, Christopher Kurtis Koeber wrote:
Aug 15 16:32:57 WTS-ZIMBRA postfix/qmgr[18608]: 248B53220E2:
from=<ckoe...@wesleyseminary.edu
<mailto:ckoe...@wesleyseminary.edu>>, size=288, nrcpt=1 (queue
active)
Aug 15 16:32:57 WTS-ZIMBRA postfix/virtual[18620]: 248B53220E2:
to=<dbayasekara8...@wts-zimbra.wesleysem.edu
<mailto:dbayasekara8...@wts-zimbra.wesleysem.edu>>,
orig_to=<dbayasekara8...@students.wesleyseminary.edu
<mailto:dbayasekara8...@students.wesleyseminary.edu>>,
relay=virtual,
delay=23, delays=23/0.03/0/0.08, dsn=5.1.1, status=bounced
(unknown user:
"dbayasekara8...@wts-zimbra.wesleysem.edu
<mailto:dbayasekara8...@wts-zimbra.wesleysem.edu>")
OK, your original command shows nothing but I am tring to send
mail to
"students.wesleyseminary.edu
<http://students.wesleyseminary.edu>" which is defined in
my virtual_mailbox_domains.cf
<http://virtual_mailbox_domains.cf> file.
Please notice the lines above. A mail is sent to
"dbayasekara8...@students.wesleyseminary.edu
<mailto:dbayasekara8...@students.wesleyseminary.edu>" but then is
aliased to "dbayasekara8...@wts-zimbra.wesleysem.edu
<mailto:dbayasekara8...@wts-zimbra.wesleysem.edu>" before it
reaches your virtual_mailbox_maps. This probably occurs in
virtual_alias_maps.
According to your previous mail:
Aug 15 13:57:45 WTS-ZIMBRA postfix/smtpd[17373]: maps_find:
virtual_alias_maps:ldap:/etc/postfix/ldap-aliases.cf
<http://ldap-aliases.cf>(0,lock|fold_fix):dbayasekara8...@students.wesleyseminary.edu
<mailto:dbayasekara8...@students.wesleyseminary.edu> =
dbayasekara8469
This will alias the mail to "dbayasekara8...@$myorigin".
Thus, your virtual_mailbox_map fails as you noticed below in
querying with postmap.
I'm not sure what you are trying to accomplish by setting
virtual_alias_maps. However, I strongly suggest returning a fully
qualified address if you do not want to append $myorigin to each
mail.
postmap outputs:
------------------------------------------------------------------
# postmap -q dbayasekara8...@wts-zimbra.wesleysem.edu
<mailto:dbayasekara8...@wts-zimbra.wesleysem.edu>
ldap:/etc/postfix/ldap-maps.cf <http://ldap-maps.cf>
# postmap -q dbayasekara8...@students.wesleyseminary.edu
<mailto:dbayasekara8...@students.wesleyseminary.edu>
ldap:/etc/postfix/ldap-maps.cf <http://ldap-maps.cf>
/home/studentemail/students.wesleyseminary.edu/dbayasekara8469
<http://students.wesleyseminary.edu/dbayasekara8469>
------------------------------------------------------------------
You also may have an error in your results for virtual_mailbox_maps.
Postconf -n:
------------------------------------------------------------------
virtual_mailbox_base = /home/studentemail/
------------------------------------------------------------------
virtual_mailbox_base will prepend to your results from
virtual_mailbox_maps.
The files will attempt to be put at
"/home/studentemail/home/studentemail/students.wesleyseminary.edu/dbayasekara8469
<http://students.wesleyseminary.edu/dbayasekara8469>"
If this is what you want, great. If not, you should fix it.
So the questions I have are (1) what do I need to do to send
mail to the
domains defined in virtual_domains.cf <http://virtual_domains.cf>
and (2) how can I get get the lookups via LDAP working for the
domains
defined in that file?
Thank you for your time.