This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision | ||
internet:hosting:virtualmin_spam_troubleshoot [2016/02/05 13:22] gcooper |
internet:hosting:virtualmin_spam_troubleshoot [2016/02/10 09:36] (current) gcooper |
||
---|---|---|---|
Line 3: | Line 3: | ||
https:// | https:// | ||
- | Scan a message | + | :!: Replace the < |
+ | |||
+ | :!: All dashes, spaces and punctuation are important. | ||
+ | |||
+ | ===== Check for Needed Perl Modules ===== | ||
< | < | ||
- | spamassassin -D -t -p / | + | spamassassin -D --lint 2>&1 | grep -i failed |
</ | </ | ||
- | Scan a message as a user: | + | ===== Permissions ===== |
+ | |||
+ | :!: Provisional - Be careful with this - Example is for Ubuntu 14.04 | ||
+ | |||
+ | :!: Use '' | ||
+ | |||
+ | Permissions on '' | ||
< | < | ||
- | su -s / | + | chown -R debian-spamd.debian-spamd /var/lib/spamassassin |
+ | find /var/lib/ | ||
+ | find /var/lib/spamassassin -type d -exec chmod 775 {} \; | ||
+ | chmod 700 /var/lib/spamassassin/sa-update-keys | ||
+ | find /var/lib/ | ||
+ | |||
+ | reboot | ||
</ | </ | ||
- | Train the Bayesian filter | + | ===== Scan a Message ===== |
+ | |||
+ | Scan a message using the '' | ||
< | < | ||
- | su -s /bin/sh -c " | + | spamc -u < |
</ | </ | ||
- | Update rules (taken from ''/ | + | Scan a message as root: |
< | < | ||
- | su - debian-spamd -c "sa-update --gpghomedir | + | spamassassin |
</ | </ | ||
- | Permissions on '' | + | Scan a message as a user: |
< | < | ||
- | chown -R debian-spamd.debian-spamd /var/lib/ | + | su -s / |
- | find /var/lib/spamassassin -type f -exec chmod 644 {} \; | + | </ |
- | find /var/lib/spamassassin | + | |
- | reboot | + | ===== Bayesian Filter ===== |
+ | |||
+ | Train the Bayesian filter as a user: | ||
+ | |||
+ | < | ||
+ | su -s /bin/sh -c " | ||
</ | </ | ||
+ | |||
+ | ===== Rules Updates ===== | ||
+ | |||
+ | Update rules (taken from ''/ | ||
+ | |||
+ | < | ||
+ | su - debian-spamd -c " | ||
+ | # Result codes: 0=got updates, 1=no updates, 2=lint failed | ||
+ | echo $? | ||
+ | su - debian-spamd -c " | ||
+ | </ | ||
+ |