I'm trying to remove the following notices from my error logs:

AH01797: client denied by server configuration: /var/www/html/example.com/xmlrpc.php

I previously had:

LogLevel notice

after reading, How to HIDE "client denied by server configuration:" error in log, I changed my code to:

#NameVirtualHost example.com:443
<VirtualHost *:443>
       LogLevel notice access_compat:crit
        ErrorLog /var/log/httpd/example.com/error.log

however the notices persist after restarting httpd. How can I remove these notices.

I'm using Server version: Apache/2.4.34.

The deny rule we use in our .htaccess is:

<Files xmlrpc.php>
        Order Deny,Allow
        Deny from all
        Allow from

The documentation for mod_access_compat mentions:

Available in Apache HTTP Server 2.3 as a compatibility module with previous versions of Apache httpd 2.x. The directives provided by this module have been deprecated by the new authz refactoring. Please see mod_authz_host

I would suspect that the messages may be logged by the new module, and so you have to change access_compat:crit to authz_host:crit or similar.

|improve this answer|||||
  • Thanks, unfortunately the authz_host performs the same. Are the parameters of the logging types documented somewhere? I noticed you said similar but I don't know currently what other values to try. – user3783243 Mar 30 at 14:02
  • I said similar because I don't know what directive you use to deny access. If you know the name of the directive, you should be able to figure out the module whose output needs to be configured. – chutz Apr 2 at 2:44
  • I've updated the question with the code we use for the deny policy. – user3783243 Apr 2 at 11:53

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.