As soon as you enable Pigeonhole with Exim and Dovecot you get email quotas not working any longer. And here is a way how to enable them back with Dovecot.
Update configuration file /etc/dovecot/dovecot.conf:
Add lines
quota = maildir:User quota quota_rule = *:storage=10M
to plugin {...} section
plugin { sieve = ~/.dovecot.sieve sieve_global_path = /var/lib/dovecot/sieve/default.sieve sieve_dir = ~/sieve sieve_global_dir = /var/lib/dovecot/sieve/global/ quota = maildir:User quota quota_rule = *:storage=10M }
Update mail_plugins line in protocol lda {...} and protocol lmtp {...} section to the following:
mail_plugins = $mail_plugins sieve quota
Add line
mail_plugins = quota
into protocol pop3 {...} and protocol imap {...} sections:
protocol pop3 { mail_plugins = quota pop3_uidl_format = %08Xu%08Xv } protocol imap { mail_plugins = quota }
See http://wiki2.dovecot.org/Quota and http://wiki2.dovecot.org/Quota/Configuration for more information.
To enable DA to add the quota options, add:
add_userdb_quota=1
to your directadmin.conf, and restart DA. The internal default is 0.
After turning on the option, to convert all existing files to use the extra format, use one of these new task.queue command:
echo "action=rewrite&value=email_passwd" >> /usr/local/directadmin/data/task.queue
If you need to convert the file only for one user, use this command (replace fred with your real username):
echo "action=rewrite&value=email_passwd&user=fred" >> /usr/local/directadmin/data/task.queue
Download a script (no more needed since Directadmin 1.43.1 is released):
# cd /usr/local/directadmin/scripts/custom # wget -O poralix_transform_passwd.sh http://plugins-da.net/_public_files/poralix_transform_passwd.sh.txt # chmod 700 poralix_transform_passwd.sh # chown diradmin:diradmin poralix_transform_passwd.sh
And update (or create):
# cd /usr/local/directadmin/scripts/custom # touch email_change_pass_post.sh email_create_post.sh # chmod 700 email_change_pass_post.sh email_create_post.sh # chown diradmin:diradmin email_change_pass_post.sh email_create_post.sh
so both of them contain the following lines:
#!/bin/bash /usr/local/directadmin/scripts/custom/poralix_transform_passwd.sh ${domain} >/dev/null 2>&1; exit 0;
To update the existing files, you should run the following command:
# for domain in `cat /etc/virtual/domains`; do /usr/local/directadmin/scripts/custom/poralix_transform_passwd.sh $domain; done;
Have a nice day!
Since a recently released version of Directadmin 1.43.1, you no more need to use any custom scripts (posted above) to have quotas in dovecot password files. It's a new built-in directadmin feature.
Please check this for more information: http://www.directadmin.com/features.php?id=1461