Wp multisite behind reverse proxy cannot access root site, but can subsites

Keywords: WordPress Multisite - Virtual Machines - Technical issue - Secure Connections (SSL/HTTPS)

bnsupport ID: 5970bfac-5912-1df7-9d92-aa977c22a151

bndiagnostic output:

? Connectivity: Found possible issues
? Mariadb: Found possible issues
? Apache: Found possible issues
https://docs.bitnami.com/general/faq/administration/use-firewall/
https://docs.bitnami.com/aws/apps/wordpress/troubleshooting/debug-errors-mariadb/
https://docs.bitnami.com/bch/apps/moodle/troubleshooting/deny-connections-bots-apache/

bndiagnostic failure reason: The suggested guides are not related with my issue

Description:
multisite with subdirectory’s. I can get too all the subsites just not the main one. I am using HA proxy. I thing this is an error with ssl somehow. I can get to the root site if I change my hosts file to the server IP directly. But not when going threw HAproxy.

The diagnostic tool is wrong. everything is just local.

I really think it is something to do with ssl. I cannot access http://rootsite.com It always redirects to https. Oddly when on wp-login I can ask for http and then it works threw HAproxy

Please help lol, it has been many hours with no progress

Hello @peter.roe,

Checking it with curl it seems that the https redirection is done by Cloudflare:

$ curl -LI http://rootsite.com/

HTTP/1.1 301 Moved Permanently
Date: Fri, 24 Sep 2021 08:28:54 GMT
Connection: keep-alive
Cache-Control: max-age=3600
Expires: Fri, 24 Sep 2021 09:28:54 GMT
Location: https://rootsite.com/
Report-To: {"endpoints":[{"url":"https:\/\/a.nel.cloudflare.com\/report\/v3?s=3fr7PCUypjrG%2B659k4J2pTe6WcEj1IokzDFeLS7ttm3zZVhPKzgAjol2MaLpWFU%2FeC%2FoDQPKIY8W5iCHlG%2FNH6ixzeaVomPRw2kKligziX%2FbZSZWXRvQZcOO8E4mkEA0eysvfw4%3D"}],"group":"cf-nel","max_age":604800}
NEL: {"success_fraction":0,"report_to":"cf-nel","max_age":604800}
Server: cloudflare
CF-RAY: 693aa459ae9e57a3-IAD
alt-svc: h3=":443"; ma=86400, h3-29=":443"; ma=86400, h3-28=":443"; ma=86400, h3-27=":443"; ma=86400

HTTP/2 200
date: Fri, 24 Sep 2021 08:28:54 GMT
content-type: text/html; charset=UTF-8
x-powered-by: PHP/7.4.23
link: <https://rootsite.com/wp-json/>; rel="https://api.w.org/", <https://rootsite.com/wp-json/wp/v2/pages/34>; rel="alternate"; type="application/json", <https://rootsite.com/>; rel=shortlink
cf-cache-status: DYNAMIC
expect-ct: max-age=604800, report-uri="https://report-uri.cloudflare.com/cdn-cgi/beacon/expect-ct"
report-to: {"endpoints":[{"url":"https:\/\/a.nel.cloudflare.com\/report\/v3?s=JX2hTGvlMLFVgmGrYU2G9qEDXWcRVpwp1oEzdOoyonwrla6klUcrhpuOlXJcX4N%2BAxqeFBhukQU7yML%2FIPMaEL4BWx5czBcfZOxzfozxNaeHuLd3zMRsE4i92c6lL5TV%2BYPhbE0%3D"}],"group":"cf-nel","max_age":604800}
nel: {"success_fraction":0,"report_to":"cf-nel","max_age":604800}
server: cloudflare
cf-ray: 693aa459e95d577c-IAD
alt-svc: h3=":443"; ma=86400, h3-29=":443"; ma=86400, h3-28=":443"; ma=86400, h3-27=":443"; ma=86400 

Maybe you followed this documentation:
https://docs.bitnami.com/aws/faq/administration/enable-ssl-cloudflare/

I hope it helps

Well I was accessing the site using the actual WAN IP. Using the hosts file. Going around cloudflair.

It is working now. For some reason saving the permalink structure on the main site fixed it. 6 hours down the toilet over that one lol

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.