Many messages from MAILER-DAEMON@example.com are stuck in mail queue on Plesk server

Follow

Comments

5 comments

  • Avatar
    TorbenH

    First thing is that postqueue -f alone would not work as cron.
    So use

    • /usr/sbin/postqueue -f

    instead.

    Second thing, I would recommend to use the following script, because "postsuper -d ALL" would delete ALL messages from the queue, not only the ones from mailer-deamon:

    • mailq|gawk '/MAILER-DAEMON/ { print $1 }'|/usr/sbin/postsuper -d -

    This removes only the unwanted mails from queue.

    0
    Comment actions Permalink
  • Avatar
    Anton Maslov

    @TorbenH Thank you a lot for the hints! The article was updated. 

    0
    Comment actions Permalink
  • Avatar
    Ian Tresman

    Command: /usr/local/psa/admin/sbin/mailqueuemng --clean

    Can this be modified to clean messages only from the deferred queue?

    0
    Comment actions Permalink
  • Avatar
    Leonid Gukhman

    @Ian Tresman

    The deferred queue can be emptied using the following command:

    # postsuper -d ALL deferred

    To resend all deferred email, use the following one:

    # postsuper -r ALL

    Check the following article, as well: https://support.plesk.com/hc/en-us/articles/115003159349

    0
    Comment actions Permalink
  • Avatar
    Ian Tresman

    Thank you!

    0
    Comment actions Permalink

Please sign in to leave a comment.

Have more questions? Submit a request