Quoth Viktor Dukhovni (21 Aug 2015, 15:13):

> $ postmap -q @example.com ldap:/usr/local/etc/postfix/example.com-users.cf
>> $ postmap -q @example.com ldap:/usr/local/etc/postfix/example.com-groups.cf
>> $
>>
>> Nothing, as expected.
>
>
> In that case, SMTP mail to non-existent recipients in virtual mailbox
> domains will be rejected.

That caused my confusion.  I had expected that for local submissions as well.

>>> And where did this mail originate?  (Show all log entries for the queue id).
>
>>
>> Locally submitted, by:
>
>
> For local submission, virtual_mailbox_maps is not checked until
> the mail gets to the delivery agent.  Only virtual alias domains
> have recipient validation done by the queue manager (via
> trivial-rewrite).

That figures.  A "telnet localhost smtp" verifies that.

Which makes all recipients (save one) bounce; I need a mailbox map, then.

> If local mail is sent to non-existent users, you'll need to configure
> dovecot (or other delivery agent) to know which users are valid.
>
> Alternatively, make the domain a virtual alias domain, and rewrite
> all valid users to some other domain actually used for delivery.

There should be no local delivery; I'm happy with that.  Thanks for pointing 
out my oversight!

After changing my virtual_mailbox_maps

  virtual_alias_maps = proxy:ldap:/usr/local/etc/postfix/example.com-groups.cf 
proxy:ldap:/usr/local/etc/postfix/example.com-users.cf
  virtual_mailbox_maps = $virtual_alias_maps

... things start working out.  I'll have to remember to test using "telnet 
localhost smtp" to verify.

Regards, Jeroen.
-- 
Jeroen Scheerder
ON2IT B.V.
Regterweistraat 7
4181 CE WAARDENBURG
T: +31 88 22 66 200 | F: +31 88 22 66 299
W: www.on2it.net    | E: jeroen.scheer...@on2it.net

Attachment: signature.asc
Description: OpenPGP digital signature

Reply via email to