https://bugs.koozali.org/show_bug.cgi?id=12201

            Bug ID: 12201
           Summary: Limit log noise in /var/log/httpd/error_log
    Classification: Contribs
           Product: SME Contribs
           Version: 10.0
          Hardware: ---
                OS: ---
            Status: UNCONFIRMED
          Severity: minor
          Priority: P3
         Component: smeserver-wordpress
          Assignee: [email protected]
          Reporter: [email protected]
        QA Contact: [email protected]
  Target Milestone: ---

After upgrading to SME 10.1, I started receiving lots of messages like this in
/var/log/httpd/error_log:

[Sun Sep 25 22:26:36.887916 2022] [proxy_fcgi:error] [pid 22050] [client
64.227.108.223:32836] AH01071: Got error 'Primary script unknown'

The messages are related to entries like this in /var/log/httpd/access_log:

ibsgaarden.dk 64.227.108.223 - - [25/Sep/2022:22:26:36 +0200] "POST
/wordpress/xmlrpc.php HTTP/1.1" 404 16 "-" "Mozilla/5.0 (Windows; U; Windows NT
5.1; en-US; rv:1.7.12) Gecko/20050915 Firefox/1.0.7"

I suggest making the following changes to 
/etc/e-smith/templates/etc/httpd/conf/httpd.conf/92wordpress :

69a70
>         $OUT .= "       <If -f %{REQUEST_FILENAME}>";
70a72
>         $OUT .= "       </If>";

Making the fragment look like this:

          $OUT .= "     <FilesMatch \.php\$\>\n";
          $OUT .= "       <If -f %{REQUEST_FILENAME}>";
          $OUT .= "             SetHandler
\"proxy:unix:/var/run/php-fpm/php$version.sock|fcgi://localhost\"\n";
          $OUT .= "       </If>";
          $OUT .= "     </FilesMatch>\n";

So, we only do the SetHandler stuff, if the requested php file indeed exists.

-- 
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.
_______________________________________________
Mail for each SME Contribs bug report
To unsubscribe, e-mail [email protected]
Searchable archive at https://lists.contribs.org/mailman/public/contribteam/

Reply via email to