Mercurial > hg > nginx-site
annotate xml/ru/docs/ngx_core_module.xml @ 1792:7992d5f907c6
Updated with Netcraft September 2016 Web Server Survey stats.
author | Yaroslav Zhuravlev <yar@nginx.com> |
---|---|
date | Tue, 20 Sep 2016 16:21:22 +0300 |
parents | 68928f8d31d9 |
children | db848aaa123a |
rev | line source |
---|---|
222
bfe3eff81d04
Removed redundant encoding specification.
Ruslan Ermilov <ru@nginx.com>
parents:
104
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:
574
diff
changeset
|
3 <!-- |
be54c443235a
Added copyright markers to documentation sources.
Ruslan Ermilov <ru@nginx.com>
parents:
574
diff
changeset
|
4 Copyright (C) Igor Sysoev |
be54c443235a
Added copyright markers to documentation sources.
Ruslan Ermilov <ru@nginx.com>
parents:
574
diff
changeset
|
5 Copyright (C) Nginx, Inc. |
be54c443235a
Added copyright markers to documentation sources.
Ruslan Ermilov <ru@nginx.com>
parents:
574
diff
changeset
|
6 --> |
be54c443235a
Added copyright markers to documentation sources.
Ruslan Ermilov <ru@nginx.com>
parents:
574
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 |
255
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
10 <module name="Основная функциональность" |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
11 link="/ru/docs/ngx_core_module.html" |
589 | 12 lang="ru" |
1784
68928f8d31d9
Updated accept_mutex with info about reuseport and epollexclusive.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1755
diff
changeset
|
13 rev="21"> |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
14 |
255
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
15 <section id="example" name="Пример конфигурации"> |
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> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
18 <example> |
255
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
19 user www www; |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
20 worker_processes 2; |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
21 |
255
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
22 error_log /var/log/nginx-error.log info; |
76
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 events { |
255
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
25 use kqueue; |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
26 worker_connections 2048; |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
27 } |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
28 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
29 ... |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
30 </example> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
31 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
32 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
33 </section> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
34 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
35 |
255
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
36 <section id="directives" name="Директивы"> |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
37 |
571
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
38 <directive name="accept_mutex"> |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
39 <syntax><literal>on</literal> | <literal>off</literal></syntax> |
1755
bde044a0bd90
Documented that accept_mutex is off by default.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1697
diff
changeset
|
40 <default>off</default> |
571
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
41 <context>events</context> |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
42 |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
43 <para> |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
44 Если <literal>accept_mutex</literal> включён, |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
45 рабочие процессы будут принимать новые соединения по очереди. |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
46 В противном случае о новых соединениях будет сообщаться сразу всем рабочим |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
47 процессам, и при низкой интенсивности поступления новых соединений |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
48 часть рабочих процессов может работать вхолостую. |
1755
bde044a0bd90
Documented that accept_mutex is off by default.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1697
diff
changeset
|
49 <note> |
1784
68928f8d31d9
Updated accept_mutex with info about reuseport and epollexclusive.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1755
diff
changeset
|
50 Нет необходимости включать <literal>accept_mutex</literal> |
68928f8d31d9
Updated accept_mutex with info about reuseport and epollexclusive.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1755
diff
changeset
|
51 на системах, поддерживающих |
68928f8d31d9
Updated accept_mutex with info about reuseport and epollexclusive.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1755
diff
changeset
|
52 флаг <link doc="events.xml" id="epoll">EPOLLEXCLUSIVE</link> (1.11.3), или |
68928f8d31d9
Updated accept_mutex with info about reuseport and epollexclusive.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1755
diff
changeset
|
53 при использовании <link doc="http/ngx_http_core_module.xml" id="reuseport"/>. |
68928f8d31d9
Updated accept_mutex with info about reuseport and epollexclusive.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1755
diff
changeset
|
54 </note> |
68928f8d31d9
Updated accept_mutex with info about reuseport and epollexclusive.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1755
diff
changeset
|
55 <note> |
1755
bde044a0bd90
Documented that accept_mutex is off by default.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1697
diff
changeset
|
56 До версии 1.11.3 по умолчанию использовалось значение <literal>on</literal>. |
bde044a0bd90
Documented that accept_mutex is off by default.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1697
diff
changeset
|
57 </note> |
571
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
58 </para> |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
59 |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
60 </directive> |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
61 |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
62 |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
63 <directive name="accept_mutex_delay"> |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
64 <syntax><value>время</value></syntax> |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
65 <default>500ms</default> |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
66 <context>events</context> |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
67 |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
68 <para> |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
69 При включённом <link id="accept_mutex"/> задаёт максимальное время, |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
70 в течение которого рабочий процесс вновь попытается начать принимать |
957
6d9d4bb571a9
Text review of the ngx_core_module.
Egor Nikitin <yegor.nikitin@gmail.com>
parents:
935
diff
changeset
|
71 новые соединения, если в настоящий момент новые соединения принимает |
6d9d4bb571a9
Text review of the ngx_core_module.
Egor Nikitin <yegor.nikitin@gmail.com>
parents:
935
diff
changeset
|
72 другой рабочий процесс. |
571
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
73 </para> |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
74 |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
75 </directive> |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
76 |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
77 |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
78 <directive name="daemon"> |
271 | 79 <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
|
80 <default>on</default> |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
81 <context>main</context> |
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 <para> |
255
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
84 Определяет, будет ли nginx запускаться в режиме демона. |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
85 Используется в основном для разработки. |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
86 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
87 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
88 </directive> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
89 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
90 |
516
8e1356bd281a
Documented the "debug_connection" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
469
diff
changeset
|
91 <directive name="debug_connection"> |
8e1356bd281a
Documented the "debug_connection" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
469
diff
changeset
|
92 <syntax> |
8e1356bd281a
Documented the "debug_connection" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
469
diff
changeset
|
93 <value>адрес</value> | |
8e1356bd281a
Documented the "debug_connection" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
469
diff
changeset
|
94 <value>CIDR</value> | |
8e1356bd281a
Documented the "debug_connection" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
469
diff
changeset
|
95 <literal>unix:</literal></syntax> |
8e1356bd281a
Documented the "debug_connection" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
469
diff
changeset
|
96 <default/> |
8e1356bd281a
Documented the "debug_connection" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
469
diff
changeset
|
97 <context>events</context> |
8e1356bd281a
Documented the "debug_connection" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
469
diff
changeset
|
98 |
8e1356bd281a
Documented the "debug_connection" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
469
diff
changeset
|
99 <para> |
8e1356bd281a
Documented the "debug_connection" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
469
diff
changeset
|
100 Включает отладочный лог для отдельных клиентских соединений. |
8e1356bd281a
Documented the "debug_connection" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
469
diff
changeset
|
101 Для остальных соединений используется уровень лога, заданный директивой |
8e1356bd281a
Documented the "debug_connection" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
469
diff
changeset
|
102 <link id="error_log"/>. |
523 | 103 Отлаживаемые соединения задаются IPv4 или IPv6 (1.3.0, 1.2.1) |
104 адресом или сетью. | |
614
0526cac4637e
Removed intimate details of the "debug_connection" directive's
Ruslan Ermilov <ru@nginx.com>
parents:
610
diff
changeset
|
105 Соединение может быть также задано при помощи имени хоста. |
523 | 106 Отладочный лог для соединений через UNIX-сокеты (1.3.0, 1.2.1) |
107 включается параметром “<literal>unix:</literal>”. | |
516
8e1356bd281a
Documented the "debug_connection" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
469
diff
changeset
|
108 <example> |
8e1356bd281a
Documented the "debug_connection" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
469
diff
changeset
|
109 events { |
8e1356bd281a
Documented the "debug_connection" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
469
diff
changeset
|
110 debug_connection 127.0.0.1; |
8e1356bd281a
Documented the "debug_connection" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
469
diff
changeset
|
111 debug_connection localhost; |
8e1356bd281a
Documented the "debug_connection" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
469
diff
changeset
|
112 debug_connection 192.0.2.0/24; |
8e1356bd281a
Documented the "debug_connection" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
469
diff
changeset
|
113 debug_connection ::1; |
8e1356bd281a
Documented the "debug_connection" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
469
diff
changeset
|
114 debug_connection 2001:0db8::/32; |
8e1356bd281a
Documented the "debug_connection" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
469
diff
changeset
|
115 debug_connection unix:; |
8e1356bd281a
Documented the "debug_connection" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
469
diff
changeset
|
116 ... |
8e1356bd281a
Documented the "debug_connection" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
469
diff
changeset
|
117 } |
8e1356bd281a
Documented the "debug_connection" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
469
diff
changeset
|
118 </example> |
8e1356bd281a
Documented the "debug_connection" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
469
diff
changeset
|
119 <note> |
8e1356bd281a
Documented the "debug_connection" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
469
diff
changeset
|
120 Для работы директивы необходимо сконфигурировать nginx с параметром |
913
9a65d437da42
Link to "A debugging log" from "debug_connection" and "error_log".
Ruslan Ermilov <ru@nginx.com>
parents:
804
diff
changeset
|
121 <literal>--with-debug</literal>, |
9a65d437da42
Link to "A debugging log" from "debug_connection" and "error_log".
Ruslan Ermilov <ru@nginx.com>
parents:
804
diff
changeset
|
122 см. “<link doc="debugging_log.xml"/>”. |
516
8e1356bd281a
Documented the "debug_connection" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
469
diff
changeset
|
123 </note> |
8e1356bd281a
Documented the "debug_connection" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
469
diff
changeset
|
124 </para> |
8e1356bd281a
Documented the "debug_connection" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
469
diff
changeset
|
125 |
8e1356bd281a
Documented the "debug_connection" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
469
diff
changeset
|
126 </directive> |
8e1356bd281a
Documented the "debug_connection" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
469
diff
changeset
|
127 |
8e1356bd281a
Documented the "debug_connection" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
469
diff
changeset
|
128 |
574 | 129 <directive name="debug_points"> |
130 <syntax><literal>abort</literal> | <literal>stop</literal></syntax> | |
131 <default/> | |
132 <context>main</context> | |
133 | |
134 <para> | |
135 Эта директива используется для отладки. | |
136 </para> | |
137 | |
138 <para> | |
139 В случае обнаружения внутренней ошибки, например, утечки сокетов в момент | |
140 перезапуска рабочих процессов, включение <literal>debug_points</literal> | |
141 приводит к созданию core-файла (<literal>abort</literal>) | |
142 или остановке процесса (<literal>stop</literal>) с целью последующей | |
143 диагностики с помощью системного отладчика. | |
144 </para> | |
145 | |
146 </directive> | |
147 | |
148 | |
255
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
149 <directive name="error_log"> |
1697
147e3d0339e8
Reduced syntax clutter in the error_log directive.
Maxim Dounin <mdounin@mdounin.ru>
parents:
1695
diff
changeset
|
150 <syntax><value>файл</value> [<value>уровень</value>]</syntax> |
255
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
151 <default>logs/error.log error</default> |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
152 <context>main</context> |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
153 <context>http</context> |
1480
d1e1a8d34bce
Documented mail support in error_log.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1465
diff
changeset
|
154 <context>mail</context> |
1450
f5b5eefc43cb
Updated commercial docs for the upcoming release.
Ruslan Ermilov <ru@nginx.com>
parents:
1449
diff
changeset
|
155 <context>stream</context> |
255
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
156 <context>server</context> |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
157 <context>location</context> |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
158 |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
159 <para> |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
160 Конфигурирует запись в лог. |
935
3860b37d56c0
Documented support for multiple "error_log" directives.
Vladimir Homutov <vl@nginx.com>
parents:
913
diff
changeset
|
161 На одном уровне может использоваться несколько логов (1.5.2). |
255
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
162 </para> |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
163 |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
164 <para> |
1697
147e3d0339e8
Reduced syntax clutter in the error_log directive.
Maxim Dounin <mdounin@mdounin.ru>
parents:
1695
diff
changeset
|
165 Первый параметр задаёт <value>файл</value>, который будет хранить лог. |
255
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
166 <!-- |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
167 Если имя файла не абсолютное, к нему добавляется в начало путь префикса. |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
168 --> |
455
571b790ddf9e
error_log: documented the special value "stderr" and default logging level.
Ruslan Ermilov <ru@nginx.com>
parents:
444
diff
changeset
|
169 Специальное значение <literal>stderr</literal> выбирает стандартный файл ошибок. |
1285
4e89518a5999
Moved syslog configuration details into the separate documents.
Ruslan Ermilov <ru@nginx.com>
parents:
1205
diff
changeset
|
170 Запись в <link doc="syslog.xml">syslog</link> настраивается указанием префикса |
1175
a05d9fa73ce2
Documented the syslog support in "error_log" and "access_log".
Yaroslav Zhuravlev <yar@nginx.com>
parents:
957
diff
changeset
|
171 “<literal>syslog:</literal>”. |
1449
c79501e16e26
Documented cyclic memory buffer support for error_log.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1436
diff
changeset
|
172 Запись в |
c79501e16e26
Documented cyclic memory buffer support for error_log.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1436
diff
changeset
|
173 <link doc="debugging_log.xml" id="memory">кольцевой буфер в памяти</link> |
c79501e16e26
Documented cyclic memory buffer support for error_log.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1436
diff
changeset
|
174 настраивается указанием префикса “<literal>memory:</literal>” и |
c79501e16e26
Documented cyclic memory buffer support for error_log.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1436
diff
changeset
|
175 <value>размера</value> буфера и как правило используется для отладки (1.7.11). |
255
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
176 </para> |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
177 |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
178 <para> |
1695
aa95174efa80
Moved levels from error_log syntax to description.
Maxim Dounin <mdounin@mdounin.ru>
parents:
1650
diff
changeset
|
179 Второй параметр определяет <value>уровень</value> лога |
aa95174efa80
Moved levels from error_log syntax to description.
Maxim Dounin <mdounin@mdounin.ru>
parents:
1650
diff
changeset
|
180 и может принимать одно из следующих значений: |
aa95174efa80
Moved levels from error_log syntax to description.
Maxim Dounin <mdounin@mdounin.ru>
parents:
1650
diff
changeset
|
181 <literal>debug</literal>, <literal>info</literal>, <literal>notice</literal>, |
aa95174efa80
Moved levels from error_log syntax to description.
Maxim Dounin <mdounin@mdounin.ru>
parents:
1650
diff
changeset
|
182 <literal>warn</literal>, <literal>error</literal>, <literal>crit</literal>, |
aa95174efa80
Moved levels from error_log syntax to description.
Maxim Dounin <mdounin@mdounin.ru>
parents:
1650
diff
changeset
|
183 <literal>alert</literal> или <literal>emerg</literal>. |
957
6d9d4bb571a9
Text review of the ngx_core_module.
Egor Nikitin <yegor.nikitin@gmail.com>
parents:
935
diff
changeset
|
184 Уровни лога, указанные выше, перечислены в порядке возрастания важности. |
255
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
185 При установке определённого уровня в лог попадают все сообщения |
957
6d9d4bb571a9
Text review of the ngx_core_module.
Egor Nikitin <yegor.nikitin@gmail.com>
parents:
935
diff
changeset
|
186 указанного уровня и уровней большей важности. |
271 | 187 Например, при стандартном уровне <literal>error</literal> в лог попадают |
188 сообщения уровней <literal>error</literal>, <literal>crit</literal>, | |
189 <literal>alert</literal> и <literal>emerg</literal>. | |
455
571b790ddf9e
error_log: documented the special value "stderr" and default logging level.
Ruslan Ermilov <ru@nginx.com>
parents:
444
diff
changeset
|
190 Если этот параметр не задан, используется <literal>error</literal>. |
255
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
191 <note> |
271 | 192 Для работы уровня лога <literal>debug</literal> необходимо сконфигурировать |
913
9a65d437da42
Link to "A debugging log" from "debug_connection" and "error_log".
Ruslan Ermilov <ru@nginx.com>
parents:
804
diff
changeset
|
193 nginx с <literal>--with-debug</literal>, |
9a65d437da42
Link to "A debugging log" from "debug_connection" and "error_log".
Ruslan Ermilov <ru@nginx.com>
parents:
804
diff
changeset
|
194 см. “<link doc="debugging_log.xml"/>”. |
255
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
195 </note> |
1450
f5b5eefc43cb
Updated commercial docs for the upcoming release.
Ruslan Ermilov <ru@nginx.com>
parents:
1449
diff
changeset
|
196 |
f5b5eefc43cb
Updated commercial docs for the upcoming release.
Ruslan Ermilov <ru@nginx.com>
parents:
1449
diff
changeset
|
197 <note> |
f5b5eefc43cb
Updated commercial docs for the upcoming release.
Ruslan Ermilov <ru@nginx.com>
parents:
1449
diff
changeset
|
198 Директива может быть указана на |
f5b5eefc43cb
Updated commercial docs for the upcoming release.
Ruslan Ermilov <ru@nginx.com>
parents:
1449
diff
changeset
|
199 уровне <literal>stream</literal> |
f5b5eefc43cb
Updated commercial docs for the upcoming release.
Ruslan Ermilov <ru@nginx.com>
parents:
1449
diff
changeset
|
200 начиная с версии 1.7.11. |
f5b5eefc43cb
Updated commercial docs for the upcoming release.
Ruslan Ermilov <ru@nginx.com>
parents:
1449
diff
changeset
|
201 </note> |
1480
d1e1a8d34bce
Documented mail support in error_log.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1465
diff
changeset
|
202 |
d1e1a8d34bce
Documented mail support in error_log.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1465
diff
changeset
|
203 <note> |
d1e1a8d34bce
Documented mail support in error_log.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1465
diff
changeset
|
204 Директива может быть указана на |
d1e1a8d34bce
Documented mail support in error_log.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1465
diff
changeset
|
205 уровне <literal>mail</literal> |
d1e1a8d34bce
Documented mail support in error_log.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1465
diff
changeset
|
206 начиная с версии 1.9.0. |
d1e1a8d34bce
Documented mail support in error_log.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1465
diff
changeset
|
207 </note> |
255
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
208 </para> |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
209 |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
210 </directive> |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
211 |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
212 |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
213 <directive name="env"> |
271 | 214 <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
|
215 <default>TZ</default> |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
216 <context>main</context> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
217 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
218 <para> |
804
d22421dc5d00
Clarified the effects of the "env" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
764
diff
changeset
|
219 По умолчанию nginx удаляет все переменные окружения, унаследованные |
d22421dc5d00
Clarified the effects of the "env" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
764
diff
changeset
|
220 от своего родительского процесса, кроме переменной TZ. |
d22421dc5d00
Clarified the effects of the "env" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
764
diff
changeset
|
221 Эта директива позволяет сохранить часть унаследованных переменных, |
d22421dc5d00
Clarified the effects of the "env" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
764
diff
changeset
|
222 поменять им значения или же создать новые переменные окружения. |
d22421dc5d00
Clarified the effects of the "env" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
764
diff
changeset
|
223 Эти переменные затем: |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
224 <list type="bullet"> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
225 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
226 <listitem> |
804
d22421dc5d00
Clarified the effects of the "env" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
764
diff
changeset
|
227 наследуются во время |
79
0a45870d0160
Fixed cross-document links to use doc and id.
Maxim Dounin <mdounin@mdounin.ru>
parents:
76
diff
changeset
|
228 <link doc="control.xml" id="upgrade">обновления исполняемого файла на лету</link>; |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
229 </listitem> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
230 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
231 <listitem> |
804
d22421dc5d00
Clarified the effects of the "env" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
764
diff
changeset
|
232 используются модулем |
79
0a45870d0160
Fixed cross-document links to use doc and id.
Maxim Dounin <mdounin@mdounin.ru>
parents:
76
diff
changeset
|
233 <link doc="http/ngx_http_perl_module.xml">ngx_http_perl_module</link>; |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
234 </listitem> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
235 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
236 <listitem> |
804
d22421dc5d00
Clarified the effects of the "env" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
764
diff
changeset
|
237 используются рабочими процессами. |
d22421dc5d00
Clarified the effects of the "env" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
764
diff
changeset
|
238 Следует иметь в виду, что управление поведением системных библиотек |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
239 подобным образом возможно не всегда, поскольку зачастую библиотеки используют |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
240 переменные только во время инициализации, то есть ещё до того, как их |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
241 можно задать с помощью данной директивы. |
957
6d9d4bb571a9
Text review of the ngx_core_module.
Egor Nikitin <yegor.nikitin@gmail.com>
parents:
935
diff
changeset
|
242 Исключением из этого является упомянутое выше |
255
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
243 <link doc="control.xml" id="upgrade">обновление исполняемого файла на лету</link>. |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
244 </listitem> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
245 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
246 </list> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
247 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
248 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
249 <para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
250 Если переменная TZ не описана явно, то она всегда наследуется |
255
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
251 и всегда доступна модулю |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
252 <link doc="http/ngx_http_perl_module.xml">ngx_http_perl_module</link>. |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
253 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
254 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
255 <para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
256 Пример использования: |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
257 <example> |
255
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
258 env MALLOC_OPTIONS; |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
259 env PERL5LIB=/data/site/modules; |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
260 env OPENSSL_ALLOW_PROXY_CERTS=1; |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
261 </example> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
262 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
263 |
444
43c84d19bf92
Added a note about the NGINX environment variable.
Ruslan Ermilov <ru@nginx.com>
parents:
289
diff
changeset
|
264 <para> |
43c84d19bf92
Added a note about the NGINX environment variable.
Ruslan Ermilov <ru@nginx.com>
parents:
289
diff
changeset
|
265 <note> |
43c84d19bf92
Added a note about the NGINX environment variable.
Ruslan Ermilov <ru@nginx.com>
parents:
289
diff
changeset
|
266 Переменная окружения NGINX используется для внутренних целей nginx |
43c84d19bf92
Added a note about the NGINX environment variable.
Ruslan Ermilov <ru@nginx.com>
parents:
289
diff
changeset
|
267 и не должна устанавливаться непосредственно самим пользователем. |
43c84d19bf92
Added a note about the NGINX environment variable.
Ruslan Ermilov <ru@nginx.com>
parents:
289
diff
changeset
|
268 </note> |
43c84d19bf92
Added a note about the NGINX environment variable.
Ruslan Ermilov <ru@nginx.com>
parents:
289
diff
changeset
|
269 </para> |
43c84d19bf92
Added a note about the NGINX environment variable.
Ruslan Ermilov <ru@nginx.com>
parents:
289
diff
changeset
|
270 |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
271 </directive> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
272 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
273 |
556
345012910707
Documented the "events" and "use" directives.
Ruslan Ermilov <ru@nginx.com>
parents:
554
diff
changeset
|
274 <directive name="events"> |
345012910707
Documented the "events" and "use" directives.
Ruslan Ermilov <ru@nginx.com>
parents:
554
diff
changeset
|
275 <syntax block="yes"/> |
345012910707
Documented the "events" and "use" directives.
Ruslan Ermilov <ru@nginx.com>
parents:
554
diff
changeset
|
276 <default/> |
345012910707
Documented the "events" and "use" directives.
Ruslan Ermilov <ru@nginx.com>
parents:
554
diff
changeset
|
277 <context>main</context> |
345012910707
Documented the "events" and "use" directives.
Ruslan Ermilov <ru@nginx.com>
parents:
554
diff
changeset
|
278 |
345012910707
Documented the "events" and "use" directives.
Ruslan Ermilov <ru@nginx.com>
parents:
554
diff
changeset
|
279 <para> |
345012910707
Documented the "events" and "use" directives.
Ruslan Ermilov <ru@nginx.com>
parents:
554
diff
changeset
|
280 Предоставляет контекст конфигурационного файла, в котором указываются |
345012910707
Documented the "events" and "use" directives.
Ruslan Ermilov <ru@nginx.com>
parents:
554
diff
changeset
|
281 директивы, влияющие на обработку соединений. |
345012910707
Documented the "events" and "use" directives.
Ruslan Ermilov <ru@nginx.com>
parents:
554
diff
changeset
|
282 </para> |
345012910707
Documented the "events" and "use" directives.
Ruslan Ermilov <ru@nginx.com>
parents:
554
diff
changeset
|
283 |
345012910707
Documented the "events" and "use" directives.
Ruslan Ermilov <ru@nginx.com>
parents:
554
diff
changeset
|
284 </directive> |
345012910707
Documented the "events" and "use" directives.
Ruslan Ermilov <ru@nginx.com>
parents:
554
diff
changeset
|
285 |
345012910707
Documented the "events" and "use" directives.
Ruslan Ermilov <ru@nginx.com>
parents:
554
diff
changeset
|
286 |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
287 <directive name="include"> |
271 | 288 <syntax><value>файл</value> | <value>маска</value></syntax> |
99
1d315ef37215
The case <default/> is now language-agnostic.
Ruslan Ermilov <ru@nginx.com>
parents:
79
diff
changeset
|
289 <default/> |
104
3ae68fe2e938
A nicer look for the directive's synopsis section, including i18n
Ruslan Ermilov <ru@nginx.com>
parents:
102
diff
changeset
|
290 <context/> |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
291 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
292 <para> |
271 | 293 Включает в конфигурацию другой <value>файл</value> или файлы, |
255
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
294 подходящие под заданную маску. |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
295 Включаемые файлы должны содержать синтаксически верные директивы и блоки. |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
296 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
297 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
298 <para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
299 Пример использования: |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
300 <example> |
255
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
301 include mime.types; |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
302 include vhosts/*.conf; |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
303 </example> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
304 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
305 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
306 </directive> |
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 |
1650
6b4cb951cf83
Documented the load_module directive.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1641
diff
changeset
|
309 <directive name="load_module"> |
6b4cb951cf83
Documented the load_module directive.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1641
diff
changeset
|
310 <syntax><value>файл</value></syntax> |
6b4cb951cf83
Documented the load_module directive.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1641
diff
changeset
|
311 <default/> |
6b4cb951cf83
Documented the load_module directive.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1641
diff
changeset
|
312 <context>main</context> |
6b4cb951cf83
Documented the load_module directive.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1641
diff
changeset
|
313 <appeared-in>1.9.11</appeared-in> |
6b4cb951cf83
Documented the load_module directive.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1641
diff
changeset
|
314 |
6b4cb951cf83
Documented the load_module directive.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1641
diff
changeset
|
315 <para> |
6b4cb951cf83
Documented the load_module directive.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1641
diff
changeset
|
316 Загружает динамический модуль. |
6b4cb951cf83
Documented the load_module directive.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1641
diff
changeset
|
317 </para> |
6b4cb951cf83
Documented the load_module directive.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1641
diff
changeset
|
318 |
6b4cb951cf83
Documented the load_module directive.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1641
diff
changeset
|
319 <para> |
6b4cb951cf83
Documented the load_module directive.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1641
diff
changeset
|
320 Пример: |
6b4cb951cf83
Documented the load_module directive.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1641
diff
changeset
|
321 <example> |
6b4cb951cf83
Documented the load_module directive.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1641
diff
changeset
|
322 load_module modules/ngx_mail_module.so; |
6b4cb951cf83
Documented the load_module directive.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1641
diff
changeset
|
323 </example> |
6b4cb951cf83
Documented the load_module directive.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1641
diff
changeset
|
324 </para> |
6b4cb951cf83
Documented the load_module directive.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1641
diff
changeset
|
325 |
6b4cb951cf83
Documented the load_module directive.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1641
diff
changeset
|
326 </directive> |
6b4cb951cf83
Documented the load_module directive.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1641
diff
changeset
|
327 |
6b4cb951cf83
Documented the load_module directive.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1641
diff
changeset
|
328 |
571
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
329 <directive name="lock_file"> |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
330 <syntax><value>файл</value></syntax> |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
331 <default>logs/nginx.lock</default> |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
332 <context>main</context> |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
333 |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
334 <para> |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
335 Для реализации <link id="accept_mutex"/> и сериализации доступа к |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
336 разделяемой памяти nginx использует механизм блокировок. |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
337 На большинстве систем блокировки реализованы с помощью атомарных |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
338 операций, и эта директива игнорируется. |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
339 Для остальных систем применяется механизм файлов блокировок. |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
340 Эта директива задаёт префикс имён файлов блокировок. |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
341 </para> |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
342 |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
343 </directive> |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
344 |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
345 |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
346 <directive name="master_process"> |
271 | 347 <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
|
348 <default>on</default> |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
349 <context>main</context> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
350 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
351 <para> |
255
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
352 Определяет, будут ли запускаться рабочие процессы. |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
353 Эта директива предназначена для разработчиков nginx. |
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 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
356 </directive> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
357 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
358 |
571
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
359 <directive name="multi_accept"> |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
360 <syntax><literal>on</literal> | <literal>off</literal></syntax> |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
361 <default>off</default> |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
362 <context>events</context> |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
363 |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
364 <para> |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
365 Если <literal>multi_accept</literal> выключен, рабочий процесс |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
366 за один раз будет принимать только одно новое соединение. |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
367 В противном случае рабочий процесс |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
368 за один раз будет принимать сразу все новые соединения. |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
369 <note> |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
370 Директива игнорируется в случае использования метода обработки соединений |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
371 <link doc="events.xml" id="kqueue"/>, т.к. данный метод сам сообщает |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
372 число новых соединений, ожидающих приёма. |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
373 </note> |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
374 </para> |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
375 |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
376 </directive> |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
377 |
71d775bef043
Documented accept_mutex, accept_mutex_delay, multi_accept, and lock_file.
Ruslan Ermilov <ru@nginx.com>
parents:
556
diff
changeset
|
378 |
289
df261b1ce71f
Documented the --with-pcre-jit configuration parameter
Ruslan Ermilov <ru@nginx.com>
parents:
271
diff
changeset
|
379 <directive name="pcre_jit"> |
df261b1ce71f
Documented the --with-pcre-jit configuration parameter
Ruslan Ermilov <ru@nginx.com>
parents:
271
diff
changeset
|
380 <syntax><literal>on</literal> | <literal>off</literal></syntax> |
df261b1ce71f
Documented the --with-pcre-jit configuration parameter
Ruslan Ermilov <ru@nginx.com>
parents:
271
diff
changeset
|
381 <default>off</default> |
df261b1ce71f
Documented the --with-pcre-jit configuration parameter
Ruslan Ermilov <ru@nginx.com>
parents:
271
diff
changeset
|
382 <context>main</context> |
df261b1ce71f
Documented the --with-pcre-jit configuration parameter
Ruslan Ermilov <ru@nginx.com>
parents:
271
diff
changeset
|
383 <appeared-in>1.1.12</appeared-in> |
df261b1ce71f
Documented the --with-pcre-jit configuration parameter
Ruslan Ermilov <ru@nginx.com>
parents:
271
diff
changeset
|
384 |
df261b1ce71f
Documented the --with-pcre-jit configuration parameter
Ruslan Ermilov <ru@nginx.com>
parents:
271
diff
changeset
|
385 <para> |
df261b1ce71f
Documented the --with-pcre-jit configuration parameter
Ruslan Ermilov <ru@nginx.com>
parents:
271
diff
changeset
|
386 Разрешает или запрещает использование JIT-компиляции (PCRE JIT) |
df261b1ce71f
Documented the --with-pcre-jit configuration parameter
Ruslan Ermilov <ru@nginx.com>
parents:
271
diff
changeset
|
387 для регулярных выражений, известных на момент парсинга конфигурации. |
df261b1ce71f
Documented the --with-pcre-jit configuration parameter
Ruslan Ermilov <ru@nginx.com>
parents:
271
diff
changeset
|
388 </para> |
df261b1ce71f
Documented the --with-pcre-jit configuration parameter
Ruslan Ermilov <ru@nginx.com>
parents:
271
diff
changeset
|
389 |
df261b1ce71f
Documented the --with-pcre-jit configuration parameter
Ruslan Ermilov <ru@nginx.com>
parents:
271
diff
changeset
|
390 <para> |
df261b1ce71f
Documented the --with-pcre-jit configuration parameter
Ruslan Ermilov <ru@nginx.com>
parents:
271
diff
changeset
|
391 Использование PCRE JIT способно существенно ускорить обработку |
df261b1ce71f
Documented the --with-pcre-jit configuration parameter
Ruslan Ermilov <ru@nginx.com>
parents:
271
diff
changeset
|
392 регулярных выражений. |
df261b1ce71f
Documented the --with-pcre-jit configuration parameter
Ruslan Ermilov <ru@nginx.com>
parents:
271
diff
changeset
|
393 <note> |
df261b1ce71f
Documented the --with-pcre-jit configuration parameter
Ruslan Ermilov <ru@nginx.com>
parents:
271
diff
changeset
|
394 Для работы JIT необходима библиотека PCRE версии 8.20 или выше, |
df261b1ce71f
Documented the --with-pcre-jit configuration parameter
Ruslan Ermilov <ru@nginx.com>
parents:
271
diff
changeset
|
395 собранная с параметром конфигурации <literal>--enable-jit</literal>. |
df261b1ce71f
Documented the --with-pcre-jit configuration parameter
Ruslan Ermilov <ru@nginx.com>
parents:
271
diff
changeset
|
396 При сборке библиотеки PCRE вместе с nginx (<literal>--with-pcre=</literal>), |
df261b1ce71f
Documented the --with-pcre-jit configuration parameter
Ruslan Ermilov <ru@nginx.com>
parents:
271
diff
changeset
|
397 для включения поддержки JIT необходимо использовать параметр |
df261b1ce71f
Documented the --with-pcre-jit configuration parameter
Ruslan Ermilov <ru@nginx.com>
parents:
271
diff
changeset
|
398 конфигурации <literal>--with-pcre-jit</literal>. |
df261b1ce71f
Documented the --with-pcre-jit configuration parameter
Ruslan Ermilov <ru@nginx.com>
parents:
271
diff
changeset
|
399 </note> |
df261b1ce71f
Documented the --with-pcre-jit configuration parameter
Ruslan Ermilov <ru@nginx.com>
parents:
271
diff
changeset
|
400 </para> |
df261b1ce71f
Documented the --with-pcre-jit configuration parameter
Ruslan Ermilov <ru@nginx.com>
parents:
271
diff
changeset
|
401 |
df261b1ce71f
Documented the --with-pcre-jit configuration parameter
Ruslan Ermilov <ru@nginx.com>
parents:
271
diff
changeset
|
402 </directive> |
df261b1ce71f
Documented the --with-pcre-jit configuration parameter
Ruslan Ermilov <ru@nginx.com>
parents:
271
diff
changeset
|
403 |
df261b1ce71f
Documented the --with-pcre-jit configuration parameter
Ruslan Ermilov <ru@nginx.com>
parents:
271
diff
changeset
|
404 |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
405 <directive name="pid"> |
271 | 406 <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
|
407 <default>nginx.pid</default> |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
408 <context>main</context> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
409 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
410 <para> |
271 | 411 Задаёт <value>файл</value>, в котором будет храниться номер (PID) основного процесса. |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
412 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
413 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
414 </directive> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
415 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
416 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
417 <directive name="ssl_engine"> |
271 | 418 <syntax><value>устройство</value></syntax> |
99
1d315ef37215
The case <default/> is now language-agnostic.
Ruslan Ermilov <ru@nginx.com>
parents:
79
diff
changeset
|
419 <default/> |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
420 <context>main</context> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
421 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
422 <para> |
255
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
423 Задаёт название аппаратного SSL-акселератора. |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
424 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
425 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
426 </directive> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
427 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
428 |
1436 | 429 <directive name="thread_pool"> |
430 <syntax> | |
431 <value>имя</value> | |
432 <literal>threads</literal>=<value>число</value> | |
433 [<literal>max_queue</literal>=<value>число</value>]</syntax> | |
434 <default>default threads=32 max_queue=65536</default> | |
435 <context>main</context> | |
436 <appeared-in>1.7.11</appeared-in> | |
437 | |
438 <para> | |
439 Задаёт именованные пулы потоков, | |
440 используемые для многопоточной обработки операций чтения и отправки файлов | |
441 <link doc="http/ngx_http_core_module.xml" id="aio">без блокирования</link> | |
442 рабочего процесса. | |
443 </para> | |
444 | |
445 <para> | |
446 Параметр <literal>threads</literal> | |
447 задаёт число потоков в пуле. | |
448 </para> | |
449 | |
450 <para> | |
451 Если все потоки из пула заняты выполнением заданий, | |
452 новое задание будет ожидать своего выполнения в очереди. | |
453 Параметр <literal>max_queue</literal> ограничивает число заданий, | |
454 ожидающих своего выполнения в очереди. | |
455 По умолчанию в очереди может находиться до 65536 заданий. | |
456 При переполнении очереди задание завершается с ошибкой. | |
457 </para> | |
458 | |
459 </directive> | |
460 | |
461 | |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
462 <directive name="timer_resolution"> |
271 | 463 <syntax><value>интервал</value></syntax> |
99
1d315ef37215
The case <default/> is now language-agnostic.
Ruslan Ermilov <ru@nginx.com>
parents:
79
diff
changeset
|
464 <default/> |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
465 <context>main</context> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
466 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
467 <para> |
255
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
468 Уменьшает разрешение таймеров времени в рабочих процессах, за счёт |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
469 чего уменьшается число системных вызовов <c-func>gettimeofday</c-func>. |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
470 По умолчанию <c-func>gettimeofday</c-func> вызывается после каждой |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
471 операции получения событий из ядра. |
957
6d9d4bb571a9
Text review of the ngx_core_module.
Egor Nikitin <yegor.nikitin@gmail.com>
parents:
935
diff
changeset
|
472 При уменьшении разрешения <c-func>gettimeofday</c-func> вызывается только |
271 | 473 один раз за указанный <value>интервал</value>. |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
474 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
475 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
476 <para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
477 Пример использования: |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
478 <example> |
255
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
479 timer_resolution 100ms; |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
480 </example> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
481 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
482 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
483 <para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
484 Внутренняя реализация интервала зависит от используемого метода: |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
485 <list type="bullet"> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
486 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
487 <listitem> |
271 | 488 фильтр <c-def>EVFILT_TIMER</c-def> при использовании <literal>kqueue</literal>; |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
489 </listitem> |
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 <listitem> |
271 | 492 <c-func>timer_create</c-func> при использовании <literal>eventport</literal>; |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
493 </listitem> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
494 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
495 <listitem> |
255
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
496 и <c-func>setitimer</c-func> во всех остальных случаях. |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
497 </listitem> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
498 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
499 </list> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
500 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
501 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
502 </directive> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
503 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
504 |
556
345012910707
Documented the "events" and "use" directives.
Ruslan Ermilov <ru@nginx.com>
parents:
554
diff
changeset
|
505 <directive name="use"> |
345012910707
Documented the "events" and "use" directives.
Ruslan Ermilov <ru@nginx.com>
parents:
554
diff
changeset
|
506 <syntax><value>метод</value></syntax> |
345012910707
Documented the "events" and "use" directives.
Ruslan Ermilov <ru@nginx.com>
parents:
554
diff
changeset
|
507 <default/> |
345012910707
Documented the "events" and "use" directives.
Ruslan Ermilov <ru@nginx.com>
parents:
554
diff
changeset
|
508 <context>events</context> |
345012910707
Documented the "events" and "use" directives.
Ruslan Ermilov <ru@nginx.com>
parents:
554
diff
changeset
|
509 |
345012910707
Documented the "events" and "use" directives.
Ruslan Ermilov <ru@nginx.com>
parents:
554
diff
changeset
|
510 <para> |
345012910707
Documented the "events" and "use" directives.
Ruslan Ermilov <ru@nginx.com>
parents:
554
diff
changeset
|
511 Задаёт <value>метод</value>, используемый для |
345012910707
Documented the "events" and "use" directives.
Ruslan Ermilov <ru@nginx.com>
parents:
554
diff
changeset
|
512 <link doc="events.xml">обработки соединений</link>. |
345012910707
Documented the "events" and "use" directives.
Ruslan Ermilov <ru@nginx.com>
parents:
554
diff
changeset
|
513 Обычно нет необходимости задавать его явно, поскольку по умолчанию |
345012910707
Documented the "events" and "use" directives.
Ruslan Ermilov <ru@nginx.com>
parents:
554
diff
changeset
|
514 nginx сам выбирает наиболее эффективный метод. |
345012910707
Documented the "events" and "use" directives.
Ruslan Ermilov <ru@nginx.com>
parents:
554
diff
changeset
|
515 </para> |
345012910707
Documented the "events" and "use" directives.
Ruslan Ermilov <ru@nginx.com>
parents:
554
diff
changeset
|
516 |
345012910707
Documented the "events" and "use" directives.
Ruslan Ermilov <ru@nginx.com>
parents:
554
diff
changeset
|
517 </directive> |
345012910707
Documented the "events" and "use" directives.
Ruslan Ermilov <ru@nginx.com>
parents:
554
diff
changeset
|
518 |
345012910707
Documented the "events" and "use" directives.
Ruslan Ermilov <ru@nginx.com>
parents:
554
diff
changeset
|
519 |
255
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
520 <directive name="user"> |
271 | 521 <syntax><value>пользователь</value> [<value>группа</value>]</syntax> |
255
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
522 <default>nobody nobody</default> |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
523 <context>main</context> |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
524 |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
525 <para> |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
526 Задаёт пользователя и группу, с правами которого будут работать |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
527 рабочие процессы. |
271 | 528 Если <value>группа</value> не задана, то используется группа, имя |
255
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
529 которой совпадает с именем пользователя. |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
530 </para> |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
531 |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
532 </directive> |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
533 |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
534 |
749
2abb92a19101
Documented 'worker_aio_requests' directive.
Vladimir Homutov <vl@nginx.com>
parents:
742
diff
changeset
|
535 <directive name="worker_aio_requests"> |
2abb92a19101
Documented 'worker_aio_requests' directive.
Vladimir Homutov <vl@nginx.com>
parents:
742
diff
changeset
|
536 <syntax><value>число</value></syntax> |
2abb92a19101
Documented 'worker_aio_requests' directive.
Vladimir Homutov <vl@nginx.com>
parents:
742
diff
changeset
|
537 <default>32</default> |
2abb92a19101
Documented 'worker_aio_requests' directive.
Vladimir Homutov <vl@nginx.com>
parents:
742
diff
changeset
|
538 <context>events</context> |
750
6a1b1ba62cab
Documented history of "worker_aio_requests" directive.
Vladimir Homutov <vl@nginx.com>
parents:
749
diff
changeset
|
539 <appeared-in>1.1.4</appeared-in> |
6a1b1ba62cab
Documented history of "worker_aio_requests" directive.
Vladimir Homutov <vl@nginx.com>
parents:
749
diff
changeset
|
540 <appeared-in>1.0.7</appeared-in> |
749
2abb92a19101
Documented 'worker_aio_requests' directive.
Vladimir Homutov <vl@nginx.com>
parents:
742
diff
changeset
|
541 |
2abb92a19101
Documented 'worker_aio_requests' directive.
Vladimir Homutov <vl@nginx.com>
parents:
742
diff
changeset
|
542 <para> |
2abb92a19101
Documented 'worker_aio_requests' directive.
Vladimir Homutov <vl@nginx.com>
parents:
742
diff
changeset
|
543 При использовании <link doc="http/ngx_http_core_module.xml" id="aio"/> |
2abb92a19101
Documented 'worker_aio_requests' directive.
Vladimir Homutov <vl@nginx.com>
parents:
742
diff
changeset
|
544 совместно с методом обработки соединений |
2abb92a19101
Documented 'worker_aio_requests' directive.
Vladimir Homutov <vl@nginx.com>
parents:
742
diff
changeset
|
545 <link doc="../docs/events.xml" id="epoll"/>, |
2abb92a19101
Documented 'worker_aio_requests' directive.
Vladimir Homutov <vl@nginx.com>
parents:
742
diff
changeset
|
546 задаёт максимальное <value>число</value> ожидающих обработки операций |
2abb92a19101
Documented 'worker_aio_requests' directive.
Vladimir Homutov <vl@nginx.com>
parents:
742
diff
changeset
|
547 асинхронного ввода-вывода для одного рабочего процесса. |
2abb92a19101
Documented 'worker_aio_requests' directive.
Vladimir Homutov <vl@nginx.com>
parents:
742
diff
changeset
|
548 </para> |
2abb92a19101
Documented 'worker_aio_requests' directive.
Vladimir Homutov <vl@nginx.com>
parents:
742
diff
changeset
|
549 |
2abb92a19101
Documented 'worker_aio_requests' directive.
Vladimir Homutov <vl@nginx.com>
parents:
742
diff
changeset
|
550 </directive> |
2abb92a19101
Documented 'worker_aio_requests' directive.
Vladimir Homutov <vl@nginx.com>
parents:
742
diff
changeset
|
551 |
2abb92a19101
Documented 'worker_aio_requests' directive.
Vladimir Homutov <vl@nginx.com>
parents:
742
diff
changeset
|
552 |
545
e97b46d1842d
Documented the "worker_connections" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
523
diff
changeset
|
553 <directive name="worker_connections"> |
e97b46d1842d
Documented the "worker_connections" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
523
diff
changeset
|
554 <syntax><value>число</value></syntax> |
e97b46d1842d
Documented the "worker_connections" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
523
diff
changeset
|
555 <default>512</default> |
e97b46d1842d
Documented the "worker_connections" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
523
diff
changeset
|
556 <context>events</context> |
e97b46d1842d
Documented the "worker_connections" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
523
diff
changeset
|
557 |
e97b46d1842d
Documented the "worker_connections" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
523
diff
changeset
|
558 <para> |
957
6d9d4bb571a9
Text review of the ngx_core_module.
Egor Nikitin <yegor.nikitin@gmail.com>
parents:
935
diff
changeset
|
559 Задаёт максимальное число соединений, которые одновременно |
545
e97b46d1842d
Documented the "worker_connections" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
523
diff
changeset
|
560 может открыть рабочий процесс. |
e97b46d1842d
Documented the "worker_connections" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
523
diff
changeset
|
561 </para> |
e97b46d1842d
Documented the "worker_connections" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
523
diff
changeset
|
562 |
e97b46d1842d
Documented the "worker_connections" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
523
diff
changeset
|
563 <para> |
e97b46d1842d
Documented the "worker_connections" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
523
diff
changeset
|
564 Следует иметь в виду, что в это число входят все соединения |
e97b46d1842d
Documented the "worker_connections" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
523
diff
changeset
|
565 (в том числе, например, соединения с проксируемыми серверами), |
e97b46d1842d
Documented the "worker_connections" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
523
diff
changeset
|
566 а не только соединения с клиентами. |
e97b46d1842d
Documented the "worker_connections" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
523
diff
changeset
|
567 Стоит также учитывать, что фактическое число одновременных |
e97b46d1842d
Documented the "worker_connections" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
523
diff
changeset
|
568 соединений не может превышать действующего ограничения на |
e97b46d1842d
Documented the "worker_connections" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
523
diff
changeset
|
569 максимальное число открытых файлов, |
659
77a3314c74a7
Avoid the uses of second person.
Ruslan Ermilov <ru@nginx.com>
parents:
614
diff
changeset
|
570 которое можно изменить с помощью <link id="worker_rlimit_nofile"/>. |
545
e97b46d1842d
Documented the "worker_connections" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
523
diff
changeset
|
571 </para> |
e97b46d1842d
Documented the "worker_connections" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
523
diff
changeset
|
572 |
e97b46d1842d
Documented the "worker_connections" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
523
diff
changeset
|
573 </directive> |
e97b46d1842d
Documented the "worker_connections" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
523
diff
changeset
|
574 |
e97b46d1842d
Documented the "worker_connections" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
523
diff
changeset
|
575 |
469
8275e169f77b
Documented the "worker_cpu_affinity" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
455
diff
changeset
|
576 <directive name="worker_cpu_affinity"> |
8275e169f77b
Documented the "worker_cpu_affinity" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
455
diff
changeset
|
577 <syntax><value>маска_CPU</value> ...</syntax> |
1641
c0d1026e7e7b
Documented the "auto" parameter in worker_cpu_affinity.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1480
diff
changeset
|
578 <syntax><literal>auto</literal> [<value>маска_CPU</value>]</syntax> |
469
8275e169f77b
Documented the "worker_cpu_affinity" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
455
diff
changeset
|
579 <default/> |
8275e169f77b
Documented the "worker_cpu_affinity" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
455
diff
changeset
|
580 <context>main</context> |
8275e169f77b
Documented the "worker_cpu_affinity" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
455
diff
changeset
|
581 |
8275e169f77b
Documented the "worker_cpu_affinity" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
455
diff
changeset
|
582 <para> |
8275e169f77b
Documented the "worker_cpu_affinity" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
455
diff
changeset
|
583 Привязывает рабочие процессы к группам процессоров. |
8275e169f77b
Documented the "worker_cpu_affinity" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
455
diff
changeset
|
584 Каждая группа процессоров задаётся битовой маской |
8275e169f77b
Documented the "worker_cpu_affinity" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
455
diff
changeset
|
585 разрешённых к использованию процессоров. |
8275e169f77b
Documented the "worker_cpu_affinity" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
455
diff
changeset
|
586 Для каждого рабочего процесса должна быть задана отдельная группа. |
8275e169f77b
Documented the "worker_cpu_affinity" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
455
diff
changeset
|
587 По умолчанию рабочие процессы не привязаны к конкретным процессорам. |
8275e169f77b
Documented the "worker_cpu_affinity" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
455
diff
changeset
|
588 </para> |
8275e169f77b
Documented the "worker_cpu_affinity" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
455
diff
changeset
|
589 |
8275e169f77b
Documented the "worker_cpu_affinity" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
455
diff
changeset
|
590 <para> |
8275e169f77b
Documented the "worker_cpu_affinity" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
455
diff
changeset
|
591 Например, |
8275e169f77b
Documented the "worker_cpu_affinity" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
455
diff
changeset
|
592 <example> |
8275e169f77b
Documented the "worker_cpu_affinity" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
455
diff
changeset
|
593 worker_processes 4; |
8275e169f77b
Documented the "worker_cpu_affinity" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
455
diff
changeset
|
594 worker_cpu_affinity 0001 0010 0100 1000; |
8275e169f77b
Documented the "worker_cpu_affinity" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
455
diff
changeset
|
595 </example> |
8275e169f77b
Documented the "worker_cpu_affinity" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
455
diff
changeset
|
596 привязывает каждый рабочий процесс к отдельному процессору, тогда как |
8275e169f77b
Documented the "worker_cpu_affinity" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
455
diff
changeset
|
597 <example> |
8275e169f77b
Documented the "worker_cpu_affinity" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
455
diff
changeset
|
598 worker_processes 2; |
8275e169f77b
Documented the "worker_cpu_affinity" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
455
diff
changeset
|
599 worker_cpu_affinity 0101 1010; |
8275e169f77b
Documented the "worker_cpu_affinity" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
455
diff
changeset
|
600 </example> |
8275e169f77b
Documented the "worker_cpu_affinity" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
455
diff
changeset
|
601 привязывает первый рабочий процесс к CPU0/CPU2, |
8275e169f77b
Documented the "worker_cpu_affinity" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
455
diff
changeset
|
602 а второй — к CPU1/CPU3. |
8275e169f77b
Documented the "worker_cpu_affinity" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
455
diff
changeset
|
603 Второй пример пригоден для hyper-threading. |
8275e169f77b
Documented the "worker_cpu_affinity" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
455
diff
changeset
|
604 </para> |
8275e169f77b
Documented the "worker_cpu_affinity" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
455
diff
changeset
|
605 |
8275e169f77b
Documented the "worker_cpu_affinity" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
455
diff
changeset
|
606 <para> |
1641
c0d1026e7e7b
Documented the "auto" parameter in worker_cpu_affinity.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1480
diff
changeset
|
607 Специальное значение <literal>auto</literal> (1.9.10) позволяет |
c0d1026e7e7b
Documented the "auto" parameter in worker_cpu_affinity.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1480
diff
changeset
|
608 автоматически привязать рабочие процессы к доступным процессорам: |
c0d1026e7e7b
Documented the "auto" parameter in worker_cpu_affinity.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1480
diff
changeset
|
609 <example> |
c0d1026e7e7b
Documented the "auto" parameter in worker_cpu_affinity.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1480
diff
changeset
|
610 worker_processes auto; |
c0d1026e7e7b
Documented the "auto" parameter in worker_cpu_affinity.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1480
diff
changeset
|
611 worker_cpu_affinity auto; |
c0d1026e7e7b
Documented the "auto" parameter in worker_cpu_affinity.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1480
diff
changeset
|
612 </example> |
c0d1026e7e7b
Documented the "auto" parameter in worker_cpu_affinity.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1480
diff
changeset
|
613 С помощью необязательной маски можно ограничить процессоры, |
c0d1026e7e7b
Documented the "auto" parameter in worker_cpu_affinity.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1480
diff
changeset
|
614 доступные для автоматической привязки: |
c0d1026e7e7b
Documented the "auto" parameter in worker_cpu_affinity.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1480
diff
changeset
|
615 <example> |
c0d1026e7e7b
Documented the "auto" parameter in worker_cpu_affinity.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1480
diff
changeset
|
616 worker_cpu_affinity auto 01010101; |
c0d1026e7e7b
Documented the "auto" parameter in worker_cpu_affinity.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1480
diff
changeset
|
617 </example> |
c0d1026e7e7b
Documented the "auto" parameter in worker_cpu_affinity.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1480
diff
changeset
|
618 </para> |
c0d1026e7e7b
Documented the "auto" parameter in worker_cpu_affinity.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1480
diff
changeset
|
619 |
c0d1026e7e7b
Documented the "auto" parameter in worker_cpu_affinity.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1480
diff
changeset
|
620 <para> |
469
8275e169f77b
Documented the "worker_cpu_affinity" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
455
diff
changeset
|
621 <note> |
8275e169f77b
Documented the "worker_cpu_affinity" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
455
diff
changeset
|
622 Директива доступна только на FreeBSD и Linux. |
8275e169f77b
Documented the "worker_cpu_affinity" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
455
diff
changeset
|
623 </note> |
8275e169f77b
Documented the "worker_cpu_affinity" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
455
diff
changeset
|
624 </para> |
8275e169f77b
Documented the "worker_cpu_affinity" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
455
diff
changeset
|
625 |
8275e169f77b
Documented the "worker_cpu_affinity" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
455
diff
changeset
|
626 </directive> |
8275e169f77b
Documented the "worker_cpu_affinity" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
455
diff
changeset
|
627 |
8275e169f77b
Documented the "worker_cpu_affinity" directive.
Ruslan Ermilov <ru@nginx.com>
parents:
455
diff
changeset
|
628 |
255
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
629 <directive name="worker_priority"> |
271 | 630 <syntax><value>число</value></syntax> |
255
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
631 <default>0</default> |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
632 <context>main</context> |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
633 |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
634 <para> |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
635 Задаёт приоритет планирования рабочих процессов подобно тому, |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
636 как это делается командой <command>nice</command>: отрицательное |
271 | 637 <value>число</value> |
255
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
638 означает более высокий приоритет. |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
639 Диапазон возможных значений, как правило, варьируется от -20 до 20. |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
640 </para> |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
641 |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
642 <para> |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
643 Пример использования: |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
644 <example> |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
645 worker_priority -10; |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
646 </example> |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
647 </para> |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
648 |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
649 </directive> |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
650 |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
651 |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
652 <directive name="worker_processes"> |
740
46d70031bea9
Documented the recently added "auto" parameter of the
Andrey Belov <defan@nginx.com>
parents:
659
diff
changeset
|
653 <syntax><value>число</value> | <literal>auto</literal></syntax> |
255
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
654 <default>1</default> |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
655 <context>main</context> |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
656 |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
657 <para> |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
658 Задаёт число рабочих процессов. |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
659 </para> |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
660 |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
661 <para> |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
662 Оптимальное значение зависит от множества факторов, включая |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
663 (но не ограничиваясь ими) число процессорных ядер, число |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
664 жёстких дисков с данными и картину нагрузок. |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
665 Если затрудняетесь в выборе правильного значения, можно начать |
740
46d70031bea9
Documented the recently added "auto" parameter of the
Andrey Belov <defan@nginx.com>
parents:
659
diff
changeset
|
666 с установки его равным числу процессорных ядер |
46d70031bea9
Documented the recently added "auto" parameter of the
Andrey Belov <defan@nginx.com>
parents:
659
diff
changeset
|
667 (значение “<literal>auto</literal>” пытается определить его |
46d70031bea9
Documented the recently added "auto" parameter of the
Andrey Belov <defan@nginx.com>
parents:
659
diff
changeset
|
668 автоматически). |
742
3a2e35f4c279
Documented that "worker_processes auto" appeared in version 1.3.8.
Ruslan Ermilov <ru@nginx.com>
parents:
740
diff
changeset
|
669 <note> |
3a2e35f4c279
Documented that "worker_processes auto" appeared in version 1.3.8.
Ruslan Ermilov <ru@nginx.com>
parents:
740
diff
changeset
|
670 Параметр <literal>auto</literal> поддерживается только начиная |
764
f8434fdd3cd9
The "auto" parameter of the ""worker_processes" directive
Ruslan Ermilov <ru@nginx.com>
parents:
750
diff
changeset
|
671 с версий 1.3.8 и 1.2.5. |
742
3a2e35f4c279
Documented that "worker_processes auto" appeared in version 1.3.8.
Ruslan Ermilov <ru@nginx.com>
parents:
740
diff
changeset
|
672 </note> |
255
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
673 </para> |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
674 |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
675 </directive> |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
676 |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
677 |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
678 <directive name="worker_rlimit_core"> |
271 | 679 <syntax><value>размер</value></syntax> |
99
1d315ef37215
The case <default/> is now language-agnostic.
Ruslan Ermilov <ru@nginx.com>
parents:
79
diff
changeset
|
680 <default/> |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
681 <context>main</context> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
682 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
683 <para> |
255
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
684 Изменяет ограничение на наибольший размер core-файла |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
685 (<c-def>RLIMIT_CORE</c-def>) для рабочих процессов. |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
686 Используется для увеличения ограничения без перезапуска основного процесса. |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
687 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
688 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
689 </directive> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
690 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
691 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
692 <directive name="worker_rlimit_nofile"> |
271 | 693 <syntax><value>число</value></syntax> |
99
1d315ef37215
The case <default/> is now language-agnostic.
Ruslan Ermilov <ru@nginx.com>
parents:
79
diff
changeset
|
694 <default/> |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
695 <context>main</context> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
696 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
697 <para> |
255
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
698 Изменяет ограничение на максимальное число открытых файлов |
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
699 (<c-def>RLIMIT_NOFILE</c-def>) для рабочих процессов. |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
700 Используется для увеличения ограничения без перезапуска основного процесса. |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
701 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
702 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
703 </directive> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
704 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
705 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
706 <directive name="working_directory"> |
271 | 707 <syntax><value>каталог</value></syntax> |
99
1d315ef37215
The case <default/> is now language-agnostic.
Ruslan Ermilov <ru@nginx.com>
parents:
79
diff
changeset
|
708 <default/> |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
709 <context>main</context> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
710 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
711 <para> |
255
e2718c7f9040
Sync ngx_core_module documentation with English version.
Ruslan Ermilov <ru@nginx.com>
parents:
222
diff
changeset
|
712 Задаёт каталог, который будет текущим для рабочего процесса. |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
713 Основное применение — запись core-файла, в этом случае рабочий |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
714 процесс должен иметь права на запись в этот каталог. |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
715 </para> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
716 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
717 </directive> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
718 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
719 </section> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
720 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
721 </module> |