The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

cpanel's exim not RFC compliant? (550 errors are ignored)

Discussion in 'E-mail Discussions' started by sehh, Jun 23, 2007.

  1. sehh

    sehh Well-Known Member

    Joined:
    Feb 11, 2006
    Messages:
    579
    Likes Received:
    5
    Trophy Points:
    18
    Location:
    Europe
    I found the following message while searching the net, which seems to be true, anyone can comment on this please?

     
  2. sehh

    sehh Well-Known Member

    Joined:
    Feb 11, 2006
    Messages:
    579
    Likes Received:
    5
    Trophy Points:
    18
    Location:
    Europe
    I found what the problem is, apparently the default cpanel exim configuration has very lax rules about delivery failures.

    The default is to re-send emails over and over again for a week, as a result the exim queue becomes huge on a busy server.

    After careful tests, i came up with these:

    auto_thaw = 1d
    ignore_bounce_errors_after = 12h
    timeout_frozen_after = 2d

    it means:
    force a retry for queued emails after 1 day in the queue
    timeout and delete queued emails after 2 days in the queue
    but bounce errors are deleted earlier, within 12hours.
     
  3. cPanelNick

    cPanelNick Administrator
    Staff Member

    Joined:
    Mar 9, 2015
    Messages:
    3,426
    Likes Received:
    2
    Trophy Points:
    38
    cPanel Access Level:
    DataCenter Provider
    You should probably set auto_thaw to something larger then both of the other values.
     
  4. sehh

    sehh Well-Known Member

    Joined:
    Feb 11, 2006
    Messages:
    579
    Likes Received:
    5
    Trophy Points:
    18
    Location:
    Europe
    but if i do that then "timeout_frozen_after" will take first precedence and delete frozen emails before "auto_thaw" has a change to resend them, right?
     
  5. cPanelNick

    cPanelNick Administrator
    Staff Member

    Joined:
    Mar 9, 2015
    Messages:
    3,426
    Likes Received:
    2
    Trophy Points:
    38
    cPanel Access Level:
    DataCenter Provider
    By making auto thaw lower, you are creating the same problem you are trying to avoid:



    auto_thaw Use: main Type: time Default: 0s

    If this option is set to a time greater than zero, a queue runner will try a new delivery attempt on any frozen message, other than a bounce message, if this much time has passed since it was frozen. This may result in the message being re-frozen if nothing has changed since the last attempt. It is a way of saying “keep on trying, even though there are big problems”.

    Note: This is an old option, which predates timeout_frozen_after and ignore_bounce_errors_after. It is retained for compatibility, but it is not thought to be very useful any more, and its use should probably be avoided.
     
  6. sehh

    sehh Well-Known Member

    Joined:
    Feb 11, 2006
    Messages:
    579
    Likes Received:
    5
    Trophy Points:
    18
    Location:
    Europe
    I see what you mean. Unfortunately i see no results either way.

    As per your suggestion i changed my configuration to:

    Code:
    ignore_bounce_errors_after = 12h
    timeout_frozen_after = 2d
    auto_thaw = 3d
    
    unfortunately my email queue is still huge and growing (685 emails, it was around 300 before).

    many of them are 4 or 3 days old, which means the "timeout_frozen_after" isn't doing anything.
     
  7. sehh

    sehh Well-Known Member

    Joined:
    Feb 11, 2006
    Messages:
    579
    Likes Received:
    5
    Trophy Points:
    18
    Location:
    Europe
    Since nothing i try can delete my frozen and old messages from the queue, i found this little command that i run as a cronjob and does it all !!!

    Code:
    exiqgrep -i -o 259200 | xargs /usr/sbin/exim -Mrm
    
    it will delete all queued/frozen messages that have been in the queue for 3 days.
     
  8. gundamz

    gundamz Well-Known Member

    Joined:
    Mar 27, 2002
    Messages:
    245
    Likes Received:
    0
    Trophy Points:
    16
    I got:

    root@sr [~]# exiqgrep -i -o 259200 | xargs /usr/sbin/exim -Mrm
    Line mismatch: 692d 1EFkjY-0006KK-GY <>
    exim: no message ids given after -Mrm option
     
  9. sehh

    sehh Well-Known Member

    Joined:
    Feb 11, 2006
    Messages:
    579
    Likes Received:
    5
    Trophy Points:
    18
    Location:
    Europe
    indeed, you'll get "no message ids" when there are no emails to delete

    you may ignore that error, or remove it completely by adding " >/dev/null 2>/dev/null" at the end of the command.
     
  10. gundamz

    gundamz Well-Known Member

    Joined:
    Mar 27, 2002
    Messages:
    245
    Likes Received:
    0
    Trophy Points:
    16
    okay.

    exiqgrep -i -o 259200 | xargs /usr/sbin/exim -Mrm > /dev/null 2>&1 will get server to delete the old mail?
     
  11. sehh

    sehh Well-Known Member

    Joined:
    Feb 11, 2006
    Messages:
    579
    Likes Received:
    5
    Trophy Points:
    18
    Location:
    Europe
    thats correct, i'm using that in a cron job.
     
Loading...

Share This Page