Go Back   HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials > ISPConfig 3 > General

Do you like HowtoForge? Please consider supporting us by becoming a subscriber.
Reply
 
Thread Tools Display Modes
  #1  
Old 10th May 2013, 20:58
monkfish monkfish is offline
HowtoForge Supporter
 
Join Date: Mar 2013
Posts: 106
Thanks: 9
Thanked 15 Times in 14 Posts
Default switching courier/maildrop to dovecot/sieve rules

Hello,

For performance reasons I just flipped a (Centos 6.4 x64 / ISPConfig 3.0.5.2) server from Courier to Dovecot. All the necessary folder changes were made, along with the server configuration System >> Server Config >> Server >> Mail and selecting Dovecot with Sieve.

Everything is working as expected, all clients and webmail users see all folders in correct places, etc. however users with mail filter rules seem to have a problem.

It seems that the .sieve ruleset initially written is structured for maildrop NOT sieve. Therefore I see parse errors such as:-

line 12: error: unexpected character(s) starting with '`'.

If I DISABLE then ENABLE the rule within ispconfig then it is written in the correct format and mail is filtered correctly.

Is this expected behaviour having to do this when flippng from one to the other?

Example is the following rule. Opened up .sieve file and inspected this which is showing in the logs as failing:-

Code:
### BEGIN FILTER_ID:50
`test -e "$DEFAULT/.oracle" && exit 1 || exit 0`
if ( $RETURNCODE != 1 )
{
        `maildirmake -f "oracle" $DEFAULT`
        `chmod -R 0700 "$DEFAULT/.oracle"`
        `echo "INBOX.oracle" >> $DEFAULT/courierimapsubscribed`
}
if (/^From: .*sup\-oracle@mydomain\.com/:h)
{
exception {
ID50EndFolder = "$DEFAULT/.oracle/"
to $ID50EndFolder
}
}
### END FILTER_ID:50
Edited the rule within the ISPConfig gui to disable it, saw it disappear from .sieve file then edited again to re-enable it. It reappeared as follows:-

Code:
### BEGIN FILTER_ID:50
if header :regex    ["from"] [".*sup\-oracle@mydomain\.com"] {
    fileinto "oracle";
    stop;
}
### END FILTER_ID:50
So while I've a feeling the "workaround" is to go through and disable all the rules and re-enable them, can I ask is this expected behaviour when flipping from courier to dovecot?

Thanks for ISPConfig
Reply With Quote
Sponsored Links
  #2  
Old 11th May 2013, 18:13
till till is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 36,202
Thanks: 829
Thanked 5,420 Times in 4,262 Posts
Default

Seems as if you switched without using the courier to dovecot conversion script. There are several threads here in the orum that describe how to migrate a server from courier to dovecot.
__________________
Till Brehm
--
Get ISPConfig support and the ISPConfig 3 manual from ispconfig.org.
Reply With Quote
  #3  
Old 11th May 2013, 19:03
monkfish monkfish is offline
HowtoForge Supporter
 
Join Date: Mar 2013
Posts: 106
Thanks: 9
Thanked 15 Times in 14 Posts
 
Default

Ok, more research suggests I used a "generic" courier >> dovecot migration script and not one targeted for ISPConfig and thus missed out the mail filters.

I have actually found simply editing the rule and saving (without disabling/re-enabling) will cause it to be rewritten in correct sieve format, so thats something.

Just out of interest I see on the roadmap an item aimed at "resync rules", is there anything already I might be able to run to get all the rules rewritten in one go?

Cheers

Monk
Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Ispconfig and iptables rules lanceq Installation/Configuration 0 27th June 2012 23:57
Mailbox Custom Rules federico Installation/Configuration 5 3rd September 2010 16:01
Rewrite Rules tristanlee85 General 2 30th January 2009 05:27
Spamsnake - Problem with spamassassin, FuzzyOcr and MySQL debuguser HOWTO-Related Questions 6 16th September 2008 18:37
Virtual Users with Postfix/Courier/Amavis etc...Quarantine? volksman HOWTO-Related Questions 9 30th January 2008 11:53


All times are GMT +2. The time now is 06:44.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.