Symptoms
-
On a Plesk for Linux server, installing the extension Plesk Email Security in the menu Extensions > Plesk Email Security > Install Now fails:
PLESK_ERROR: Access denied
-
The following error can be spotted in the log file
/var/log/plesk/panel.log
with debug enabled:CONFIG_TEXT: 35162:63b174e633218 ERR [panel] pm_Exception: Access denied
file: /usr/local/psa/admin/plib/modules/email-security/library/Component/Dovecot.php
line: 227
code: 0
trace: #0 /usr/local/psa/admin/plib/modules/email-security/library/Component/Dovecot.php(240): PleskExt\EmailSecurity\Component\Dovecot::mailDir(string 'johndoe@example.com')
Cause
Mailbox johndoe@example.com still exists in SpamAssassin database but it does not exist in Plesk in Domains > example.com > Mail > Email Addresses.
# plesk db "select * from spamfilter;"
+----+--------------------------------+---------------+-------------+
| id | username | serviceNodeId | preferences |
+----+--------------------------------+---------------+-------------+
| 1 | @ | 1 | true |
| 2 | johndoe@example.com | 1 | true |
Resolution
-
Connect to the server via SSH.
-
Download the fixing script and make it executable:
# wget https://raw.githubusercontent.com/plesk/kb-scripts/refs/heads/master/pes-sa-remove/spamfilter_fix.php && chmod +x spamfilter_fix.php
-
Run the script to show the inconsistencies:
# plesk php spamfilter_fix.php
To automatically fix them, use the
-f
flag:# plesk php spamfilter_fix.php -f
Comments
0 comments
Please sign in to leave a comment.