changeset 1529:bcffd2161de7

Translated the stream core module into Russian.
author Yaroslav Zhuravlev <yar@nginx.com>
date Thu, 02 Jul 2015 14:23:39 +0300
parents 3ae5301ea37a
children 2db1dc7cc1a3
files xml/ru/GNUmakefile xml/ru/docs/index.xml xml/ru/docs/stream/ngx_stream_core_module.xml
diffstat 3 files changed, 113 insertions(+), 105 deletions(-) [+]
line wrap: on
line diff
--- a/xml/ru/GNUmakefile
+++ b/xml/ru/GNUmakefile
@@ -82,6 +82,7 @@ REFS =									\
 		mail/ngx_mail_smtp_module				\
 		mail/ngx_mail_ssl_module				\
 		stream/ngx_stream_access_module				\
+		stream/ngx_stream_core_module				\
 		stream/ngx_stream_limit_conn_module				\
 		stream/ngx_stream_proxy_module				\
 		stream/ngx_stream_ssl_module				\
--- a/xml/ru/docs/index.xml
+++ b/xml/ru/docs/index.xml
@@ -476,8 +476,8 @@ ngx_mail_smtp_module</link>
 <list type="bullet">
 
 <listitem>
-<link doc="../../en/docs/stream/ngx_stream_core_module.xml">
-ngx_stream_core_module</link> [en]
+<link doc="stream/ngx_stream_core_module.xml">
+ngx_stream_core_module</link>
 </listitem>
 
 <listitem>
copy from xml/en/docs/stream/ngx_stream_core_module.xml
copy to xml/ru/docs/stream/ngx_stream_core_module.xml
--- a/xml/en/docs/stream/ngx_stream_core_module.xml
+++ b/xml/ru/docs/stream/ngx_stream_core_module.xml
@@ -6,25 +6,25 @@
 
 <!DOCTYPE module SYSTEM "../../../../dtd/module.dtd">
 
-<module name="Module ngx_stream_core_module"
-        link="/en/docs/stream/ngx_stream_core_module.html"
-        lang="en"
+<module name="Модуль ngx_stream_core_module"
+        link="/ru/docs/stream/ngx_stream_core_module.html"
+        lang="ru"
         rev="9">
 
 <section id="summary">
 
 <para>
-The <literal>ngx_stream_core_module</literal> module
-is available since version 1.9.0.
-This module is not built by default, it should be enabled with the
-<literal>--with-stream</literal>
-configuration parameter.
+Модуль <literal>ngx_stream_core_module</literal>
+доступен начиная с версии 1.9.0.
+По умолчанию этот модуль не собирается, его сборку необходимо
+разрешить с помощью конфигурационного параметра
+<literal>--with-stream</literal>.
 </para>
 
 </section>
 
 
-<section id="example" name="Example Configuration">
+<section id="example" name="Пример конфигурации">
 
 <para>
 <example>
