Page 1 of 1

How to disable local delivery for domain.

Posted: Fri Nov 30, 2012 3:18 am
by 1241tejas
We have hundreds of domain hosted on Zimbra server. Suppose I want to shift domain1.com from the server to other server. I update MX records.

There also domain2.com hosted on Zimbra server. If any users from domain2.com sends mail to domain1.com it delivers locally. I want to deliver it to the server which serves as MX for the domain instead of delivering locally.

This means I want to keep the domain on the server but want to disable the local delivery for the that domain.

How to disable local delivery for domain.

Posted: Fri Nov 30, 2012 3:34 am
by 15337Raunaq
Hey Tejas,
you can check zimbraPrefMailLocalDeliveryDisabled option in zmprov

How to disable local delivery for domain.

Posted: Fri Nov 30, 2012 6:36 am
by 1241tejas
Raunaq, thanks for your reply,

The option zimbraPrefMailLocalDeliveryDisabled decides whether mail should be stored locally if the forwarder is set for that email ID.

I want the setup where there are multiple domains on the single zimbra server and if user from one domain sends and an email to user of another domain it should be delivered by checking proper mx record.

Basically what happens if the both domains are on the same server mails are delivered locally. What if I want to keep the setup of domain on zimbra server but want to shift the domain to another service provider like google apps.

Re: How to disable local delivery for domain.

Posted: Sat Feb 17, 2018 9:50 pm
by mhammett
I'm looking for this as well.

Re: How to disable local delivery for domain.

Posted: Sun Feb 18, 2018 10:16 am
by DualBoot
Hello,

Why do not set up a spli-domain ?

Regards,

Re: How to disable local delivery for domain.

Posted: Sun Feb 18, 2018 1:31 pm
by mhammett
Maybe I misunderstand, but split domain seems to be when you want to forward outgoing messges to a specific mail server. I (and from what I can infer, the OP as well) want to send outgoing messages to any server on the Internet, as designated by that domain's MX record. I don't want any local delivery for that domain. The intention of that domain is simply to authenticate local users (more accurately local automated programs) for remote delivery.

The domain does exist for full send\receive elsewhere. No, the local users I'm referring to can't just relay through that server.

Re: How to disable local delivery for domain.

Posted: Tue Dec 27, 2022 12:03 pm
by neptuneIS
For the record : this shoud do the trick :

zmprov ma user@domain.com zimbraMailStatus disabled


zimbraMailStatus is an LDAP value checked by postfix to verify what is a valid email address

postconf -n | grep virtual
virtual_alias_domains = proxy:ldap:/opt/zimbra/conf/ldap-vad.cf
virtual_alias_expansion_limit = 10000
virtual_alias_maps = proxy:ldap:/opt/zimbra/conf/ldap-vam.cf
virtual_mailbox_domains = proxy:ldap:/opt/zimbra/conf/ldap-vmd.cf
virtual_mailbox_maps = proxy:ldap:/opt/zimbra/conf/ldap-vmm.cf
virtual_transport = error

cat /opt/zimbra/conf/ldap-vam.cf
server_host = ldap://zimbrapro.neptune.fr:389
server_port = 389
search_base =
query_filter = (&(|(zimbraMailDeliveryAddress=%s)(zimbraMailAlias=%s)(zimbraOldMailAddress=%s)(zimbraMailCatchAllAddress=%s))(zimbraMailStatus=enabled))
result_attribute = zimbraMailDeliveryAddress,zimbraMailForwardingAddress,zimbraPrefMailForwardingAddress,zimbraMailCatchAllForwardingAddress
version = 3
start_tls = yes
tls_ca_cert_dir = /opt/zimbra/conf/ca
bind = yes
bind_dn = uid=zmpostfix,cn=appaccts,cn=zimbra
bind_pw = CC53ahI_v
timeout = 30
special_result_attribute = member