Sending Rate limit with policyd in zimbra
– For Zimbra 8.7.x/8.8.x
su zimbra
zmprov ms `zmhostname` +zimbraServiceInstalled cbpolicyd +zimbraServiceEnabled cbpolicyd
[Run as Root]
cd /opt/zimbra/data/httpd/htdocs/
ln -s /opt/zimbra/common/share/webui/ .
[Run as zimbra]
vi /opt/zimbra/common/share/webui/includes/config.php
$DB_DSN="sqlite:/opt/zimbra/data/cbpolicyd/db/cbpolicyd.sqlitedb";
Restart Services
su - zimbra -c "zmcontrol restart"
su - zimbra -c "zmapachectl restart"
http://192.168.1.211:7780/webui/index.php
1. Policy > Groups
> Action (Add)
> Name: list_domain [Submit]
> Make group enabled
Select the group and select Members
> Add
> Member: @drbdtest.com
Make the Member enabled
Select Policies > main
> Action: Add
> Name: Rate limit sending message
> Priority: 20
> Description: Rate limit sending message
Make the policy enable
Select Policy > Action > Members > Add
> Source: %list_domain
> Destination: !%list_domain
Make it enable
> Source: !%list_domain
> Destination: any
Make it enable
Select Quotas > Configure
> Action > Add
> Name: Rate Limit
Track: Sender: user@domain
Period: 3600
Link to policy: Rate limit sending message
Defer (Delay)
Data: Sorry your quota to sending email has been full. please try again later
Stop Processing here: No
[Submit]
Make it enable
Above configuration will limit sending message from domain local to outside and outside to any domain with maximum message 200 email/user/hour. Please try to sending message to other domain and see the log information on /opt/zimbra/log/cbpolicyd.log
Ref: https://imanudin.net/2014/09/08/how-to-install-policyd-on-zimbra-8-5/
Ref: https://imanudin.net/2014/09/09/zimbra-tips-how-to-configure-rate-limit-sending-message-on-policyd/
Comments
Post a Comment