0
votes
1answer
35 views
+100

Update Cache-Control max-age when srcache returns response from cache

I have configured Nginx to use srcache (along with the redis and redis2 modules). Server-side caching works great. My application responds with the appropriate Expires and Cache-Control headers, and ...
2
votes
1answer
121 views

How to invalidate nginx reverse proxy cache in front of other nginx servers?

I'm running a Proxmox server on a single IP address, that will dispatch HTTP requests to containers depending on the requested host. I am using nginx on the Proxmox side to listen to HTTP requests ...
0
votes
0answers
39 views

Does Apache or Nginx Proxy serve the browser caching directives?

I am running nginx as a proxy for my apache server. I am trying to leverage browser caching for PNG and JPG files. Which of these two should have the caching settings applied? I believe they both have ...
0
votes
0answers
22 views

Altering Cache value based on php response of an image or html in Nginx

I'have a set up where a PHP script dynamically creates images based on size and the device requesting them. Everything is working fine apart setting a higher cache expiry for images when they are ...
0
votes
0answers
52 views

Nginx cache shared between multiple servers

We have 8 REST-ish API servers with Nginx using FastCGI with PHP-FPM to handle requests. We're currently using Nginx' FastCGI caching (directives like fastcgi_cache_path). This means that API ...
0
votes
0answers
50 views

How to use Redis as a cache backend for uwsgi_cache in Nginx

I'm using Nginx with HttpUwsgiModule and i want to perform caching. I know that there is a uwsgi_cache which can be used to cache pages on the local file system. But i want to use Redis to cache pages ...
0
votes
2answers
186 views

Enable nginx browser catching for specific url

How can I enable nginx catch for specific URL? I have a django web app and I put my static files such as CSS, JavaScript and ... in a folder called static and I can access them via ...
1
vote
1answer
143 views

Nginx: How to set expiration for 404 responses?

My nginx server acts as a proxy for another server, which sometimes returns 404s. I want the 404 responses to be cacheable, just like 200 responses. However, I cannot use expires, because the ...
0
votes
1answer
170 views

Varnish stops listening on port 80 after few hours

I have configured varnish to listen on port 80 and nginx to listen on 8080. After around 24 hours of uptime, my site has been down for 22 hours. I checked in and found varnish isn't listening on port ...
0
votes
0answers
57 views

Are there any performance benefits when using Redis caching combined with Nginx caching?

I came across these posts about putting Redis in front of Nginx. I also noticed the Nginx HTTPRedis module. Which seem interesting from a performance standpoint, but I don't have much experience in ...
0
votes
0answers
32 views

nginx - BOA: “[alert] stalled cache updating” when running purge

I have BOA 2.1.0 installed, which uses nginx. Default caching is running by nginx. Unfortunately, whenever I am issuing a purge command, curl -X GET -H "Host:www.domain.com" ...
0
votes
0answers
262 views

Nginx does not cache json

