ПРОЕКТЫ 


  АРХИВ 


Apache-Talk @lexa.ru 

Inet-Admins @info.east.ru 

Filmscanners @halftone.co.uk 

Security-alerts @yandex-team.ru 

nginx-ru @sysoev.ru 


  СТАТЬИ 


  ПЕРСОНАЛЬНОЕ 


  ПРОГРАММЫ 



ПИШИТЕ
ПИСЬМА












     АРХИВ :: nginx-ru
Nginx-ru mailing list archive (nginx-ru@sysoev.ru)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: бага или фича?


  • To: nginx-ru@xxxxxxxxx
  • Subject: Re: бага или фича?
  • From: Никита Козлов <niakrisn@xxxxxxxxx>
  • Date: Fri, 24 Sep 2010 18:27:02 +0400
  • Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:received:in-reply-to :references:date:message-id:subject:from:to:content-type; bh=HTlyxMGqeN8bsx/hgrxxdp/LHcb/FCP/JyLEeomYI2s=; b=AbEPU6eIDCBstsbl0A5Oq68KGJw1tuBaf9eFzBZTIiV1jSAc7xDf+9MBYCf9zlx54h 4YoU9VmCRqsmU67McnoggstSn4lmUpQjTSwMOVZ1h3D6vAczrddAzlHIA+x4Asuehxlc 2wmAGrPBoAwxujyapriI7liLBMBXV4EhVYflQ=
  • Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; b=i8ifOvD7CBMVcFuzzKy/BhhfBaeinOk+bg7LZJmQjKUs8NTYpW9QDvRYiUwK8c5TOT KVDeNJWDL7zfCTwhiieZhirYPuoY9HqLbEDSW5F/g3Q2I0pdLqso4wOmyJuiBdd+loLf 3nzQh5/o/EXdljWLpe1+DdhK+0uXRg5Qx0MJI=
  • In-reply-to: <84e9b3f2e237b63f79072bb34f495989.NginxMailingListRussian@xxxxxxxxxxxxxxx>
  • References: <84e9b3f2e237b63f79072bb34f495989.NginxMailingListRussian@xxxxxxxxxxxxxxx>

Может это связано с правами nginx на каталог где хранится кэш?

24 сентября 2010 г. 17:59 пользователь Dmitry Veselov <nginx-forum@xxxxxxxx> написал:
Интересный момент, что если вместо

location ~* \.(css|flv|gif|html|jpg|js|png|swf|xml)$ {

поставить

location / {

То есть, кэширование всего сразу, то
отваливаются индексные файлы index.html, и
nginx выдает ошибку 403 при любой линке
типа http://www.bla-bla.com/link/ даже если ему
прописать в конфигурации директиву index
index.html
[b]Притом происходит это не сразу, а
через несколько минут ? возможно когда
устаревает кэш.[/b]


вот конфиг:
[code]
server {
   listen  80;

   server_name bla-bla.com www.bla-bla.com;

   location ~* \.(css|flv|gif|html|jpg|js|png|swf|xml)$ {
#    location ~* \.(css|gif|html|jpg|png|swf|xml)$ {

       root /var/cache/nginx/$server_name;
#       expires  max;
       expires  1m;
       open_file_cache_errors  off;
       error_page 404 = @fetch;
       access_log              /var/log/nginx/bla-bla.com.access.log;
       error_log              /var/log/nginx/bla-bla.error.log error;
   }

   location @fetch {
       internal;
       proxy_pass              http://1.2.3.4;
       proxy_store             on;
       proxy_store_access      user:rw  group:rw  all:r;
       proxy_temp_path         /var/nginx/proxy_temp;
       proxy_set_header        Host             $host;
       proxy_set_header        X-Real-IP        $remote_addr;
       root /var/cache/nginx/$server_name;
       access_log              /var/log/nginx/bla-bla.com.access.log;
       error_log              /var/log/nginx/bla-bla.com.error.log
error;
   }

   location / {
       proxy_pass          http://1.2.3.4/;
       access_log              /var/log/nginx/bla-bla.com.access.log;
       error_log              /var/log/nginx/bla-bla.com.error.log
error;
       include             /etc/nginx/proxy.conf;
   }
}
[/code]
[code]
nginx version: nginx/0.7.67
[/code]

Posted at Nginx Forum: http://forum.nginx.org/read.php?21,133570,133570#msg-133570


_______________________________________________
nginx-ru mailing list
nginx-ru@xxxxxxxxx
http://nginx.org/mailman/listinfo/nginx-ru

_______________________________________________
nginx-ru mailing list
nginx-ru@xxxxxxxxx
http://nginx.org/mailman/listinfo/nginx-ru


 




Copyright © Lexa Software, 1996-2009.