Varnish is a high-performance reverse proxy and load-balancer package for Linux/Unix systems.

learn more… | top users | synonyms

100
votes
12answers
95k views

How to set up Nginx as a caching reverse proxy?

I heard recently that Nginx has added caching to its reverse proxy feature. I looked around but couldn't find much info about it. I want to set up Nginx as a caching reverse proxy in front of ...
14
votes
3answers
9k views

Ordering: 1. nginx 2. varnish 3. haproxy 4. webserver?

I've seen people recommend combining all of these in a flow, but they seem to have lots of overlapping features so I'd like to dig in to why you might want to pass through 3 different programs before ...
4
votes
2answers
2k views

How to setup Nginx with Varnish

I'd like to see how to configure Nginx and Varnish. I'm running several PHP sites and Rack-Sinatra sites as virtual hosts across two IP's. I'd like to prevent Nginx from having to serve static ...
3
votes
1answer
2k views

Configuring HTTPD behind Varnish on a 512mb VPS

I am hosting a website for a client on a dedicated VPS that has 512mb of RAM. Within the last 2 weeks, it has hosed up twice due to 0% free memory (or free swap). The site is pretty database ...
2
votes
1answer
3k views

WebDav rename fails on an Apache mod_dav install behind NginX

I'm trying to solve a problem with renaming files over WebDav. Our stack consists of a single machine, serving content through Nginx, Varnish and Apache. When you try to rename a file, the operation ...
8
votes
7answers
5k views

Varnish -> Nginx -> Apache a good idea?

I'm thinking about the architecture for a new Webserver. Would having Varnish as a cache in front of Nginx as a reverse-proxy and serving static files in front of apache for all heavy lifting be a ...
8
votes
1answer
3k views

The strange case of Mr. Time To First Byte

I've got a webserver on a Linode 1024 VPS based on Ubuntu 11.10 Nginx 1.0.5 PHP 5.3.6 (with PHP-FPM, APC) Varnish 3.0.2 And a couple of blogs there based on WordPress 3.3.1. One of them is a ...
13
votes
3answers
7k views

How to check if chosen Varnish cache size is ideal?

I've configured my Varnish cache to use a cache size of 512 MB, using: varnishd ... -s file,/var/cache/varnish.cache,512M Questions: How do I monitor if 512 MB is too small, too big or okay? How ...
8
votes
1answer
1k views

Poor load balancer performance on rackspace and centos

I am load testing different options for load balancing, and am getting poor results from Nginx, haproxy, and varnish. I have one 4GB load balancer at Rackspace, hitting 4x1GB app servers. I'm ...
3
votes
2answers
2k views

How to filter Varnish logs based on XID?

I'm running into infrequent 503 errors which appear hard to pinpoint. Varnishlog is driving me mad, since I can't seem to get the information I want out of it. I'd like to see both the client- and ...
2
votes
1answer
213 views

How can I log timestamps with Varnish health probes?

I'm using Varnish 3.0.3 on RHEL 6 as a caching load balancer in front of several Apache web servers and want to keep a log of when Varnish sees the back-ends change from healthy to sick and back ...
7
votes
2answers
6k views

Varnish Cache - default TTL?

I have discovered that I can set the TTL in Varnish as follows in my VCL file: sub vcl_fetch { # 1 minute set obj.ttl = 1m; } But what is the default setting (assuming the backend server is ...
1
vote
3answers
1k views

varnish demon error: libvarnish.so.1 not found

In order to try out varnish for an upcoming project I installed it on an ubuntu server using this tutorial: http://varnish-cache.org/wiki/InstallationOnUbuntuDapper The build process worked without ...
4
votes
3answers
1k views

Varnish only cache assets from single session

Currently I manage to configure varnish to cache items from 1 user, but the when the second users comes in varnish fetch another asset from Apache. How can I cache static assets behind magento ( ...
3
votes
5answers
646 views

Apache/Varnish/PHP: Just to confirm, is it possible to automatically update $_SERVER['REMOTE_ADDR'] to have the real client's IP?

I just cannot seem to get the real client IP to show in PHP's $_SERVER['REMOTE_ADDR']. It shows in $_SERVER['X_FORWARDED_FOR'], but the $_SERVER['REMOTE_ADDR'] always points to the Varnish service ...
3
votes
3answers
2k views

Load balancing: Nginx, Varnish and HTTP sessions

I have to setup a load balancing system. At the moment I have two machines running Nginx 0.8.52, PHP-FPM (on unix socket) and an application based on PHP Symfony 1.4.11. On a third machine, I have to ...
2
votes
2answers
2k views

Avoiding Varnish Hitting Magento Cookies - VCL

Hello to serverfault users, I would like to kindly ask someone to help me configure varnish for magento. Using command: varnishtop -i TxHeader -I Cookie , following info show: TxHeader Cookie: ...
2
votes
2answers
965 views

Does Varnish support IPv6?

Their specification draft says they should on section 3.2.1. Are we there yet? Has anyone used Varnish with IPv6?
1
vote
3answers
349 views

Apache Performance analysis

I am having really difficult time with my web server. I have been tweaking things as per the suggestions on web, yet not able to find anything concrete. My Apache process was eating 450MB under ...
1
vote
1answer
195 views

Varnish send while cache

I wanted the varnish download the file to the cache while sends to client. From what I am seeing, it first download and then send the file, and that with very large files, is slow. (sorry for ...
1
vote
3answers
3k views

Logging behind a reverse proxy?

I am currently running Varnish as a reverse proxy in front of our development website, testing before deployment into production. One of the things I've had to come to grips with is logging: in a ...
0
votes
1answer
145 views

IP bases access control list script

I would like to setup ACL (python script or any ready made Centos compatible scipt) & limit rate for all IP addresses, who are hitting the site very frequently. For example crawlers, bots (except ...
0
votes
1answer
388 views

proxy pass to varnish not hitting cache

On my web server I have a varnish instance that I would like to cache a third party hosted website (at blog.company.com/blog). I have a proxypass for this since the rest of the site is hosted locally ...
0
votes
1answer
605 views

how to redirect from www to non-www varnish

How do I go about automatically redirect any link of the type www.example.com to example.com. I would like to do this for all link that hits the varnish instance (so i don't have to individually ...
0
votes
1answer
471 views

Apache or Varnish reverse proxy to subfolder

I have a domain, site.example.com and I would like to reverse-proxy a web app in site2.example.com/subfolder. Users should access that app by using site.example.com/subfolder. Is it possible? I would ...
-1
votes
1answer
359 views

How to arrange web servers with Varnish? [closed]

I am wondering what it the best (most stable with the least memory footprint) arrangment for a busy php+mysql app? request > Varnish > Apache requests > Varnish > Nginx > php5-fpm ...