Skip to content

Commit b24ca04

Browse files
committed
UNIX ulimit Settings mongodb#146 translation
1 parent 015383f commit b24ca04

File tree

1 file changed

+111
-51
lines changed

1 file changed

+111
-51
lines changed
Lines changed: 111 additions & 51 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,22 @@
1-
#
1+
#
22
msgid ""
33
msgstr ""
44
"Project-Id-Version: mongodb-manual 2.6\n"
55
"Report-Msgid-Bugs-To: \n"
66
"POT-Creation-Date: 2014-09-03 15:39-0400\n"
7-
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
7+
"PO-Revision-Date: 2015-02-02 10:56+0800\n"
88
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
9-
"Language-Team: LANGUAGE <LL@li.org>\n"
9+
"Language-Team: CH <Li@li.org>\n"
1010
"MIME-Version: 1.0\n"
1111
"Content-Type: text/plain; charset=UTF-8\n"
1212
"Content-Transfer-Encoding: 8bit\n"
13+
"Plural-Forms: nplurals=1; plural=0;\n"
14+
"Language: zh\n"
15+
"X-Generator: Poedit 1.7.3\n"
1316

1417
#: ../source/reference/ulimit.txt:3
1518
msgid "UNIX ``ulimit`` Settings"
16-
msgstr ""
19+
msgstr "UNIX系统下 ``ulimit`` 的设置"
1720

1821
#: ../source/reference/ulimit.txt:7
1922
msgid ""
@@ -24,19 +27,27 @@ msgid ""
2427
"limits have low default values that can cause a number of issues in the "
2528
"course of normal MongoDB operation."
2629
msgstr ""
30+
"大多类似UNIX的操作系统,包括Linux和OS X,都提供了方法对每个进程和每个用户使"
31+
"用线程,文件和网络连接等系统资源进行限制。 \"ulimits\" 防止单个用户使用太多"
32+
"的系统资源。有时,这些限制值的默认值太小会导致正常的MongoDB操作过程中出现的"
33+
"一系列问题。"
2734

2835
#: ../source/reference/ulimit.txt:16
2936
msgid ""
30-
"Red Hat Enterprise Linux and CentOS 6 place a max process limitation of 1024"
31-
" which overrides ``ulimit`` settings. Create a file named "
32-
"``/etc/security/limits.d/99-mongodb-nproc.conf`` with new ``soft nproc`` and"
33-
" ``hard nproc`` values to increase the process limit. See "
34-
"``/etc/security/limits.d/90-nproc.conf`` file as an example."
37+
"Red Hat Enterprise Linux and CentOS 6 place a max process limitation of "
38+
"1024 which overrides ``ulimit`` settings. Create a file named ``/etc/"
39+
"security/limits.d/99-mongodb-nproc.conf`` with new ``soft nproc`` and "
40+
"``hard nproc`` values to increase the process limit. See ``/etc/security/"
41+
"limits.d/90-nproc.conf`` file as an example."
3542
msgstr ""
43+
"Red Hat Enterprise Linux和 CentOS 6设置最大进程数为1024,超出了 ``ulimit`` "
44+
"设置。新建一个 ``/etc/security/limits.d/99-mongodb-nproc.conf`` 文件,重新设"
45+
"置 ``soft nproc`` 和 ``hard nproc`` 的值来增加进程限制。具体例子参见 ``/etc/"
46+
"security/limits.d/90-nproc.conf`` 。"
3647

3748
#: ../source/reference/ulimit.txt:26
3849
msgid "Resource Utilization"
39-
msgstr ""
50+
msgstr "资源利用"
4051

4152
#: ../source/reference/ulimit.txt:28
4253
msgid ""
@@ -46,40 +57,47 @@ msgid ""
4657
"these figures in combination with the actual information about your "
4758
"deployment and its use to determine ideal ``ulimit`` settings."
4859
msgstr ""
60+
" :program:`mongod` 和 :program:`mongos` 每次使用线程和文件描述符来跟踪连接和"
61+
"管理内部操作。这部分概述了MongoDB中一般的资源利用方式。利用这部分内容,并结"
62+
"合实际的部署和使用来决定合适的 ``ulimit`` 。"
4963

