Topic: Scanning and removing existing spam messages?
==== Required information ====
- iRedMail version (check /etc/iredmail-release): 0.9.3
- Linux/BSD distribution name and version: CentOS 7.1
- Store mail accounts in which backend (LDAP/MySQL/PGSQL): MariaDB
- Web server (Apache or Nginx): Apache
====
Greetings,
iRedmail hasn't been flagging spam messages for a long time and there are 1000s in iMap/Dovecot email folders.
I manually moved some messages in one account to a Junk folder for training and ran sa-learn spam to update the tags.
Now I need to run "some job" on the INBOXes of all user accounts where existing messages are analyzed, retagged and MOVED to a Junk folder so they can be reviewed and deleted.
I tried running `spamc -c < message` in the .Junk/cur folder and all of the messages report 0/0 even though I trained on them.
sa-learn --spam --username=vmail /var/mail/vmail1/my.tld/o/n/o/onno-2016.01.04.23.27.14/Maildir/.Junk/{cur,new}
cd /var/mail/vmail1/my.tld/o/n/o/onno-2016.01.04.23.27.14/Maildir/.Junk/cur
for i in *; do spamc -c < $i; done
all report 0/0
1. Why is spamc showing 0/0?
2. Once I get spamc to show them as spam (not 0/0) what command do I run to analyze INBOX/cur and re-flag each message analyzed as spam and then move those to JUNK/cur for verification and deletion?
Thanks!
----
Spider Email Archiver: On-Premises, lightweight email archiving software developed by iRedMail team. Supports Amazon S3 compatible storage and custom branding.