Jump to content
Froxlor Forum
  • 0

roundcube and managesieve issues


steve_adams

Question

Help!,

  I have roundcube installed with managesieve successfully creating filters, but I cannot seem to get the filters to work - even globally.

 

I'm using ubuntu 12.04 LTS, postfix 2.9.6 and dovecot 2.0.19.

 

I think it's my postfix configuration which reads:

 

dovecot          unix  -       n       n       -       -       pipe
        flags=DRhu user=vmail:vmail argv=/usr/lib/dovecot/dovecot-lda -c /etc/dovecot/conf.d/01-dovecot-postfix.conf -d ${recipient}

 

doveconf -n reveals lda is installed and managesieve plugin active:

 

protocols = imap pop3 sieve
service auth {
  unix_listener /var/spool/postfix/private/dovecot-auth {
    group = postfix
    mode = 0660
    user = postfix
  }
  unix_listener auth-userdb {
    group = vmail
    user = vmail
  }
}
service managesieve-login {
  inet_listener sieve {
    port = 4190
  }

...

protocol lda {
  deliver_log_format = msgid=%m: %$
  log_path = /var/log/sieve.log
  mail_plugins = sieve quota
  postmaster_address = postmaster@enventive.com
  quota_full_tempfail = yes
  rejection_reason = Your message to <%t> was automatically rejected:%n%r
}

 

any help will be appreciated

Link to comment
Share on other sites

Recommended Posts

Doop, et. al.,

   I've updated all the config files and restarted dovecot and postfix. Even the default rules are not being processed. The one area where I anticipate a problem is where the sieve and roundcube settings look for the rules. For instance, my user mail directory is actually in:

 

So, the 90-sieve.conf where it specifies
plugin {
        sieve=~/.dovecot.sieve
        sieve_dir=~/sieve
        quota = maildir
}

 

is perhaps inaccurate and should read

sieve = /home/mail/enventive/%d/%n/Maildir/sieve/.dovecot.sieve

sieve_dir = /home/mail/enventive/%d/%n/Maildir/sieve

 

?

These diretories are where the roundcube filters rules are created!

 

----

 

To further complicate the issue, there is no .dovecot.sieve symbolic link being created by the roundcube filter. Rather, in these directories, there is only a managesieve.sieve file containing the freshly created filter rules.

 

If, in the 90-sieve.conf file I specify the sieve_global_dir =/var/lib/dovecot/sieve/ directory, create a global rule and compile it with sivec it does create a .dovecot.sieve symbolic link--- however, that rule is never actuated!

Link to comment
Share on other sites

So, the 90-sieve.conf where it specifies

plugin {

        sieve=~/.dovecot.sieve

        sieve_dir=~/sieve

        quota = maildir

}

 

The configs say:

sieve = ~/sieve/.dovecot.sieve
sieve_dir=~/sieve
Link to comment
Share on other sites

Doop,

  Thanks again. I modified the config so current doveconf. -n reads:

 

plugin {
  quota = maildir
  sieve = ~/sieve/.dovecot.sieve
  sieve_dir = ~/sieve
}

 

Still no love! Can't get the scripts in /home/mail/enventive/%d/%n/Maildir/sieve/ to process, and there is no .dovecot.sieve symbolic link in that directory.

Link to comment
Share on other sites

while grepping the log, I see no errors. Here's what I got by searcjhing for "managesieve":

 

Dec 16 11:14:18 managesieve: Debug: Added userdb setting: mail=maildir:/home/mail/enventive/enventive.com/steve.adams/Maildir/
Dec 16 11:14:18 managesieve: Debug: Added userdb setting: plugin/quota=maildir:storage=0
Dec 16 11:14:18 managesieve(steve.adams@enventive.com): Debug: Effective uid=2000, gid=2000, home=/home/mail/enventive/enventive.com/steve.adams/Maildir/
Dec 16 11:14:18 managesieve(steve.adams@enventive.com): Debug: maildir++: root=/home/mail/enventive/enventive.com/steve.adams/Maildir, index=, control=, inbox=/home/mail/enventive/enventive.com/steve.adams/Maildir, alt=
Dec 16 11:14:18 managesieve(steve.adams@enventive.com): Debug: sieve-storage: using active sieve script path: /home/mail/enventive/enventive.com/steve.adams/Maildir/sieve/.managesieve.sieve
Dec 16 11:14:18 managesieve(steve.adams@enventive.com): Debug: sieve-storage: using sieve script storage directory: /home/mail/enventive/enventive.com/steve.adams/Maildir/sieve/
Dec 16 11:14:18 managesieve(steve.adams@enventive.com): Debug: sieve-storage: using permissions from /home/mail/enventive/enventive.com/steve.adams/Maildir/sieve/: mode=0700 gid=-1
Dec 16 11:14:18 managesieve(steve.adams@enventive.com): Debug: sieve-storage: relative path to sieve storage in active link:

 

and here's what I get when I search for "sieve":

 

Dec 16 15:32:43 auth-worker: Debug: sql(ralph@enventive.com,174.62.143.115): query: SELECT username AS user, password_enc AS password, CONCAT(homedir, maildir) AS userdb_home, uid AS userdb_uid, gid AS userdb_gid,  CONCAT('maildir:', homedir, maildir) AS userdb_mail, CONCAT('maildir:storage=', (quota*1024)) as userdb_quota FROM mail_users WHERE (username = 'ralph@enventive.com' OR email = 'ralph@enventive.com') AND ((imap = 1 AND 'pop3' = 'imap') OR (pop3 = 1 AND 'pop3' = 'pop3') OR 'pop3' = 'smtp' OR 'pop3' = 'sieve')

Link to comment
Share on other sites

specifically where should I look to adjust it? I've followed the link you suggested and heavily modified the 90-sieve.conf to add in the extensions and completely replaced the 20-managesieve.conf with the one from the tutorial. Still no errors and no script activity.

 

here's the mail log of the test transation:

 

Dec 17 00:08:00 envent postfix/smtpd[4186]: connect from mail.port-o-call.net[50.56.219.239]
Dec 17 00:08:00 envent postfix/smtpd[4186]: 9093F2126E: client=mail.port-o-call.net[50.56.219.239]
Dec 17 00:08:00 envent postfix/cleanup[4088]: 9093F2126E: message-id=<9D1E4A29-0B8C-4BBB-8BD3-F5F273F19A30@keystonedesign.com>
Dec 17 00:08:00 envent postfix/qmgr[26582]: 9093F2126E: from=<steve@keystonedesign.com>, size=4918, nrcpt=1 (queue active)
Dec 17 00:08:00 envent postfix/smtpd[4186]: disconnect from mail.port-o-call.net[50.56.219.239]
Dec 17 00:08:00 envent amavis[2989]: (02989-18) ESMTP::10024 /var/lib/amavis/tmp/amavis-20141216T162438-02989: <steve@keystonedesign.com> -> <steve.adams@enventive.com> SIZE=4918 BODY=7BIT Received: from mail.enventive.com ([127.0.0.1]) by localhost (mail.enventive.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP for <steve.adams@enventive.com>; Tue, 16 Dec 2014 17:08:00 -0700 (MST)
Dec 17 00:08:00 envent amavis[2989]: (02989-18) Checking: 62citP-9luZK [50.56.219.239] <steve@keystonedesign.com> -> <steve.adams@enventive.com>
Dec 17 00:08:02 envent postfix/smtpd[4093]: connect from localhost[127.0.0.1]
Dec 17 00:08:02 envent postfix/smtpd[4093]: 1F1AB220A8: client=localhost[127.0.0.1]
Dec 17 00:08:02 envent postfix/cleanup[4088]: 1F1AB220A8: message-id=<9D1E4A29-0B8C-4BBB-8BD3-F5F273F19A30@keystonedesign.com>
Dec 17 00:08:02 envent postfix/qmgr[26582]: 1F1AB220A8: from=<steve@keystonedesign.com>, size=5586, nrcpt=1 (queue active)
Dec 17 00:08:02 envent postfix/smtpd[4093]: disconnect from localhost[127.0.0.1]
Dec 17 00:08:02 envent amavis[2989]: (02989-18) FWD via SMTP: <steve@keystonedesign.com> -> <steve.adams@enventive.com>,BODY=7BIT 250 2.0.0 from MTA([127.0.0.1]:10025): 250 2.0.0 Ok: queued as 1F1AB220A8
Dec 17 00:08:02 envent postfix/virtual[4095]: 1F1AB220A8: to=<steve.adams@enventive.com>, relay=virtual, delay=0.01, delays=0/0/0/0, dsn=2.0.0, status=sent (delivered to maildir)
Dec 17 00:08:02 envent postfix/qmgr[26582]: 1F1AB220A8: removed
Dec 17 00:08:02 envent amavis[2989]: (02989-18) Passed CLEAN, [50.56.219.239] [67.166.55.4] <steve@keystonedesign.com> -> <steve.adams@enventive.com>, Message-ID: <9D1E4A29-0B8C-4BBB-8BD3-F5F273F19A30@keystonedesign.com>, mail_id: 62citP-9luZK, Hits: -1.899, size: 4918, queued_as: 1F1AB220A8, 1521 ms
Dec 17 00:08:02 envent postfix/smtp[4089]: 9093F2126E: to=<steve.adams@enventive.com>, relay=127.0.0.1[127.0.0.1]:10024, delay=1.6, delays=0.12/0/0/1.5, dsn=2.0.0, status=sent (250 2.0.0 from MTA([127.0.0.1]:10025): 250 2.0.0 Ok: queued as 1F1AB220A8)
Dec 17 00:08:02 envent postfix/qmgr[26582]: 9093F2126E: removed

 

Here's the relavent dovecot log:

 

Dec 16 17:02:13 auth-worker: Debug: sql(steve.adams@enventive.com,67.166.55.4): query: SELECT username AS user, password_enc AS password, CONCAT(homedir, maildir) AS userdb_home, uid AS userdb_uid, gid A$
Dec 16 17:02:13 auth: Debug: client out: OK     1       user=steve.adams@enventive.com
Dec 16 17:02:13 auth: Debug: master in: REQUEST 1734475777      4052    1       f09fc19eb101ee840af52a8a7c1d2d1c
Dec 16 17:02:13 auth-worker: Debug: sql(steve.adams@enventive.com,67.166.55.4): SELECT CONCAT(homedir, maildir) AS home, CONCAT('maildir:', homedir, maildir) AS mail, uid, gid, CONCAT('maildir:storage=',$
Dec 16 17:02:13 auth: Debug: master out: USER   1734475777      steve.adams@enventive.com       home=/home/mail/enventive/enventive.com/steve.adams/Maildir/    mail=maildir:/home/mail/enventive/enventive$
Dec 16 17:02:13 pop3: Debug: Loading modules from directory: /usr/lib/dovecot/modules
Dec 16 17:02:13 pop3: Debug: Module loaded: /usr/lib/dovecot/modules/lib10_quota_plugin.so
Dec 16 17:02:13 pop3: Debug: Added userdb setting: mail=maildir:/home/mail/enventive/enventive.com/steve.adams/Maildir/
Dec 16 17:02:13 pop3: Debug: Added userdb setting: plugin/quota=maildir:storage=0
Dec 16 17:02:13 pop3(steve.adams@enventive.com): Debug: Effective uid=2000, gid=2000, home=/home/mail/enventive/enventive.com/steve.adams/Maildir/
Dec 16 17:02:13 pop3(steve.adams@enventive.com): Debug: Quota root: name=storage=0 backend=maildir args=
Dec 16 17:02:13 pop3(steve.adams@enventive.com): Debug: maildir++: root=/home/mail/enventive/enventive.com/steve.adams/Maildir, index=, control=, inbox=/home/mail/enventive/enventive.com/steve.adams/Mail$
 

 

here's the separate sieve.log:

 

Dec 16 17:02:13 pop3-login: Info: Login: user=<steve.adams@enventive.com>, method=PLAIN, rip=67.166.55.4, lip=207.210.202.116, mpid=4053, TLS
Dec 16 17:02:13 pop3(steve.adams@enventive.com): Info: Disconnected: Logged out in=44 out=27537 top=0/0 retr=2/11462 del=0/487 size=2202822
 

do you want to see the doveconf again?

Link to comment
Share on other sites

For the record, I've presently resolved the issue by applying the update to Froxlor 0.9.33-1 and applied the configuration changes that conform to the differences in Dovecot 1.x and 2.x and the sieve filters started working right away. I did have some difficuly permissioning the Dovecot log files correctly, but that too is now resolved.

Link to comment
Share on other sites

Scripts are in /home/mail/customer/domain/user/Maildir/sieve/

 

listing that directory:

ls -la
total 20
drwx------  3 vmail vmail 4096 Jan  8 10:02 .
drwx------ 11 vmail vmail 4096 Jan 13 08:03 ..
-rw-------  1 vmail vmail  317 Jan  8 10:02 managesieve.sieve
-rw-------  1 root  root   313 Dec 16 16:56 managesieve.svbin
drwx------  2 vmail vmail 4096 Jan  8 10:02 tmp

 

that managesieve.sieve file looks like this:

 

require ["vacation","fileinto","copy"];
# rule:[vacation]
if true
{
        vacation :days 10 :subject "out of office reply" "I'm out of the office";
}
# rule:[junk]
if header :contains "Subject" "*** Spam >"
{
        fileinto "INBOX.Junk";
        stop;
}

 

I have also tried configuring 90-sieve.conf with several alternate solutions such as:

 

  # is also where the ManageSieve service stores the user's scripts.
  sieve_dir = /home/mail/enventive/%d/%n/Maildir/sieve, sieve_dir = ~/Maildir/sieve, sieve_dir = ~/sieve

as well as:

sieve = /home/mail/enventive/%d/%n/Maildir/sieve/.dovecot.sieve, sieve = ~/sieve/managesieve.sieve, sieve = ~/sieve/.dovecot.sieve

 

all with no luck

Link to comment
Share on other sites

The scripts are created correctly, so the config is ok. Do you have installed ALL sieve-packages from Dovecot? Managesieve AND sieve? Maybe you have only installed managesieve - so the scripts can be created but Dovecot does not execute them.

 

And please use this config:

sieve_dir = ~/sieve
sieve = ~/sieve/.dovecot.sieve
Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.



×
×
  • Create New...