Welcome! Log In Create A New Profile

Advanced

Re: Nginx Caching strategy

October 08, 2010 08:08AM
Hi!

I'm not a nginx developer and I've not even seen the source yet, however I've nginx running on cache and I can reply by experience one of your questions.

As long as you have free memory and your os (mine is debian too) correctly uses that memory to cache, you won't see a single IO Read into the cache files by nginx. You will see the first io read to the cached files whenever you have no more free memory to cache.

Please share later your experience :)

In my case in case it helps someone else, I had serious issues with IO but didn't blame nginx but my current virtualization setup: XenServer from Citrix over two SATA disks using software raid-1, using lvm for partitions and having on the same host other vm's with the backends, mysql database, etc. My IO was killing me when reaching a few hundreds requests per second, leaving sometimes most of workers locked on IO wait. After tunning and tunning nginx decided it wasn't the one to blame and fixed it other way: added SSD disk (software RAID-1 and LVM too) to the host and mounted a partition on the nginx debian machine exclusively for nginx cache, temp folder and logs. Since then i've not been able to throw enough load to have a IO problem again :-).

My current iostats on the production server:
avg-cpu:
%user %nice %system %iowait %steal %idle
0.10 0.03 0.31 0.39 0.02 99.15

Cheers

Guzman
Subject Author Posted

Nginx Caching strategy

cachenewbie October 04, 2010 03:12PM

Re: Nginx Caching strategy

cachenewbie October 04, 2010 03:55PM

Re: Nginx Caching strategy

valor October 08, 2010 08:08AM

Re: Nginx Caching strategy

Maxim Dounin October 05, 2010 07:36AM

Re: Nginx Caching strategy

cachenewbie October 13, 2010 10:17AM

Re: Nginx Caching strategy

Ryan Malayter October 13, 2010 09:54PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 126
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready