Question on Proxy_Cache_Path

Igor Sysoev is at rambler-co.ru
Wed Apr 22 11:53:01 MSD 2009


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;



-- 
Igor Sysoev
http://sysoev.ru/en/





More information about the nginx mailing list