I have the following nginx configuration user nginx; worker_processes 10; pid /var/run/nginx.pid; events { worker_connections 1000; } http { sendfile on; tcp_nopush on; tcp_nodelay ...
0
votes
0answers
39 views

Clear NGINX cache using FTP

I have an NGINX server set-up to handle caching for a website (running elsewhere). Works like a charm, however we want to administrators to have an option to flush the cache from their backoffice. I ...
1
vote
1answer
107 views

Serving a file with an expires header depending on when it was last modified

In nginx is there a way to conditionally serve a file with different expires headers depending on when the file was last modified? For example, if foo was modified within the last week then I want it ...
0
votes
1answer
53 views

Nginx cache entire site while performing MySQL maintenance

I currently have a high traffic WordPress site that is entirely static. But it currently generates each page via the MySQL database anyway (I know I should be caching content). I will be moving the ...
2
votes
1answer
103 views

Nginx and js/css versioning via browser's cache

I want to easily clear the browser's cache when js/css files are updated. Real file location: /js/some-files.js /css/some-files.css File location set in the app to be called by browser: ...
0
votes
1answer
35 views

Does nginx cache the unencrypted responses when using HTTPS?

I thought public cache was not possible when using HTTPS since every response was different (due to encryption), but just now I realized one could at least cache the unencrypted response, and the only ...
0
votes
1answer
256 views

Microcaching with nginx & uwsgi [closed]

i am running my personal website written with python on nginx with uwsgi. Since the site is very static i want to improve the performace by adding microcaching. Both nginx and also uwsgi do offer ...
0
votes
0answers
65 views

How to prevent nginx from caching certain files?

Is it possible to configure nginx to never cache certain files? I have two files on the root directory, index.html and list.json, and I want to disable caching for them completely. Can this be done by ...
0
votes
1answer
54 views

How to do Caching only for specific IP's, in Nginx or Rails

We have a Rails 2.3.8 app running on a nginx/passenger server. Recently the crawlers generate a huge load on us. We'd like to turn on page caching ONLY for crawlers (specific IP addresses), i.e., ...
0
votes
1answer
108 views

nginx proxy_cache or Memcached

I currently use nginx's proxy_cache for file-based caching in front of three Django applications (Apache/mod_wsgi). For some locations/URLs, I disabled proxy_cache and used Memcached (per view) within ...
1
vote
2answers
1k views

Setting up a reverse proxy to cache images

I wrote a quick Python server to serve resampled images. For example, a URL might look something like http://images.domain.com/resample/100x100/9f362e1994264321.jpg. Being that resampling images is ...
1
vote
1answer
169 views

Nginx not caching pages immediately

I am utilizing Nginx's proxy_cache module for caching but have noticed the page does not cache immediately. The content is very dynamic and each page load produces a different layout, I am trying to ...
0
votes
0answers
185 views

nginx caching and proxy pass

I'm trying to use nginx to proxy CDN use for our site to prevent raw video access when people put the CDN URL into their browser, and instead redirect them to a video page. If it's not a cacheable ...
0
votes
2answers
94 views

Set “expires” in nginx for multiple vhosts

I use the "apache style" nginx config (include /sites-enabled folder files and a single .conf for every website I host). How can I set this: location ~* \.(?:ico|css|js|gif|jpe?g|png)$ { expires 30d; ...
0
votes
1answer
323 views

How to tell nginx to honor backend's cache?

I'm using php-fpm with nginx as http server (I don't know much about reverse proxies, I just installed it and didn't touch anything), without Apache nor Varnish. I need nginx to understand and honor ...
0
votes
1answer
63 views

static index.html file nginx

We are using nginx with php-fpm. We plan to make first page static (generate html file). if we have 100 concurrent connections, how we can handle file regeneration? basically we need generate new file ...
0
votes
1answer
79 views

Seperating Audio,js,css,and images in seperate directory nginx

I am having a dynamic website,which is running on nginx and php-fpm. Can there be any performance improvement if images,Audio Files,css,js files are put into a seperate directory. here is my current ...
1
vote
0answers
212 views

Nginx, wordpress: Unable to proper reverse proxy caching due to Set-Cookie. Recommendation for a good strategy

I am trying to do reverse proxy caching for a wordpress blog and I am hit with snags. The initial configuration was a simple reverse caching like this location / { proxy_cache_key ...
2
votes
1answer
322 views

How to Confirm working of Nginx Caching Proxy

I am having nginx on port 80 and apache on port 8080 on same server. I have configured nginx such that it act as reverse proxy(i am not sure whether its working or not) using this tutorial ...
1
vote
1answer
273 views

Nodejs for processing js and Nginx for handling everything else

I am having a nodejs running on port 8000 and nginx on port 80 on same server. I want Nginx to handle all the requests(image,css,etc) and forward js requests to nodejs server on port 8000. Is it ...
1
vote
1answer
511 views

CSS and JS files not being updated, supposedly because of Nginx Caching

I have my web app working with AppCache and I would like that when I modify my html/css/js files, and then update my Cache Manifest, that when the user accesses my web app, they will have an updated ...
1
vote
1answer
44 views

Differences in memory consumption between two identical D7 sites?

I'm running Drupal on a news site that has a lot of different View blocks on the front page (~5 total, all cached). In trying to reduce the memory footprint of the site, I've checked out source from ...
2
votes
2answers
422 views

Using nginx / varnish for SSL and Non-SSL pages

Disclaimer: I have posted this on Stackoverflow as well as I thought it may have fit better there. The link to the question is below if someone would like to answer there. -- I have the following: ...
1
vote
2answers
1k views

Is there a way to cleverly cache with Nginx?

We have an Apache behind Nginx. Nginx is used to load balance between webservers and to cache static content. The only problem is, every time the web application is updated we have to completely clear ...
5
votes
2answers
2k views

Main differences between SSI (Server Side Include) and ESI (Edge Side include)

I need to include dynamic content into static pages at web server level. The 2 options I have found so far are Server Side Include (SSI) and Edge Side Include (ESI). While the origins of SSI seem ...
1
vote
1answer
175 views

Nginx issue with two web nodes

I'm running Wordpress website with Nginx and Memcached. I have simple DNS round robin balancing with A records pointing to both web servers. I've noticed the following entries in both web servers ...
1
vote
1answer
291 views

Nginx: read temporary cache file

I use ngx_http_proxy_module with proxy_ignore_client_abort to cache files. So when client close connection nginx will continue copying file from backend to current server. But when another user will ...
0
votes
1answer
94 views

news portal caching system

We have news portal. We have 5 identical dedicated boxes. 2xE5620, 16GB ram, 4x146gb 15k sas raid10. at this time bottleneck is mysql. One box is load balancer (nginx), two boxes (C,D) is nginx & ...
3
votes
2answers
3k views

How to Cache dynamic content using Nginx when sessions are involved?

This link explains how to create static files from dynamic content using Nginx. My question is this: can I achieve the same if login sessions are involved. ie. when I want to serve content to only ...
2
votes
1answer
256 views

Nginx: Cache only home page

How do I specify the location directive to cache my homepage without any filename or extension suffix. I need to cache only my home page at site.com and not anything under it(i.e ...
-1
votes
1answer
394 views

nginx proxypass content 404s when adding caching location block

Below is my nginx conf - the location block for adding expires max to content is causing issues with content from the /internal proxied sites. nginx error log; 2011/11/22 15:51:23 [error] 22124#0: ...
1
vote
1answer
253 views

Nginx: Per user caching

For normal public pages & js I do a proxy_cache assets; proxy_cache_key backend$request_uri; proxy_cache_valid 200 302 100d; proxy_cache_valid 404 1m; ...
1
vote
3answers
843 views

Is using both Nginx and Varnish at the same time redudant?

Disclaimer: I'm not an expert on either Linux, Nginx, Varnish or anything related to servers but I've managed to get a Linode VPS up and running, serving two blogs with Wordpress on them to different ...
1
vote
1answer
630 views

nginx proxy caching and ssi

I am using nginx for caching requests from the upstream apache server, however I want few blocks inside to be fetched from apache all the time. I am hoping ssi can do this, but the SSI tags are ...
2
votes
1answer
442 views

Caching 404s - NGINX or Varnished?

I'm looking for a solution to cache 404s in long term (a few days/weeks) on the webserver. My current setup is NGINX with memcached_pass proxy and PHP-FPM to deliver uncached pages (PHP also writes ...
3
votes
1answer
1k views

Nginx reverse proxy: Not setting expires header

I have my static assets configured as location @upstream { proxy_pass http://localhost:82; proxy_set_header Host $host; proxy_set_header X-Real-IP $remote_addr; ...
1
vote
4answers
741 views

Fastest/scalable way to serve static files?

What options are there to serve static files very fast? Are there any options that allow caching the file in the memory of the server, etc? For example caching the js files in the memory. I know of ...
1
vote
0answers
264 views

Browser continues to request headers of cached files, even after instructing it otherwise

I am trying to add a expires header to the nginx configuration like this : location ~* \.css|\.js|\.jpg|\.jpeg|\.png|\.gif|\.swf|\.svg|\.tiff|\.pdf|\.ico$ { expires max; ...
0
votes
1answer
887 views

nginx static files caching doesn't work

here is my conf file: usr/local/nginx/sites-available/default server { listen 80; server_name localhost; location / { root html; index index.php index.html index.htm; } # redirect server error pages ...