5064
#: ../source/reference/ulimit.txt:34
5165
msgid "Generally, all :program:`mongod` and :program:`mongos` instances:"
52-
msgstr ""
66+
msgstr "通常情况下, :program:`mongod` 和 :program:`mongos` 实例:"
5367

5468
#: ../source/reference/ulimit.txt:36
5569
msgid "track each incoming connection with a file descriptor *and* a thread."
56-
msgstr ""
70+
msgstr "利用一个文件描述符 *和* 线程来跟踪每个即将到来的连接。"
5771

5872
#: ../source/reference/ulimit.txt:39
5973
msgid "track each internal thread or *pthread* as a system process."
60-
msgstr ""
74+
msgstr "将每个内部thread或 *pthread* 作为一个系统进程来跟踪。"
6175

6276
#: ../source/reference/ulimit.txt:42
6377
msgid "``mongod``"
64-
msgstr ""
78+
msgstr " ``mongod`` "
6579

6680
#: ../source/reference/ulimit.txt:44
6781
msgid ""
6882
"1 file descriptor for each data file in use by the :program:`mongod` "
6983
"instance."
70-
msgstr ""
84+
msgstr " :program:`mongod` 实例使用的每个数据文件都单独享有一个文件描述符。"
7185

7286
#: ../source/reference/ulimit.txt:47
7387
msgid ""
7488
"1 file descriptor for each journal file used by the :program:`mongod` "
7589
"instance when :setting:`storage.journal.enabled` is ``true``."
7690
msgstr ""
91+
"当 :setting:`storage.journal.enabled` 为 ``true`` 时, :program:`mongod` 进"
92+
"程实例使用的每个日志文件都有一个文件描述符。"
7793

7894
#: ../source/reference/ulimit.txt:50
7995
msgid ""
8096
"In replica sets, each :program:`mongod` maintains a connection to all other "
8197
"members of the set."
8298
msgstr ""
99+
"在复制集中,每个 :program:`mongod` 保持一个连接复制集中的所有其他集合成员的"
100+
"连接。"
83101

84102
#: ../source/reference/ulimit.txt:53
85103
msgid ""
@@ -88,55 +106,65 @@ msgid ""
88106
"and replica set health checks, which may require a small number of "
89107
"additional resources."
90108
msgstr ""
109+
" :program:`mongod` 为一些内部进程,如 :ref:`TTL collections <ttl-"
110+
"collections>` ,复制和复制集健康检查,开启了后台线程。因为这些内部进程需要一"
111+
"部分额外资源。"
91112

92113
#: ../source/reference/ulimit.txt:61
93114
msgid "``mongos``"
94-
msgstr ""
115+
msgstr " ``mongos`` "
95116

96117
#: ../source/reference/ulimit.txt:63
97118
msgid ""
98-
"In addition to the threads and file descriptors for client connections, "
99-
":program:`mongos` must maintain connects to all config servers and all "
119+
"In addition to the threads and file descriptors for client connections, :"
120+
"program:`mongos` must maintain connects to all config servers and all "
100121
"shards, which includes all members of all replica sets."
101122
msgstr ""
123+
"除了客户端连接的线程和文件描述符, :program:`mongos` 还必须与所有配置服务器"
124+
"和分片保持连接,该进程包含了所有复制集成员。"
102125

103126
#: ../source/reference/ulimit.txt:68
104127
msgid "For :program:`mongos`, consider the following behaviors:"
105-
msgstr ""
128+
msgstr "关于 :program:`mongos` 进程,考虑如下行为:"
106129

