Re: [maildropl] Maildroprc and Quota
Brought to you by:
mrsam
From: Renato O. Jr. <ren...@ra...> - 2006-10-10 21:01:06
|
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html> <head> <meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type"> </head> <body bgcolor="#ffffff" text="#000000"> <!----><br> <blockquote cite="mid...@fl..." type="cite"> <pre wrap="">I think that maildrop gets the quota value from authlib, regardless of any Postfix supplied value. Your quota value as returned by authlib needs to include the 'S' on the end. If using MySQL for your data, set the MYSQL_QUOTA_FIELD to be concat(quota,'S') in your authmysqlrc Hope this helps.</pre> </blockquote> <br> I already test it, but unsuccessful. Let me show my whole steps. <br> I´m sorry by the long post...<br> <br> My /etc/maildroprc:<br> <pre wrap="">----------------------------------------------------------- MAIL = "$HOME" QUOTA="$MAILDIRQUOTA"'S' `echo "$HOME --> $QUOTA" >> /tmp/result` `test -d $MAIL` if( $RETURNCODE == 1) { `maildirmake $MAIL` `maildirmake -q $QUOTA $MAIL` } ------------------------------------------------------------ When my LDAP_MAILDIRQUOTA in /etc/courier/authldaprc file is: ----------------------------------------------------------- LDAP_MAILDIRQUOTA mailQuotaSize ----------------------------------------------------------- </pre> The maildrop -d comand reports:<br> <br> <br> <pre wrap="">--------------------------------------------------------------------------------------- maildrop -V 7 -d user@domain < /etc/fstab maildrop: authlib: groupid=108 maildrop: authlib: userid=108 maildrop: authlib: logname=user@domain, home=/var/maildirs/domain/user, mail=(default) maildrop: Changing to /var/maildirs/domain/user Message start at 0 bytes, envelope sender=user@domain /etc/courier/maildroprc(1): MAIL="/var/maildirs/domain/user" /etc/courier/maildroprc(2): QUOTA="40000000S" maildrop: Filtering through `echo "$HOME --> $QUOTA" >> /tmp/result` maildrop: Filtering through `test -d $MAIL` /etc/courier/maildroprc(7): Evaluating IF condition. /etc/courier/maildroprc(7): Operation on: 0 and 1 - equal, result is 0 /etc/courier/maildroprc(7): IF evaluated, result=0 maildrop: Attempting .mailfilter WARN: quota string '40000000' not parseable maildrop: Delivery complete. --------------------------------------------------------------------------------------- As shown, the quota is read ok (QUOTA="40000000S") </pre> And the /tmp/result reports: <br> <pre wrap="">/var/maildirs/domain/user --> 40000000S </pre> (home --> quota)<br> <br> <br> If I change my LDAP_MAILDIRQUOTA in /etc/courier/authldaprc to:<br> <br> <pre wrap="">----------------------------------------------------------- LDAP_MAILDIRQUOTA concat(mailQuotaSize,'S') -----------------------------------------------------------</pre> <br> When I run the comand:<br> maildrop -V 7 -d user@domain < /etc/fstab<br> <br> The WARN is out, as follows:<br> <br> <pre wrap="">-----------------------------------------------------------</pre> maildrop -V 7 -d user@domain < /etc/fstab<br> maildrop: authlib: groupid=108<br> maildrop: authlib: userid=108<br> maildrop: authlib: logname=user@domain, home=/var/maildirs/domain/user, mail=(default)<br> maildrop: Changing to /var/maildirs/domain/user<br> Message start at 0 bytes, envelope sender=user@domain<br> /etc/courier/maildroprc(1): MAIL="/var/maildirs/domain/user"<br> /etc/courier/maildroprc(2): QUOTA="S"<br> maildrop: Filtering through `echo "$HOME --> $QUOTA" >> /tmp/result`<br> maildrop: Filtering through `test -d $MAIL`<br> /etc/courier/maildroprc(7): Evaluating IF condition.<br> /etc/courier/maildroprc(7): Operation on: 0 and 1 - equal, result is 0<br> /etc/courier/maildroprc(7): IF evaluated, result=0<br> maildrop: Attempting .mailfilter<br> maildrop: Delivery complete.<br> <pre wrap="">-----------------------------------------------------------</pre> <br> But the quota is presented as just an "S"<br> <br> The /tmp/result has problem too (with quota), as follows:<br> <br> <br> -------------------------------------------------------------------------------<br> /var/maildirs/domain/user --> S<br> -------------------------------------------------------------------------------<br> <br> <br> The other problem related with maildrop is that when I send a message through Postfix to user that<br> does not have maildir created yet, the maildir is created, but without the maildirsize. If I use the command<br> <br> maildrop -V 7 -d user@domain < file<br> <br> to send a message to a valid user in my LDAP base, but he does not have the maildir created yet,<br> I get the error message "Unable to change to home directory"<br> <br> <br> When I create the maildirsize file running the comand:<br> <br> maildirmake -q QUOTA Maildir<br> <br> In a maildir already created, I can put the maildirsize file in the directory, but without result to "close" maildir<br> when the limit is over.<br> <br> Thanks<br> <br> </body> </html> |