How to Delete,Create,Modify and Restrict Distribution list in zimbra

How to Delete,Create,Modify and Restrict Distribution list in zimbra

by -
1 2199

How to Get, Add, Delete, Distribution List using zmprov and How to restrict DistributionList.

:- How to create DistributionList

[zimbra@kvit ~]$ zmprov cdl

:- How to add DistributionListMember.

[zimbra@kvit ~]$ zmprov adlm


:- How to list all DistributionList.

[zimbra@kvit ~]$ zmprov gadl

:- How to check DistributionListMember in our exsiting DL

[zimbra@kvit ~]$ zmprov gdl | grep zimbraMailForwardingAddress: | awk {‘print $2’}

Note:- Here is only one member which add earlier.
:- Now i am going to add more member.

[zimbra@kvit ~]$ zmprov adlm
[zimbra@kvit ~]$ zmprov adlm

:- How to remove DistributionListMember.

[zimbra@kvit ~]$ zmprov rdlm

:- How to rename DistributionList.

[zimbra@kvit ~]$ zmprov rdl

:- How to Delete DistributionList

[zimbra@kvit ~]$ zmprov ddl

How to restrict DistributionList

By default, Zimbra distribution list or group list can receive email from anywhere. This can be dangerous because it could be a target of spam attackers.

We do that through recipent restraction.



:- Login as zimbra user Put your domain or user who can send email to your protected DL or users

[root@kvit ~]# su – zimbra
[zimbra@kvit ~]$ vi /opt/zimbra/postfix/conf/permitted_senders Ok Ok Ok

Note:- We can can allowed user or domain as per requirement

:- This is your list of email addresses that may only receive email from permitted senders which we have created above

[zimbra@kvit ~]$ vim /opt/zimbra/postfix/conf/protected_ permitted_ permitted_senders

Note:- In above file we can put DL,Email,Domain as per requirement.

:- Now we have to do postmap

[zimbra@kvit ~]$ postmap /opt/zimbra/postfix/conf/permitted_senders
[zimbra@kvit ~]$ postmap /opt/zimbra/postfix/conf/protected_recipients
[zimbra@kvit ]$ vim /opt/zimbra/conf/zmconfigd/
check_recipient_access hash:/opt/zimbra/postfix/conf/protected_recipients <——-Put this line—>
%%contains VAR:zimbraServiceEnabled cbpolicyd, check_policy_service inet:localhost:@@cbpolicyd_bind_port@@%%
%%contains VAR:zimbraMtaRestriction reject_invalid_helo_hostname%%
%%contains VAR:zimbraMtaRestriction reject_non_fqdn_helo_hostname%%
%%contains VAR:zimbraMtaRestriction reject_non_fqdn_sender%%
%%contains VAR:zimbraMtaRestriction reject_unknown_client_hostname%%
%%contains VAR:zimbraMtaRestriction reject_unknown_helo_hostname%%
%%contains VAR:zimbraMtaRestriction reject_unknown_sender_domain%%
%%explode reject_rbl_client VAR:zimbraMtaRestrictionRBLs%%
%%contains VAR:zimbraMtaRestriction check_policy_service unix:private/policy%%

:- Put these lines at botam in

[zimbra@kvit ]$ vim /opt/zimbra/postfix/conf/
permitted_senders = check_sender_access hash:/opt/zimbra/postfix/conf/permitted_senders, reject
smtpd_restriction_classes = permitted_senders

[zimbra@kvit]$ postfix reload
/postfix-script: refreshing the Postfix mail system


Note:- Please check mail through sending mail.Only prabhat( can send mail.


How to restrict DL in zimbra

DL Restriction in zimbra

:- Send mail from other account (

Note:- This user (   can not sendmail on DL

Screenshot from 2015-06-24 19:54:52

:- You can also check in zimbra.log that is not able to sendmail on DL


Enjoy  🙂

Senior Linux Administrator at KV IT-Solutions Pvt Ltd || A Linux Lover || having 4 years of experience || Handling various Linux projects || Email ID : || cell: 9818001497

“We are born free, No gates and Windows can snatch our freedom “

Download PDF


Leave a Reply

Required Captcha *