ACPI administration advocacy advocacy advocacy opinion alsa apache apple apt aptitude audio authentication awk bash BIOS boot business cache calendar censorship commandline cron database debian desktop development disk dvd economics emacs email europe exim files firefox firewall flash foss freedom ftp fun git grub hardware hardware html images installation ipod kde kernel keyboard knoppix laptop latex linux locale lockin longlines microsoft minitab mplayer multimedia mysql network nfs openbox openoffice opinion opinion partition pdf perl php politics postgresql printing privacy rant rxvt script scripting scsi security sed server shell siteadmin sitenews sitesoftware skype skype slackware sound spam ssh statistics subversion sudo svk swap t23 t43 terminal text thinkpad thunderbird time timezone ubuntu upgrade users versioncontrol video windows wine wordpress wordprocessing X40 xwindows xwindows youtube
Over the last few months on one of my Linux computers, the mail transfer agent, exim has been trying to return email back to certain people to tell them it can't deliver the messages. But because these people are spammers their addresses don't exist so the messages can't be returned. As a result a huge mail queue has been built up of 'frozen' messages.
To get rid of them, log in as root and enter the following command:
exim -bpr | grep frozen | awk {'print $3'} | xargs exim -Mrm
Another useful command is the following one that reports how many frozen mails are in the queue:
exim -bpr | grep frozen | wc -l
And finally this command reports how many mails (frozen or not) are in the queue:
exim -bpr | grep "<" | wc -l
Thanks to this thread for this invaluable advice.Red Hat Certified Technician & Engineer (RHCT and RHCE) Training Guide and Administrator's Reference
Also, instead of doing "grep frozen | wc -l", you can shorten that to "grep -c frozen"
exim -bpc gives a ques count and saves resources as no grepping is needed
Posted by Guest User on 2006-09-08 11:14:07.