Koozali.org: home of the SME Server

Obsolete Releases => SME 9.x Contribs => Topic started by: mats on November 25, 2014, 05:06:47 PM

Title: pre-existing .procmailrc breaks sieve functionality (after migration to SME 9)
Post by: mats on November 25, 2014, 05:06:47 PM
Hi,

might be a general problem or with our individual SME setup (after migrating from 7 to 8 to 9), however:

on our previous SME 8.1 system we had been using the smeserver-mailsorting contrib and configured mail filtering via procmail.

After migration to SME 9 (ie. backup to USB and replay of the backup when asked to do so upon first reboot of fresh SME9 installation), I reinstalled the additional contribs present in the previous SME 8 system (namely, smeserver-mailsorting, smeserver-roundcube).

Afterwards I installed the smeserver-dovecot-extras and smeserver-roundcube contribs and added a sieve filter rule through the roundcube settings dialog for a specific user. Testing the sieve rule, I found that although the corresponding sieve script was created in the users home directory as intented, it did not have an effect on received mails. I also created a fresh test user with the same result.

The problem seems to be that according to the user's ~/.qmail file mails are piped through to procmail before being piped to dovecot-lda, but in the last step of the default .procmailrc are getting delivered directly to the user's inbox, so never get passed on to dovecot's sieve filtering (mails are logged in /var/log/dovecot, though, as going directly to the INBOX).

Substituting

Code: [Select]
# ----  to the inbox------------------
:0
$DEFAULT

with

Code: [Select]
# ---- final procmail rule: call deliver
:0 w
| /usr/libexec/dovecot/deliver

in ~/.procmailrc allowed me to chain existing procmail and sieve rules correctly (found the hint on this german site: https://wiki.hostsharing.net/index.php?title=Managesieve#Zusammenarbeit_mit_Procmail -> Managesieve collaborating with procmail).

Not sure if this is a bug (as sieve and mailsorting/procmail duplicate functionality to some extend, but I was hoping for a smooth transition for existing users), but maybe some warning on the wiki pages for said contribs could be added with respect to migration to SME 9.0?

Alternatively, either the DEFAULT setting in /etc/e-smith/templates-user/.procmailrc/10header could reflect the usage of dovecot-lda in SME 9, or a switch (similar to the existing zarafa stuff) could be implemented in /etc/e-smith/templates-user/.procmailrc/90default (if sieve is enabled, pipe to dovecot lda)?


Title: Re: pre-existing .procmailrc breaks sieve functionality (after migration to SME 9)
Post by: janet on November 25, 2014, 09:03:11 PM
mats

Please raise a bug in bugzilla
Title: Re: pre-existing .procmailrc breaks sieve functionality (after migration to SME 9)
Post by: mats on November 25, 2014, 10:06:47 PM
Please raise a bug in bugzilla

Would love to 8) but ATM I am not sure against which contrib, smeserver-mailsorting or smeserver-dovecot-extras/sieve stuff?
Title: Re: pre-existing .procmailrc breaks sieve functionality (after migration to SME 9)
Post by: janet on November 25, 2014, 10:34:57 PM
Would love to 8) but ATM I am not sure against which contrib, smeserver-mailsorting or smeserver-dovecot-extras/sieve stuff?

Let that not be an obstacle ! A bug triage member will reallocate if necessary. It sounds to me like procmail is behaving as it should, so maybe the issue is unexpected interaction with sieve stuff.
Title: Re: pre-existing .procmailrc breaks sieve functionality (after migration to SME 9)
Post by: mats on November 26, 2014, 09:37:13 AM
Raised a bug at http://bugs.contribs.org/show_bug.cgi?id=8694 (http://bugs.contribs.org/show_bug.cgi?id=8694) for the smeserver-mailsorting component, because IMHO the problem can be solved by modifiying the user templates in this contrib (and the mailsorting contrib already takes into account 3rd-party stuff like zarafa).