@@ -63,13 +63,13 @@ stream {
 </section>
 
 
-<section id="directives" name="Directives">
+<section id="directives" name="Директивы">
 
 <directive name="listen">
 <syntax>
-    <value>address</value>:<value>port</value>
+    <value>адрес</value>:<value>порт</value>
     [<literal>ssl</literal>]
-    [<literal>backlog</literal>=<value>number</value>]
+    [<literal>backlog</literal>=<value>число</value>]
     [<literal>bind</literal>]
     [<literal>ipv6only</literal>=<literal>on</literal>|<literal>off</literal>]
     [<literal>reuseport</literal>]
@@ -78,23 +78,22 @@ stream {
 <context>server</context>
 
 <para>
-Sets the <value>address</value> and <value>port</value> for the socket
-on which the server will accept connections.
-It is possible to specify just the port.
-The address can also be a hostname, for example:
+Задаёт <value>адрес</value> и <value>порт</value> для сокета,
+на котором сервер будет принимать соединения.
+Можно указать только порт.
+Кроме того, адрес может быть именем хоста, например:
 <example>
 listen 127.0.0.1:12345;
 listen *:12345;
-listen 12345;     # same as *:12345
+listen 12345;     # то же, что и *:12345
 listen localhost:12345;
 </example>
-IPv6 addresses are specified in square brackets:
+IPv6-адреса задаются в квадратных скобках:
 <example>
 listen [::1]:12345;
 listen [::]:12345;
 </example>
-UNIX-domain sockets are specified with the “<literal>unix:</literal>”
-prefix:
+UNIX-сокеты задаются префиксом “<literal>unix:</literal>”
 <example>
 listen unix:/var/run/nginx.sock;
 </example>
@@ -102,71 +101,74 @@ listen unix:/var/run/nginx.sock;
 </para>
 
 <para>
-The <literal>ssl</literal> parameter allows specifying that all
-connections accepted on this port should work in SSL mode.
+Параметр <literal>ssl</literal> указывает на то, что все соединения,
+принимаемые на данном порту, должны работать в режиме SSL.
 </para>
 
 <para>
-The <literal>listen</literal> directive
-can have several additional parameters specific to socket-related system calls.
+В директиве <literal>listen</literal> можно также указать несколько
+дополнительных параметров, специфичных для связанных с сокетами
+системных вызовов.
 <list type="tag">
 
 <tag-name>
-<literal>backlog</literal>=<value>number</value>
+<literal>backlog</literal>=<value>число</value>
 </tag-name>
 <tag-desc>
-sets the <literal>backlog</literal> parameter in the
-<c-func>listen</c-func> call that limits
-the maximum length for the queue of pending connections (1.9.2).
-By default,
-<literal>backlog</literal> is set to -1 on FreeBSD, DragonFly BSD, and Mac OS X,
-and to 511 on other platforms.
+задаёт параметр <literal>backlog</literal> в вызове
+<c-func>listen</c-func>, который ограничивает
+максимальный размер очереди ожидающих приёма соединений (1.9.2).
+По умолчанию <literal>backlog</literal> устанавливается равным -1 для
+FreeBSD, DragonFly BSD и Mac OS X,
+и 511 для других платформ.
 </tag-desc>
 
 <tag-name>
 <literal>bind</literal>
 </tag-name>
 <tag-desc>
-this parameter instructs to make a separate <c-func>bind</c-func>
-call for a given address:port pair.
-The fact is that if there are several <literal>listen</literal> directives with
-the same port but different addresses, and one of the
-<literal>listen</literal> directives listens on all addresses
-for the given port (<literal>*:</literal><value>port</value>), nginx will
-<c-func>bind</c-func> only to <literal>*:</literal><value>port</value>.
-It should be noted that the <c-func>getsockname</c-func> system call will be
-made in this case to determine the address that accepted the connection.
-If the <literal>ipv6only</literal>
-or <literal>so_keepalive</literal> parameters
-are used then for a given
-<value>address</value>:<value>port</value> pair
-a separate <c-func>bind</c-func> call will always be made.
+параметр указывает, что для данной пары
+<value>адрес</value>:<value>порт</value> нужно делать
+<c-func>bind</c-func> отдельно.
+Это нужно потому, что если описаны несколько директив <literal>listen</literal>
+с одинаковым портом, но разными адресами, и одна из директив
+<literal>listen</literal> слушает на всех адресах для данного порта
+(<literal>*:</literal><value>порт</value>), то nginx сделает
+<c-func>bind</c-func> только на <literal>*:</literal><value>порт</value>.
+Необходимо заметить, что в этом случае для определения адреса, на которой
+пришло соединение, делается системный вызов <c-func>getsockname</c-func>.
+Если же используются параметры <literal>ipv6only</literal>
+или <literal>so_keepalive</literal>,
+то для данной пары
+<value>адрес</value>:<value>порт</value> всегда делается
+отдельный вызов <c-func>bind</c-func>.
 </tag-desc>
 
 <tag-name>
 <literal>ipv6only</literal>=<literal>on</literal>|<literal>off</literal>
 </tag-name>
 <tag-desc>
-this parameter determines
-(via the <c-def>IPV6_V6ONLY</c-def> socket option)
-whether an IPv6 socket listening on a wildcard address <literal>[::]</literal>
-will accept only IPv6 connections or both IPv6 and IPv4 connections.
-This parameter is turned on by default.
-It can only be set once on start.
+этот параметр определяет
+(через параметр сокета <c-def>IPV6_V6ONLY</c-def>),
+будет ли слушающий на wildcard-адресе <literal>[::]</literal> IPv6-сокет
+принимать только IPv6-соединения, или же одновременно IPv6- и IPv4-соединения.
+По умолчанию параметр включён.
+Установить его можно только один раз на старте.
 </tag-desc>
 
 <tag-name id="reuseport">
 <literal>reuseport</literal>
 </tag-name>
 <tag-desc>
-this parameter (1.9.1) instructs to create an individual listening socket
-for each worker process
-(using the <c-def>SO_REUSEPORT</c-def> socket option), allowing a kernel
-to distribute incoming connections between worker processes.
-This currently works only on Linux 3.9+ and DragonFly BSD.
+этот параметр (1.9.1) указывает, что нужно создавать отдельный слушающий сокет
+для каждого рабочего процесса
+(через параметр сокета <c-def>SO_REUSEPORT</c-def>), позволяя ядру
+распределять входящие соединения между рабочими процессами.
+В настоящий момент это работает только на Linux 3.9+ и DragonFly BSD.
 <note>
-Inappropriate use of this option may have its security
-<link url="http://man7.org/linux/man-pages/man7/socket.7.html">implications</link>.
+Ненадлежащее использование параметра может иметь
+<link url="http://man7.org/linux/man-pages/man7/socket.7.html">последствия</link>
+в плане безопасности.
 </note>
 </tag-desc>
 
@@ -174,36 +176,39 @@ Inappropriate use of this option may hav
 <literal>so_keepalive</literal>=<literal>on</literal>|<literal>off</literal>|[<value>keepidle</value>]:[<value>keepintvl</value>]:[<value>keepcnt</value>]
 </tag-name>
 <tag-desc>
-this parameter configures the “TCP keepalive” behavior
-for the listening socket.
-If this parameter is omitted then the operating system’s settings will be
-in effect for the socket.
-If it is set to the value “<literal>on</literal>”, the
-<c-def>SO_KEEPALIVE</c-def> option is turned on for the socket.
-If it is set to the value “<literal>off</literal>”, the
-<c-def>SO_KEEPALIVE</c-def> option is turned off for the socket.
-Some operating systems support setting of TCP keepalive parameters on
-a per-socket basis using the <c-def>TCP_KEEPIDLE</c-def>,
-<c-def>TCP_KEEPINTVL</c-def>, and <c-def>TCP_KEEPCNT</c-def> socket options.
-On such systems (currently, Linux 2.4+, NetBSD 5+, and
-FreeBSD 9.0-STABLE), they can be configured
-using the <value>keepidle</value>, <value>keepintvl</value>, and
-<value>keepcnt</value> parameters.
-One or two parameters may be omitted, in which case the system default setting
-for the corresponding socket option will be in effect.
-For example,
+этот параметр конфигурирует для слушающего сокета
+поведение “TCP keepalive”.
+Если этот параметр опущен, то для сокета будут действовать
+настройки операционной системы.
+Если он установлен в значение “<literal>on</literal>”, то для сокета
+включается параметр <c-def>SO_KEEPALIVE</c-def>.
+Если он установлен в значение “<literal>off</literal>”, то для сокета
+параметр <c-def>SO_KEEPALIVE</c-def> выключается.
+Некоторые операционные системы поддерживают настройку параметров
+“TCP keepalive” на уровне сокета посредством параметров
+<c-def>TCP_KEEPIDLE</c-def>, <c-def>TCP_KEEPINTVL</c-def> и
+<c-def>TCP_KEEPCNT</c-def>.
+На таких системах (в настоящий момент это Linux 2.4+, NetBSD 5+ и
+FreeBSD 9.0-STABLE)
+их можно сконфигурировать с помощью параметров <value>keepidle</value>,
+<value>keepintvl</value> и <value>keepcnt</value>.
+Один или два параметра могут быть опущены, в таком случае для
+соответствующего параметра сокета будут действовать стандартные
+системные настройки.
+Например,
 <example>so_keepalive=30m::10</example>
-will set the idle timeout (<c-def>TCP_KEEPIDLE</c-def>) to 30 minutes,
-leave the probe interval (<c-def>TCP_KEEPINTVL</c-def>) at its system default,
-and set the probes count (<c-def>TCP_KEEPCNT</c-def>) to 10 probes.
+установит таймаут бездействия (<c-def>TCP_KEEPIDLE</c-def>) в 30 минут,
+для интервала проб (<c-def>TCP_KEEPINTVL</c-def>) будет действовать
+стандартная системная настройка, а счётчик проб (<c-def>TCP_KEEPCNT</c-def>)
+будет равен 10.
 </tag-desc>
 
 </list>
 </para>
 
 <para>
-Different servers must listen on different
-<value>address</value>:<value>port</value> pairs.
+Разные серверы должны слушать на разных парах
+<value>адрес</value>:<value>порт</value>.
 </para>
 
 </directive>
@@ -211,40 +216,42 @@ Different servers must listen on differe
 
 <directive name="resolver">
 <syntax>
-    <value>address</value> ...
-    [<literal>valid</literal>=<value>time</value>]
+    <value>адрес</value> ...
+    [<literal>valid</literal>=<value>время</value>]
     [<literal>ipv6</literal>=<literal>on</literal>|<literal>off</literal>]</syntax>
 <default/>
 <context>stream</context>
 <context>server</context>
 
 <para>
-Configures name servers used to resolve names of upstream servers
-into addresses, for example:
+Задаёт серверы DNS, используемые для преобразования имён вышестоящих серверов
+в адреса, например:
 <example>
 resolver 127.0.0.1 [::1]:5353;
 </example>
-An address can be specified as a domain name or IP address,
-and an optional port.
-If port is not specified, the port 53 is used.
-Name servers are queried in a round-robin fashion.
+Адрес может быть указан в виде доменного имени или IP-адреса,
+и необязательного порта.
+Если порт не указан, используется порт 53.
+Серверы DNS опрашиваются циклически.
 </para>
 
 <para>
-By default, nginx will look up both IPv4 and IPv6 addresses while resolving.
-If looking up of IPv6 addresses is not desired,
-the <literal>ipv6=off</literal> parameter can be specified.
+По умолчанию nginx будет искать как IPv4-, так и IPv6-адреса
+при преобразовании имён в адреса.
+Если поиск IPv6-адресов нежелателен,
+можно указать параметр <literal>ipv6=off</literal>.
 </para>
 
 <para>
-By default, nginx caches answers using the TTL value of a response.
-The optional <literal>valid</literal> parameter allows overriding it:
+По умолчанию nginx кэширует ответы, используя значение TTL из ответа.
+Необязательный параметр <literal>valid</literal> позволяет это
+переопределить:
 <example>
 resolver 127.0.0.1 [::1]:5353 valid=30s;
 </example>
 <note>
-This directive is available as part of our
-<commercial_version>commercial subscription</commercial_version>.
+Эта директива доступна как часть
+<commercial_version>коммерческой подписки</commercial_version>.
 </note>
 </para>
 
@@ -252,19 +259,19 @@ This directive is available as part of o
 
 
 <directive name="resolver_timeout">
-<syntax><value>time</value></syntax>
+<syntax><value>время</value></syntax>
 <default>30s</default>
 <context>stream</context>
 <context>server</context>
 
 <para>
-Sets a timeout for name resolution, for example:
+Задаёт таймаут для преобразования имени в адрес, например:
 <example>
 resolver_timeout 5s;
 </example>
 <note>
-This directive is available as part of our
-<commercial_version>commercial subscription</commercial_version>.
+Эта директива доступна как часть
+<commercial_version>коммерческой подписки</commercial_version>.
 </note>
 </para>
 
@@ -277,7 +284,7 @@ This directive is available as part of o
 <context>stream</context>
 
 <para>
-Sets the configuration for a server.
+Задаёт конфигурацию для сервера.
 </para>
 
 </directive>
@@ -289,8 +296,8 @@ Sets the configuration for a server.
 <context>main</context>
 
 <para>
-Provides the configuration file context in which the stream server directives
-are specified.
+Предоставляет контекст конфигурационного файла, в котором указываются
+директивы stream-сервера.
 </para>
 
 </directive>