• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion

Issue SpamAssassin identifying spam but not marking as such nor moving to Spam folder

Denis Gomes Franco

Regular Pleskian
And that's it.

The spam filter is set to add *****SPAM***** to the subject, but that's not happening.

Spam is being delivered to the inbox with a report attached to the top of the message ("Spam detection software, running on the system xxx has identified this incoming email as possible spam....") and the score is way above the threshold.

Plesk is set up to allow individual spam settings for mailboxes, and mailboxes are set up to MOVE spam messages, but they keep getting delivered to the inbox.

I don't want to have to ask my users to set up filters or anything. Plesk should just work but it does not seem to respect my settings. So what gives?
 
According to your post that spam is marked as spam, you have not configured spam to be delivered into a separate folder. If you want spam marked, select the "Mark spam messages by adding the following text to messages ...", but if you want spam to be delivered into a spam folder, select "Move spam to the Spam folder". Please check this again what option you have picked in the corresponding mailboxes.

spam01.jpg
 
The spam filter is set to add *****SPAM***** to the subject, but that's not happening.
Spam is being delivered to the inbox with a report attached to the top of the message ("Spam detection software, running on the system xxx has identified this incoming email as possible spam....") and the score is way above the threshold."
So is this information incorrect? It seems to remain unclear what is actually configured. In your first post you said, you configured it to the message setting, in a later post the move setting. You will need to make sure that it is all configured to "move". The "server wide" settings are a preset. Individual settings override the server settings.
 
Okay, let's clear things up:
1. Mailboxes *are* configured to move messages to the spam folder, as per your screenshot
2. Spamassassin is correctly identifying spam messages. I know that because it is adding a report to the message's body ("Spam detection software...")
3. These messages are *not* being moved to the spam folder. They stay in the inbox.
And that's it.

Maybe I need to reset Spamassassin settings or something? Reloading the service or rebooting the server didn't help.
 
So, anybody have any ideas on how to solve this? My customers are complaining a lot about it.

upload_2019-2-10_11-9-41.png

Here it is, a spam message sitting in the inbox. Spamassassin added its report to the message's body and it clearly exceeded the threshold.

This is how Spamassassin is configured for this particular mailbox:
upload_2019-2-10_11-12-8.png

As you can see on the first screenshot, the message was neither moved nor marked with ***SPAM*** in the subject.

And this is Spamassassin's server-wide configuration:

upload_2019-2-10_11-14-7.png

Can somebody please point me in the right direction? I really hate to provide poor customer service to my clients and Plesk is starting to disappoint me a bit.
 
Try this first:

// this will ensure that /etc/sysconfig/spamassassin is configured correctly for Plesk
Code:
/usr/local/psa/bin/spamassassin --update-server -personal-conf false
/usr/local/psa/bin/spamassassin --update-server -status true -personal-conf true
service spamassassin restart

If that doesn't fix it then try running repair on the mailbox
Code:
plesk repair mail [email protected]
 
Last edited:
Thanks @danami, ran the first set of commands you recommended, let's see what happens from now on. The REPAIR command came back with 0 warnings and 0 errors, so the mailbox itself does not seem to have any problems.
 
No good... customer complained again that spam is not being moved to the Spam folder. But at least this time the messages got marked with ***SPAM*** on the subject line. So, what's going on? Is my Plesk instance going crazy or what?

By the way, I know I can set up a Roundcube filter to take care of this but that's not a proper solution for me.
 
Try changing the mailbox from" move to spam folder" to just "tag" and re-save. Then move it back to "move to spam folder" and re-save it once again.
 
Nothing, customers are still complaining about this.

Can someone please give me a definitive solution to this? What the heck is going on? Should I move to Cpanel? Everything seems to be configured correctly yet it still won't work.
 
Alright, here's an update. Since I could not figure out what happened and no one seems to have any idea of what's going on (also, do Plesk developers read these threads? I can't be the only one that's had this problem) I decided to move on to Cpanel. I really ran out of excuses to my customers about why spam is still going to their inboxes. I don't have enough technical knowledge to fix this, I tried what I could searching the web for help and with tips from Danami and Peter but still couldn't make it work.

I really love Plesk - the interface is nicer and more organized than Cpanel, and the Wordpress Toolkit is a godsend (by the way there is no equivalent for it in Cpanel). But I need to put my clients first and had to make a decision so as to not risk my reputation. Migration is being quite smooth, and I hope I'll come back to Plesk in the future.
 
This seems like a serious problem. Unfortunately I don't have a solution for you. Did you open a support ticket with Plesk?
 
Just a thought, I see you have your Junk folder named Spam in Roundcube, I am not sure if you use Postfix and Linux, but Make sure that you have a standard folder structure, so SpamAssassin is not trying to move messages to non-existing folder.

On new empty installation of latest Plesk Onyx for Linux, I have:

In Roundcube > Settings > Folders > Junk | Location: Foldername = Junk

On the server I have directories /var/qmail/mailnames/"example.com"/"username"/Maildir/.Spam/...[cur/new/tmp] (example.com and username should be your domain and user), make sure you have this folder or it's equivalent for your mail server/agent.
 
Thanks Rasp and Mike99 for your replies. I did not open a support ticket with Plesk, I couldn't wait any longer because complaints were starting to pile up, so I accelerated my move to Cpanel.

Mike99, you have an interesting theory there, even though it was Plesk that set up domains, mailboxes and Roundcube, so I presume it would create the correct structure already. I'll keep your explanation in mind.
 
Hello, I have had the same problem as you and I already solve it.
After much research and testing, I think I found the solution:

1- Uninstall spamassasin from Plesk

1627757290831.png

2- Connect by SSH and check if spamassasin still installed and remove it (this is the problem)
yum list installed | grep spam

yum remove spamassassin.x86_64
spam.jpg

3- Reboot your server.
4- Install spamassassin on Plesk.

This is all. In my case this fix it.
 
Hello,
Is there now more information about the solution?
I've had the same problem and checked the settings multiple times.
All spam mails end up in the inbox, not in the SPAM folder as desired
 
Back
Top