Incoming mail stuck in queue

Discussion in 'Server Operation' started by mike_p, May 18, 2011.

  1. mike_p

    mike_p Member

    Up until last night, my server has been working beautifully (ISPConfig3, Centos 5 etc).

    However today it appears all incoming mail is getting stuck in the queue and is marked "(temporary failure)".

    I can't spot anything in the mail logs to identify the problem.

    How should I go about solving the problem?

    Mail software: postfix & dovecot.

    (My users are getting fidgety!)

    I have restarted postfix, dovecot and amavisd : all started without problem.
     
  2. mike_p

    mike_p Member

    I've now found this in my mail logs:

    deliver([email protected]): Module is for different version 1.2.16: /usr/lib/dovecot/lda/lib90_sieve_plugin.so

    So I guess I've had an automatic update of dovecot and have an incompatible sieve plugin.

    Mail server configuation is a black art to me ... so what's the quickest fix?

    Is it safe to temporarily disable sieve?

    Whether it is or not I have just edited my dovecot.conf to remove sieve from the pop3 plugins and restarted dovecot. All the mail immediately came tumbling through. Users now happy!

    BUT how do I fix the sieve incompatability?
     
  3. Lionheart82

    Lionheart82 Member

  4. falko

    falko Super Moderator Howtoforge Staff

    What's your dovecot version now? ISPConfig 3 does not support dovecot 2.x, only 1.x.
     
  5. Lionheart82

    Lionheart82 Member

    I have found the problem see here bottom page (http://www.howtoforge.com/perfect-server-centos-5.6-x86_64-ispconfig-3-p4) but not the sollution yet... it seems that atrpms upgraded dovecot from 1.2.16 into 1.2.17 and now dovecot-sieve does not support it... so we either wait for a sieve upgraded version or we recompile it (dont know how yet).

    If anyone has a sollution please say so :D

    Edit: Is there a way to downgrade dovecot-sieve?(i mean version 1.2.16) i cannot find it from atrpms repo its removed...
     
    Last edited: May 20, 2011
  6. mike_p

    mike_p Member

    Lionheart appears to have identified the precise problem.

    My current dovecot version is 1.2.17

    As I said, by disabling sieve in the dovecot.conf, I have got my mail flowing correctly.
    If dovecot[/-sieve 1.2.17] has been removed from the atrpms repo, maybe they're aware of the problem?
     
    Last edited: May 20, 2011
  7. Lionheart82

    Lionheart82 Member

    Last edited: May 20, 2011
  8. mike_p

    mike_p Member

    .. and I presume you mean 1.2.16 ...
     
  9. saptaru

    saptaru New Member

    Solution - downgrade to Version 1.2.16

    Hi all,

    I have found the solution in order to fix this. The problem is that the lib90-... is not compatible with Version 1.2.17, so in order to solve this I installed dovecot again from rpms like this :

    PLEASE BACK UP ALL YOUR DATA LIKE dovecot.conf and dovecot-sql.conf (you might want to search and backup also dovecot.conf.rpmsave) from /etc/

    first is to stop dovecot: /etc/ini.d/dovecot stop

    remove dovecot without dependencies: rpm -e --nodeps dovecot

    cd /tmp

    download it : wget http://centos.alt.ru/pub/dovecot/1.2.16/RHEL/RPMS/x86_64/dovecot-1.2.16-1.el5.x86_64.rpm

    install from rpms : rpm -i dovecot-1.2.16-1.el5.x86_64.rpm

    then edit /etc/dovecot.conf and paste the content from the old dovecot.conf.rpmsave or dovecot.conf depending what is your previous working backup version.

    /etc/init.d/dovecot start
     
  10. Lionheart82

    Lionheart82 Member

  11. vestport4

    vestport4 New Member

    Temporary solution until sieve update

    After recent updates to dovecot and or postfix around May-June 2011 your email may no longer be working.


    First of all back your files up before editing etc. Normally I create directories in "/root" for files I am working on.

    for example if I were working on postfix I may do something like:

    mkdir /root/postfix-backup
    cp /etc/postfix/* /root/postfix-backup

    then you are pretty much safe or reasonably safe before proceeding.




    Potential issues with this recet email problem are:

    spamassassin and amavis may not be running.

    If this is the case then one or both of the above 2 may be preventing postfix from accepting mail hence the following postfix error messages in "/var/log/maillog".

    status=deferred (temporary failure)
    It may also say mail "loops" or "bounces" back to myself" (This may be a config problem or rather over-written .cf file)

    What I did was copied older postfix config files back that may have been over-written by the upgrade.

    ex:

    cp /etc/postfix/main.cf~ /etc/postfix/main.cf
    cp /etc/postfix/master.cf~ /etc/postfix/master.cf

    Your files may differ! Look at dates etc. and copy back older files to the default before things went haywire!


    Be sure to set postfix to auto startup ex:


    chkconfig --levels 235 sendmail off
    chkconfig --levels 235 postfix on
    /etc/init.d/sendmail stop
    /etc/init.d/postfix start




    If incomming mail is stuck in que and not being delivered by dovecot then you probably want to eliminate the "sieve plugin" in: /etc/dovecot.conf

    Again, you may need to copy older working config files before things went haywire.

    Ex: cp /etc/dovecot.config~ /etc/dovecot.config

    then proceed.



    First stop dovecot like so:

    /etc/init.d/dovecot stop



    You can check the queue by doing a:

    postqueue -pv

    and try to flush it with

    postqueue -f

    but it may not flush yet until you complete the steps below.



    To eliminate the "sieve plugin" in /etc/dovecot.conf just prefix it with a hash mark like so:

    #mail_plugins = sieve quota




    Make sure dovecot is set to run at startup and re-start like so:



    chkconfig --levels 235 dovecot on
    /etc/init.d/dovecot start


    re-check postqueue

    Ex: postqueue pv

    if all went well then there are probably no more messages in the que and your squirrelmail, iphone or whatever you use has now received all of your old messages.


    You should be all set after completing the above steps but I would re-boot and check one more time after re-boot to confirm that dovecot, postfix, spamassasin, amavis are all still running. If not start at the top again or you may need other resources if you did somehting different than just took yum updates etc. or if you did not save older config files etc.


    Most of this has been covered on a few diffierent sites including this one. It took me about a day to sort it all out because as usual when you can't fix it quick sometimes you start grabbing at staws and not keeping everything so focused and methodical. Regardless, I just hope that this helps someone out there fix the problem and save many hours of confusion.

    Please post when new "sieve" plugin can be updated with "yum" or specific instructions how to compile. Then you can re-activate "sieve" plugin in /etc/dovecot.conf.


    Good Luck!


    Art
     
  12. Lionheart82

    Lionheart82 Member

    Sieve plugin has been upgraded and is working ok.
    Just run yum upgrade dovecot-sieve :D
     

Share This Page