Hello, i m running one wordpress site on 512 droplet. i want install varnish for my droplet and i believe i must do some extra things also so that varnish can cache my wordpress site efficiently. just like its described in the following tutorial https://www.digitalocean.com/community/tutorials/how-to-install-wordpress-nginx-php-and-varnish-on-ubuntu-12-04
now my questions are the following
Q1. How can i install varnish for my nginx server which is on ubuntu 14.04.1? i tried to follow the above tutorial which is for 12.04 but that didnt work. says not supported when i try to install varnish. maybe that procedure not supported anymore for 14.04.1 or maybe because that is for varnish v3.
Q2. Currently Opcache code is enabled and its set to following parameter opcache.memory_consumption=128 opcache.max_accelerated_files=4000 opcache.revalidate_freq=60
should i change them to default or keep them as it is? or i simply dont need Opcache anymore?
Q3. i need to add one sub-domain that will bypass varnish cache and hit directly to my nginx server which is on default port 80.
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
When I Google Install Varnish 4 on Ubuntu, the first result is on Varnish’s website: https://www.varnish-cache.org/installation/ubuntu. It provides the commands to copy into terminal, and at the footer it mentions if you are installing on 14.04 rather than 12 to just change one word in the commands. Just make sure you sudo su into root first. Installed without any issues here on 14.04 running LEMP. If you use WordPress you will want to add the lines aristovia mentioned to your /etc/varnish/default.vcl file so that the WordPress admin works properly regardless of the version of Varnish. Hope this helps!
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.
Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.
New accounts only. By submitting your email you agree to our Privacy Policy
Scale up as you grow — whether you're running one virtual machine or ten thousand.
Sign up and get $200 in credit for your first 60 days with DigitalOcean.*
*This promotional offer applies to new accounts only.