Optimize Nginx Configuration on Ubuntu 14.04

September 17, 2014 4.1k views

Hello! After installing LEMP on Ubuntu 14.04 with "one click applications" in my 512 droplet i want to optimize Nginx.

This tutorial required Debian >> How To Optimize Nginx Configuration

Is it advisable to follow the same steps of this tutorial to optimize Nginx on ubuntu 14.04?

Thanks!

3 Answers

Hi!

As Ubuntu is based on Debian, they are largely the same on some levels. All the configurations described in that article should work just as well on an Ubuntu as a Debian one.

Let us know how it goes!

I have a problem in this point with the Static File Caching:

location ~* .(jpg|jpeg|png|gif|ico|css|js)$ {
expires 365d;
}

If i put in /etc/nginx/nginx.conf "http" block fail,

Where should be placed?

Thanks

I think In this part of tutorial the " ; " is missing to close access_log off and the ngnix.conf fail

Logging
Nginx logs every request that hits the VPS to a log file. If you use analytics to monitor this, you may want to turn this functionality off. Simply edit the access_log directive:

access_log off

Have another answer? Share your knowledge.