reverse proxy sitemap white page

#682466
  • Resolved Anonymous
    Rank Math free

    i use reverse proxy but sitemap it white page
    original website:http://shoes.bagsacs.ru/sitemap_index.xml this it ok
    reverse proxy:https://www.replicashoes.me/sitemap_index.xml
    but https://www.replicashoes.me/sitemap_index.xml not white.
    i user ngigx

    #PROXY-START/

    location ^~ /
    {
    proxy_pass http://shoes.bagsacs.ru/;
    proxy_set_header Host shoes.bagsacs.ru;
    proxy_set_header X-Real-IP $remote_addr;
    proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
    proxy_set_header REMOTE-HOST $remote_addr;
    proxy_set_header Upgrade $http_upgrade;
    proxy_set_header Connection $connection_upgrade;
    proxy_http_version 1.1;
    # proxy_hide_header Upgrade;

    add_header X-Cache $upstream_cache_status;
    #Set Nginx Cache

    proxy_set_header Accept-Encoding “”;
    sub_filter “shoes.bagsacs.ru” “www.replicashoes.me”;
    sub_filter “http://” “https://”;
    sub_filter_once off;
    set $static_fileJhCJ0CId 0;
    if ( $uri ~* “.(gif|png|jpg|css|js|woff|woff2)$” )
    {
    set $static_fileJhCJ0CId 1;
    expires 1m;
    }
    if ( $static_fileJhCJ0CId = 0 )
    {
    add_header Cache-Control no-cache;
    }
    }

    #PROXY-END/

Viewing 7 replies - 1 through 7 (of 7 total)
  • Hello,

    I apologize for the inconvenience you’re experiencing with your sitemap. It seems that you are using a reverse proxy with Nginx and the sitemap is showing a white page when accessed through the reverse proxy URL.

    To resolve this issue, you may need to add some rewrite rules manually to your Nginx server configuration. Here are the rewrite rules that you can add:

    # START Nginx Rewrites for Rank Math Sitemaps
    rewrite ^/sitemap_index.xml$ /index.php?sitemap=1 last;
    rewrite ^/([^/]+?)-sitemap([0-9]+)?.xml$ /index.php?sitemap=$1&sitemap_n=$2 last;
    rewrite ^/([a-z]+)?-sitemap.xsl$ /index.php?xsl=$1 last;
    # END Nginx Rewrites for Rank Math Sitemaps

    Please ensure that these rewrite rules are added to your Nginx server configuration file. If you’re not sure about adding these rules, I recommend reaching out to your server administrator or hosting support for assistance.

    Once these rewrite rules are added, the sitemap should load correctly when accessed through the reverse proxy URL.

    If you encounter any further issues or need additional assistance, please feel free to reach out to us.

    Thank you for bringing this to our attention.

    Sources:
    Rank Math Sitemap Issues and Their Fixes » Rank Math
    Why the Sitemap_Index.xml is Throwing a 404 Error » Rank Math

    Anonymous
    Rank Math free

    Hello,

    I have updated the sensitive data as requested. Can you please check further?

    Thank you.

    Anonymous
    Rank Math free

    Hello,

    I have updated the sensitive data as requested. Can you please check further?

    Thank you.

    Anonymous
    Rank Math free

    Hello,

    I have updated the sensitive data as requested. Can you please check further?

    Thank you.

    Anonymous
    Rank Math free

    Hello,

    I have updated the sensitive data as requested. Can you please check further?

    Thank you.

    Anonymous
    Rank Math free

    The editing error was deleted for me.

    Hello,

    Thank you for contacting us and sorry for any inconvenience that this issue might have caused.

    Please follow the steps below for initial troubleshooting:

    1. Flush the Sitemap cache by following this video screencast:
    https://i.rankmath.com/pipRDp

    2. Exclude the Sitemap files of the Rank Math plugin in your caching plugin. The cache could be via a plugin or from the server. For plugins or Cloudflare, please follow this article: https://rankmath.com/kb/exclude-sitemaps-from-caching/

    If the issue persists then try disabling the transient cache for the sitemap. This will make sure that your XML sitemap always reflects the latest changes on your site. To do this, you need to add a small piece of code to your site’s functions.php file or use a plugin like Code Snippets.
    The code you need to add is this:

    /**
    * Filter if XML sitemap transient cache is enabled.
    *
    * @param boolean $unsigned Enable cache or not, defaults to true
    */
    add_filter( ‘rank_math/sitemap/enable_caching’, ‘__return_false’);
    If you’re not sure how to add this code, you can follow this guide: https://rankmath.com/kb/wordpress-hooks-actions-filters/.

    It will show you step-by-step how to use the Code Snippets plugin or edit the functions.php file safely.

    After you add the code, please clear any cache on your site or server and check your XML sitemap again. If you’re still facing issues with the sitemap, please let us know – we are happy to investigate further.

    Hello,

    Since we did not hear back from you for 15 days, we are assuming that you found the solution. We are closing this support ticket.

    If you still need assistance or any other help, please feel free to open a new support ticket, and we will be more than happy to assist.

    Thank you.

Viewing 7 replies - 1 through 7 (of 7 total)

The ticket ‘reverse proxy sitemap white page’ is closed to new replies.