• Introducing WebPros Cloud - a fully managed infrastructure platform purpose-built to simplify the deployment of WebPros products !  WebPros Cloud enables you to easily deliver WebPros solutions — without the complexity of managing the infrastructure.
    Join the pilot program today!
  • Support for BIND DNS has been removed from Plesk for Windows due to security and maintenance risks.
    If a Plesk for Windows server is still using BIND, the upgrade to Plesk Obsidian 18.0.70 will be unavailable until the administrator switches the DNS server to Microsoft DNS.

Issue Nginx: unknown directive "modsecurity" when try to activate Comodo (modsecurity)

andreios

Regular Pleskian
Server operating system version
Ubuntu 24.04
Plesk version and microupdate number
18.0.62 #2
nginx: [emerg] unknown directive "modsecurity" in /etc/nginx/conf.d/modsecurity.conf:5
nginx: configuration file /etc/nginx/nginx.conf test failed
Shouldn't this work out of the box or am I missing something?
 
It should. However I am not sure what exactly is causing that error. I can't find any other reports from users with the same issue.

From what I can piece together from Googling around is that maybe modsecurity isn't loaded correctly. So you could try (if you haven't already) to uninstall the modsecurity component in Plesk and re-install it afterwards.
 
Have tried to reinstall. It is there.

dpkg -l |grep mod-security
ii mod-security-v3 3.0.12-v.ubuntu.24.04+p18.0.61.0+t240430.0818 amd64 Open source, cross-platform, web server WAF module library with nginx support
 
I see, unfortunately I don't have any other recommendations to try. Best suggestion I have left is opening a support ticket to let our support engineers assist you with find the cause. To sign-in to support and open a ticket go to https://support.plesk.com.

If you got your license from a reseller, your reseller should provide support for you. If the reseller does not provide support, here is an alternative to get support directly from Plesk: https://support.plesk.com/hc/en-us/articles/12388090147095-How-to-get-support-directly-from-Plesk
 
Back
Top