107130
#: ../source/reference/ulimit.txt:70
108131
msgid ""
109-
":program:`mongos` instances maintain a connection pool to each shard so that"
110-
" the :program:`mongos` can reuse connections and quickly fulfill requests "
111-
"without needing to create new connections."
132+
":program:`mongos` instances maintain a connection pool to each shard so "
133+
"that the :program:`mongos` can reuse connections and quickly fulfill "
134+
"requests without needing to create new connections."
112135
msgstr ""
136+
" :program:`mongos` 实例与每个分片都保持一个连接池,所以 :program:`mongos` 可"
137+
"以重用连接,这样因为不用建立新连接,从而能快速的满足请求。"
113138

114139
#: ../source/reference/ulimit.txt:74
115140
msgid ""
116-
"You can limit the number of incoming connections using the "
117-
":setting:`~net.maxIncomingConnections` run-time option."
141+
"You can limit the number of incoming connections using the :setting:`~net."
142+
"maxIncomingConnections` run-time option."
118143
msgstr ""
144+
"你可以利用启动参数 :setting:`~net.maxIncomingConnections` 限制连接数。"
119145

120146
#: ../source/reference/ulimit.txt:77
121147
msgid ""
122148
"By restricting the number of incoming connections you can prevent a cascade "
123-
"effect where the :program:`mongos` creates too many connections on the "
124-
":program:`mongod` instances."
149+
"effect where the :program:`mongos` creates too many connections on the :"
150+
"program:`mongod` instances."
125151
msgstr ""
152+
"通过限制连接数,可以防止 :program:`mongos` 因在 :program:`mongod` 实例上创建"
153+
"太多连接而产生级联效应。"
126154

127155
#: ../source/includes/note-max-conns-max.rst:3
128156
msgid ""
129-
"MongoDB removed the upward limit on the "
130-
":setting:`~net.maxIncomingConnections` setting."
131-
msgstr ""
157+
"MongoDB removed the upward limit on the :setting:`~net."
158+
"maxIncomingConnections` setting."
159+
msgstr "MongoDB移除了 :setting:`~net.maxIncomingConnections` 设置值的上限。"
132160

133161
#: ../source/reference/ulimit.txt:84
134162
msgid "Review and Set Resource Limits"
135-
msgstr ""
163+
msgstr "回顾和资源限制的设置"
136164

137165
#: ../source/reference/ulimit.txt:87
138166
msgid "``ulimit``"
139-
msgstr ""
167+
msgstr " ``ulimit`` "
140168

141169
#: ../source/reference/ulimit.txt:91
142170
msgid ""
@@ -147,6 +175,11 @@ msgid ""
147175
"is the limit that is actually enforced for a session or process, but any "
148176
"process can increase it up to \"hard\" ``ulimit`` maximum."
149177
msgstr ""
178+
" \"hard\"\"soft\" ``ulimit`` 都会影响MongoDB的性能。 \"hard\" "
179+
"``ulimit`` 是指任何时候单个用户可使用的最大进程数。这是原子性的,非超级用户"
180+
"进程是不能增加 \"hard\" ``ulimit`` 。相反, \"soft\" ``ulimit`` 实际上是驱动"
181+
"一个会话或进程的限制,任何进程都可以增加该参数值达到 \"hard\" ``ulimit`` 的"
182+
"最大值。"
150183

151184
#: ../source/reference/ulimit.txt:99
152185
msgid ""
@@ -155,12 +188,16 @@ msgid ""
155188
"reason, it is extremely important to set *both* ``ulimit`` values to the "
156189
"recommended values."
157190
msgstr ""
191+
"如果连接数太多,较低的 \"soft\" ``ulimit`` 会引起 ``can't create new "
192+
"thread, closing connection`` 错误。因此,设置合理的*这两个* ``ulimit`` 值是"
193+
"非常重要的。"
158194

159195
#: ../source/reference/ulimit.txt:104
160196
msgid ""
161197
"You can use the ``ulimit`` command at the system prompt to check system "
162198
"limits, as in the following example:"
163199
msgstr ""
200+
"你可以在系统命令行下使用 ``ulimit`` 命令查看系统的限制值,比如如下例子:"
164201

