Symptoms
- After installing SmarterMail, Plesk is unable to add new Subscriptions
- The following error message can be found in the Plesk log at
%plesk_dir%adminlogsphp_error.log
:
[2023-01-30 07:56:18] 18884:63d7e894d8cae ERR [panel] Long task executor: id=91 completed with error: mailmng failed: Incorrect Content-Type: must be textual to extract_string, JSON to extract_json.
at newDomain(example.com)(SmarterMail::Local::Provider::newDomain line 195)
at Unable to execute console command: '--add-domain'(vconsoleapp::start line 95)
at Unable to execute command: '"C:Program Files (x86)Pleskadminbinmailmng" --add-domain "--domain-name=example.com" "--disk-quota=104857600" "--total-disk-quota=-1"'(vconsoleapp::run line 117)
(Error code 1):
- The same error may appear during an attempt to remove a mail account
- The default
http://localhost:9998/
binding exists for the SmarterMail site in IIS (Windows > IIS > Sites > SmarterMail > Bindings)
Cause
ModSecurity blocks the newly created default SmarterMail website and prevents the addition of new Subscriptions In Plesk as a side effect.
Resolution
- Connect to the server via RDP
- Start a command prompt as Administrator
- Run the following command in order to reconfigure ModSecurity:
C:> plesk sbin defpackagemng --update --type=waf.modsecurity --package=modsecurity --fix
Once ModSecurity is reconfigured, it will no longer block the SmarterMail website and the issue will be resolved.