Proxy_cache_purge clear Nginx Cache return 404

Source: Internet
Author: User

Today debug Nginx A third-party purge cache module Proxy_cache_purge.

During debugging, the cache already has data but it is not clear that the return is always 404.

The last check for a long time, the reason for people three black lines ah.

Original configuration at the beginning

Put in

After that.

Change the order OK.

However, the configuration was configured on the official website. The official website example is as follows:

Sample configuration (separate location syntax)
http {    proxy_cache_path  /tmp/cache  keys_zone=tmpcache:10m;    server {        location / {            proxy_pass         http://127.0.0.1:8000;            proxy_cache        tmpcache;            proxy_cache_key    $uri$is_args$args;        }        location ~ /purge(/.*) {            allow              127.0.0.1;            deny               all;            proxy_cache_purge  tmpcache $1$is_args$args;        }    }}


我们使用的nginx和清除插件是被公司改过的,不知道是不是这个原因。
总之吧,这种限制真是。。。。

Proxy_cache_purge clear Nginx Cache return 404

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.