• Our team is looking to connect with folks who use email services provided by Plesk, or a premium service. If you'd like to be part of the discovery process and share your experiences, we invite you to complete this short screening survey. If your responses match the persona we are looking for, you'll receive a link to schedule a call at your convenience. We look forward to hearing from you!
  • We are looking for U.S.-based freelancer or agency working with SEO or WordPress for a quick 30-min interviews to gather feedback on XOVI, a successful German SEO tool we’re looking to launch in the U.S.
    If you qualify and participate, you’ll receive a $30 Amazon gift card as a thank-you. Please apply here. Thanks for helping shape a better SEO product for agencies!
  • The BIND DNS server has already been deprecated and removed from Plesk for Windows.
    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. We strongly recommend transitioning to Microsoft DNS within the next 6 weeks, before the Plesk 18.0.70 release.
  • The Horde component is removed from Plesk Installer. We recommend switching to another webmail software supported in Plesk.

Issue Help needed with restoring users IP when coming from Cloudflare, Provided Doc script not working for me.

raykai

Basic Pleskian
Server operating system version
Debian 10.12
Plesk version and microupdate number
Plesk Obsidian 18.0.44 Update #3
Hi, I have Plesk set up as default as Nginx ( Reverse Proxy Server ) > Apache.

I'm trying to restore the true users IP that comes from the Cloudflare proxy. I got Apache to give the users true IP but I can't get Nginx to do it server-wide.

Snipaste_2022-06-28_13-33-53.png

I do have logs that are showing Cloudflare IP with Nginx like in the screenshot the IP 162.158.126.206 = Cloudflare, Inc.

When following the guide for the Server-wide solution with Nginx enabled: https://support.plesk.com/hc/en-us/...behind-load-balancer-or-reverse-forward-proxy

When I run the provided script cf.sh with the Plesk Scheduled Tasks I get this error:
Code:
Nginx is not in use on this Plesk server. Exiting... /cf.sh: line 7: /usr/local/psa/admin/bin/nginxmng: No such file or directory

When I run the provided script in SSH /root/cf.sh I get an error:
Code:
# /root/cf.sh
Previous execution of the script failed!
There is /etc/nginx/conf.d/cf-stop
Review the script functional and remove the /etc/nginx/conf.d/cf-stop
The script execution was halted.

I have also added real_ip_header CF-Connecting-IP; in nginx directives but it does not seem to work

How can I fix this for it to work?
 
I need help with this, please. As my logs in /var/log/nginx/access.log are still showing Cloudflare Ips
 
Back
Top