165202
#: ../source/reference/ulimit.txt:127
166203
msgid ""
@@ -171,12 +208,16 @@ msgid ""
171208
"``processes`` value (i.e. ``-u``) refers to the combined number of distinct "
172209
"processes and sub-process threads."
173210
msgstr ""
211+
" ``ulimit`` 是指每个 *user* 使用各种资源的限制值。因此,无论你的 :program:"
212+
"`mongod` 实例是以单个用户多进程执行,还是以多 :program:`mongod` 进程执行,都"
213+
"可以看到对这些资源的连接。同样,要了解到 ``processes`` 值(比如 ``-u`` )是"
214+
"指不同进程和子进程线程之和。"
174215

175216
#: ../source/reference/ulimit.txt:135
176217
msgid ""
177218
"You can change ``ulimit`` settings by issuing a command in the following "
178219
"form:"
179-
msgstr ""
220+
msgstr "你可以按下面形式的命令修改 ``ulimit`` 的设置。"
180221

181222
#: ../source/reference/ulimit.txt:142
182223
msgid ""
@@ -186,89 +227,108 @@ msgid ""
186227
"documentation for the precise procedure for changing system limits on "
187228
"running systems."
188229
msgstr ""
230+
"对许多版本的Linux来说,您可以通过 ``-n`` 选项代替 ``ulimit -a`` 输出的任何值"
231+
"来改变值。在OS X上,使用 ``launchctl limit`` 命令。参看您的操作系统文档来改"
232+
"变运行系统的系统限制值。"
189233

190234
#: ../source/reference/ulimit.txt:150
191235
msgid ""
192236
"After changing the ``ulimit`` settings, you *must* restart the process to "
193237
"take advantage of the modified settings. You can use the ``/proc`` file "
194238
"system to see the current limitations on a running process."
195239
msgstr ""
240+
"改变 ``ulimit`` 设置之后, *要* 重启进程修改值才会有效。通过 ``/proc`` 文件"
241+
"可以查看运行进程当前的限制值。"
196242

197243
#: ../source/reference/ulimit.txt:155
198244
msgid ""
199245
"Depending on your system's configuration, and default settings, any change "
200246
"to system limits made using ``ulimit`` may revert following system a system "
201-
"restart. Check your distribution and operating system documentation for more"
202-
" information."
247+
"restart. Check your distribution and operating system documentation for "
248+
"more information."
203249
msgstr ""
250+
"根据您系统配置和默认的设置值,任何使用 ``ulimit`` 对系统限制的改变在系统重启"
251+
"后都会恢复到默认值。更多相关信息请参考您的版本和操作系统文档。"
204252

205253
#: ../source/reference/ulimit.txt:163
206254
msgid "``/proc`` File System"
207-
msgstr ""
255+
msgstr " ``/proc`` 文件"
208256

209257
#: ../source/reference/ulimit.txt:167
210258
msgid "This section applies only to Linux operating systems."
211-
msgstr ""
259+
msgstr "此部分文档只适合Linux操作系统"
212260

213261
#: ../source/reference/ulimit.txt:169
214262
msgid ""
215263
"The ``/proc`` file-system stores the per-process limits in the file system "
216-
"object located at ``/proc/<pid>/limits``, where ``<pid>`` is the process's "
217-
":term:`PID` or process identifier. You can use the following ``bash`` "
264+
"object located at ``/proc/<pid>/limits``, where ``<pid>`` is the process's :"
265+
"term:`PID` or process identifier. You can use the following ``bash`` "
218266
"function to return the content of the ``limits`` object for a process or "
219267
"processes with a given name:"
220268
msgstr ""
269+
" ``/proc`` 文件存储每个进程的限制值,该文件存放在 ``/proc/<pid>/limits``形式"
270+
"的文件系统对象。其中 ``<pid>`` 是进程的 :term:`PID` 项或进程标识。您可以通过"
271+
"下列 ``bash`` 函数返回一个进程或某个进程的 ``limits`` 对象内容。"
221272

