Mercurial > hg > nginx-site
annotate xml/ru/docs/http/ngx_http_fastcgi_module.xml @ 1378:6bfd39dc48c5
NGINX Plus EC2 documentation was moved to nginx.com.
Removed the page sources and fixed links to point to current location where applicable.
author | Konstantin Pavlov <thresh@nginx.com> |
---|---|
date | Thu, 18 Dec 2014 14:32:53 +0300 |
parents | 25db29c8875e |
children | 91f5c089f4ca |
rev | line source |
---|---|
222
bfe3eff81d04
Removed redundant encoding specification.
Ruslan Ermilov <ru@nginx.com>
parents:
135
diff
changeset
|
1 <?xml version="1.0"?> |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
2 |
580
be54c443235a
Added copyright markers to documentation sources.
Ruslan Ermilov <ru@nginx.com>
parents:
575
diff
changeset
|
3 <!-- |
be54c443235a
Added copyright markers to documentation sources.
Ruslan Ermilov <ru@nginx.com>
parents:
575
diff
changeset
|
4 Copyright (C) Igor Sysoev |
be54c443235a
Added copyright markers to documentation sources.
Ruslan Ermilov <ru@nginx.com>
parents:
575
diff
changeset
|
5 Copyright (C) Nginx, Inc. |
be54c443235a
Added copyright markers to documentation sources.
Ruslan Ermilov <ru@nginx.com>
parents:
575
diff
changeset
|
6 --> |
be54c443235a
Added copyright markers to documentation sources.
Ruslan Ermilov <ru@nginx.com>
parents:
575
diff
changeset
|
7 |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
8 <!DOCTYPE module SYSTEM "../../../../dtd/module.dtd"> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
9 |
295 | 10 <module name="Модуль ngx_http_fastcgi_module" |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
11 link="/ru/docs/http/ngx_http_fastcgi_module.html" |
589 | 12 lang="ru" |
1353
25db29c8875e
Documented how the "Vary" response header field affects caching.
Ruslan Ermilov <ru@nginx.com>
parents:
1352
diff
changeset
|
13 rev="24"> |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
14 |
110
40eec261c2a6
Added proper support for anonymous sections, notably for the summary.
Ruslan Ermilov <ru@nginx.com>
parents:
106
diff
changeset
|
15 <section id="summary"> |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
16 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
17 <para> |
295 | 18 Модуль <literal>ngx_http_fastcgi_module</literal> позволяет передавать |
19 запросы FastCGI-серверу. | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
20 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
21 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
22 </section> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
23 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
24 |
295 | 25 <section id="example" name="Пример конфигурации"> |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
26 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
27 <para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
28 <example> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
29 location / { |
295 | 30 fastcgi_pass localhost:9000; |
31 fastcgi_index index.php; | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
32 |
295 | 33 fastcgi_param SCRIPT_FILENAME /home/www/scripts/php$fastcgi_script_name; |
34 fastcgi_param QUERY_STRING $query_string; | |
35 fastcgi_param REQUEST_METHOD $request_method; | |
36 fastcgi_param CONTENT_TYPE $content_type; | |
37 fastcgi_param CONTENT_LENGTH $content_length; | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
38 } |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
39 </example> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
40 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
41 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
42 </section> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
43 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
44 |
295 | 45 <section id="directives" name="Директивы"> |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
46 |
772
ce121bf644f5
Documented "bind" directive in memcached, fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
625
diff
changeset
|
47 <directive name="fastcgi_bind"> |
815
ed29fd8be462
*_bind: variables support and inheritance.
Ruslan Ermilov <ru@nginx.com>
parents:
793
diff
changeset
|
48 <syntax><value>адрес</value> | <literal>off</literal></syntax> |
772
ce121bf644f5
Documented "bind" directive in memcached, fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
625
diff
changeset
|
49 <default/> |
ce121bf644f5
Documented "bind" directive in memcached, fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
625
diff
changeset
|
50 <context>http</context> |
ce121bf644f5
Documented "bind" directive in memcached, fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
625
diff
changeset
|
51 <context>server</context> |
ce121bf644f5
Documented "bind" directive in memcached, fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
625
diff
changeset
|
52 <context>location</context> |
ce121bf644f5
Documented "bind" directive in memcached, fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
625
diff
changeset
|
53 <appeared-in>0.8.22</appeared-in> |
ce121bf644f5
Documented "bind" directive in memcached, fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
625
diff
changeset
|
54 |
ce121bf644f5
Documented "bind" directive in memcached, fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
625
diff
changeset
|
55 <para> |
ce121bf644f5
Documented "bind" directive in memcached, fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
625
diff
changeset
|
56 Задаёт локальный IP-<value>адрес</value>, который будет использоваться в |
ce121bf644f5
Documented "bind" directive in memcached, fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
625
diff
changeset
|
57 исходящих соединениях с FastCGI-сервером. |
815
ed29fd8be462
*_bind: variables support and inheritance.
Ruslan Ermilov <ru@nginx.com>
parents:
793
diff
changeset
|
58 В значении параметра допустимо использование переменных (1.3.12). |
ed29fd8be462
*_bind: variables support and inheritance.
Ruslan Ermilov <ru@nginx.com>
parents:
793
diff
changeset
|
59 Специальное значение <literal>off</literal> (1.3.12) отменяет действие |
ed29fd8be462
*_bind: variables support and inheritance.
Ruslan Ermilov <ru@nginx.com>
parents:
793
diff
changeset
|
60 унаследованной с предыдущего уровня конфигурации |
ed29fd8be462
*_bind: variables support and inheritance.
Ruslan Ermilov <ru@nginx.com>
parents:
793
diff
changeset
|
61 директивы <literal>fastcgi_bind</literal>, позволяя системе |
966 | 62 самостоятельно выбирать локальный IP-адрес. |
772
ce121bf644f5
Documented "bind" directive in memcached, fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
625
diff
changeset
|
63 </para> |
ce121bf644f5
Documented "bind" directive in memcached, fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
625
diff
changeset
|
64 |
ce121bf644f5
Documented "bind" directive in memcached, fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
625
diff
changeset
|
65 </directive> |
ce121bf644f5
Documented "bind" directive in memcached, fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
625
diff
changeset
|
66 |
ce121bf644f5
Documented "bind" directive in memcached, fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
625
diff
changeset
|
67 |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
68 <directive name="fastcgi_buffer_size"> |
102
c76a257f3fd4
The directive name is now automatically printed in <default> and <syntax>.
Ruslan Ermilov <ru@nginx.com>
parents:
99
diff
changeset
|
69 <syntax><value>размер</value></syntax> |
295 | 70 <default>4k|8k</default> |
71 <context>http</context> | |
72 <context>server</context> | |
73 <context>location</context> | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
74 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
75 <para> |
295 | 76 Задаёт <value>размер</value> буфера, в который будет читаться |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
77 первая часть ответа, получаемого от FastCGI-сервера. |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
78 В этой части ответа находится, как правило, небольшой заголовок ответа. |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
79 По умолчанию размер буфера равен размеру одного буфера в директиве |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
80 <link id="fastcgi_buffers"/>, однако его можно сделать меньше. |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
81 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
82 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
83 </directive> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
84 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
85 |
995
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
86 <directive name="fastcgi_buffering"> |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
87 <syntax><literal>on</literal> | <literal>off</literal></syntax> |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
88 <default>on</default> |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
89 <context>http</context> |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
90 <context>server</context> |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
91 <context>location</context> |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
92 <appeared-in>1.5.6</appeared-in> |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
93 |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
94 <para> |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
95 Разрешает или запрещает использовать буферизацию ответов FastCGI-сервера. |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
96 </para> |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
97 |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
98 <para> |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
99 Если буферизация включена, то nginx принимает ответ FastCGI-сервера |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
100 как можно быстрее, сохраняя его в буферы, заданные директивами |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
101 <link id="fastcgi_buffer_size"/> и <link id="fastcgi_buffers"/>. |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
102 Если ответ не вмещается целиком в память, то его часть может быть записана |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
103 на диск во <link id="fastcgi_temp_path">временный файл</link>. |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
104 Запись во временные файлы контролируется директивами |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
105 <link id="fastcgi_max_temp_file_size"/> и |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
106 <link id="fastcgi_temp_file_write_size"/>. |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
107 </para> |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
108 |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
109 <para> |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
110 Если буферизация выключена, то ответ синхронно передаётся клиенту сразу же |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
111 по мере его поступления. |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
112 nginx не пытается считать весь ответ FastCGI-сервера. |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
113 Максимальный размер данных, который nginx может принять от сервера |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
114 за один раз, задаётся директивой <link id="fastcgi_buffer_size"/>. |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
115 </para> |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
116 |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
117 <para> |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
118 Буферизация может быть также включена или выключена путём передачи |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
119 значения “<literal>yes</literal>” или “<literal>no</literal>” в поле |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
120 <header>X-Accel-Buffering</header> заголовка ответа. |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
121 Эту возможность можно запретить с помощью директивы |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
122 <link id="fastcgi_ignore_headers"/>. |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
123 </para> |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
124 |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
125 </directive> |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
126 |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
127 |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
128 <directive name="fastcgi_buffers"> |
271 | 129 <syntax><value>число</value> <value>размер</value></syntax> |
295 | 130 <default>8 4k|8k</default> |
131 <context>http</context> | |
132 <context>server</context> | |
133 <context>location</context> | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
134 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
135 <para> |
295 | 136 Задаёт <value>число</value> и <value>размер</value> буферов |
137 для одного соединения, | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
138 в которые будет читаться ответ, получаемый от FastCGI-сервера. |
295 | 139 По умолчанию размер одного буфера равен размеру страницы. |
140 В зависимости от платформы это или 4K, или 8K. | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
141 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
142 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
143 </directive> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
144 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
145 |
411
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
146 <directive name="fastcgi_busy_buffers_size"> |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
147 <syntax><value>размер</value></syntax> |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
148 <default>8k|16k</default> |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
149 <context>http</context> |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
150 <context>server</context> |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
151 <context>location</context> |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
152 |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
153 <para> |
995
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
154 При включённой <link id="fastcgi_buffering">буферизации</link> ответов |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
155 FastCGI-сервера, ограничивает суммарный <value>размер</value> |
411
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
156 буферов, которые могут быть заняты для отправки ответа клиенту, пока |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
157 ответ ещё не прочитан целиком. |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
158 Оставшиеся буферы тем временем могут использоваться для чтения ответа |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
159 и, при необходимости, буферизации части ответа во временный файл. |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
160 По умолчанию <value>размер</value> ограничен двумя буферами, заданными |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
161 директивами <link id="fastcgi_buffer_size"/> и <link id="fastcgi_buffers"/>. |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
162 </para> |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
163 |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
164 </directive> |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
165 |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
166 |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
167 <directive name="fastcgi_cache"> |
271 | 168 <syntax><value>зона</value> | <literal>off</literal></syntax> |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
169 <default>off</default> |
295 | 170 <context>http</context> |
171 <context>server</context> | |
172 <context>location</context> | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
173 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
174 <para> |
575
ebcb351d9eb3
Consistently using the term "shared memory zone".
Ruslan Ermilov <ru@nginx.com>
parents:
509
diff
changeset
|
175 Задаёт зону разделяемой памяти, используемой для кэширования. |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
176 Одна и та же зона может использоваться в нескольких местах. |
295 | 177 Параметр <literal>off</literal> запрещает кэширование, унаследованное |
178 с предыдущего уровня конфигурации. | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
179 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
180 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
181 </directive> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
182 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
183 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
184 <directive name="fastcgi_cache_bypass"> |
271 | 185 <syntax><value>строка</value> ...</syntax> |
99
1d315ef37215
The case <default/> is now language-agnostic.
Ruslan Ermilov <ru@nginx.com>
parents:
98
diff
changeset
|
186 <default/> |
295 | 187 <context>http</context> |
188 <context>server</context> | |
189 <context>location</context> | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
190 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
191 <para> |
295 | 192 Задаёт условия, при которых ответ не будет браться из кэша. |
193 Если значение хотя бы одного из строковых параметров непустое и не равно “0”, | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
194 то ответ не берётся из кэша: |
98 | 195 <example> |
295 | 196 fastcgi_cache_bypass $cookie_nocache $arg_nocache$arg_comment; |
197 fastcgi_cache_bypass $http_pragma $http_authorization; | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
198 </example> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
199 Можно использовать совместно с директивой <link id="fastcgi_no_cache"/>. |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
200 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
201 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
202 </directive> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
203 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
204 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
205 <directive name="fastcgi_cache_key"> |
102
c76a257f3fd4
The directive name is now automatically printed in <default> and <syntax>.
Ruslan Ermilov <ru@nginx.com>
parents:
99
diff
changeset
|
206 <syntax><value>строка</value></syntax> |
99
1d315ef37215
The case <default/> is now language-agnostic.
Ruslan Ermilov <ru@nginx.com>
parents:
98
diff
changeset
|
207 <default/> |
295 | 208 <context>http</context> |
209 <context>server</context> | |
210 <context>location</context> | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
211 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
212 <para> |
295 | 213 Задаёт ключ для кэширования, например, |
98 | 214 <example> |
295 | 215 fastcgi_cache_key localhost:9000$request_uri; |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
216 </example> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
217 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
218 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
219 </directive> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
220 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
221 |
302
df728215db07
Documented "proxy_cache_lock", "proxy_cache_lock_timeout",
Ruslan Ermilov <ru@nginx.com>
parents:
299
diff
changeset
|
222 <directive name="fastcgi_cache_lock"> |
df728215db07
Documented "proxy_cache_lock", "proxy_cache_lock_timeout",
Ruslan Ermilov <ru@nginx.com>
parents:
299
diff
changeset
|
223 <syntax><literal>on</literal> | <literal>off</literal></syntax> |
df728215db07
Documented "proxy_cache_lock", "proxy_cache_lock_timeout",
Ruslan Ermilov <ru@nginx.com>
parents:
299
diff
changeset
|
224 <default>off</default> |
df728215db07
Documented "proxy_cache_lock", "proxy_cache_lock_timeout",
Ruslan Ermilov <ru@nginx.com>
parents:
299
diff
changeset
|
225 <context>http</context> |
df728215db07
Documented "proxy_cache_lock", "proxy_cache_lock_timeout",
Ruslan Ermilov <ru@nginx.com>
parents:
299
diff
changeset
|
226 <context>server</context> |
df728215db07
Documented "proxy_cache_lock", "proxy_cache_lock_timeout",
Ruslan Ermilov <ru@nginx.com>
parents:
299
diff
changeset
|
227 <context>location</context> |
310
86732337c730
Added a historical information for proxy_cache_lock, proxy_cache_lock_timeout,
Ruslan Ermilov <ru@nginx.com>
parents:
302
diff
changeset
|
228 <appeared-in>1.1.12</appeared-in> |
302
df728215db07
Documented "proxy_cache_lock", "proxy_cache_lock_timeout",
Ruslan Ermilov <ru@nginx.com>
parents:
299
diff
changeset
|
229 |
df728215db07
Documented "proxy_cache_lock", "proxy_cache_lock_timeout",
Ruslan Ermilov <ru@nginx.com>
parents:
299
diff
changeset
|
230 <para> |
df728215db07
Documented "proxy_cache_lock", "proxy_cache_lock_timeout",
Ruslan Ermilov <ru@nginx.com>
parents:
299
diff
changeset
|
231 Если включено, одновременно только одному запросу будет позволено |
df728215db07
Documented "proxy_cache_lock", "proxy_cache_lock_timeout",
Ruslan Ermilov <ru@nginx.com>
parents:
299
diff
changeset
|
232 заполнить новый элемент кэша, идентифицируемый согласно директиве |
df728215db07
Documented "proxy_cache_lock", "proxy_cache_lock_timeout",
Ruslan Ermilov <ru@nginx.com>
parents:
299
diff
changeset
|
233 <link id="fastcgi_cache_key"/>, передав запрос на FastCGI-сервер. |
df728215db07
Documented "proxy_cache_lock", "proxy_cache_lock_timeout",
Ruslan Ermilov <ru@nginx.com>
parents:
299
diff
changeset
|
234 Остальные запросы этого же элемента будут либо ожидать |
df728215db07
Documented "proxy_cache_lock", "proxy_cache_lock_timeout",
Ruslan Ermilov <ru@nginx.com>
parents:
299
diff
changeset
|
235 появления ответа в кэше, либо освобождения блокировки |
df728215db07
Documented "proxy_cache_lock", "proxy_cache_lock_timeout",
Ruslan Ermilov <ru@nginx.com>
parents:
299
diff
changeset
|
236 этого элемента, в течение времени, заданного директивой |
df728215db07
Documented "proxy_cache_lock", "proxy_cache_lock_timeout",
Ruslan Ermilov <ru@nginx.com>
parents:
299
diff
changeset
|
237 <link id="fastcgi_cache_lock_timeout"/>. |
df728215db07
Documented "proxy_cache_lock", "proxy_cache_lock_timeout",
Ruslan Ermilov <ru@nginx.com>
parents:
299
diff
changeset
|
238 </para> |
df728215db07
Documented "proxy_cache_lock", "proxy_cache_lock_timeout",
Ruslan Ermilov <ru@nginx.com>
parents:
299
diff
changeset
|
239 |
df728215db07
Documented "proxy_cache_lock", "proxy_cache_lock_timeout",
Ruslan Ermilov <ru@nginx.com>
parents:
299
diff
changeset
|
240 </directive> |
df728215db07
Documented "proxy_cache_lock", "proxy_cache_lock_timeout",
Ruslan Ermilov <ru@nginx.com>
parents:
299
diff
changeset
|
241 |
df728215db07
Documented "proxy_cache_lock", "proxy_cache_lock_timeout",
Ruslan Ermilov <ru@nginx.com>
parents:
299
diff
changeset
|
242 |
df728215db07
Documented "proxy_cache_lock", "proxy_cache_lock_timeout",
Ruslan Ermilov <ru@nginx.com>
parents:
299
diff
changeset
|
243 <directive name="fastcgi_cache_lock_timeout"> |
df728215db07
Documented "proxy_cache_lock", "proxy_cache_lock_timeout",
Ruslan Ermilov <ru@nginx.com>
parents:
299
diff
changeset
|
244 <syntax><value>время</value></syntax> |
df728215db07
Documented "proxy_cache_lock", "proxy_cache_lock_timeout",
Ruslan Ermilov <ru@nginx.com>
parents:
299
diff
changeset
|
245 <default>5s</default> |
df728215db07
Documented "proxy_cache_lock", "proxy_cache_lock_timeout",
Ruslan Ermilov <ru@nginx.com>
parents:
299
diff
changeset
|
246 <context>http</context> |
df728215db07
Documented "proxy_cache_lock", "proxy_cache_lock_timeout",
Ruslan Ermilov <ru@nginx.com>
parents:
299
diff
changeset
|
247 <context>server</context> |
df728215db07
Documented "proxy_cache_lock", "proxy_cache_lock_timeout",
Ruslan Ermilov <ru@nginx.com>
parents:
299
diff
changeset
|
248 <context>location</context> |
310
86732337c730
Added a historical information for proxy_cache_lock, proxy_cache_lock_timeout,
Ruslan Ermilov <ru@nginx.com>
parents:
302
diff
changeset
|
249 <appeared-in>1.1.12</appeared-in> |
302
df728215db07
Documented "proxy_cache_lock", "proxy_cache_lock_timeout",
Ruslan Ermilov <ru@nginx.com>
parents:
299
diff
changeset
|
250 |
df728215db07
Documented "proxy_cache_lock", "proxy_cache_lock_timeout",
Ruslan Ermilov <ru@nginx.com>
parents:
299
diff
changeset
|
251 <para> |
df728215db07
Documented "proxy_cache_lock", "proxy_cache_lock_timeout",
Ruslan Ermilov <ru@nginx.com>
parents:
299
diff
changeset
|
252 Задаёт таймаут для <link id="fastcgi_cache_lock"/>. |
df728215db07
Documented "proxy_cache_lock", "proxy_cache_lock_timeout",
Ruslan Ermilov <ru@nginx.com>
parents:
299
diff
changeset
|
253 </para> |
df728215db07
Documented "proxy_cache_lock", "proxy_cache_lock_timeout",
Ruslan Ermilov <ru@nginx.com>
parents:
299
diff
changeset
|
254 |
df728215db07
Documented "proxy_cache_lock", "proxy_cache_lock_timeout",
Ruslan Ermilov <ru@nginx.com>
parents:
299
diff
changeset
|
255 </directive> |
df728215db07
Documented "proxy_cache_lock", "proxy_cache_lock_timeout",
Ruslan Ermilov <ru@nginx.com>
parents:
299
diff
changeset
|
256 |
df728215db07
Documented "proxy_cache_lock", "proxy_cache_lock_timeout",
Ruslan Ermilov <ru@nginx.com>
parents:
299
diff
changeset
|
257 |
793
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
258 <directive name="fastcgi_cache_methods"> |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
259 <syntax> |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
260 <literal>GET</literal> | |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
261 <literal>HEAD</literal> | |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
262 <literal>POST</literal> |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
263 ...</syntax> |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
264 <default>GET HEAD</default> |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
265 <context>http</context> |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
266 <context>server</context> |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
267 <context>location</context> |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
268 <appeared-in>0.7.59</appeared-in> |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
269 |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
270 <para> |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
271 Если метод запроса клиента указан в этой директиве, |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
272 то ответ будет закэширован. |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
273 Методы “<literal>GET</literal>” и “<literal>HEAD</literal>” всегда добавляются |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
274 в список, но тем не менее рекомендуется перечислять их явно. |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
275 См. также директиву <link id="fastcgi_no_cache"/>. |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
276 </para> |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
277 |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
278 </directive> |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
279 |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
280 |
295 | 281 <directive name="fastcgi_cache_min_uses"> |
282 <syntax><value>число</value></syntax> | |
283 <default>1</default> | |
284 <context>http</context> | |
285 <context>server</context> | |
286 <context>location</context> | |
287 | |
288 <para> | |
289 Задаёт <value>число</value> запросов, после которого ответ будет закэширован. | |
290 </para> | |
291 | |
292 </directive> | |
293 | |
294 | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
295 <directive name="fastcgi_cache_path"> |
271 | 296 <syntax> |
364 | 297 <value>путь</value> |
298 [<literal>levels</literal>=<value>уровни</value>] | |
299 <literal>keys_zone</literal>=<value>имя</value>:<value>размер</value> | |
300 [<literal>inactive</literal>=<value>время</value>] | |
508
5e332fafd228
Documented "cache loader" and its parameters.
Ruslan Ermilov <ru@nginx.com>
parents:
507
diff
changeset
|
301 [<literal>max_size</literal>=<value>размер</value>] |
5e332fafd228
Documented "cache loader" and its parameters.
Ruslan Ermilov <ru@nginx.com>
parents:
507
diff
changeset
|
302 [<literal>loader_files</literal>=<value>число</value>] |
5e332fafd228
Documented "cache loader" and its parameters.
Ruslan Ermilov <ru@nginx.com>
parents:
507
diff
changeset
|
303 [<literal>loader_sleep</literal>=<value>время</value>] |
5e332fafd228
Documented "cache loader" and its parameters.
Ruslan Ermilov <ru@nginx.com>
parents:
507
diff
changeset
|
304 [<literal>loader_threshold</literal>=<value>время</value>]</syntax> |
99
1d315ef37215
The case <default/> is now language-agnostic.
Ruslan Ermilov <ru@nginx.com>
parents:
98
diff
changeset
|
305 <default/> |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
306 <context>http</context> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
307 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
308 <para> |
295 | 309 Задаёт путь и другие параметры кэша. |
310 Данные кэша хранятся в файлах. | |
311 Ключом и именем файла в кэше является результат функции MD5 | |
312 от проксированного URL. | |
313 Параметр <literal>levels</literal> задаёт уровни иерархии кэша, | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
314 например, при использовании |
98 | 315 <example> |
295 | 316 fastcgi_cache_path /data/nginx/cache levels=1:2 keys_zone=one:10m; |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
317 </example> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
318 имена файлов в кэше будут такого вида: |
98 | 319 <example> |
295 | 320 /data/nginx/cache/<emphasis>c</emphasis>/<emphasis>29</emphasis>/b7f54b2df7773722d382f4809d650<emphasis>29c</emphasis> |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
321 </example> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
322 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
323 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
324 <para> |
295 | 325 Кэшируемый ответ сначала записывается во временный файл, а потом этот файл |
364 | 326 переименовывается. |
327 Начиная с версии 0.8.9, временные файлы и кэш | |
966 | 328 могут располагаться на разных файловых системах. |
329 Однако нужно учитывать, | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
330 что в этом случае вместо дешёвой операции переименовывания в пределах |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
331 одной файловой системы файл копируется с одной файловой системы на другую. |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
332 Поэтому лучше, если кэш будет находиться на той же файловой |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
333 системе, что и каталог с временными файлами, задаваемый директивой |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
334 <link id="fastcgi_temp_path"/> для данного location. |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
335 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
336 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
337 <para> |
575
ebcb351d9eb3
Consistently using the term "shared memory zone".
Ruslan Ermilov <ru@nginx.com>
parents:
509
diff
changeset
|
338 Кроме того, все активные ключи и информация о данных хранятся в зоне |
ebcb351d9eb3
Consistently using the term "shared memory zone".
Ruslan Ermilov <ru@nginx.com>
parents:
509
diff
changeset
|
339 разделяемой памяти, <value>имя</value> и <value>размер</value> которой |
295 | 340 задаются параметром <literal>keys_zone</literal>. |
1189
f25d00109de0
Documented cache keys_zone memory estimates.
Maxim Dounin <mdounin@mdounin.ru>
parents:
1185
diff
changeset
|
341 Зоны размером в 1 мегабайт достаточно для хранения около 8 тысяч ключей. |
f25d00109de0
Documented cache keys_zone memory estimates.
Maxim Dounin <mdounin@mdounin.ru>
parents:
1185
diff
changeset
|
342 </para> |
f25d00109de0
Documented cache keys_zone memory estimates.
Maxim Dounin <mdounin@mdounin.ru>
parents:
1185
diff
changeset
|
343 |
f25d00109de0
Documented cache keys_zone memory estimates.
Maxim Dounin <mdounin@mdounin.ru>
parents:
1185
diff
changeset
|
344 <para> |
285 | 345 Если к данным кэша не обращаются в течение времени, заданного параметром |
295 | 346 <literal>inactive</literal>, то данные удаляются, независимо от их свежести. |
347 По умолчанию <literal>inactive</literal> равен 10 минутам. | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
348 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
349 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
350 <para> |
295 | 351 Специальный процесс “cache manager” следит за максимальным размером кэша, |
352 заданным параметром <literal>max_size</literal>, и при превышении | |
507 | 353 его размеров удаляет наименее востребованные данные. |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
354 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
355 |
508
5e332fafd228
Documented "cache loader" and its parameters.
Ruslan Ermilov <ru@nginx.com>
parents:
507
diff
changeset
|
356 <para> |
5e332fafd228
Documented "cache loader" and its parameters.
Ruslan Ermilov <ru@nginx.com>
parents:
507
diff
changeset
|
357 Через минуту после старта активируется специальный процесс “cache loader”, |
5e332fafd228
Documented "cache loader" and its parameters.
Ruslan Ermilov <ru@nginx.com>
parents:
507
diff
changeset
|
358 который загружает в зону кэша информацию о ранее закэшированных данных, |
5e332fafd228
Documented "cache loader" and its parameters.
Ruslan Ermilov <ru@nginx.com>
parents:
507
diff
changeset
|
359 хранящихся на файловой системе. |
5e332fafd228
Documented "cache loader" and its parameters.
Ruslan Ermilov <ru@nginx.com>
parents:
507
diff
changeset
|
360 Загрузка происходит итерациями. |
5e332fafd228
Documented "cache loader" and its parameters.
Ruslan Ermilov <ru@nginx.com>
parents:
507
diff
changeset
|
361 За одну итерацию загружается не более <literal>loader_files</literal> |
5e332fafd228
Documented "cache loader" and its parameters.
Ruslan Ermilov <ru@nginx.com>
parents:
507
diff
changeset
|
362 элементов (по умолчанию 100). |
5e332fafd228
Documented "cache loader" and its parameters.
Ruslan Ermilov <ru@nginx.com>
parents:
507
diff
changeset
|
363 Кроме того, время работы одной итерации ограничено параметром |
5e332fafd228
Documented "cache loader" and its parameters.
Ruslan Ermilov <ru@nginx.com>
parents:
507
diff
changeset
|
364 <literal>loader_threshold</literal> (по умолчанию 200 миллисекунд). |
5e332fafd228
Documented "cache loader" and its parameters.
Ruslan Ermilov <ru@nginx.com>
parents:
507
diff
changeset
|
365 Между итерациями делается пауза на время, заданное параметром |
5e332fafd228
Documented "cache loader" and its parameters.
Ruslan Ermilov <ru@nginx.com>
parents:
507
diff
changeset
|
366 <literal>loader_sleep</literal> (по умолчанию 50 миллисекунд). |
5e332fafd228
Documented "cache loader" and its parameters.
Ruslan Ermilov <ru@nginx.com>
parents:
507
diff
changeset
|
367 </para> |
5e332fafd228
Documented "cache loader" and its parameters.
Ruslan Ermilov <ru@nginx.com>
parents:
507
diff
changeset
|
368 |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
369 </directive> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
370 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
371 |
1116
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
372 <directive name="fastcgi_cache_purge"> |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
373 <syntax>строка ...</syntax> |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
374 <default/> |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
375 <context>http</context> |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
376 <context>server</context> |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
377 <context>location</context> |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
378 <appeared-in>1.5.7</appeared-in> |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
379 |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
380 <para> |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
381 Задаёт условия, при которых запрос будет считаться запросом |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
382 на очистку кэша. |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
383 Если значение хотя бы одного из строковых параметров непустое и не равно “0”, |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
384 то запись в кэше с соответствующим |
1134
666052986b99
Fixed spelling in proxy_cache_purge and fastcgi_cache_purge.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1128
diff
changeset
|
385 <link id="fastcgi_cache_key">ключом кэширования</link> удаляется. |
1135
90c1c83fcba6
Changed translation in proxy_cache_purge and fastcgi_cache_purge.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1134
diff
changeset
|
386 В результате успешной операции возвращается ответ с кодом |
1116
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
387 <http-status code="204" text="No Content"/>. |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
388 </para> |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
389 |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
390 <para> |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
391 Если <link id="fastcgi_cache_key">ключ кэширования</link> |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
392 запроса на очистку заканчивается |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
393 звёздочкой (“<literal>*</literal>”), то все записи в кэше, соответствующие |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
394 этой маске, будут удалены из кэша. |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
395 </para> |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
396 |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
397 <para> |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
398 Пример конфигурации: |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
399 <example> |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
400 fastcgi_cache_path /data/nginx/cache keys_zone=cache_zone:10m; |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
401 |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
402 map $request_method $purge_method { |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
403 PURGE 1; |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
404 default 0; |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
405 } |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
406 |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
407 server { |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
408 ... |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
409 location / { |
1185
f9c8336fe43c
Aligned configuration examples with fastcgi/scgi_cache_purge.
Ruslan Ermilov <ru@nginx.com>
parents:
1155
diff
changeset
|
410 fastcgi_pass http://backend; |
f9c8336fe43c
Aligned configuration examples with fastcgi/scgi_cache_purge.
Ruslan Ermilov <ru@nginx.com>
parents:
1155
diff
changeset
|
411 fastcgi_cache cache_zone; |
f9c8336fe43c
Aligned configuration examples with fastcgi/scgi_cache_purge.
Ruslan Ermilov <ru@nginx.com>
parents:
1155
diff
changeset
|
412 fastcgi_cache_key $uri; |
1116
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
413 fastcgi_cache_purge $purge_method; |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
414 } |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
415 } |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
416 </example> |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
417 <note> |
1128
1594ed379f1f
De-i18n'ed <commercial_version/>.
Ruslan Ermilov <ru@nginx.com>
parents:
1117
diff
changeset
|
418 Функциональность доступна как часть |
1594ed379f1f
De-i18n'ed <commercial_version/>.
Ruslan Ermilov <ru@nginx.com>
parents:
1117
diff
changeset
|
419 <commercial_version>коммерческой подписки</commercial_version>. |
1116
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
420 </note> |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
421 </para> |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
422 |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
423 </directive> |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
424 |
d882c6f3323d
FastCGI and Proxy: translated the "_cache_purge" directives into RU.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1016
diff
changeset
|
425 |
1016
2d8269d8fea8
Translated documentation on cache revalidation into russian.
Vladimir Homutov <vl@nginx.com>
parents:
1005
diff
changeset
|
426 <directive name="fastcgi_cache_revalidate"> |
2d8269d8fea8
Translated documentation on cache revalidation into russian.
Vladimir Homutov <vl@nginx.com>
parents:
1005
diff
changeset
|
427 <syntax><literal>on</literal> | <literal>off</literal></syntax> |
2d8269d8fea8
Translated documentation on cache revalidation into russian.
Vladimir Homutov <vl@nginx.com>
parents:
1005
diff
changeset
|
428 <default>off</default> |
2d8269d8fea8
Translated documentation on cache revalidation into russian.
Vladimir Homutov <vl@nginx.com>
parents:
1005
diff
changeset
|
429 <context>http</context> |
2d8269d8fea8
Translated documentation on cache revalidation into russian.
Vladimir Homutov <vl@nginx.com>
parents:
1005
diff
changeset
|
430 <context>server</context> |
2d8269d8fea8
Translated documentation on cache revalidation into russian.
Vladimir Homutov <vl@nginx.com>
parents:
1005
diff
changeset
|
431 <context>location</context> |
2d8269d8fea8
Translated documentation on cache revalidation into russian.
Vladimir Homutov <vl@nginx.com>
parents:
1005
diff
changeset
|
432 <appeared-in>1.5.7</appeared-in> |
2d8269d8fea8
Translated documentation on cache revalidation into russian.
Vladimir Homutov <vl@nginx.com>
parents:
1005
diff
changeset
|
433 |
2d8269d8fea8
Translated documentation on cache revalidation into russian.
Vladimir Homutov <vl@nginx.com>
parents:
1005
diff
changeset
|
434 <para> |
2d8269d8fea8
Translated documentation on cache revalidation into russian.
Vladimir Homutov <vl@nginx.com>
parents:
1005
diff
changeset
|
435 Разрешает ревалидацию просроченных элементов кэша при помощи |
1246
5be7716a5684
Documented If-None-Match in proxy_cache_revalidate and friends.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1189
diff
changeset
|
436 условных запросов с полями заголовка |
5be7716a5684
Documented If-None-Match in proxy_cache_revalidate and friends.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1189
diff
changeset
|
437 <header>If-Modified-Since</header> и <header>If-None-Match</header>. |
1016
2d8269d8fea8
Translated documentation on cache revalidation into russian.
Vladimir Homutov <vl@nginx.com>
parents:
1005
diff
changeset
|
438 </para> |
2d8269d8fea8
Translated documentation on cache revalidation into russian.
Vladimir Homutov <vl@nginx.com>
parents:
1005
diff
changeset
|
439 |
2d8269d8fea8
Translated documentation on cache revalidation into russian.
Vladimir Homutov <vl@nginx.com>
parents:
1005
diff
changeset
|
440 </directive> |
2d8269d8fea8
Translated documentation on cache revalidation into russian.
Vladimir Homutov <vl@nginx.com>
parents:
1005
diff
changeset
|
441 |
2d8269d8fea8
Translated documentation on cache revalidation into russian.
Vladimir Homutov <vl@nginx.com>
parents:
1005
diff
changeset
|
442 |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
443 <directive name="fastcgi_cache_use_stale"> |
271 | 444 <syntax> |
364 | 445 <literal>error</literal> | |
446 <literal>timeout</literal> | | |
447 <literal>invalid_header</literal> | | |
448 <literal>updating</literal> | | |
449 <literal>http_500</literal> | | |
450 <literal>http_503</literal> | | |
917
e26a18eb5ccd
Documented http_403 in proxy_next_upstream and friends.
Maxim Dounin <mdounin@mdounin.ru>
parents:
907
diff
changeset
|
451 <literal>http_403</literal> | |
364 | 452 <literal>http_404</literal> | |
453 <literal>off</literal> | |
454 ...</syntax> | |
102
c76a257f3fd4
The directive name is now automatically printed in <default> and <syntax>.
Ruslan Ermilov <ru@nginx.com>
parents:
99
diff
changeset
|
455 <default>off</default> |
295 | 456 <context>http</context> |
457 <context>server</context> | |
458 <context>location</context> | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
459 |
295 | 460 <para> |
461 Определяет, в каких случаях можно использовать устаревший закэшированный ответ, | |
462 если при работе с FastCGI-сервером возникла ошибка. | |
463 Параметры директивы совпадают с параметрами | |
464 директивы <link id="fastcgi_next_upstream"/>. | |
505
837bcf62b628
Emphasized on what the "updating" parameter of the "fastcgi_cache_use_stale"
Ruslan Ermilov <ru@nginx.com>
parents:
498
diff
changeset
|
465 </para> |
837bcf62b628
Emphasized on what the "updating" parameter of the "fastcgi_cache_use_stale"
Ruslan Ermilov <ru@nginx.com>
parents:
498
diff
changeset
|
466 |
837bcf62b628
Emphasized on what the "updating" parameter of the "fastcgi_cache_use_stale"
Ruslan Ermilov <ru@nginx.com>
parents:
498
diff
changeset
|
467 <para> |
295 | 468 Кроме того, дополнительный параметр <literal>updating</literal> |
469 разрешает использовать устаревший закэшированный ответ, | |
470 если на данный момент он уже обновляется. | |
505
837bcf62b628
Emphasized on what the "updating" parameter of the "fastcgi_cache_use_stale"
Ruslan Ermilov <ru@nginx.com>
parents:
498
diff
changeset
|
471 Это позволяет минимизировать число обращений к FastCGI-серверам |
837bcf62b628
Emphasized on what the "updating" parameter of the "fastcgi_cache_use_stale"
Ruslan Ermilov <ru@nginx.com>
parents:
498
diff
changeset
|
472 при обновлении закэшированных данных. |
837bcf62b628
Emphasized on what the "updating" parameter of the "fastcgi_cache_use_stale"
Ruslan Ermilov <ru@nginx.com>
parents:
498
diff
changeset
|
473 </para> |
837bcf62b628
Emphasized on what the "updating" parameter of the "fastcgi_cache_use_stale"
Ruslan Ermilov <ru@nginx.com>
parents:
498
diff
changeset
|
474 |
837bcf62b628
Emphasized on what the "updating" parameter of the "fastcgi_cache_use_stale"
Ruslan Ermilov <ru@nginx.com>
parents:
498
diff
changeset
|
475 <para> |
509 | 476 Чтобы минимизировать число обращений к FastCGI-серверам при |
505
837bcf62b628
Emphasized on what the "updating" parameter of the "fastcgi_cache_use_stale"
Ruslan Ermilov <ru@nginx.com>
parents:
498
diff
changeset
|
477 заполнении нового элемента кэша, можно воспользоваться директивой |
837bcf62b628
Emphasized on what the "updating" parameter of the "fastcgi_cache_use_stale"
Ruslan Ermilov <ru@nginx.com>
parents:
498
diff
changeset
|
478 <link id="fastcgi_cache_lock"/>. |
295 | 479 </para> |
480 | |
481 </directive> | |
482 | |
483 | |
484 <directive name="fastcgi_cache_valid"> | |
485 <syntax>[<value>код</value> ...] <value>время</value></syntax> | |
486 <default/> | |
487 <context>http</context> | |
488 <context>server</context> | |
489 <context>location</context> | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
490 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
491 <para> |
295 | 492 Задаёт время кэширования для разных кодов ответа. |
493 Например, директивы | |
494 <example> | |
495 fastcgi_cache_valid 200 302 10m; | |
496 fastcgi_cache_valid 404 1m; | |
497 </example> | |
966 | 498 задают время кэширования 10 минут для ответов с кодами 200 и 302 |
295 | 499 и 1 минуту для ответов с кодом 404. |
500 </para> | |
501 | |
502 <para> | |
503 Если указано только <value>время</value> кэширования, | |
504 <example> | |
505 fastcgi_cache_valid 5m; | |
506 </example> | |
507 то кэшируются только ответы 200, 301 и 302. | |
508 </para> | |
509 | |
510 <para> | |
511 Кроме того, можно кэшировать любые ответы с помощью параметра | |
512 <literal>any</literal>: | |
513 <example> | |
514 fastcgi_cache_valid 200 302 10m; | |
515 fastcgi_cache_valid 301 1h; | |
516 fastcgi_cache_valid any 1m; | |
517 </example> | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
518 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
519 |
506
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
520 <para> |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
521 Параметры кэширования могут также быть заданы непосредственно |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
522 в заголовке ответа. |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
523 Такой способ приоритетнее, чем задание времени кэширования с помощью директивы. |
1349
97c8b146cb0e
Split the long paragraph about caching parameters into the list.
Ruslan Ermilov <ru@nginx.com>
parents:
1345
diff
changeset
|
524 <list type="bullet" compact="no"> |
97c8b146cb0e
Split the long paragraph about caching parameters into the list.
Ruslan Ermilov <ru@nginx.com>
parents:
1345
diff
changeset
|
525 |
97c8b146cb0e
Split the long paragraph about caching parameters into the list.
Ruslan Ermilov <ru@nginx.com>
parents:
1345
diff
changeset
|
526 <listitem> |
506
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
527 Поле заголовка <header>X-Accel-Expires</header> задаёт время кэширования |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
528 ответа в секундах. |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
529 Значение 0 запрещает кэшировать ответ. |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
530 Если значение начинается с префикса <literal>@</literal>, оно задаёт абсолютное |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
531 время в секундах с начала эпохи, до которого ответ может быть закэширован. |
1349
97c8b146cb0e
Split the long paragraph about caching parameters into the list.
Ruslan Ermilov <ru@nginx.com>
parents:
1345
diff
changeset
|
532 </listitem> |
97c8b146cb0e
Split the long paragraph about caching parameters into the list.
Ruslan Ermilov <ru@nginx.com>
parents:
1345
diff
changeset
|
533 |
97c8b146cb0e
Split the long paragraph about caching parameters into the list.
Ruslan Ermilov <ru@nginx.com>
parents:
1345
diff
changeset
|
534 <listitem> |
506
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
535 Если в заголовке нет поля <header>X-Accel-Expires</header>, |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
536 параметры кэширования определяются по полям заголовка |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
537 <header>Expires</header> или <header>Cache-Control</header>. |
1349
97c8b146cb0e
Split the long paragraph about caching parameters into the list.
Ruslan Ermilov <ru@nginx.com>
parents:
1345
diff
changeset
|
538 </listitem> |
97c8b146cb0e
Split the long paragraph about caching parameters into the list.
Ruslan Ermilov <ru@nginx.com>
parents:
1345
diff
changeset
|
539 |
97c8b146cb0e
Split the long paragraph about caching parameters into the list.
Ruslan Ermilov <ru@nginx.com>
parents:
1345
diff
changeset
|
540 <listitem> |
506
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
541 Ответ, в заголовке которого есть поле <header>Set-Cookie</header>, |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
542 не будет кэшироваться. |
1349
97c8b146cb0e
Split the long paragraph about caching parameters into the list.
Ruslan Ermilov <ru@nginx.com>
parents:
1345
diff
changeset
|
543 </listitem> |
97c8b146cb0e
Split the long paragraph about caching parameters into the list.
Ruslan Ermilov <ru@nginx.com>
parents:
1345
diff
changeset
|
544 |
1353
25db29c8875e
Documented how the "Vary" response header field affects caching.
Ruslan Ermilov <ru@nginx.com>
parents:
1352
diff
changeset
|
545 <listitem> |
25db29c8875e
Documented how the "Vary" response header field affects caching.
Ruslan Ermilov <ru@nginx.com>
parents:
1352
diff
changeset
|
546 Ответ, в заголовке которого есть поле <header>Vary</header> |
25db29c8875e
Documented how the "Vary" response header field affects caching.
Ruslan Ermilov <ru@nginx.com>
parents:
1352
diff
changeset
|
547 со специальным значением “<literal>*</literal>”, |
25db29c8875e
Documented how the "Vary" response header field affects caching.
Ruslan Ermilov <ru@nginx.com>
parents:
1352
diff
changeset
|
548 не будет кэшироваться (1.7.7). |
25db29c8875e
Documented how the "Vary" response header field affects caching.
Ruslan Ermilov <ru@nginx.com>
parents:
1352
diff
changeset
|
549 Ответ, в заголовке которого есть поле <header>Vary</header> |
25db29c8875e
Documented how the "Vary" response header field affects caching.
Ruslan Ermilov <ru@nginx.com>
parents:
1352
diff
changeset
|
550 с другим значением, будет закэширован |
25db29c8875e
Documented how the "Vary" response header field affects caching.
Ruslan Ermilov <ru@nginx.com>
parents:
1352
diff
changeset
|
551 с учётом соответствующих полей заголовка запроса (1.7.7). |
25db29c8875e
Documented how the "Vary" response header field affects caching.
Ruslan Ermilov <ru@nginx.com>
parents:
1352
diff
changeset
|
552 </listitem> |
25db29c8875e
Documented how the "Vary" response header field affects caching.
Ruslan Ermilov <ru@nginx.com>
parents:
1352
diff
changeset
|
553 |
1349
97c8b146cb0e
Split the long paragraph about caching parameters into the list.
Ruslan Ermilov <ru@nginx.com>
parents:
1345
diff
changeset
|
554 </list> |
506
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
555 Обработка одного или более из этих полей заголовка может быть отключена |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
556 при помощи директивы <link id="fastcgi_ignore_headers"/>. |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
557 </para> |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
558 |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
559 </directive> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
560 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
561 |
862
6a40b8e7219a
Documented the "fastcgi_catch_stderr" directive.
Homutov Vladimir <vl@nginx.com>
parents:
815
diff
changeset
|
562 <directive name="fastcgi_catch_stderr"> |
6a40b8e7219a
Documented the "fastcgi_catch_stderr" directive.
Homutov Vladimir <vl@nginx.com>
parents:
815
diff
changeset
|
563 <syntax><value>строка</value></syntax> |
6a40b8e7219a
Documented the "fastcgi_catch_stderr" directive.
Homutov Vladimir <vl@nginx.com>
parents:
815
diff
changeset
|
564 <default/> |
6a40b8e7219a
Documented the "fastcgi_catch_stderr" directive.
Homutov Vladimir <vl@nginx.com>
parents:
815
diff
changeset
|
565 <context>http</context> |
6a40b8e7219a
Documented the "fastcgi_catch_stderr" directive.
Homutov Vladimir <vl@nginx.com>
parents:
815
diff
changeset
|
566 <context>server</context> |
6a40b8e7219a
Documented the "fastcgi_catch_stderr" directive.
Homutov Vladimir <vl@nginx.com>
parents:
815
diff
changeset
|
567 <context>location</context> |
6a40b8e7219a
Documented the "fastcgi_catch_stderr" directive.
Homutov Vladimir <vl@nginx.com>
parents:
815
diff
changeset
|
568 |
6a40b8e7219a
Documented the "fastcgi_catch_stderr" directive.
Homutov Vladimir <vl@nginx.com>
parents:
815
diff
changeset
|
569 <para> |
6a40b8e7219a
Documented the "fastcgi_catch_stderr" directive.
Homutov Vladimir <vl@nginx.com>
parents:
815
diff
changeset
|
570 Задаёт строку для поиска в потоке ошибок ответа, |
6a40b8e7219a
Documented the "fastcgi_catch_stderr" directive.
Homutov Vladimir <vl@nginx.com>
parents:
815
diff
changeset
|
571 полученного от FastCGI-сервера. |
6a40b8e7219a
Documented the "fastcgi_catch_stderr" directive.
Homutov Vladimir <vl@nginx.com>
parents:
815
diff
changeset
|
572 Если <value>строка</value> найдена, то считается, что FastCGI-сервер |
6a40b8e7219a
Documented the "fastcgi_catch_stderr" directive.
Homutov Vladimir <vl@nginx.com>
parents:
815
diff
changeset
|
573 вернул <link id="fastcgi_next_upstream">неверный ответ</link>. |
6a40b8e7219a
Documented the "fastcgi_catch_stderr" directive.
Homutov Vladimir <vl@nginx.com>
parents:
815
diff
changeset
|
574 Это позволяет обрабатывать ошибки приложений в nginx, например: |
6a40b8e7219a
Documented the "fastcgi_catch_stderr" directive.
Homutov Vladimir <vl@nginx.com>
parents:
815
diff
changeset
|
575 <example> |
6a40b8e7219a
Documented the "fastcgi_catch_stderr" directive.
Homutov Vladimir <vl@nginx.com>
parents:
815
diff
changeset
|
576 location /php { |
6a40b8e7219a
Documented the "fastcgi_catch_stderr" directive.
Homutov Vladimir <vl@nginx.com>
parents:
815
diff
changeset
|
577 fastcgi_pass backend:9000; |
6a40b8e7219a
Documented the "fastcgi_catch_stderr" directive.
Homutov Vladimir <vl@nginx.com>
parents:
815
diff
changeset
|
578 ... |
6a40b8e7219a
Documented the "fastcgi_catch_stderr" directive.
Homutov Vladimir <vl@nginx.com>
parents:
815
diff
changeset
|
579 fastcgi_catch_stderr "PHP Fatal error"; |
6a40b8e7219a
Documented the "fastcgi_catch_stderr" directive.
Homutov Vladimir <vl@nginx.com>
parents:
815
diff
changeset
|
580 fastcgi_next_upstream error timeout invalid_header; |
6a40b8e7219a
Documented the "fastcgi_catch_stderr" directive.
Homutov Vladimir <vl@nginx.com>
parents:
815
diff
changeset
|
581 } |
6a40b8e7219a
Documented the "fastcgi_catch_stderr" directive.
Homutov Vladimir <vl@nginx.com>
parents:
815
diff
changeset
|
582 </example> |
6a40b8e7219a
Documented the "fastcgi_catch_stderr" directive.
Homutov Vladimir <vl@nginx.com>
parents:
815
diff
changeset
|
583 </para> |
6a40b8e7219a
Documented the "fastcgi_catch_stderr" directive.
Homutov Vladimir <vl@nginx.com>
parents:
815
diff
changeset
|
584 |
6a40b8e7219a
Documented the "fastcgi_catch_stderr" directive.
Homutov Vladimir <vl@nginx.com>
parents:
815
diff
changeset
|
585 </directive> |
6a40b8e7219a
Documented the "fastcgi_catch_stderr" directive.
Homutov Vladimir <vl@nginx.com>
parents:
815
diff
changeset
|
586 |
6a40b8e7219a
Documented the "fastcgi_catch_stderr" directive.
Homutov Vladimir <vl@nginx.com>
parents:
815
diff
changeset
|
587 |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
588 <directive name="fastcgi_connect_timeout"> |
102
c76a257f3fd4
The directive name is now automatically printed in <default> and <syntax>.
Ruslan Ermilov <ru@nginx.com>
parents:
99
diff
changeset
|
589 <syntax><value>время</value></syntax> |
295 | 590 <default>60s</default> |
591 <context>http</context> | |
592 <context>server</context> | |
593 <context>location</context> | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
594 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
595 <para> |
295 | 596 Задаёт таймаут для установления соединения с FastCGI-сервером. |
597 Необходимо иметь в виду, что этот таймаут обычно не может превышать 75 секунд. | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
598 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
599 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
600 </directive> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
601 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
602 |
1337
91a064bdb4f9
Documented the "proxy_force_ranges" directive and friends.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1290
diff
changeset
|
603 <directive name="fastcgi_force_ranges"> |
91a064bdb4f9
Documented the "proxy_force_ranges" directive and friends.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1290
diff
changeset
|
604 <syntax><literal>on</literal> | <literal>off</literal></syntax> |
91a064bdb4f9
Documented the "proxy_force_ranges" directive and friends.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1290
diff
changeset
|
605 <default>off</default> |
91a064bdb4f9
Documented the "proxy_force_ranges" directive and friends.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1290
diff
changeset
|
606 <context>http</context> |
91a064bdb4f9
Documented the "proxy_force_ranges" directive and friends.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1290
diff
changeset
|
607 <context>server</context> |
91a064bdb4f9
Documented the "proxy_force_ranges" directive and friends.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1290
diff
changeset
|
608 <context>location</context> |
91a064bdb4f9
Documented the "proxy_force_ranges" directive and friends.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1290
diff
changeset
|
609 <appeared-in>1.7.7</appeared-in> |
91a064bdb4f9
Documented the "proxy_force_ranges" directive and friends.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1290
diff
changeset
|
610 |
91a064bdb4f9
Documented the "proxy_force_ranges" directive and friends.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1290
diff
changeset
|
611 <para> |
91a064bdb4f9
Documented the "proxy_force_ranges" directive and friends.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1290
diff
changeset
|
612 Включает поддержку диапазонов запрашиваемых байт (byte-range) |
91a064bdb4f9
Documented the "proxy_force_ranges" directive and friends.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1290
diff
changeset
|
613 для кэшированных и некэшированных ответов FastCGI-сервера |
91a064bdb4f9
Documented the "proxy_force_ranges" directive and friends.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1290
diff
changeset
|
614 вне зависимости от наличия поля <header>Accept-Ranges</header> |
91a064bdb4f9
Documented the "proxy_force_ranges" directive and friends.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1290
diff
changeset
|
615 в заголовках этих ответов. |
91a064bdb4f9
Documented the "proxy_force_ranges" directive and friends.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1290
diff
changeset
|
616 </para> |
91a064bdb4f9
Documented the "proxy_force_ranges" directive and friends.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1290
diff
changeset
|
617 |
91a064bdb4f9
Documented the "proxy_force_ranges" directive and friends.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1290
diff
changeset
|
618 </directive> |
91a064bdb4f9
Documented the "proxy_force_ranges" directive and friends.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1290
diff
changeset
|
619 |
91a064bdb4f9
Documented the "proxy_force_ranges" directive and friends.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1290
diff
changeset
|
620 |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
621 <directive name="fastcgi_hide_header"> |
295 | 622 <syntax><value>поле</value></syntax> |
102
c76a257f3fd4
The directive name is now automatically printed in <default> and <syntax>.
Ruslan Ermilov <ru@nginx.com>
parents:
99
diff
changeset
|
623 <default/> |
295 | 624 <context>http</context> |
625 <context>server</context> | |
626 <context>location</context> | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
627 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
628 <para> |
295 | 629 По умолчанию |
630 nginx не передаёт клиенту поля заголовка <header>Status</header> и | |
631 <header>X-Accel-...</header> из ответа FastCGI-сервера. | |
632 Директива <literal>fastcgi_hide_header</literal> задаёт дополнительные поля, | |
633 которые не будут передаваться. | |
634 Если же передачу полей нужно разрешить, можно воспользоваться | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
635 директивой <link id="fastcgi_pass_header"/>. |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
636 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
637 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
638 </directive> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
639 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
640 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
641 <directive name="fastcgi_ignore_client_abort"> |
271 | 642 <syntax><literal>on</literal> | <literal>off</literal></syntax> |
102
c76a257f3fd4
The directive name is now automatically printed in <default> and <syntax>.
Ruslan Ermilov <ru@nginx.com>
parents:
99
diff
changeset
|
643 <default>off</default> |
295 | 644 <context>http</context> |
645 <context>server</context> | |
646 <context>location</context> | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
647 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
648 <para> |
295 | 649 Определяет, закрывать ли соединение с FastCGI-сервером |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
650 в случае, если клиент закрыл соединение, не дождавшись ответа. |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
651 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
652 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
653 </directive> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
654 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
655 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
656 <directive name="fastcgi_ignore_headers"> |
295 | 657 <syntax><value>поле</value> ...</syntax> |
102
c76a257f3fd4
The directive name is now automatically printed in <default> and <syntax>.
Ruslan Ermilov <ru@nginx.com>
parents:
99
diff
changeset
|
658 <default/> |
295 | 659 <context>http</context> |
660 <context>server</context> | |
661 <context>location</context> | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
662 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
663 <para> |
295 | 664 Запрещает обработку некоторых полей заголовка из ответа FastCGI-сервера. |
665 В директиве можно указать поля <header>X-Accel-Redirect</header>, | |
666 <header>X-Accel-Expires</header>, <header>X-Accel-Limit-Rate</header> (1.1.6), | |
667 <header>X-Accel-Buffering</header> (1.1.6), | |
668 <header>X-Accel-Charset</header> (1.1.6), <header>Expires</header>, | |
1345
da296387cdac
Documented the Vary support in proxy_ignore_headers and friends.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1343
diff
changeset
|
669 <header>Cache-Control</header>, <header>Set-Cookie</header> (0.8.44) |
da296387cdac
Documented the Vary support in proxy_ignore_headers and friends.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1343
diff
changeset
|
670 и <header>Vary</header> (1.7.7). |
295 | 671 </para> |
672 | |
506
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
673 <para> |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
674 Если не запрещено, обработка этих полей заголовка заключается в следующем: |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
675 <list type="bullet" compact="no"> |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
676 |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
677 <listitem> |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
678 <header>X-Accel-Expires</header>, <header>Expires</header>, |
1345
da296387cdac
Documented the Vary support in proxy_ignore_headers and friends.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1343
diff
changeset
|
679 <header>Cache-Control</header>, <header>Set-Cookie</header> |
da296387cdac
Documented the Vary support in proxy_ignore_headers and friends.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1343
diff
changeset
|
680 и <header>Vary</header> |
506
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
681 задают параметры <link id="fastcgi_cache_valid">кэширования</link> ответа; |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
682 </listitem> |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
683 |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
684 <listitem> |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
685 <header>X-Accel-Redirect</header> производит |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
686 <link doc="ngx_http_core_module.xml" id="internal">внутреннее |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
687 перенаправление</link> на указанный URI; |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
688 </listitem> |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
689 |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
690 <listitem> |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
691 <header>X-Accel-Limit-Rate</header> задаёт |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
692 <link doc="ngx_http_core_module.xml" id="limit_rate">ограничение |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
693 скорости</link> передачи ответа клиенту; |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
694 </listitem> |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
695 |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
696 <listitem> |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
697 <header>X-Accel-Buffering</header> включает или выключает |
995
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
698 <link id="fastcgi_buffering">буферизацию</link> ответа; |
506
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
699 </listitem> |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
700 |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
701 <listitem> |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
702 <header>X-Accel-Charset</header> задаёт желаемую |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
703 <link doc="ngx_http_charset_module.xml" id="charset">кодировку</link> |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
704 ответа. |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
705 </listitem> |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
706 |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
707 </list> |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
708 </para> |
657848837328
Documented how nginx processes proxied server's response header fields
Ruslan Ermilov <ru@nginx.com>
parents:
505
diff
changeset
|
709 |
295 | 710 </directive> |
711 | |
712 | |
713 <directive name="fastcgi_index"> | |
714 <syntax><value>имя</value></syntax> | |
715 <default/> | |
716 <context>http</context> | |
717 <context>server</context> | |
718 <context>location</context> | |
719 | |
720 <para> | |
721 Задаёт имя файла, который при создании переменной | |
722 <var>$fastcgi_script_name</var> будет добавляться после URI, | |
723 если URI заканчивается слэшом. | |
724 Например, при таких настройках | |
725 <example> | |
726 fastcgi_index index.php; | |
727 fastcgi_param SCRIPT_FILENAME /home/www/scripts/php$fastcgi_script_name; | |
728 </example> | |
729 и запросе “<literal>/page.php</literal>” | |
730 параметр <literal>SCRIPT_FILENAME</literal> будет равен | |
731 “<literal>/home/www/scripts/php/page.php</literal>”, | |
732 а при запросе “<literal>/</literal>”— | |
733 “<literal>/home/www/scripts/php/index.php</literal>”. | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
734 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
735 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
736 </directive> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
737 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
738 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
739 <directive name="fastcgi_intercept_errors"> |
271 | 740 <syntax><literal>on</literal> | <literal>off</literal></syntax> |
102
c76a257f3fd4
The directive name is now automatically printed in <default> and <syntax>.
Ruslan Ermilov <ru@nginx.com>
parents:
99
diff
changeset
|
741 <default>off</default> |
295 | 742 <context>http</context> |
743 <context>server</context> | |
744 <context>location</context> | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
745 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
746 <para> |
295 | 747 Определяет, передавать ли клиенту ответы FastCGI-сервера с кодом |
907
43887f41bb17
Corrected the descriptions of {proxy,fastcgi}_intercept_errors.
Ruslan Ermilov <ru@nginx.com>
parents:
862
diff
changeset
|
748 больше либо равным 300, или же перенаправлять их на обработку nginx’у с помощью |
295 | 749 директивы <link doc="ngx_http_core_module.xml" id="error_page"/>. |
98 | 750 </para> |
751 | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
752 </directive> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
753 |
364 | 754 |
316
1fb1c077658b
Documented the following directives: "keepalive", "proxy_http_version",
Ruslan Ermilov <ru@nginx.com>
parents:
310
diff
changeset
|
755 <directive name="fastcgi_keep_conn"> |
1fb1c077658b
Documented the following directives: "keepalive", "proxy_http_version",
Ruslan Ermilov <ru@nginx.com>
parents:
310
diff
changeset
|
756 <syntax><literal>on</literal> | <literal>off</literal></syntax> |
1fb1c077658b
Documented the following directives: "keepalive", "proxy_http_version",
Ruslan Ermilov <ru@nginx.com>
parents:
310
diff
changeset
|
757 <default>off</default> |
1fb1c077658b
Documented the following directives: "keepalive", "proxy_http_version",
Ruslan Ermilov <ru@nginx.com>
parents:
310
diff
changeset
|
758 <context>http</context> |
1fb1c077658b
Documented the following directives: "keepalive", "proxy_http_version",
Ruslan Ermilov <ru@nginx.com>
parents:
310
diff
changeset
|
759 <context>server</context> |
1fb1c077658b
Documented the following directives: "keepalive", "proxy_http_version",
Ruslan Ermilov <ru@nginx.com>
parents:
310
diff
changeset
|
760 <context>location</context> |
498
65843513cff5
Documented that "fastcgi_keep_conn" appeared in 1.1.4.
Ruslan Ermilov <ru@nginx.com>
parents:
411
diff
changeset
|
761 <appeared-in>1.1.4</appeared-in> |
316
1fb1c077658b
Documented the following directives: "keepalive", "proxy_http_version",
Ruslan Ermilov <ru@nginx.com>
parents:
310
diff
changeset
|
762 |
1fb1c077658b
Documented the following directives: "keepalive", "proxy_http_version",
Ruslan Ermilov <ru@nginx.com>
parents:
310
diff
changeset
|
763 <para> |
1fb1c077658b
Documented the following directives: "keepalive", "proxy_http_version",
Ruslan Ermilov <ru@nginx.com>
parents:
310
diff
changeset
|
764 По умолчанию FastCGI-сервер будет закрывать соединение сразу же |
1fb1c077658b
Documented the following directives: "keepalive", "proxy_http_version",
Ruslan Ermilov <ru@nginx.com>
parents:
310
diff
changeset
|
765 после отправки ответа. |
1fb1c077658b
Documented the following directives: "keepalive", "proxy_http_version",
Ruslan Ermilov <ru@nginx.com>
parents:
310
diff
changeset
|
766 При установке значения <literal>on</literal> nginx указывает |
1fb1c077658b
Documented the following directives: "keepalive", "proxy_http_version",
Ruslan Ermilov <ru@nginx.com>
parents:
310
diff
changeset
|
767 FastCGI-серверу оставлять соединения открытыми. |
1fb1c077658b
Documented the following directives: "keepalive", "proxy_http_version",
Ruslan Ermilov <ru@nginx.com>
parents:
310
diff
changeset
|
768 Это в частности требуется для функционирования |
1fb1c077658b
Documented the following directives: "keepalive", "proxy_http_version",
Ruslan Ermilov <ru@nginx.com>
parents:
310
diff
changeset
|
769 <link doc="ngx_http_upstream_module.xml" id="keepalive">постоянных |
1fb1c077658b
Documented the following directives: "keepalive", "proxy_http_version",
Ruslan Ermilov <ru@nginx.com>
parents:
310
diff
changeset
|
770 соединений</link> с FastCGI-серверами. |
1fb1c077658b
Documented the following directives: "keepalive", "proxy_http_version",
Ruslan Ermilov <ru@nginx.com>
parents:
310
diff
changeset
|
771 </para> |
1fb1c077658b
Documented the following directives: "keepalive", "proxy_http_version",
Ruslan Ermilov <ru@nginx.com>
parents:
310
diff
changeset
|
772 |
1fb1c077658b
Documented the following directives: "keepalive", "proxy_http_version",
Ruslan Ermilov <ru@nginx.com>
parents:
310
diff
changeset
|
773 </directive> |
1fb1c077658b
Documented the following directives: "keepalive", "proxy_http_version",
Ruslan Ermilov <ru@nginx.com>
parents:
310
diff
changeset
|
774 |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
775 |
1343
1bdde28e359b
Fixed fallouts from the previous change.
Ruslan Ermilov <ru@nginx.com>
parents:
1342
diff
changeset
|
776 <directive name="fastcgi_limit_rate"> |
1bdde28e359b
Fixed fallouts from the previous change.
Ruslan Ermilov <ru@nginx.com>
parents:
1342
diff
changeset
|
777 <syntax><value>скорость</value></syntax> |
1bdde28e359b
Fixed fallouts from the previous change.
Ruslan Ermilov <ru@nginx.com>
parents:
1342
diff
changeset
|
778 <default>0</default> |
1bdde28e359b
Fixed fallouts from the previous change.
Ruslan Ermilov <ru@nginx.com>
parents:
1342
diff
changeset
|
779 <context>http</context> |
1bdde28e359b
Fixed fallouts from the previous change.
Ruslan Ermilov <ru@nginx.com>
parents:
1342
diff
changeset
|
780 <context>server</context> |
1bdde28e359b
Fixed fallouts from the previous change.
Ruslan Ermilov <ru@nginx.com>
parents:
1342
diff
changeset
|
781 <context>location</context> |
1bdde28e359b
Fixed fallouts from the previous change.
Ruslan Ermilov <ru@nginx.com>
parents:
1342
diff
changeset
|
782 <appeared-in>1.7.7</appeared-in> |
1bdde28e359b
Fixed fallouts from the previous change.
Ruslan Ermilov <ru@nginx.com>
parents:
1342
diff
changeset
|
783 |
1bdde28e359b
Fixed fallouts from the previous change.
Ruslan Ermilov <ru@nginx.com>
parents:
1342
diff
changeset
|
784 <para> |
1bdde28e359b
Fixed fallouts from the previous change.
Ruslan Ermilov <ru@nginx.com>
parents:
1342
diff
changeset
|
785 Ограничивает скорость чтения ответа от FastCGI-сервера. |
1bdde28e359b
Fixed fallouts from the previous change.
Ruslan Ermilov <ru@nginx.com>
parents:
1342
diff
changeset
|
786 <value>Скорость</value> задаётся в байтах в секунду. |
1bdde28e359b
Fixed fallouts from the previous change.
Ruslan Ermilov <ru@nginx.com>
parents:
1342
diff
changeset
|
787 Значение 0 отключает ограничение скорости. |
1bdde28e359b
Fixed fallouts from the previous change.
Ruslan Ermilov <ru@nginx.com>
parents:
1342
diff
changeset
|
788 Ограничение устанавливается на запрос, |
1bdde28e359b
Fixed fallouts from the previous change.
Ruslan Ermilov <ru@nginx.com>
parents:
1342
diff
changeset
|
789 поэтому, если nginx одновременно |
1bdde28e359b
Fixed fallouts from the previous change.
Ruslan Ermilov <ru@nginx.com>
parents:
1342
diff
changeset
|
790 откроет два соединения к FastCGI-серверу, |
1bdde28e359b
Fixed fallouts from the previous change.
Ruslan Ermilov <ru@nginx.com>
parents:
1342
diff
changeset
|
791 суммарная скорость будет вдвое выше заданного ограничения. |
1bdde28e359b
Fixed fallouts from the previous change.
Ruslan Ermilov <ru@nginx.com>
parents:
1342
diff
changeset
|
792 Ограничение работает только в случае, если включена |
1bdde28e359b
Fixed fallouts from the previous change.
Ruslan Ermilov <ru@nginx.com>
parents:
1342
diff
changeset
|
793 <link id="fastcgi_buffering">буферизация</link> ответов FastCGI-сервера. |
1bdde28e359b
Fixed fallouts from the previous change.
Ruslan Ermilov <ru@nginx.com>
parents:
1342
diff
changeset
|
794 </para> |
1bdde28e359b
Fixed fallouts from the previous change.
Ruslan Ermilov <ru@nginx.com>
parents:
1342
diff
changeset
|
795 |
1bdde28e359b
Fixed fallouts from the previous change.
Ruslan Ermilov <ru@nginx.com>
parents:
1342
diff
changeset
|
796 </directive> |
1bdde28e359b
Fixed fallouts from the previous change.
Ruslan Ermilov <ru@nginx.com>
parents:
1342
diff
changeset
|
797 |
1bdde28e359b
Fixed fallouts from the previous change.
Ruslan Ermilov <ru@nginx.com>
parents:
1342
diff
changeset
|
798 |
411
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
799 <directive name="fastcgi_max_temp_file_size"> |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
800 <syntax><value>размер</value></syntax> |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
801 <default>1024m</default> |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
802 <context>http</context> |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
803 <context>server</context> |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
804 <context>location</context> |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
805 |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
806 <para> |
995
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
807 Если включена <link id="fastcgi_buffering">буферизация</link> ответов |
1153
4e20e4f8f49b
Finished truncation of "memory buffers" to just "buffers".
Ruslan Ermilov <ru@nginx.com>
parents:
1135
diff
changeset
|
808 FastCGI-сервера, и ответ не вмещается целиком в буферы, |
995
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
809 заданные директивами <link id="fastcgi_buffer_size"/> и |
c5ccf511346a
Documented the "fastcgi_buffering" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
966
diff
changeset
|
810 <link id="fastcgi_buffers"/>, часть ответа может быть записана во временный файл. |
411
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
811 Эта директива задаёт максимальный <value>размер</value> временного файла. |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
812 Размер данных, сбрасываемых во временный файл за один раз, задаётся |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
813 директивой <link id="fastcgi_temp_file_write_size"/>. |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
814 </para> |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
815 |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
816 <para> |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
817 Значение 0 отключает возможность буферизации ответов во временные файлы. |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
818 </para> |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
819 |
1352
dbb618f60a54
Elaborate on writing proxied responses to files.
Ruslan Ermilov <ru@nginx.com>
parents:
1349
diff
changeset
|
820 <para> |
dbb618f60a54
Elaborate on writing proxied responses to files.
Ruslan Ermilov <ru@nginx.com>
parents:
1349
diff
changeset
|
821 <note> |
dbb618f60a54
Elaborate on writing proxied responses to files.
Ruslan Ermilov <ru@nginx.com>
parents:
1349
diff
changeset
|
822 Данное ограничение не распространяется на ответы, |
dbb618f60a54
Elaborate on writing proxied responses to files.
Ruslan Ermilov <ru@nginx.com>
parents:
1349
diff
changeset
|
823 которые будут <link id="fastcgi_cache">закэшированы</link> |
dbb618f60a54
Elaborate on writing proxied responses to files.
Ruslan Ermilov <ru@nginx.com>
parents:
1349
diff
changeset
|
824 или <link id="fastcgi_store">сохранены</link> на диске. |
dbb618f60a54
Elaborate on writing proxied responses to files.
Ruslan Ermilov <ru@nginx.com>
parents:
1349
diff
changeset
|
825 </note> |
dbb618f60a54
Elaborate on writing proxied responses to files.
Ruslan Ermilov <ru@nginx.com>
parents:
1349
diff
changeset
|
826 </para> |
dbb618f60a54
Elaborate on writing proxied responses to files.
Ruslan Ermilov <ru@nginx.com>
parents:
1349
diff
changeset
|
827 |
411
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
828 </directive> |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
829 |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
830 |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
831 <directive name="fastcgi_next_upstream"> |
102
c76a257f3fd4
The directive name is now automatically printed in <default> and <syntax>.
Ruslan Ermilov <ru@nginx.com>
parents:
99
diff
changeset
|
832 <syntax> |
364 | 833 <literal>error</literal> | |
834 <literal>timeout</literal> | | |
835 <literal>invalid_header</literal> | | |
836 <literal>http_500</literal> | | |
837 <literal>http_503</literal> | | |
917
e26a18eb5ccd
Documented http_403 in proxy_next_upstream and friends.
Maxim Dounin <mdounin@mdounin.ru>
parents:
907
diff
changeset
|
838 <literal>http_403</literal> | |
364 | 839 <literal>http_404</literal> | |
840 <literal>off</literal> | |
841 ...</syntax> | |
102
c76a257f3fd4
The directive name is now automatically printed in <default> and <syntax>.
Ruslan Ermilov <ru@nginx.com>
parents:
99
diff
changeset
|
842 <default>error timeout</default> |
295 | 843 <context>http</context> |
844 <context>server</context> | |
845 <context>location</context> | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
846 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
847 <para> |
295 | 848 Определяет, в каких случаях запрос будет передан следующему серверу: |
849 <list type="tag"> | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
850 |
295 | 851 <tag-name><literal>error</literal></tag-name> |
852 <tag-desc>произошла ошибка соединения с сервером, передачи ему запроса или | |
853 чтения заголовка ответа сервера;</tag-desc> | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
854 |
295 | 855 <tag-name><literal>timeout</literal></tag-name> |
856 <tag-desc>произошёл таймаут во время соединения с сервером, | |
857 передачи ему запроса или чтения заголовка ответа сервера;</tag-desc> | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
858 |
295 | 859 <tag-name><literal>invalid_header</literal></tag-name> |
860 <tag-desc>сервер вернул пустой или неверный ответ;</tag-desc> | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
861 |
295 | 862 <tag-name><literal>http_500</literal></tag-name> |
863 <tag-desc>сервер вернул ответ с кодом 500;</tag-desc> | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
864 |
295 | 865 <tag-name><literal>http_503</literal></tag-name> |
866 <tag-desc>сервер вернул ответ с кодом 503;</tag-desc> | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
867 |
917
e26a18eb5ccd
Documented http_403 in proxy_next_upstream and friends.
Maxim Dounin <mdounin@mdounin.ru>
parents:
907
diff
changeset
|
868 <tag-name><literal>http_403</literal></tag-name> |
e26a18eb5ccd
Documented http_403 in proxy_next_upstream and friends.
Maxim Dounin <mdounin@mdounin.ru>
parents:
907
diff
changeset
|
869 <tag-desc>сервер вернул ответ с кодом 403;</tag-desc> |
e26a18eb5ccd
Documented http_403 in proxy_next_upstream and friends.
Maxim Dounin <mdounin@mdounin.ru>
parents:
907
diff
changeset
|
870 |
295 | 871 <tag-name><literal>http_404</literal></tag-name> |
872 <tag-desc>сервер вернул ответ с кодом 404;</tag-desc> | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
873 |
295 | 874 <tag-name><literal>off</literal></tag-name> |
875 <tag-desc>запрещает передачу запроса следующему серверу.</tag-desc> | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
876 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
877 </list> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
878 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
879 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
880 <para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
881 Необходимо понимать, что передача запроса следующему серверу возможна |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
882 только при условии, что клиенту ещё ничего не передавалось. |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
883 То есть, если ошибка или таймаут возникли в середине передачи ответа, |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
884 то исправить это уже невозможно. |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
885 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
886 |
942
ba3d6ade3513
Elaborate on upstream server failures.
Ruslan Ermilov <ru@nginx.com>
parents:
917
diff
changeset
|
887 <para> |
1289
57fc39924d42
Proxy/memcached/fastcgi/scgi/uwsgi: updated link in _next_upstream directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1246
diff
changeset
|
888 Директива также определяет, что считается |
57fc39924d42
Proxy/memcached/fastcgi/scgi/uwsgi: updated link in _next_upstream directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1246
diff
changeset
|
889 <link doc="ngx_http_upstream_module.xml" id="max_fails">неудачной |
57fc39924d42
Proxy/memcached/fastcgi/scgi/uwsgi: updated link in _next_upstream directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1246
diff
changeset
|
890 попыткой</link> работы с сервером. |
942
ba3d6ade3513
Elaborate on upstream server failures.
Ruslan Ermilov <ru@nginx.com>
parents:
917
diff
changeset
|
891 Случаи <literal>error</literal>, <literal>timeout</literal> и |
ba3d6ade3513
Elaborate on upstream server failures.
Ruslan Ermilov <ru@nginx.com>
parents:
917
diff
changeset
|
892 <literal>invalid_header</literal> |
ba3d6ade3513
Elaborate on upstream server failures.
Ruslan Ermilov <ru@nginx.com>
parents:
917
diff
changeset
|
893 всегда считаются неудачными попытками, даже если они не указаны в директиве. |
ba3d6ade3513
Elaborate on upstream server failures.
Ruslan Ermilov <ru@nginx.com>
parents:
917
diff
changeset
|
894 Случаи <literal>http_500</literal> и <literal>http_503</literal> |
ba3d6ade3513
Elaborate on upstream server failures.
Ruslan Ermilov <ru@nginx.com>
parents:
917
diff
changeset
|
895 считаются неудачными попытками, только если они указаны в директиве. |
ba3d6ade3513
Elaborate on upstream server failures.
Ruslan Ermilov <ru@nginx.com>
parents:
917
diff
changeset
|
896 Случаи <literal>http_403</literal> и <literal>http_404</literal> |
ba3d6ade3513
Elaborate on upstream server failures.
Ruslan Ermilov <ru@nginx.com>
parents:
917
diff
changeset
|
897 никогда не считаются неудачными попытками. |
ba3d6ade3513
Elaborate on upstream server failures.
Ruslan Ermilov <ru@nginx.com>
parents:
917
diff
changeset
|
898 </para> |
ba3d6ade3513
Elaborate on upstream server failures.
Ruslan Ermilov <ru@nginx.com>
parents:
917
diff
changeset
|
899 |
1290
f5cc9f2aef9a
Proxy/memcached/fastcgi/scgi/uwsgi: _next_upstream_timeout,_next_upstream_tries.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1289
diff
changeset
|
900 <para> |
f5cc9f2aef9a
Proxy/memcached/fastcgi/scgi/uwsgi: _next_upstream_timeout,_next_upstream_tries.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1289
diff
changeset
|
901 Передача запроса следующему серверу может быть ограничена по |
f5cc9f2aef9a
Proxy/memcached/fastcgi/scgi/uwsgi: _next_upstream_timeout,_next_upstream_tries.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1289
diff
changeset
|
902 <link id="fastcgi_next_upstream_tries">количеству попыток</link> |
f5cc9f2aef9a
Proxy/memcached/fastcgi/scgi/uwsgi: _next_upstream_timeout,_next_upstream_tries.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1289
diff
changeset
|
903 и по <link id="fastcgi_next_upstream_timeout">времени</link>. |
f5cc9f2aef9a
Proxy/memcached/fastcgi/scgi/uwsgi: _next_upstream_timeout,_next_upstream_tries.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1289
diff
changeset
|
904 </para> |
f5cc9f2aef9a
Proxy/memcached/fastcgi/scgi/uwsgi: _next_upstream_timeout,_next_upstream_tries.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1289
diff
changeset
|
905 |
f5cc9f2aef9a
Proxy/memcached/fastcgi/scgi/uwsgi: _next_upstream_timeout,_next_upstream_tries.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1289
diff
changeset
|
906 </directive> |
f5cc9f2aef9a
Proxy/memcached/fastcgi/scgi/uwsgi: _next_upstream_timeout,_next_upstream_tries.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1289
diff
changeset
|
907 |
f5cc9f2aef9a
Proxy/memcached/fastcgi/scgi/uwsgi: _next_upstream_timeout,_next_upstream_tries.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1289
diff
changeset
|
908 |
f5cc9f2aef9a
Proxy/memcached/fastcgi/scgi/uwsgi: _next_upstream_timeout,_next_upstream_tries.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1289
diff
changeset
|
909 <directive name="fastcgi_next_upstream_timeout"> |
f5cc9f2aef9a
Proxy/memcached/fastcgi/scgi/uwsgi: _next_upstream_timeout,_next_upstream_tries.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1289
diff
changeset
|
910 <syntax><value>время</value></syntax> |
f5cc9f2aef9a
Proxy/memcached/fastcgi/scgi/uwsgi: _next_upstream_timeout,_next_upstream_tries.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1289
diff
changeset
|
911 <default>0</default> |
f5cc9f2aef9a
Proxy/memcached/fastcgi/scgi/uwsgi: _next_upstream_timeout,_next_upstream_tries.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1289
diff
changeset
|
912 <context>http</context> |
f5cc9f2aef9a
Proxy/memcached/fastcgi/scgi/uwsgi: _next_upstream_timeout,_next_upstream_tries.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1289
diff
changeset
|
913 <context>server</context> |
f5cc9f2aef9a
Proxy/memcached/fastcgi/scgi/uwsgi: _next_upstream_timeout,_next_upstream_tries.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1289
diff
changeset
|
914 <context>location</context> |
f5cc9f2aef9a
Proxy/memcached/fastcgi/scgi/uwsgi: _next_upstream_timeout,_next_upstream_tries.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1289
diff
changeset
|
915 <appeared-in>1.7.5</appeared-in> |
f5cc9f2aef9a
Proxy/memcached/fastcgi/scgi/uwsgi: _next_upstream_timeout,_next_upstream_tries.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1289
diff
changeset
|
916 |
f5cc9f2aef9a
Proxy/memcached/fastcgi/scgi/uwsgi: _next_upstream_timeout,_next_upstream_tries.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1289
diff
changeset
|
917 <para> |
f5cc9f2aef9a
Proxy/memcached/fastcgi/scgi/uwsgi: _next_upstream_timeout,_next_upstream_tries.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1289
diff
changeset
|
918 Ограничивает время, в течение которого возможна передача запроса |
f5cc9f2aef9a
Proxy/memcached/fastcgi/scgi/uwsgi: _next_upstream_timeout,_next_upstream_tries.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1289
diff
changeset
|
919 <link id="fastcgi_next_upstream">следующему серверу</link>. |
f5cc9f2aef9a
Proxy/memcached/fastcgi/scgi/uwsgi: _next_upstream_timeout,_next_upstream_tries.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1289
diff
changeset
|
920 Значение <literal>0</literal> отключает это ограничение. |
f5cc9f2aef9a
Proxy/memcached/fastcgi/scgi/uwsgi: _next_upstream_timeout,_next_upstream_tries.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1289
diff
changeset
|
921 </para> |
f5cc9f2aef9a
Proxy/memcached/fastcgi/scgi/uwsgi: _next_upstream_timeout,_next_upstream_tries.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1289
diff
changeset
|
922 |
f5cc9f2aef9a
Proxy/memcached/fastcgi/scgi/uwsgi: _next_upstream_timeout,_next_upstream_tries.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1289
diff
changeset
|
923 </directive> |
f5cc9f2aef9a
Proxy/memcached/fastcgi/scgi/uwsgi: _next_upstream_timeout,_next_upstream_tries.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1289
diff
changeset
|
924 |
f5cc9f2aef9a
Proxy/memcached/fastcgi/scgi/uwsgi: _next_upstream_timeout,_next_upstream_tries.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1289
diff
changeset
|
925 |
f5cc9f2aef9a
Proxy/memcached/fastcgi/scgi/uwsgi: _next_upstream_timeout,_next_upstream_tries.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1289
diff
changeset
|
926 <directive name="fastcgi_next_upstream_tries"> |
f5cc9f2aef9a
Proxy/memcached/fastcgi/scgi/uwsgi: _next_upstream_timeout,_next_upstream_tries.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1289
diff
changeset
|
927 <syntax><value>число</value></syntax> |
f5cc9f2aef9a
Proxy/memcached/fastcgi/scgi/uwsgi: _next_upstream_timeout,_next_upstream_tries.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1289
diff
changeset
|
928 <default>0</default> |
f5cc9f2aef9a
Proxy/memcached/fastcgi/scgi/uwsgi: _next_upstream_timeout,_next_upstream_tries.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1289
diff
changeset
|
929 <context>http</context> |
f5cc9f2aef9a
Proxy/memcached/fastcgi/scgi/uwsgi: _next_upstream_timeout,_next_upstream_tries.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1289
diff
changeset
|
930 <context>server</context> |
f5cc9f2aef9a
Proxy/memcached/fastcgi/scgi/uwsgi: _next_upstream_timeout,_next_upstream_tries.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1289
diff
changeset
|
931 <context>location</context> |
f5cc9f2aef9a
Proxy/memcached/fastcgi/scgi/uwsgi: _next_upstream_timeout,_next_upstream_tries.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1289
diff
changeset
|
932 <appeared-in>1.7.5</appeared-in> |
f5cc9f2aef9a
Proxy/memcached/fastcgi/scgi/uwsgi: _next_upstream_timeout,_next_upstream_tries.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1289
diff
changeset
|
933 |
f5cc9f2aef9a
Proxy/memcached/fastcgi/scgi/uwsgi: _next_upstream_timeout,_next_upstream_tries.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1289
diff
changeset
|
934 <para> |
f5cc9f2aef9a
Proxy/memcached/fastcgi/scgi/uwsgi: _next_upstream_timeout,_next_upstream_tries.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1289
diff
changeset
|
935 Ограничивает число допустимых попыток для передачи запроса |
f5cc9f2aef9a
Proxy/memcached/fastcgi/scgi/uwsgi: _next_upstream_timeout,_next_upstream_tries.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1289
diff
changeset
|
936 <link id="fastcgi_next_upstream">следующему серверу</link>. |
f5cc9f2aef9a
Proxy/memcached/fastcgi/scgi/uwsgi: _next_upstream_timeout,_next_upstream_tries.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1289
diff
changeset
|
937 Значение <literal>0</literal> отключает это ограничение. |
f5cc9f2aef9a
Proxy/memcached/fastcgi/scgi/uwsgi: _next_upstream_timeout,_next_upstream_tries.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1289
diff
changeset
|
938 </para> |
f5cc9f2aef9a
Proxy/memcached/fastcgi/scgi/uwsgi: _next_upstream_timeout,_next_upstream_tries.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1289
diff
changeset
|
939 |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
940 </directive> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
941 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
942 |
295 | 943 <directive name="fastcgi_no_cache"> |
944 <syntax><value>строка</value> ...</syntax> | |
945 <default/> | |
946 <context>http</context> | |
947 <context>server</context> | |
948 <context>location</context> | |
949 | |
950 <para> | |
951 Задаёт условия, при которых ответ не будет сохраняться в кэш. | |
952 Если значение хотя бы одного из строковых параметров непустое и не равно “0”, | |
953 то ответ не будет сохранён: | |
954 <example> | |
955 fastcgi_no_cache $cookie_nocache $arg_nocache$arg_comment; | |
956 fastcgi_no_cache $http_pragma $http_authorization; | |
957 </example> | |
958 Можно использовать совместно с директивой <link id="fastcgi_cache_bypass"/>. | |
959 </para> | |
960 | |
961 </directive> | |
962 | |
963 | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
964 <directive name="fastcgi_param"> |
239
fe72da550150
"fastcgi_param" directive has new parameter "if_not_empty".
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
965 <syntax> |
271 | 966 <value>параметр</value> <value>значение</value> |
967 [<literal>if_not_empty</literal>]</syntax> | |
99
1d315ef37215
The case <default/> is now language-agnostic.
Ruslan Ermilov <ru@nginx.com>
parents:
98
diff
changeset
|
968 <default/> |
295 | 969 <context>http</context> |
970 <context>server</context> | |
971 <context>location</context> | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
972 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
973 <para> |
295 | 974 Задаёт <value>параметр</value>, который будет передаваться FastCGI-серверу. |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
975 В качестве значения можно использовать текст, переменные и их комбинации. |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
976 Директивы наследуются с предыдущего уровня при условии, что на данном |
271 | 977 уровне не описаны свои директивы <literal>fastcgi_param</literal>. |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
978 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
979 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
980 <para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
981 Ниже приведён пример минимально необходимых параметров для PHP: |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
982 <example> |
295 | 983 fastcgi_param SCRIPT_FILENAME /home/www/scripts/php$fastcgi_script_name; |
984 fastcgi_param QUERY_STRING $query_string; | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
985 </example> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
986 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
987 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
988 <para> |
295 | 989 Параметр <literal>SCRIPT_FILENAME</literal> используется в PHP для |
990 определения имени скрипта, а в параметре <literal>QUERY_STRING</literal> | |
991 передаются параметры запроса. | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
992 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
993 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
994 <para> |
295 | 995 Если скрипты обрабатывают запросы <literal>POST</literal>, то нужны |
996 ещё три параметра: | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
997 <example> |
295 | 998 fastcgi_param REQUEST_METHOD $request_method; |
999 fastcgi_param CONTENT_TYPE $content_type; | |
1000 fastcgi_param CONTENT_LENGTH $content_length; | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1001 </example> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1002 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1003 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1004 <para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1005 Если PHP был собран с параметром конфигурации |
271 | 1006 <literal>--enable-force-cgi-redirect</literal>, то нужно передавать |
295 | 1007 параметр <literal>REDIRECT_STATUS</literal> со значением “200”: |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1008 <example> |
295 | 1009 fastcgi_param REDIRECT_STATUS 200; |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1010 </example> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1011 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1012 |
239
fe72da550150
"fastcgi_param" directive has new parameter "if_not_empty".
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
1013 <para> |
295 | 1014 Если директива указана с <literal>if_not_empty</literal> (1.1.11), |
239
fe72da550150
"fastcgi_param" directive has new parameter "if_not_empty".
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
1015 то такой параметр с пустым значением передаваться на сервер не будет: |
fe72da550150
"fastcgi_param" directive has new parameter "if_not_empty".
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
1016 <example> |
295 | 1017 fastcgi_param HTTPS $https if_not_empty; |
239
fe72da550150
"fastcgi_param" directive has new parameter "if_not_empty".
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
1018 </example> |
fe72da550150
"fastcgi_param" directive has new parameter "if_not_empty".
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
1019 </para> |
fe72da550150
"fastcgi_param" directive has new parameter "if_not_empty".
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
1020 |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1021 </directive> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1022 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1023 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1024 <directive name="fastcgi_pass"> |
295 | 1025 <syntax><value>адрес</value></syntax> |
99
1d315ef37215
The case <default/> is now language-agnostic.
Ruslan Ermilov <ru@nginx.com>
parents:
98
diff
changeset
|
1026 <default/> |
295 | 1027 <context>location</context> |
1028 <context>if в location</context> | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1029 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1030 <para> |
295 | 1031 Задаёт адрес FastCGI-сервера. |
1032 Адрес может быть указан в виде доменного имени или адреса, и порта, например, | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1033 <example> |
351
a4fa80755eab
Consistently strip initial offset in examples.
Ruslan Ermilov <ru@nginx.com>
parents:
316
diff
changeset
|
1034 fastcgi_pass localhost:9000; |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1035 </example> |
295 | 1036 или в виде пути UNIX-сокета: |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1037 <example> |
351
a4fa80755eab
Consistently strip initial offset in examples.
Ruslan Ermilov <ru@nginx.com>
parents:
316
diff
changeset
|
1038 fastcgi_pass unix:/tmp/fastcgi.socket; |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1039 </example> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1040 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1041 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1042 <para> |
295 | 1043 Если доменному имени соответствует несколько адресов, то все они будут |
1044 использоваться по очереди (round-robin). | |
1045 И, кроме того, адрес может быть | |
135
edf8c90f8085
Renamed ngx_http_upstream to ngx_http_upstream_module.
Ruslan Ermilov <ru@nginx.com>
parents:
110
diff
changeset
|
1046 <link doc="ngx_http_upstream_module.xml">группой серверов</link>. |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1047 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1048 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1049 </directive> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1050 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1051 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1052 <directive name="fastcgi_pass_header"> |
295 | 1053 <syntax><value>поле</value></syntax> |
102
c76a257f3fd4
The directive name is now automatically printed in <default> and <syntax>.
Ruslan Ermilov <ru@nginx.com>
parents:
99
diff
changeset
|
1054 <default/> |
295 | 1055 <context>http</context> |
1056 <context>server</context> | |
1057 <context>location</context> | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1058 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1059 <para> |
295 | 1060 Разрешает передавать от FastCGI-сервера клиенту |
1061 <link id="fastcgi_hide_header">запрещённые для передачи</link> поля заголовка. | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1062 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1063 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1064 </directive> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1065 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1066 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1067 <directive name="fastcgi_read_timeout"> |
102
c76a257f3fd4
The directive name is now automatically printed in <default> and <syntax>.
Ruslan Ermilov <ru@nginx.com>
parents:
99
diff
changeset
|
1068 <syntax><value>время</value></syntax> |
295 | 1069 <default>60s</default> |
1070 <context>http</context> | |
1071 <context>server</context> | |
1072 <context>location</context> | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1073 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1074 <para> |
295 | 1075 Задаёт таймаут при чтении ответа FastCGI-сервера. |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1076 Таймаут устанавливается не на всю передачу ответа, |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1077 а только между двумя операциями чтения. |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1078 Если по истечении этого времени FastCGI-сервер ничего не передаст, |
295 | 1079 соединение закрывается. |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1080 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1081 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1082 </directive> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1083 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1084 |
793
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
1085 <directive name="fastcgi_pass_request_body"> |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
1086 <syntax><literal>on</literal> | <literal>off</literal></syntax> |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
1087 <default>on</default> |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
1088 <context>http</context> |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
1089 <context>server</context> |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
1090 <context>location</context> |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
1091 |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
1092 <para> |
966 | 1093 Позволяет запретить передачу исходного тела запроса |
793
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
1094 на FastCGI-сервер. |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
1095 См. также директиву <link id="fastcgi_pass_request_headers"/>. |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
1096 </para> |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
1097 |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
1098 </directive> |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
1099 |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
1100 |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
1101 <directive name="fastcgi_pass_request_headers"> |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
1102 <syntax><literal>on</literal> | <literal>off</literal></syntax> |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
1103 <default>on</default> |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
1104 <context>http</context> |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
1105 <context>server</context> |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
1106 <context>location</context> |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
1107 |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
1108 <para> |
966 | 1109 Позволяет запретить передачу полей заголовка исходного запроса на |
793
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
1110 FastCGI-сервер. |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
1111 См. также директивы <link id="fastcgi_pass_request_body"/>. |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
1112 </para> |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
1113 |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
1114 </directive> |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
1115 |
9104a921d940
Documented "fastcgi_pass_request_body/headers" directives.
Vladimir Homutov <vl@nginx.com>
parents:
773
diff
changeset
|
1116 |
773
24b1b0101250
Documented "send_lowat" directive in fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
772
diff
changeset
|
1117 <directive name="fastcgi_send_lowat"> |
24b1b0101250
Documented "send_lowat" directive in fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
772
diff
changeset
|
1118 <syntax><value>размер</value></syntax> |
24b1b0101250
Documented "send_lowat" directive in fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
772
diff
changeset
|
1119 <default>0</default> |
24b1b0101250
Documented "send_lowat" directive in fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
772
diff
changeset
|
1120 <context>http</context> |
24b1b0101250
Documented "send_lowat" directive in fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
772
diff
changeset
|
1121 <context>server</context> |
24b1b0101250
Documented "send_lowat" directive in fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
772
diff
changeset
|
1122 <context>location</context> |
24b1b0101250
Documented "send_lowat" directive in fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
772
diff
changeset
|
1123 |
24b1b0101250
Documented "send_lowat" directive in fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
772
diff
changeset
|
1124 <para> |
966 | 1125 При установке директивы в ненулевое значение nginx будет пытаться минимизировать |
773
24b1b0101250
Documented "send_lowat" directive in fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
772
diff
changeset
|
1126 число операций отправки на исходящих соединениях с FastCGI-сервером |
24b1b0101250
Documented "send_lowat" directive in fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
772
diff
changeset
|
1127 либо при помощи флага <c-def>NOTE_LOWAT</c-def> метода |
24b1b0101250
Documented "send_lowat" directive in fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
772
diff
changeset
|
1128 <link doc="../events.xml" id="kqueue"/>, |
24b1b0101250
Documented "send_lowat" directive in fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
772
diff
changeset
|
1129 либо при помощи параметра сокета <c-def>SO_SNDLOWAT</c-def>, |
24b1b0101250
Documented "send_lowat" directive in fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
772
diff
changeset
|
1130 с указанным <value>размером</value>. |
24b1b0101250
Documented "send_lowat" directive in fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
772
diff
changeset
|
1131 </para> |
24b1b0101250
Documented "send_lowat" directive in fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
772
diff
changeset
|
1132 |
24b1b0101250
Documented "send_lowat" directive in fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
772
diff
changeset
|
1133 <para> |
24b1b0101250
Documented "send_lowat" directive in fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
772
diff
changeset
|
1134 Эта директива игнорируется на Linux, Solaris и Windows. |
24b1b0101250
Documented "send_lowat" directive in fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
772
diff
changeset
|
1135 </para> |
24b1b0101250
Documented "send_lowat" directive in fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
772
diff
changeset
|
1136 |
24b1b0101250
Documented "send_lowat" directive in fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
772
diff
changeset
|
1137 </directive> |
24b1b0101250
Documented "send_lowat" directive in fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
772
diff
changeset
|
1138 |
24b1b0101250
Documented "send_lowat" directive in fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
772
diff
changeset
|
1139 |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1140 <directive name="fastcgi_send_timeout"> |
102
c76a257f3fd4
The directive name is now automatically printed in <default> and <syntax>.
Ruslan Ermilov <ru@nginx.com>
parents:
99
diff
changeset
|
1141 <syntax><value>время</value></syntax> |
295 | 1142 <default>60s</default> |
1143 <context>http</context> | |
1144 <context>server</context> | |
1145 <context>location</context> | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1146 |
98 | 1147 <para> |
295 | 1148 Задаёт таймаут при передаче запроса FastCGI-серверу. |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1149 Таймаут устанавливается не на всю передачу запроса, |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1150 а только между двумя операциями записи. |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1151 Если по истечении этого времени FastCGI-сервер не примет новых данных, |
295 | 1152 соединение закрывается. |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1153 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1154 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1155 </directive> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1156 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1157 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1158 <directive name="fastcgi_split_path_info"> |
102
c76a257f3fd4
The directive name is now automatically printed in <default> and <syntax>.
Ruslan Ermilov <ru@nginx.com>
parents:
99
diff
changeset
|
1159 <syntax><value>regex</value></syntax> |
99
1d315ef37215
The case <default/> is now language-agnostic.
Ruslan Ermilov <ru@nginx.com>
parents:
98
diff
changeset
|
1160 <default/> |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1161 <context>location</context> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1162 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1163 <para> |
295 | 1164 Задаёт регулярное выражение, выделяющее значение для переменной |
1165 <var>$fastcgi_path_info</var>. | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1166 Регулярное выражение должно иметь два выделения, из которых первое |
295 | 1167 становится значением переменной <var>$fastcgi_script_name</var>, |
1168 а второе—значением переменной <var>$fastcgi_path_info</var>. | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1169 Например, при таких настройках |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1170 <example> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1171 location ~ ^(.+\.php)(.*)$ { |
295 | 1172 fastcgi_split_path_info ^(.+\.php)(.*)$; |
1173 fastcgi_param SCRIPT_FILENAME /path/to/php$fastcgi_script_name; | |
1174 fastcgi_param PATH_INFO $fastcgi_path_info; | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1175 </example> |
295 | 1176 и запросе “<literal>/show.php/article/0001</literal>” |
1177 параметр <literal>SCRIPT_FILENAME</literal> будет равен | |
1178 “<literal>/path/to/php/show.php</literal>”, а параметр | |
1179 <literal>PATH_INFO</literal>—“<literal>/article/0001</literal>”. | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1180 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1181 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1182 </directive> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1183 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1184 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1185 <directive name="fastcgi_store"> |
271 | 1186 <syntax> |
295 | 1187 <literal>on</literal> | |
1188 <literal>off</literal> | | |
1189 <value>строка</value></syntax> | |
102
c76a257f3fd4
The directive name is now automatically printed in <default> and <syntax>.
Ruslan Ermilov <ru@nginx.com>
parents:
99
diff
changeset
|
1190 <default>off</default> |
295 | 1191 <context>http</context> |
1192 <context>server</context> | |
1193 <context>location</context> | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1194 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1195 <para> |
295 | 1196 Разрешает сохранение на диск файлов. |
1197 Параметр <literal>on</literal> сохраняет файлы в соответствии с путями, | |
1198 указанными в директивах | |
106
56457a474903
If text of the link is not provided, the @id is used.
Ruslan Ermilov <ru@nginx.com>
parents:
102
diff
changeset
|
1199 <link doc="ngx_http_core_module.xml" id="alias"/> или |
56457a474903
If text of the link is not provided, the @id is used.
Ruslan Ermilov <ru@nginx.com>
parents:
102
diff
changeset
|
1200 <link doc="ngx_http_core_module.xml" id="root"/>. |
295 | 1201 Параметр <literal>off</literal> запрещает сохранение файлов. |
1202 Кроме того, имя файла можно задать явно с помощью строки с переменными: | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1203 <example> |
295 | 1204 fastcgi_store /data/www$original_uri; |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1205 </example> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1206 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1207 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1208 <para> |
295 | 1209 Время изменения файлов выставляется согласно полученному полю |
1210 <header>Last-Modified</header> в заголовке ответа. | |
1211 Ответ сначала записывается во временный файл, а потом этот файл | |
1212 переименовывается. | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1213 Начиная с версии 0.8.9, временный файл и постоянное место хранения ответа |
966 | 1214 могут располагаться на разных файловых системах. |
1215 Однако нужно учитывать, | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1216 что в этом случае вместо дешёвой операции переименовывания в пределах |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1217 одной файловой системы файл копируется с одной файловой системы на другую. |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1218 Поэтому лучше, если сохраняемые файлы будут находиться на той же файловой |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1219 системе, что и каталог с временными файлами, задаваемый директивой |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1220 <link id="fastcgi_temp_path"/> для данного location. |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1221 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1222 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1223 <para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1224 Директиву можно использовать для создания локальных копий статических |
295 | 1225 неизменяемых файлов, например, так: |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1226 <example> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1227 location /images/ { |
1005
2275611970dd
Removed open_file_cache_errors from proxy_store examples.
Maxim Dounin <mdounin@mdounin.ru>
parents:
995
diff
changeset
|
1228 root /data/www; |
2275611970dd
Removed open_file_cache_errors from proxy_store examples.
Maxim Dounin <mdounin@mdounin.ru>
parents:
995
diff
changeset
|
1229 error_page 404 = /fetch$uri; |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1230 } |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1231 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1232 location /fetch/ { |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1233 internal; |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1234 |
295 | 1235 fastcgi_pass backend:9000; |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1236 ... |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1237 |
295 | 1238 fastcgi_store on; |
1239 fastcgi_store_access user:rw group:rw all:r; | |
1240 fastcgi_temp_path /data/temp; | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1241 |
295 | 1242 alias /data/www/; |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1243 } |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1244 </example> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1245 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1246 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1247 </directive> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1248 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1249 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1250 <directive name="fastcgi_store_access"> |
271 | 1251 <syntax><value>пользователи</value>:<value>права</value> ...</syntax> |
102
c76a257f3fd4
The directive name is now automatically printed in <default> and <syntax>.
Ruslan Ermilov <ru@nginx.com>
parents:
99
diff
changeset
|
1252 <default>user:rw</default> |
295 | 1253 <context>http</context> |
1254 <context>server</context> | |
1255 <context>location</context> | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1256 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1257 <para> |
295 | 1258 Задаёт права доступа для создаваемых файлов и каталогов, например, |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1259 <example> |
295 | 1260 fastcgi_store_access user:rw group:rw all:r; |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1261 </example> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1262 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1263 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1264 <para> |
295 | 1265 Если заданы какие-либо права для <literal>group</literal> или |
1266 <literal>all</literal>, то права для <literal>user</literal> | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1267 указывать необязательно: |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1268 <example> |
295 | 1269 fastcgi_store_access group:rw all:r; |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1270 </example> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1271 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1272 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1273 </directive> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1274 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1275 |
411
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
1276 <directive name="fastcgi_temp_file_write_size"> |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
1277 <syntax><value>размер</value></syntax> |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
1278 <default>8k|16k</default> |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
1279 <context>http</context> |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
1280 <context>server</context> |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
1281 <context>location</context> |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
1282 |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
1283 <para> |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
1284 Ограничивает <value>размер</value> данных, сбрасываемых во временный файл |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
1285 за один раз, при включённой буферизации ответов FastCGI-сервера |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
1286 во временные файлы. |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
1287 По умолчанию <value>размер</value> ограничен двумя буферами, заданными |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
1288 директивами <link id="fastcgi_buffer_size"/> и <link id="fastcgi_buffers"/>. |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
1289 Максимальный размер временного файла задаётся директивой |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
1290 <link id="fastcgi_max_temp_file_size"/>. |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
1291 </para> |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
1292 |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
1293 </directive> |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
1294 |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
1295 |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1296 <directive name="fastcgi_temp_path"> |
295 | 1297 <syntax> |
1298 <value>путь</value> | |
1299 [<value>уровень1</value> | |
1300 [<value>уровень2</value> | |
1301 [<value>уровень3</value>]]]</syntax> | |
102
c76a257f3fd4
The directive name is now automatically printed in <default> and <syntax>.
Ruslan Ermilov <ru@nginx.com>
parents:
99
diff
changeset
|
1302 <default>fastcgi_temp</default> |
295 | 1303 <context>http</context> |
1304 <context>server</context> | |
1305 <context>location</context> | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1306 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1307 <para> |
411
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
1308 Задаёт имя каталога для хранения временных файлов с данными, |
f8248d0e3c8f
Documented the following directives: fastcgi_busy_buffers_size,
Ruslan Ermilov <ru@nginx.com>
parents:
367
diff
changeset
|
1309 полученными от FastCGI-серверов. |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1310 В каталоге может использоваться иерархия подкаталогов до трёх уровней. |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1311 Например, при такой конфигурации |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1312 <example> |
295 | 1313 fastcgi_temp_path /spool/nginx/fastcgi_temp 1 2; |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1314 </example> |
295 | 1315 временный файл будет следующего вида: |
98 | 1316 <example> |
295 | 1317 /spool/nginx/fastcgi_temp/<emphasis>7</emphasis>/<emphasis>45</emphasis>/00000123<emphasis>457</emphasis> |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1318 </example> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1319 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1320 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1321 </directive> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1322 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1323 </section> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1324 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1325 |
295 | 1326 <section id="parameters" name="Параметры, передаваемые FastCGI-серверу"> |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1327 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1328 <para> |
295 | 1329 Поля заголовка HTTP-запроса передаются FastCGI-серверу в виде параметров. |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1330 В приложениях и скриптах, запущенных в виде FastCGI-сервера, |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1331 эти параметры обычно доступны в виде переменных среды. |
295 | 1332 Например, поле заголовка <header>User-Agent</header> передаётся как параметр |
1333 <literal>HTTP_USER_AGENT</literal>. | |
1334 Кроме полей заголовка HTTP-запроса можно передавать произвольные параметры | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1335 с помощью директивы <link id="fastcgi_param"/>. |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1336 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1337 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1338 </section> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1339 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1340 |
295 | 1341 <section id="variables" name="Встроенные переменные"> |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1342 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1343 <para> |
295 | 1344 В модуле <literal>ngx_http_fastcgi_module</literal> есть встроенные переменные, |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1345 которые можно использовать для формирования параметров с помощью директивы |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1346 <link id="fastcgi_param"/>: |
295 | 1347 <list type="tag"> |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1348 |
1155
07402a11fd8d
Assigned IDs to tags describing variables.
Vladimir Homutov <vl@nginx.com>
parents:
1153
diff
changeset
|
1349 <tag-name id="var_fastcgi_script_name"><var>$fastcgi_script_name</var> |
07402a11fd8d
Assigned IDs to tags describing variables.
Vladimir Homutov <vl@nginx.com>
parents:
1153
diff
changeset
|
1350 </tag-name> |
295 | 1351 <tag-desc> |
1352 URI запроса или же, если URI заканчивается слэшом, | |
367
f4033b9bc4ec
- Removed unnecessary instances of unbreakable space.
Ruslan Ermilov <ru@nginx.com>
parents:
364
diff
changeset
|
1353 то URI запроса, дополненное именем индексного файла, задаваемого директивой |
295 | 1354 <link id="fastcgi_index"/>. |
1355 Эту переменную можно использовать для задания параметров | |
1356 <literal>SCRIPT_FILENAME</literal> и <literal>PATH_TRANSLATED</literal>, | |
1357 используемых, в частности, для определения имени скрипта в PHP. | |
1358 Например, для запроса “<literal>/info/</literal>” и при использовании | |
1359 директив | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1360 <example> |
295 | 1361 fastcgi_index index.php; |
1362 fastcgi_param SCRIPT_FILENAME /home/www/scripts/php$fastcgi_script_name; | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1363 </example> |
295 | 1364 параметр <literal>SCRIPT_FILENAME</literal> будет равен |
1365 “<literal>/home/www/scripts/php/info/index.php</literal>”. | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1366 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1367 <para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1368 При использовании директивы <link id="fastcgi_split_path_info"/> |
295 | 1369 переменная <var>$fastcgi_script_name</var> равна значению первого выделения, |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1370 задаваемого этой директивой. |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1371 </para> |
295 | 1372 </tag-desc> |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1373 |
1155
07402a11fd8d
Assigned IDs to tags describing variables.
Vladimir Homutov <vl@nginx.com>
parents:
1153
diff
changeset
|
1374 <tag-name id="var_fastcgi_path_info"><var>$fastcgi_path_info</var></tag-name> |
295 | 1375 <tag-desc>значение второго выделения, задаваемого директивой |
1376 <link id="fastcgi_split_path_info"/>. | |
1377 Эту переменную можно использовать для задания параметра | |
1378 <literal>PATH_INFO</literal>. | |
1379 </tag-desc> | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1380 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1381 </list> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1382 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1383 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1384 </section> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1385 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1386 </module> |