[Dovecot] Does the list work?

Umut Arus umuta at sabanciuniv.edu
Tue Sep 11 14:20:48 EEST 2007


Please check /var/run/dovecot/auth-master files Is this file writeable 
or you can change mode=0777 in dovecot.conf and restart dovecot (file 
attributes will be change) then test quota.

Regards,

Osvaldo Alvarez Pozo wrote:

>My sql.conf:
>user_query = SELECT concat('/var/vmail/', maildir, 'Maildir') as home,
>concat('maildir:/var/vmail/', maildir, 'Maildir') as mail, 5000 AS
>uid, 8 AS gid, concat('maildir:storage=', floor(quota/1024)) AS quota
>FROM mailbox WHERE username = '%u' AND active = '1'
>
>password_query = SELECT username as user, password,
>concat('/var/vmail/', maildir, 'Maildir') as home,
>concat('maildir:/var/vmail/', maildir, 'Maildir') as mail , 5000 as
>uid, 12 as gid FROM mailbox WHERE username = '%u' AND active = '1'
>
>
>Dovecot logs:
>dovecot: 2007-09-11 15:01:55 Info: auth(default): master in: USER       1
>contact at rexemple.com        service=deliver
>
>dovecot: 2007-09-11 15:01:55 Info: auth-worker(default):
>sql(contact at exemple.com): SELECT concat('/var/vmail/', maildir,
>'Maildir') as home, concat('maildir:/var/vmail/', maildir, 'Maildir')
>as mail, 5000 AS uid, 8 AS gid, concat('maildir:storage=',
>floor(quota/1024)) AS quota FROM mailbox WHERE username =
>'contact at exemple.com' AND active = '1'
>
>dovecot: 2007-09-11 15:01:55 Info: auth(default): master out: USER
> 1       contact at exemple.com
>home=/var/vmail/exemple.com/contact/Maildir
>mail=maildir:/var/vmail/exemple.com/contact/Maildir        uid=5000
>    gid=8   quota=maildir:storage=1000
>
>dovecot: 2007-09-11 15:12:21 Info: auth(default): master in: USER
> 1       contact at exemple.com        service=deliver
>
>dovecot: 2007-09-11 15:12:21 Info: auth-worker(default):
>sql(contact at exemple.com): SELECT concat('/var/vmail/', maildir,
>'Maildir') as home, concat('maildir:/var/vmail/', maildir, 'Maildir')
>as mail, 5000 AS uid, 8 AS gid, concat('maildir:storage=',
>floor(quota/1024)) AS quota FROM mailbox WHERE username =
>'contact at exemple.com' AND active = '1'
>
>dovecot: 2007-09-11 15:12:21 Info: auth(default): master out: USER
> 1       contact at exemple.com
>home=/var/vmail/exemple.com/contact/Maildir
>mail=maildir:/var/vmail/exemple.com/contact/Maildir        uid=5000
>    gid=8   quota=maildir:storage=1000
>
>But quota does not work
>Thanks
>
>On 9/11/07, Umut Arus <umuta at sabanciuniv.edu> wrote:
>  
>
>> Hello,
>>
>> I had compiled only those parameters,
>> ./configure --with-ssl=openssl --with-mysql --with-ldap
>>--prefix=/usr/local/dovecot
>>
>> My mysql.conf running user_query configuration is,
>> user_query  = SELECT home, uid, gid,
>>concat('maildir:storage=',quota) as quota, mail_plugins
>>FROM users WHERE userid = '%u'
>>
>> Check your, dovecot-deliver.log
>>
>> Healtly dovecot's (in maillog) log,
>> Sep 10 17:05:30 mail2 dovecot: auth(default): pam(umuta,10.10.1.121):
>>lookup service=dovecot
>> Sep 10 17:05:30 mail2 dovecot: auth(default): client out: OK    1
>>user=umuta
>> Sep 10 17:05:30 mail2 dovecot: auth(default): master in: REQUEST        1
>>    26162   1
>> Sep 10 17:05:30 mail2 dovecot: auth-worker(default):
>>sql(umuta,10.10.1.125): SELECT home, uid, gid,
>>concat('maildir:storage=',quota) as quota, mail_plugins
>>FROM users WHERE userid = 'umuta'
>> Sep 10 17:05:30 mail2 dovecot: auth(default): master out: USER  1
>>umuta   home=/home/umuta        uid=8287        gid=100
>>quota=maildir:storage=2048      mail_plugins=quota imap_quota
>>
>>
>> regards,
>>
>> Osvaldo Alvarez Pozo wrote:
>> Hi
>>I thank you very much for your answer
>>I am testing with dovecot-1.0.5.tar.gz i configured it like this:
>>./configure --prefix=/usr/local/dovecot --with-deliver
>>--with-sql-drivers --with-ioloop=epoll --with-notify=dnotify
>>--with-pop3d --with-mysql --with-static-userdb --with-prefetch-userdb
>>--with-sql --with-ssl=openssl
>>
>>I think i 'am a litle lost with the configuration parametres. I was
>>reading the wiki but maybe I 'm missing something.
>>
>>Thanks Very much.
>>
>>
>>On 9/11/07, Umut Arus <umuta at sabanciuniv.edu> wrote:
>>
>>
>> Hello,
>>
>>What is your dovecot version? If you are not using dovecot-1.0.5 (below
>>versions are buggy) you cannot set the users' quota from mysqldb. I had
>>tried with one of buggy version two days.
>>
>>regards,
>>
>>
>>Osvaldo Alvarez Pozo wrote:
>>
>>
>>
>> Hi all
>>Does the list work?
>>I have sent two mail without answer up today.
>>I want to change Courrier-imap by dovecot but i have problems with
>>quota and sieve in dovecot. would you help validating dovecot? I this
>>does not work i would have to stay with courier-imap.
>>
>>
>>This is the mail I sent before.
>>
>>
>>Hi
>>Well my problem is with quota it is not taken into account by deliver
>>i compiled dovecot from sorces and the resault is the same.
>>
>>thoses are my files:
>>
>>File /etc/dovecot/dovecot.conf
>>ssl_cert_file = /etc/apache2/ssl/server.crt
>>ssl_key_file = /etc/apache2/ssl/server.key
>>#ssl_ca_file = /etc/pki/dovecot/certs/ca-bundle.crt
>>protocols = imap pop3 imaps pop3s
>>log_timestamp = "%Y-%m-%d %H:%M:%S "
>>#mail_location = maildir:/export/mail/%d/%u
>>mail_location = maildir:/var/vmail/%d/%u/Maildir
>>mail_extra_groups = mail
>>first_valid_uid = 5000
>>last_valid_uid = 5000
>>maildir_copy_with_hardlinks = yes
>>disable_plaintext_auth = no
>>protocol imap {
>> mail_plugins = quota imap_quota
>> imap_client_workarounds = outlook-idle delay-newmail
>>}
>>protocol pop3 {
>> mail_plugins = quota
>> pop3_client_workarounds = outlook-no-nuls oe-ns-eoh
>>protocol lda {
>> postmaster_address = postmaster at example.com
>> mail_plugins = quota
>> log_path = /var/log/dovecot-deliver.log
>> info_log_path = /var/log/dovecot-deliver.log
>> mail_plugins = cmusieve
>># sieve_global_dir = /etc/dovecot/sieve/
>>global_script_path =/etc/dovecot/sieve/dovecot.sieve
>>}
>>auth default {
>># Having "login" also as a mechanism make sure outlook can use the
>>auth smtpd as well
>># http://wiki.dovecot.org/Authentication/Mechanisms
>> mechanisms = plain login
>> passdb sql {
>> args = /etc/dovecot/sql.conf
>> }
>> userdb sql {
>> args = /etc/dovecot/sql.conf
>> }
>> userdb prefetch {
>> }
>> user = nobody
>>socket listen {
>> master {
>> path = /var/run/dovecot/auth-master
>> mode = 0660
>> user = vmail
>> group = mail
>> }
>>client {
>> path = /var/spool/postfix/private/auth
>> mode = 0660
>> user = postfix
>> group = mail
>> }
>> }
>>}
>>dict {
>>}
>>plugin {
>> quota = maildir:storage=10240:messages=1000
>> acl = vfile:/etc/dovecot/acls
>> trash = /etc/dovecot/trash.conf
>>}
>>file /etc/dovecot/sql.conf
>>driver = mysql
>>default_pass_scheme = MD5
>>connect = host=localhost dbname=postfix user=postfix password=password
>>user_query = SELECT concat('/var/vmail/', maildir, 'Maildir') as home,
>>concat('maildir:/var/vmail/', maildir, 'Maildir') as mail, 5000 AS
>>uid, 8 AS gid, concat('maildir:storage=', floor(quota/1024)) AS quota
>>
>> >FROM mailbox WHERE username = '%u' AND active = '1'
>>
>>
>> password_query = SELECT username as user, password,
>>concat('/var/vmail/', maildir, 'Maildir') as userdb_home,
>>concat('maildir:/var/vmail/', maildir, 'Maildir') as userdb_mail, 5000
>>as userdb_uid, 12 as userdb_gid FROM mailbox WHERE username = '%u' AND
>>active = '1'
>>
>>Thanks
>>
>>Thanks in advance
>>
>>
>>
>>
>>
>>
>> --
>>Umut ARUS
>>System Specialist
>>Sabanci University
>>Information Technology
>>Tel: 0216 483 9172
>>
>>
>>    
>>


-- 
Umut ARUS
System Specialist
Sabanci University
Information Technology
Tel: 0216 483 9172



More information about the dovecot mailing list