• 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.

Bug in Apache 2.4 centos 7 mod_remoteip ?

moswak

Regular Pleskian
Hi @ all,

i have a fresh install
centos7
12.5.30 Update #20
apache 2.4.6-40.el7.centos
nginx 1.9.4-centos7.15091112

in /var/log/httpd/access_log the serverIP is written instead of client IP

"but" in logs for domains its "ok" client ip is written.

control:
/etc/httpd/conf/plesk.conf.d/server.conf

<IfModule mod_remoteip.c>
RemoteIPInternalProxy ..serverIP..
RemoteIPHeader X-Forwarded-For
</IfModule>

seems ok

using google i found "Apache2 2.4+ not logging remote IP address using mod_remoteip"
(https://trick77.com/apache2-2-4-logging-remote-ip-address-using-mod_remoteip/)

in /etc/httpd/conf/httpd.conf

LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined

change to

LogFormat "%a %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined

fixed the issue.

Is this normal with apache 2.4.6-40.el7.centos ? a bug ?
 
Last edited:
Back
Top