cPanel Exim How To Clear The Mail Queue

Here’s the proper way to clear the exim mail queue on a cpanel server.

/etc/init.d/exim stop;
sleep 10;
killall -9 exim eximd
sleep 5;

#clean out the mail queue
find /var/spool/exim -mindepth 2 -type f -exec rm -rf {} \;

#clean out the mail db files
find /var/spool/exim/db -type f -exec rm -rf {} \;

#reset the eximstats database tables
echo “truncate table sends;” | mysql eximstats
echo “truncate table defers;” | mysql eximstats
echo “truncate table failures;” | mysql eximstats
echo “truncate table smtp;” | mysql eximstats

/etc/init.d/exim restart

Was this answer helpful?

 Print this Article

Also Read

Unable to see my website

We have sometime receive clients complain of server not reachable, while their IP are blocked by...

Clone a cPanel server configuration to a new server (excluding server specific items)

As a Server Administrator, I want the ability to clone a cPanel server to a new setup, so that...

How do I create a MySQL database and user in cPanel/WHM? How do I connect them?

To create a MySQL database and user, log into the cPanel interface for the desired domain and...

FTP - Uploading the Website

There are many ways that you can transfer files and folder to and from your hosting account. We...

Redirect HTTP TO HTTPS Automatically

If you need to create a .htaccess file, you can use your control panel's file manager.Using the...