Hello all,
I use dovecot11-1.1.7-1.4.1 with OpenSuse 11.1. Everything works fine, except the vacation with managesieve.
When i send a mail to an address with vacation, i recieve back a vacation message, but i read an error like this into dovecot-deliver.log:
Error: file_dotlock_create(~/.dovecot.lda-dupes) failed: No such file or directory
And then the vacation is send any time, without limits.
I think the problem is dovecot can't find home directory for the mail to write the .dovecot.lda-dupes, but i don't know how to specify that.
Here is my config:
# 1.1.7: /etc/dovecot/dovecot.conf # OS: Linux 2.6.27.29-0.1-default x86_64 openSUSE 11.1 (x86_64) ext3 log_path: /var/log/dovecot-err.log info_log_path: /var/log/dovecot-inf.log protocols: imap imaps pop3 pop3s managesieve login_dir: /var/run/dovecot/login login_executable(default): /usr/lib/dovecot/imap-login login_executable(imap): /usr/lib/dovecot/imap-login login_executable(pop3): /usr/lib/dovecot/pop3-login login_executable(managesieve): /usr/lib/dovecot/managesieve-login first_valid_uid: 51 last_valid_uid: 51 first_valid_gid: 51 last_valid_gid: 51 mail_location: maildir:/var/mail/virtual/%d/%u mail_debug: yes mail_executable(default): /usr/lib/dovecot/imap mail_executable(imap): /usr/lib/dovecot/imap mail_executable(pop3): /usr/lib/dovecot/pop3 mail_executable(managesieve): /usr/lib/dovecot/managesieve mail_plugins(default): quota imap_quota mail_plugins(imap): quota imap_quota mail_plugins(pop3): quota mail_plugins(managesieve): mail_plugin_dir(default): /usr/lib64/dovecot/modules/imap mail_plugin_dir(imap): /usr/lib64/dovecot/modules/imap mail_plugin_dir(pop3): /usr/lib64/dovecot/modules/pop3 mail_plugin_dir(managesieve): /usr/lib64/dovecot/modules/managesieve imap_client_workarounds(default): outlook-idle imap_client_workarounds(imap): outlook-idle imap_client_workarounds(pop3): imap_client_workarounds(managesieve): pop3_uidl_format(default): %08Xu%08Xv pop3_uidl_format(imap): %08Xu%08Xv pop3_uidl_format(pop3): UID%u-%v pop3_uidl_format(managesieve): %08Xu%08Xv sieve_storage(default): sieve_storage(imap): sieve_storage(pop3): sieve_storage(managesieve): /var/mail/virtual/%d/%u/sieve sieve(default): sieve(imap): sieve(pop3): sieve(managesieve): /var/mail/virtual/%d/%u/.dovecot.sieve namespace: type: private prefix: INBOX. inbox: yes list: yes subscriptions: yes auth default: mechanisms: plain login passdb: driver: sql args: /etc/dovecot/dovecot-mysql.conf userdb: driver: passwd userdb: driver: sql args: /etc/dovecot/dovecot-mysql.conf socket: type: listen client: path: /var/spool/postfix/private/auth mode: 432 user: postfix group: postfix master: path: /var/run/dovecot/auth-master mode: 384 plugin: quota: maildir quota: maildir:User quota quota_warning: storage=80%% /usr/bin/quota_warning.sh 80 quota_warning2: storage=90%% /usr/bin/quota_warning.sh 90 quota_warning3: storage=99%% /usr/bin/quota_warning.sh 90 sieve: /var/mail/virtual/%d/%u/.dovecot.sieve sieve_storage: /var/mail/virtual/%d/%u/sieve
And this is my vacation script (generated with smartsieve):
#Mail filter rules for claudio@mediaservice.net #Generated by claudio@mediaservice.net using SmartSieve 1.0.0-RC2 2009/10/26 12:34:19 require ["vacation"];
vacation :days 1 :addresses ["claudio@mediaservice.net"] text: sono assente . ;
##PSEUDO script start #SmartSieveRule#a:6:{s:6:"status";s:7:"ENABLED";s:7:"control";N;s:8:"matchAny";N;s:10:"conditions";a:0:{}s:7:"special";s:8:"vacation";s:7:"actions";a:1:{i:0;a:4:{s:4:"type";s:8:"vacation";s:7:"message";s:12:"sono assente";s:4:"days";s:1:"1";s:9:"addresses";a:1:{i:0;s:24:"claudio@mediaservice.net";}}}} #mode&&basic
How i can fix this?
Thank u,
Claudio.
--
Claudio Prono Systems Development @ PSS Srl, Divisione Implementazione Sistemi Via San Bernardino, 17 - 10137 Torino (TO) - IT Tel +39-011.32.72.100 Fax +39-011.32.46.497 PGP Fingerprint: 75C2 4049 E23D 2FBF A65F 40DB EA5C 11AC C2B0 3647 Disclaimer: http://atpss.net/disclaimer
On 10/26/2009 12:42 PM Claudio Prono wrote:
… When i send a mail to an address with vacation, i recieve back a vacation message, but i read an error like this into dovecot-deliver.log:
Error: file_dotlock_create(~/.dovecot.lda-dupes) failed: No such file or directory … I think the problem is dovecot can't find home directory for the mail to write the .dovecot.lda-dupes, but i don't know how to specify that.
Here is my config:
# 1.1.7: /etc/dovecot/dovecot.conf # OS: Linux 2.6.27.29-0.1-default x86_64 openSUSE 11.1 (x86_64) ext3 log_path: /var/log/dovecot-err.log info_log_path: /var/log/dovecot-inf.log protocols: imap imaps pop3 pop3s managesieve … mail_location: maildir:/var/mail/virtual/%d/%u mail_debug: yes … sieve_storage(default): sieve_storage(imap): sieve_storage(pop3): sieve_storage(managesieve): /var/mail/virtual/%d/%u/sieve sieve(default): sieve(imap): sieve(pop3): sieve(managesieve): /var/mail/virtual/%d/%u/.dovecot.sieve … plugin: … sieve: /var/mail/virtual/%d/%u/.dovecot.sieve sieve_storage: /var/mail/virtual/%d/%u/sieve …
How i can fix this?
Let your mysql based userdb return a home field. Then set your mail_location to maildir:~/Maildir. In order to get this working you have also to move all the files from /var/mail/virtual/example.com/user, except the sieve stuff, into the Maildir folder
Regards, Pascal
The trapper recommends today: f007ba11.0929916@localdomain.org
Pascal Volk ha scritto:
On 10/26/2009 12:42 PM Claudio Prono wrote:
… When i send a mail to an address with vacation, i recieve back a vacation message, but i read an error like this into dovecot-deliver.log:
Error: file_dotlock_create(~/.dovecot.lda-dupes) failed: No such file or directory … I think the problem is dovecot can't find home directory for the mail to write the .dovecot.lda-dupes, but i don't know how to specify that.
Here is my config:
# 1.1.7: /etc/dovecot/dovecot.conf # OS: Linux 2.6.27.29-0.1-default x86_64 openSUSE 11.1 (x86_64) ext3 log_path: /var/log/dovecot-err.log info_log_path: /var/log/dovecot-inf.log protocols: imap imaps pop3 pop3s managesieve … mail_location: maildir:/var/mail/virtual/%d/%u mail_debug: yes … sieve_storage(default): sieve_storage(imap): sieve_storage(pop3): sieve_storage(managesieve): /var/mail/virtual/%d/%u/sieve sieve(default): sieve(imap): sieve(pop3): sieve(managesieve): /var/mail/virtual/%d/%u/.dovecot.sieve … plugin: … sieve: /var/mail/virtual/%d/%u/.dovecot.sieve sieve_storage: /var/mail/virtual/%d/%u/sieve …
How i can fix this?
Let your mysql based userdb return a home field. Then set your mail_location to maildir:~/Maildir. In order to get this working you have also to move all the files from /var/mail/virtual/example.com/user, except the sieve stuff, into the Maildir folder
Regards, Pascal
Sorry but for me is not clear what u say... I can't specify a mail location manually? Like /var/mail/virtual/%d/%u ?
Regards,
Claudio.
--
Claudio Prono Systems Development @ PSS Srl, Divisione Implementazione Sistemi Via San Bernardino, 17 - 10137 Torino (TO) - IT Tel +39-011.32.72.100 Fax +39-011.32.46.497 PGP Fingerprint: 75C2 4049 E23D 2FBF A65F 40DB EA5C 11AC C2B0 3647 Disclaimer: http://atpss.net/disclaimer
On 10/26/2009 05:26 PM Claudio Prono wrote:
Sorry but for me is not clear what u say... I can't specify a mail location manually? Like /var/mail/virtual/%d/%u ?
Regards,
Claudio.
You have to modify your user_query in the dovecot-sql.conf file.
Use for example:
user_query = SELECT CONCAT('/var/mail/virtual/', '%d', '/', '%n')
as home, ... FROM table WHERE ...
In your dovecot.conf file set: mail_location = maildir:~/Mialdir
The tilde (~) will be expanded to the home value from the user_query
Regards, Pascal
The trapper recommends today: cafefeed.0929917@localdomain.org
Pascal Volk ha scritto:
On 10/26/2009 05:26 PM Claudio Prono wrote:
Sorry but for me is not clear what u say... I can't specify a mail location manually? Like /var/mail/virtual/%d/%u ?
Regards,
Claudio.
You have to modify your user_query in the dovecot-sql.conf file. Use for example: user_query = SELECT CONCAT('/var/mail/virtual/', '%d', '/', '%n')
as home, ... FROM table WHERE ...In your dovecot.conf file set: mail_location = maildir:~/Mialdir
The tilde (~) will be expanded to the home value from the user_query
Regards, Pascal
My user_query is this:
user_query = SELECT maildir, 51 AS uid, 51 AS gid, CONCAT('*:bytes=', mailbox.quota ) AS quota_rule FROM mailbox WHERE username = '%u' AND active = '1'
Is wrong?
Regards,
Claudio.
--
Claudio Prono Systems Development @ PSS Srl, Divisione Implementazione Sistemi Via San Bernardino, 17 - 10137 Torino (TO) - IT Tel +39-011.32.72.100 Fax +39-011.32.46.497 PGP Fingerprint: 75C2 4049 E23D 2FBF A65F 40DB EA5C 11AC C2B0 3647 Disclaimer: http://atpss.net/disclaimer
On 10/26/2009 06:05 PM Claudio Prono wrote:
My user_query is this:
user_query = SELECT maildir, 51 AS uid, 51 AS gid, CONCAT('*:bytes=', mailbox.quota ) AS quota_rule FROM mailbox WHERE username = '%u' AND active = '1'
Is wrong?
There is still no home directory for your users. The home directory is the place for a user's: * Maildir, mbox (or which mailbox format ever you choose) * .dovecot.sieve (script or link) * sieve directories for sieve scripts * .dovecot.lda-dupes
Regards, Pascal
The trapper recommends today: beeffeed.0929918@localdomain.org
Pascal Volk schrieb:
There is still no home directory for your users. The home directory is the place for a user's:
- Maildir, mbox (or which mailbox format ever you choose)
- .dovecot.sieve (script or link)
- sieve directories for sieve scripts
- .dovecot.lda-dupes
please allow me to jump in. On my system I have a similar mysql query to determinate the user maildir etc.
With my tests with Exim and Dovecot I had to set the home directory within EXIM, because I found no way to specify the homedir within dovecot.
local_mysql_delivery_dovecot: driver = pipe command = /usr/lib/dovecot/deliver -d $local_part@$domain home_directory = /var/mails/${domain}/${local_part}/
Maybe you can give me an idea to specify the homedir from the mysql query as well.
Stonki
On 10/27/2009 06:54 AM Stefan Onken wrote:
… With my tests with Exim and Dovecot I had to set the home directory within EXIM, because I found no way to specify the homedir within dovecot.
local_mysql_delivery_dovecot: driver = pipe command = /usr/lib/dovecot/deliver -d $local_part@$domain home_directory = /var/mails/${domain}/${local_part}/
Maybe you can give me an idea to specify the homedir from the mysql query as well.
I've done this two mails earlier. ;) http://dovecot.org/list/dovecot/2009-October/044033.html
Maybe http://wiki.dovecot.org/AuthDatabase/SQL#MySQL and http://wiki.dovecot.org/UserDatabase helps a little bit more.
Regards, Pascal
The trapper recommends today: 5e1f1e55.0930015@localdomain.org
Now i am really confused.
The result of that query i have wrotten in the last mail is this:
+--------------------------------------------+-----+-----+------------+ | maildir | uid | gid | quota_rule | +--------------------------------------------+-----+-----+------------+ | domain.net/claudio@domain.net/ | 51 | 51 | *:bytes=0 | +--------------------------------------------+-----+-----+------------+
What is missing ? maildir can't be sufficient as home directory?
Regards,
Claudio.
Pascal Volk ha scritto:
On 10/26/2009 06:05 PM Claudio Prono wrote:
My user_query is this:
user_query = SELECT maildir, 51 AS uid, 51 AS gid, CONCAT('*:bytes=', mailbox.quota ) AS quota_rule FROM mailbox WHERE username = '%u' AND active = '1'
Is wrong?
There is still no home directory for your users. The home directory is the place for a user's:
- Maildir, mbox (or which mailbox format ever you choose)
- .dovecot.sieve (script or link)
- sieve directories for sieve scripts
- .dovecot.lda-dupes
Regards, Pascal
--
Claudio Prono Systems Development @ PSS Srl, Divisione Implementazione Sistemi Via San Bernardino, 17 - 10137 Torino (TO) - IT Tel +39-011.32.72.100 Fax +39-011.32.46.497 PGP Fingerprint: 75C2 4049 E23D 2FBF A65F 40DB EA5C 11AC C2B0 3647 Disclaimer: http://atpss.net/disclaimer
On 10/28/2009 11:47 AM Claudio Prono wrote:
Now i am really confused.
The result of that query i have wrotten in the last mail is this:
+--------------------------------------------+-----+-----+------------+ | maildir | uid | gid | quota_rule | +--------------------------------------------+-----+-----+------------+ | domain.net/claudio@domain.net/ | 51 | 51 | *:bytes=0 | +--------------------------------------------+-----+-----+------------+
What is missing ? maildir can't be sufficient as home directory?
Please stop top posting.
http://wiki.dovecot.org/UserDatabase mentions: The user database lookup returns these fields: * uid * gid * home * mail
Try this query: SELECT maildir AS home, 51 AS uid, 51 AS gid, 'maildir:~/Maildir' as mail, CONCAT('*:bytes=', mailbox.quota ) AS quota_rule FROM mailbox WHERE username = '%u' AND active = '1'
This should return something like: *************************** 1. row *************************** home: domain.net/claudio@domain.net/ uid: 51 gid: 51 mail: maildir:~/Maildir quota_rule: *:bytes=0
You should also prefix home with '/var/mail/virtual/'
SELECT CONCAT('/var/mail/virtual/', maildir) AS home, 51 AS uid, 51 AS gid, 'maildir:~/Maildir' as mail, CONCAT('*:bytes=', mailbox.quota ) AS quota_rule FROM mailbox WHERE username = '%u' AND active = '1'
*************************** 1. row *************************** home: /var/mail/virtual/domain.net/claudio@domain.net/ uid: 51 gid: 51 mail: maildir:~/Maildir quota_rule: *:bytes=0
Regards, Pascal
The trapper recommends today: beeffeed.0930105@localdomain.org
On Wed, 2009-10-28 at 11:47 +0100, Claudio Prono wrote:
Now i am really confused.
The result of that query i have wrotten in the last mail is this:
+--------------------------------------------+-----+-----+------------+ | maildir | uid | gid | quota_rule | +--------------------------------------------+-----+-----+------------+ | domain.net/claudio@domain.net/ | 51 | 51 | *:bytes=0 | +--------------------------------------------+-----+-----+------------+
What is missing ? maildir can't be sufficient as home directory?
If you *really* want to, you can set home=maildir, but that can have some problems. http://wiki.dovecot.org/VirtualUsers#homedirs
Also there's no point in returning "maildir" field from the query. Dovecot ignores that field.
participants (4)
-
Claudio Prono
-
Pascal Volk
-
Stefan Onken
-
Timo Sirainen