[Dovecot] Dovecot + managesieve + ldap not working

Stephan Bosch stephan at rename-it.nl
Wed Oct 5 22:04:31 EEST 2011


On 10/5/2011 6:11 PM, Philip Brechler wrote:
> I want to use managesieve in my dovecot server which uses virtual users and a ldap for the users. This is in my dovecot.conf:
>
> # 1.2.15: /etc/dovecot/dovecot.conf
[...]
> mail_location: maildir:/var/mail/%u/Maildir
> mail_debug: yes
[...]
> plugin:
>    sieve_dir: /var/mail/sievescript/%u_scripts/
[...]
> If I try to talk to managesieve with telnet this happens:
>
>   BYE "Internal error occured. Refer to server log for more information. [2011-10-02 00:48:09]"
>   Connection closed by foreign host.
>
> Dies is a log reading
>
>   2011-10-02 00:48:09 MANAGESIEVE(user): Fatal: Failed to create sieve storage with data: /var/mail/sievescript/user_scripts
>
> But the permissions are 775 dovecot:dovecot and the system tells me that dovecot was the last user who had access to the directory.

I'd expect to see more errors and debug messages preceding the log line 
above.

Looking at your config, I suspect your problem has something to do with 
the fact that you provide no 'home' directory for your users. The 
default location of the active sieve script (as configured with sieve=) 
is ~/.dovecot.sieve. You don't override this, so this is what you are 
now using. Since no home directory is defined, ~/ cannot be substituted, 
causing this failure (there must be an error about this in your logs 
somewhere). You can do something analogous to your sieve_dir setting and 
use % variable substitution in your sieve= setting. Still, having no 
home directory for your users is a bad idea. Read the wiki for more 
information:

http://wiki2.dovecot.org/VirtualUsers/Home

Also read this carefully:

http://wiki2.dovecot.org/Pigeonhole/ManageSieve/Configuration

Regards,

Stephan.




More information about the dovecot mailing list