HHawk
Regular Pleskian
I did a search and came up with the following posted by IgorG and I quote:
For mass enabling antispam or antivirus for all emails you can use following scripts:
First; this still works with Plesk 12.5 as well, right?
And how would I enable anti-spam (using the above) and set all emailaccounts to "Move spam to the Spam folder" (move)? I don't dare to fool around myself before I mess up things to be honest.
Also I want the anti-virus to be set to scan only incoming email (in) for all emailaccounts.
Thanks in advance for your help and advice.
Regards
For mass enabling antispam or antivirus for all emails you can use following scripts:
# for i in `mysql -uadmin -p\`cat /etc/psa/.psa.shadow\` psa -Ns -e "select concat(mail.mail_name,\"@\",domains.name) as address from mail,domains,accounts where mail.dom_id=domains.id and mail.account_id=accounts.id order by address"`; do /usr/local/psa/bin/spamassassin -u $i -status true; done
# for i in `mysql -uadmin -p\`cat /etc/psa/.psa.shadow\` psa -Ns -e "select concat(mail.mail_name,\"@\",domains.name) as address from mail,domains,accounts where mail.dom_id=domains.id and mail.account_id=accounts.id order by address"`; do /usr/local/psa/bin/mail -u $i -antivirus inout; done
First; this still works with Plesk 12.5 as well, right?
And how would I enable anti-spam (using the above) and set all emailaccounts to "Move spam to the Spam folder" (move)? I don't dare to fool around myself before I mess up things to be honest.
Also I want the anti-virus to be set to scan only incoming email (in) for all emailaccounts.
Thanks in advance for your help and advice.
Regards