LINUX.IE, website of the Irish Linux Users' Group
Tux rules!

   
Home
New Users
Articles
Download
Projects
Community
Vendors

  Print Version
Email to...
 
Archives:


planetILUG

Recent News

News Archive


Join the
ILUG
on FaceBook


Join the
ILUG
on LinkedIn


Join the
ILUG SETI
Group



















 
 :: Mailing Lists

[ILUG] Running spamassassin on a large number of email messages

[ILUG] Running spamassassin on a large number of email messages

Justin Mason jm at jmason.org
Wed Sep 10 11:44:11 IST 2008


Timothy Murphy writes:
> On Tuesday 09 September 2008, FRLinux wrote:
> 
> I have a directory containing about 50,000 email messages,
> of which I am sure over 95% is spam.
> 
> What is the best (quickest) way of passing these messages through spamassassin
> and deleting those that fail the test.
> [I'm running spamd on the machine in question.]
> 
> A simple script - if appropriate - would be very much appreciated.
> 
> > Hello Timothy, you didn't specify the mailbox format (mbox or Maildir)
> 
> They are in maildir format - 50,000 separate files.


You could run 

    spamassassin -t /path/to/maildir/new > mbox1
    spamassassin -t /path/to/maildir/cur > mbox2

It'll output mboxes with the filtered versions of each message.  You then
need to replace the maildir with the mboxes and remove the ones that
match "X-Spam-Flag: YES".

--j.



More information about the ILUG mailing list
Read this without the formatting.
                                                                                                    

 

Hosted by HEAnet


Maintained by the ILUG website team. The aim of Linux.ie is to support and help commercial and private users of Linux in Ireland. You can display ILUG news in your own webpages, read backend information to find out how. Networking services kindly provided by HEAnet, server kindly donated by Dell. Linux is a trademark of Linus Torvalds, used with permission. No penguins were harmed in the production or maintenance of this highly praised website. Looking for the Indian Linux Users' Group? Try here. If you've read all this and aren't a lawyer: you should be!
RSS Version
Powered by Dell