Skip to content

Commit dab560f

Browse files
yichao2015medcl
authored andcommitted
chapter10_part2:/070_Index_Mgmt/10_Settings.asciidoc (#297)
* chapter10_part2:/070_Index_Mgmt/10_Settings.asciidoc * 二次review后修改
1 parent 73e3f55 commit dab560f

File tree

1 file changed

+10
-17
lines changed

1 file changed

+10
-17
lines changed

070_Index_Mgmt/10_Settings.asciidoc

Lines changed: 10 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,21 @@
1-
=== Index Settings
1+
=== 索引设置
22

3-
There are many many knobs((("index settings"))) that you can twiddle to
4-
customize index behavior, which you can read about in the
5-
{ref}/index-modules.html[Index Modules reference documentation],
6-
but...
3+
你可以通过修改配置来((("index settings")))自定义索引行为,详细配置参照
4+
{ref}/index-modules.html[索引模块]
75

8-
TIP: Elasticsearch comes with good defaults. Don't twiddle these knobs until
9-
you understand what they do and why you should change them.
6+
TIP: Elasticsearch 提供了优化好的默认配置。 除非你理解这些配置的作用并且知道为什么要去修改,否则不要随意修改。
107

11-
Two of the most important((("shards", "number_of_shards index setting")))((("number_of_shards setting")))((("index settings", "number_of_shards"))) settings are as follows:
8+
下面是两个((("shards", "number_of_shards index setting")))((("number_of_shards setting")))((("index settings", "number_of_shards"))) 最重要的设置:
129

1310
`number_of_shards`::
1411

15-
The number of primary shards that an index should have,
16-
which defaults to `5`. This setting cannot be changed
17-
after index creation.
12+
每个索引的主分片数,默认值是 `5` 。这个配置在索引创建后不能修改。
1813

1914
`number_of_replicas`::
2015

21-
The number of replica shards (copies) that each primary shard
22-
should have, which defaults to `1`. This setting can be changed
23-
at any time on a live index.
16+
每个主分片的副本数,默认值是 `1` 。对于活动的索引库,这个配置可以随时修改。
2417

25-
For instance, we could create a small index--just((("index settings", "number_of_replicas")))((("replica shards", "number_of_replicas index setting"))) one primary shard--and no replica shards with the following request:
18+
例如,我们可以创建只有((("index settings", "number_of_replicas")))((("replica shards", "number_of_replicas index setting"))) 一个主分片,没有副本的小索引:
2619

2720
[source,js]
2821
--------------------------------------------------
@@ -36,8 +29,8 @@ PUT /my_temp_index
3629
--------------------------------------------------
3730
// SENSE: 070_Index_Mgmt/10_Settings.json
3831

39-
Later, we can change the number of replica shards dynamically using the
40-
`update-index-settings` API as((("update-index-settings API"))) follows:
32+
然后,我们可以用
33+
`update-index-settings` API ((("update-index-settings API"))) 动态修改副本数:
4134

4235
[source,js]
4336
--------------------------------------------------

0 commit comments

Comments
 (0)