[Dovecot] Can't find sieve files
I have been running dovecot on a Fedora 14 host for years and am moving up to Fedora 19.
I have things setup to run as a generic user vmail and have all users mailboxes in /var/vmail which is owned by the vmail user. Each user has a Maildir directory and a sieve directory. I also changed sendmail's procmail to run dovecot so it delivers into /var/vmail/<user>/Maildir instead of /var/spool/mail.
I just copied the /var/vmail directory from the old machine to the new machine and made all the files there owned by vmail that had the same uid. I then compared the /etc/dovecot/conf.d files and made changes to ty and match the previous configuration as much as possible.
I can send mail to a local user and se it show up in the users INBOX. However, when I watch /var/log/maillog when I send the mail I see errors like this:
script /var/vmail//ckottari/sieve/Active.sieve;name=main script (view user logfile /var/vmail//ckottari/sieve/Active.sieve.log for more information) Apr 22 17:05:46 ckottari-dhcp1 dovecot: lda(ckottari): msgid=201404222205.s3MM5jJs003128@ckottari-dhcp1.wrs.com: saved mail to INBOX
When I look at Active.sieve.log:
sieve: info: started log at Apr 22 17:05:46. main script: line 8: error: included personal script 'My RRs.sieve' does not exist. main script: line 9: error: included personal script 'RCPL.sieve' does not exist. main script: line 10: error: included personal script 'New_Incomplete Messages.sieve' does not exist.
Basically, I get an error message for all my scripts that get included by the Active.sieve. The Active.sieve file and all the scripts exist in the /var/vmail/<user>/sieve directory and sieve_dir is set to ~/sieve. So, I am not sure why it can't find them if it can find Active.sieve.
Below is my configuration output. This has been working for years in my Fedora 14 host without errors. But, there are some configuration differences that I just kind of guessed at.
Any ideas on how to get sieve working would be appreciated.
$ dovecot -n # 2.2.12: /etc/dovecot/dovecot.conf # OS: Linux 3.13.5-101.fc19.x86_64 x86_64 Fedora release 19 (Schrödinger’s Cat) login_trusted_networks = 172.25.33.32/5 mail_location = maildir:~/Maildir:LAYOUT=fs managesieve_notify_capability = mailto managesieve_sieve_capability = fileinto reject envelope encoded-character vacation subaddress comparator-i;ascii-numeric relational regex imap4flags copy include variables body enotify environment mailbox date ihave mbox_write_locks = fcntl namespace inbox { inbox = yes location = mailbox Drafts { special_use = \Drafts } mailbox Junk { special_use = \Junk } mailbox Sent { special_use = \Sent } mailbox "Sent Messages" { special_use = \Sent } mailbox Trash { special_use = \Trash } prefix = } passdb { args = dovecot driver = pam } plugin { sieve = ~/sieve/Active.sieve sieve_dir = ~/sieve } protocols = imap sieve ssl = required ssl_cert =
Thanks Chris Kottaridis
On 4/23/2014 12:52 AM, Chris Kottaridis wrote:
Basically, I get an error message for all my scripts that get included by the Active.sieve. The Active.sieve file and all the scripts exist in the /var/vmail/<user>/sieve directory and sieve_dir is set to ~/sieve. So, I am not sure why it can't find them if it can find Active.sieve.
Enable mail_debug=yes. This way, Dovecot should log where it is looking for the Sieve files.
plugin { sieve = ~/sieve/Active.sieve sieve_dir = ~/sieve }
This is not a good idea. Don't put the active script link (sieve=) inside the script storage (sieve_dir=). There is special magic to prevent the Active script from showing up in ManageSieve as an additional script, but it is best to avoid this situation altogether.
Regards,
Stephan.
On 04/22/2014 07:10 PM, Stephan Bosch wrote:
On 4/23/2014 12:52 AM, Chris Kottaridis wrote:
Basically, I get an error message for all my scripts that get included by the Active.sieve. The Active.sieve file and all the scripts exist in the /var/vmail/<user>/sieve directory and sieve_dir is set to ~/sieve. So, I am not sure why it can't find them if it can find Active.sieve. Enable mail_debug=yes. This way, Dovecot should log where it is looking for the Sieve files.
Well indeed that was helpful in the log file I see:
Apr 22 22:51:48 ckottari-dhcp1 dovecot: lda(ckottari): Debug: sieve: script file /var/vmail/ckottari/sieve/My RRs.sieve.sieve not found Apr 22 22:51:48 ckottari-dhcp1 dovecot: lda(ckottari): Debug: sieve: script file /var/vmail/ckottari/sieve/RCPL.sieve.sieve not found
Seems in this version it assumes the files will end in .sieve and I guess that previously they had to have the whole filename in the include statement. So, I removed the .sieve in the include statements:
include :personal "My RRs.sieve"; include :personal "RCPL.sieve";
to include :personal "My RRs"; include :personal "RCPL";
Seems to do it since I get a successful compile now:
Apr 22 23:01:12 ckottari-dhcp1 dovecot: lda(ckottari): Debug: sieve: binary open: binary /var/vmail/ckottari/sieve/Active.svbin stored with different binary version 0.3 (!= 1.0; automatically fixed when re-compiled) Apr 22 23:01:12 ckottari-dhcp1 dovecot: lda(ckottari): Debug: sieve: script `main script' from /var/vmail/ckottari/sieve/Active.sieve;name=main script successfully compiled
plugin { sieve = ~/sieve/Active.sieve sieve_dir = ~/sieve } This is not a good idea. Don't put the active script link (sieve=) inside the script storage (sieve_dir=). There is special magic to prevent the Active script from showing up in ManageSieve as an additional script, but it is best to avoid this situation altogether. OK, I moved Active.sieve out of the sieve_dir directory and relinked to the Main.sieve that is in the sieve directory.
The only other issue is the following Warning I get that doesn't seem to prevent anything, but probably means I don't have something correct:
Apr 22 23:21:30 ckottari-dhcp1 dovecot: auth: Warning: userdb passwd: Move templates args to override_fields setting Apr 22 23:21:30 ckottari-dhcp1 dovecot: auth-worker(5089): Warning: userdb passwd: Move templates args to override_fields setting
Not exactly sure what these warning messages are trying to tell me.
Thanks Chris Kottaridis
Regards,
Stephan.
participants (2)
-
Chris Kottaridis
-
Stephan Bosch