尼玛折腾了半天看网上各种网站都是告诉我这么解决的

Add these line to the end of file:
 
SecAuditLogDirMode 1733

SecAuditLogFileMode 0550

SecAuditLogType Concurrent

SecAuditLogStorageDir /usr/local/apache/logs/modsec_audit
 
Check the directory of /usr/local/apache/logs/modsec_audit for proper permissions of : 1733

折腾了半天 还是提示

2017/05/08 11:09:04 [error] 26844#0: [client ] ModSecurity: Audit log: Failed to lock global mutex: Permission denied [hostname "localhost.localdomain"] [uri "/favicon.ico"] [unique_id "AhAcAcAcAcAcAcAcpcAcAcAc"]
 
2017/05/08 11:09:04 [error] 26844#0: [client ] ModSecurity: Audit log: Failed to unlock global mutex: Permission denied [hostname "localhost.localdomain"] [uri "/favicon.ico"] [unique_id "AhAcAcAcAcAcAcAcpcAcAcAc"]

后来改了他们说的SecAuditLogStorageDir的用户组和权限 还是不行。。

最后发现nginx.conf 的启动用户没配置 添加了user nobody;

nginx -s reopen 还是不行。。

在千钧一发之际 nginx -c /etc/nginx.conf

可以了 解决了!真是b了狗

Comments
Write a Comment