222273
#: ../source/reference/ulimit.txt:195
223274
msgid ""
224-
"You can copy and paste this function into a current shell session or load it"
225-
" as part of a script. Call the function with one the following invocations:"
275+
"You can copy and paste this function into a current shell session or load "
276+
"it as part of a script. Call the function with one the following "
277+
"invocations:"
226278
msgstr ""
279+
"您可以复制粘贴该函数到当前shell下,或者作为脚本的一部分。通过下列调用形式调"
280+
"用该函数。"
227281

228282
#: ../source/reference/ulimit.txt:206
229283
msgid "Recommended Settings"
230-
msgstr ""
284+
msgstr "ulimit值相关推荐"
231285

232286
#: ../source/reference/ulimit.txt:208
233287
msgid ""
234288
"Every deployment may have unique requirements and settings; however, the "
235-
"following thresholds and settings are particularly important for "
236-
":program:`mongod` and :program:`mongos` deployments:"
289+
"following thresholds and settings are particularly important for :program:"
290+
"`mongod` and :program:`mongos` deployments:"
237291
msgstr ""
292+
"每个部署或许都有唯一的要求和设置。然而,下面的阈值和设置对 :program:"
293+
"`mongod` 和 :program:`mongos` 部署来说是非常重要的。"
238294

239295
#: ../source/reference/ulimit.txt:212
240296
msgid "``-f`` (file size): ``unlimited``"
241-
msgstr ""
297+
msgstr " ``-f`` (文件大小): ``unlimited`` "
242298

243299
#: ../source/reference/ulimit.txt:213
244300
msgid "``-t`` (cpu time): ``unlimited``"
245-
msgstr ""
301+
msgstr " ``-t`` (cpu 时间): ``unlimited`` "
246302

247303
#: ../source/reference/ulimit.txt:214
248304
msgid "``-v`` (virtual memory): ``unlimited`` [#memory-size]_"
249-
msgstr ""
305+
msgstr " ``-v`` (虚拟内存): ``unlimited`` [#memory-size]_"
250306

251307
#: ../source/reference/ulimit.txt:215
252308
msgid "``-n`` (open files): ``64000``"
253-
msgstr ""
309+
msgstr " ``-n`` (单个进程文件打开数): ``64000`` "
254310

255311
#: ../source/reference/ulimit.txt:216
256312
msgid "``-m`` (memory size): ``unlimited`` [#memory-size]_"
257-
msgstr ""
313+
msgstr " ``-m`` (内存大小): ``unlimited`` [#memory-size]_ "
258314

259315
#: ../source/reference/ulimit.txt:217
260316
msgid "``-u`` (processes/threads): ``64000``"
261-
msgstr ""
317+
msgstr " ``-u`` (可打开的进程/线程): ``64000`` "
262318

263319
#: ../source/reference/ulimit.txt:219
264320
msgid ""
265321
"Always remember to restart your :program:`mongod` and :program:`mongos` "
266322
"instances after changing the ``ulimit`` settings to make sure that the "
267323
"settings change takes effect."
268324
msgstr ""
325+
"修改完 ``ulimit`` 值后记得重启 :program:`mongod` 和 :program:`mongos` 保证这"
326+
"些值起作用。"
269327

270328
#: ../source/reference/ulimit.txt:223
271329
msgid ""
272-
"If you limit virtual or resident memory size on a system running MongoDB the"
273-
" operating system will refuse to honor additional allocation requests."
330+
"If you limit virtual or resident memory size on a system running MongoDB "
331+
"the operating system will refuse to honor additional allocation requests."
274332
msgstr ""
333+
"如果您限制了运行MongoDB系统的虚拟或预留内存大小,那么操作系统将拒绝额外的分"
334+
"配要求。"

0 commit comments

Comments
 (0)