Plesk usually uses either Postfix (new versions) or Qmail (old ones).

To find out which one you’re currently using, run the following command via SSH:

# /usr/local/psa/admin/sbin/mailmng –features | grep SMTP_Server

A QUICK COMMANDS GUIDE FOR POSTFIX

Show the email messages in Queue:

postqueue -p | tail -n 1 | cut -d’ ‘ -f5

List all messages currently in queue:

# mailq

To see the contents of an email in queue, including headers, use:

# postcat -vq messageID

*you can see the message ID in the queue

To delete the messages in the queue:

# postsuper -d ALL
# postsuper -d ALL deferred

A QUICK COMMANDS GUIDE FOR  QMAIL

Show the email messages in Queue:

# /var/qmail/bin/qmail-qstat

List all messages currently in queue:

# /var/qmail/bin/qmail-qread

To see the contents of an email in queue, including headers, use:

# find /var/qmail/queue -name NNNN| xargs cat | less
To delete the messages in the queue:
#  service qmail stop
# find /var/qmail/queue/mess -type f -exec rm {} \;# find /var/qmail/queue/info -type f -exec rm {} \;
# find /var/qmail/queue/local -type f -exec rm {} \;
# find /var/qmail/queue/intd -type f -exec rm {} \;
# find /var/qmail/queue/todo -type f -exec rm {} \;
# find /var/qmail/queue/remote -type f -exec rm {} \;
#  service qmail start

To switch from Qmail to Postfix run:

# /usr/local/psa/admin/sbin/autoinstaller –select-release-current –install-component postfix

To switch from Postfix to Qmail run:

# /usr/local/psa/admin/sbin/autoinstaller –select-release-current –install-component qmail

Old mail messages remain unchanged and are available after switching MTAs – but any messages in the queue will be lost.