Welcome! Log In Create A New Profile

Advanced

Re: Question on Proxy_Cache_Path

Resicow
April 22, 2009 11:28AM
Thanks!

Will this be in the next version?

The issue is that in order to do proxy_cache obviously proxy_buffer
needs to be on. This is bad if you set the minimum number of hits for a
file to 10 lets say... so nginx will buffer and write the file out 10
times, and then just throw the file away since it is not considered for
inclusion into the cache.

This may be okay under normal circumstances... but if you have an SSD in
the computer, you'll burn up all of your write cycles very quickly.
Instead proxy_temp can be on a regular HDD, and then nginx can copy the
file to the proxy_cache location on the SSD if the file is being
included in the cache.

Thanks,

John





Igor Sysoev wrote:
> On Tue, Apr 21, 2009 at 07:10:41PM -0500, Resicow wrote:
>
>
>> Hello,
>>
>> Have a quick question for you.
>>
>> Is it possible for proxy_temp_path and proxy_cache_path to be on
>> separate volumes?
>>
>> It seems like nginx accepts this, however when I tried nginx would make
>> the folders necessary in proxy_cache_path, but wouldn't ever copy files
>> from the temp_path to the cache_path. When I locate the temp_path and
>> the cache_path on the same volume, then everything works as expected.
>>
>> This would be very helpful, is there anyway to accomplish this?
>>
>
> Currently, these path must be on the same volume, because nginx just
> link() to new place without copying. However, I plan to fallback
> to copy temp file to another temporarily file on proxy_cache_path
> voulme and then link() it to permanent name. As current workaround
> you may set special proxy_temp_path for some locaitons only:
>
> http {
>
> proxy_cache_path /vol1/cache ...
> proxy_temp_path /vol2/temp;
>
> server {
>
> location / {
> proxy_cache ...
> proxy_temp_path /vol1/temp;
>
>
>
>
Subject Author Posted

Question on Proxy_Cache_Path

Resicow April 21, 2009 08:10PM

Re: Question on Proxy_Cache_Path

Igor Sysoev April 22, 2009 03:53AM

Re: Question on Proxy_Cache_Path

Resicow April 22, 2009 11:28AM

Re: Question on Proxy_Cache_Path

testbot January 31, 2010 10:07PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 285
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