forked from docs/doc-exports
Reviewed-by: Pruthi, Vineet <vineet.pruthi@t-systems.com> Co-authored-by: zhengxiu <zhengxiu@huawei.com> Co-committed-by: zhengxiu <zhengxiu@huawei.com>
110 lines
15 KiB
HTML
110 lines
15 KiB
HTML
<a name="EN-US_TOPIC_0000001965416825"></a><a name="EN-US_TOPIC_0000001965416825"></a>
|
|
|
|
<h1 class="topictitle1">Configuring Default Parameters in the .yml Configuration File of an Elasticsearch Cluster</h1>
|
|
<div id="body1572848909034"><p id="EN-US_TOPIC_0000001965416825__p18201144182511">You can modify an Elasticsearch cluster's configuration file for purposes like accelerating queries, modifying cross-domain access configuration, adjusting the internal cache size, and managing the task queue size. The core configuration information of an Elasticsearch cluster is stored in a file named <span class="parmvalue" id="EN-US_TOPIC_0000001965416825__parmvalue1748315012519"><b>elasticsearch.yml</b></span>. You can modify specific parameters in this file on the CSS management console.</p>
|
|
<div class="section" id="EN-US_TOPIC_0000001965416825__en-us_topic_0000001268594501_section1846352754911"><h4 class="sectiontitle">Configuring the .yml File</h4><ol id="EN-US_TOPIC_0000001965416825__en-us_topic_0000001268594501_ol8194123694919"><li id="EN-US_TOPIC_0000001965416825__en-us_topic_0000001268594501_li1142971461017"><span id="EN-US_TOPIC_0000001965416825__ph4222205142920">Log in to the CSS management console.</span></li><li id="EN-US_TOPIC_0000001965416825__li4250043448">In the navigation pane on the left, choose <span class="uicontrol" id="EN-US_TOPIC_0000001965416825__uicontrol30767863585138"><b>Clusters > Elasticsearch</b></span>.</li><li id="EN-US_TOPIC_0000001965416825__en-us_topic_0000001268154521_li6012554340">In the cluster list, click the name of the target cluster. The cluster information page is displayed.</li><li id="EN-US_TOPIC_0000001965416825__li1818362518380">Choose <strong id="EN-US_TOPIC_0000001965416825__b17425501418">Cluster Settings</strong> > <strong id="EN-US_TOPIC_0000001965416825__b127425531413">Parameter Settings</strong>.</li><li id="EN-US_TOPIC_0000001965416825__en-us_topic_0000001268594501_li1277611425215">Click <strong id="EN-US_TOPIC_0000001965416825__b94241555154">Edit</strong> to modify module parameters as required.
|
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="EN-US_TOPIC_0000001965416825__en-us_topic_0000001268594501_table53371628162416" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Module parameters</caption><thead align="left"><tr id="EN-US_TOPIC_0000001965416825__en-us_topic_0000001268594501_row103280287249"><th align="left" class="cellrowborder" valign="top" width="16.541654165416542%" id="mcps1.3.2.2.5.2.2.4.1.1"><p id="EN-US_TOPIC_0000001965416825__en-us_topic_0000001268594501_p932842832419">Module Name</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="26.15261526152615%" id="mcps1.3.2.2.5.2.2.4.1.2"><p id="EN-US_TOPIC_0000001965416825__en-us_topic_0000001268594501_p33281528192417">Parameter</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="57.3057305730573%" id="mcps1.3.2.2.5.2.2.4.1.3"><p id="EN-US_TOPIC_0000001965416825__en-us_topic_0000001268594501_p20328132810245">Description</p>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody><tr id="EN-US_TOPIC_0000001965416825__en-us_topic_0000001268594501_row19330192810243"><td class="cellrowborder" rowspan="6" valign="top" width="16.541654165416542%" headers="mcps1.3.2.2.5.2.2.4.1.1 "><p id="EN-US_TOPIC_0000001965416825__en-us_topic_0000001268594501_p183291528122417">Cross-domain Access</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="26.15261526152615%" headers="mcps1.3.2.2.5.2.2.4.1.2 "><p id="EN-US_TOPIC_0000001965416825__en-us_topic_0000001268594501_p11329162882415">http.cors.allow-credentials</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="57.3057305730573%" headers="mcps1.3.2.2.5.2.2.4.1.3 "><p id="EN-US_TOPIC_0000001965416825__en-us_topic_0000001268594501_p17329162892417">Whether to carry authentication information in cross-domain requests, that is, whether to contain the Access-Control-Allow-Credentials field in the response header.</p>
|
|
<div class="p" id="EN-US_TOPIC_0000001965416825__en-us_topic_0000001268594501_p16330628132414">The value can be:<ul id="EN-US_TOPIC_0000001965416825__ul1960516915565"><li id="EN-US_TOPIC_0000001965416825__li17606793567"><strong id="EN-US_TOPIC_0000001965416825__b16471521701">true</strong>: The response header contains the Access-Control-Allow-Credentials field.</li><li id="EN-US_TOPIC_0000001965416825__li3606109145614"><strong id="EN-US_TOPIC_0000001965416825__b13675561506">false</strong> (default value): The response header does not contain the Access-Control-Allow-Credentials field.</li></ul>
|
|
</div>
|
|
</td>
|
|
</tr>
|
|
<tr id="EN-US_TOPIC_0000001965416825__en-us_topic_0000001268594501_row1330428132419"><td class="cellrowborder" valign="top" headers="mcps1.3.2.2.5.2.2.4.1.1 "><p id="EN-US_TOPIC_0000001965416825__en-us_topic_0000001268594501_p933042832410">http.cors.allow-origin</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" headers="mcps1.3.2.2.5.2.2.4.1.2 "><p id="EN-US_TOPIC_0000001965416825__p94339325161">Source IP addresses or domain names allowed for cross-domain access. When there are multiple values, separate them with commas (,).</p>
|
|
<p id="EN-US_TOPIC_0000001965416825__p618873135816">Example: <span class="parmvalue" id="EN-US_TOPIC_0000001965416825__parmvalue11961325593"><b>192.168.122.122:9200</b></span> or <span class="parmvalue" id="EN-US_TOPIC_0000001965416825__parmvalue14219121210594"><b>192.168.1.1:9200, 192.168.1.2:9200</b></span></p>
|
|
</td>
|
|
</tr>
|
|
<tr id="EN-US_TOPIC_0000001965416825__en-us_topic_0000001268594501_row133010281246"><td class="cellrowborder" valign="top" headers="mcps1.3.2.2.5.2.2.4.1.1 "><p id="EN-US_TOPIC_0000001965416825__en-us_topic_0000001268594501_p73307287241">http.cors.allow-headers</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" headers="mcps1.3.2.2.5.2.2.4.1.2 "><p id="EN-US_TOPIC_0000001965416825__p724310368163">Request header fields for cross-domain access. When there are multiple values, separate them using a comma (,) and a space.</p>
|
|
<p id="EN-US_TOPIC_0000001965416825__p342711258814">Example: <span class="parmvalue" id="EN-US_TOPIC_0000001965416825__parmvalue76309215812"><b>X-Requested-With, Content-Type, Content-Length</b></span></p>
|
|
<p id="EN-US_TOPIC_0000001965416825__p69517219616">The value can contain a maximum of 1024 characters. It can only contain letters, digits, hyphens (-), underscores (_), colons (:), and slashes (/).</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="EN-US_TOPIC_0000001965416825__row10468131010314"><td class="cellrowborder" valign="top" headers="mcps1.3.2.2.5.2.2.4.1.1 "><p id="EN-US_TOPIC_0000001965416825__p315814152316">http.cors.max-age</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" headers="mcps1.3.2.2.5.2.2.4.1.2 "><p id="EN-US_TOPIC_0000001965416825__p1044410506018">Maximum retention duration of pre-check responses in the browser cache.</p>
|
|
<p id="EN-US_TOPIC_0000001965416825__p79145315012">Unit: s</p>
|
|
<p id="EN-US_TOPIC_0000001965416825__p10799123315915">Value range: 0 to 31,536,000 (0 to 1 year)</p>
|
|
<p id="EN-US_TOPIC_0000001965416825__p250119551603">Default value: 1,728,000 (20 days)</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="EN-US_TOPIC_0000001965416825__en-us_topic_0000001268594501_row123301728142417"><td class="cellrowborder" valign="top" headers="mcps1.3.2.2.5.2.2.4.1.1 "><p id="EN-US_TOPIC_0000001965416825__en-us_topic_0000001268594501_p833013283249">http.cors.enabled</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" headers="mcps1.3.2.2.5.2.2.4.1.2 "><p id="EN-US_TOPIC_0000001965416825__p24065911212">Whether to enable cross-domain access.</p>
|
|
<div class="p" id="EN-US_TOPIC_0000001965416825__p1238901913920">The value can be:<ul id="EN-US_TOPIC_0000001965416825__ul9735915181211"><li id="EN-US_TOPIC_0000001965416825__li4735415131213"><strong id="EN-US_TOPIC_0000001965416825__b022022215421">true</strong>: Enable cross-domain access.</li><li id="EN-US_TOPIC_0000001965416825__li14735191517121"><strong id="EN-US_TOPIC_0000001965416825__b10314629204316">false</strong> (default): Disable cross-domain access.</li></ul>
|
|
</div>
|
|
</td>
|
|
</tr>
|
|
<tr id="EN-US_TOPIC_0000001965416825__en-us_topic_0000001268594501_row833113287248"><td class="cellrowborder" valign="top" headers="mcps1.3.2.2.5.2.2.4.1.1 "><p id="EN-US_TOPIC_0000001965416825__en-us_topic_0000001268594501_p13301828172410">http.cors.allow-methods</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" headers="mcps1.3.2.2.5.2.2.4.1.2 "><p id="EN-US_TOPIC_0000001965416825__p1642515250171">HTTP methods allowed for cross-domain access. When there are multiple values, separate them using a comma (,) and a space.</p>
|
|
<p id="EN-US_TOPIC_0000001965416825__p735825781313">Example: <span class="parmvalue" id="EN-US_TOPIC_0000001965416825__parmvalue8974294142"><b>OPTIONS, GET, POST</b></span></p>
|
|
<p id="EN-US_TOPIC_0000001965416825__p14690192616135">Value range: OPTIONS, HEAD, GET, POST, PUT, and DELETE</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="EN-US_TOPIC_0000001965416825__en-us_topic_0000001268594501_row12333192812418"><td class="cellrowborder" valign="top" width="16.541654165416542%" headers="mcps1.3.2.2.5.2.2.4.1.1 "><p id="EN-US_TOPIC_0000001965416825__en-us_topic_0000001268594501_p183319285248">Reindexing</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="26.15261526152615%" headers="mcps1.3.2.2.5.2.2.4.1.2 "><p id="EN-US_TOPIC_0000001965416825__en-us_topic_0000001268594501_p33319289247">reindex.remote.whitelist</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="57.3057305730573%" headers="mcps1.3.2.2.5.2.2.4.1.3 "><p id="EN-US_TOPIC_0000001965416825__p1118665418146">Which remote hosts are allowed for remote reindexing operations. Use commas (,) to separate multiple values.</p>
|
|
<p id="EN-US_TOPIC_0000001965416825__p99661913171715">Example: <span class="parmvalue" id="EN-US_TOPIC_0000001965416825__parmvalue1237347144813"><b>192.168.122.122:9200</b></span> or <span class="parmvalue" id="EN-US_TOPIC_0000001965416825__parmvalue138847154819"><b>192.168.1.1:9200, 192.168.1.2:9200</b></span></p>
|
|
</td>
|
|
</tr>
|
|
<tr id="EN-US_TOPIC_0000001965416825__en-us_topic_0000001268594501_row12334228112416"><td class="cellrowborder" valign="top" width="16.541654165416542%" headers="mcps1.3.2.2.5.2.2.4.1.1 "><p id="EN-US_TOPIC_0000001965416825__en-us_topic_0000001268594501_p1433382862410">Custom Cache</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="26.15261526152615%" headers="mcps1.3.2.2.5.2.2.4.1.2 "><p id="EN-US_TOPIC_0000001965416825__en-us_topic_0000001268594501_p1633332814245">indices.queries.cache.size</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="57.3057305730573%" headers="mcps1.3.2.2.5.2.2.4.1.3 "><p id="EN-US_TOPIC_0000001965416825__p17904193113208">Maximum heap space allocated to the query cache.</p>
|
|
<p id="EN-US_TOPIC_0000001965416825__p154931235182011">Unit: percentage (%)</p>
|
|
<p id="EN-US_TOPIC_0000001965416825__p7360143782012">Value range: 1 to 100</p>
|
|
<p id="EN-US_TOPIC_0000001965416825__p935134941714">Default value: 10%</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="EN-US_TOPIC_0000001965416825__en-us_topic_0000001268594501_row83359287248"><td class="cellrowborder" valign="top" width="16.541654165416542%" headers="mcps1.3.2.2.5.2.2.4.1.1 "><p id="EN-US_TOPIC_0000001965416825__en-us_topic_0000001268594501_p83349283241">Queue Size in a Thread Pool</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="26.15261526152615%" headers="mcps1.3.2.2.5.2.2.4.1.2 "><p id="EN-US_TOPIC_0000001965416825__p8711855420">thread_pool.force_merge.size</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="57.3057305730573%" headers="mcps1.3.2.2.5.2.2.4.1.3 "><p id="EN-US_TOPIC_0000001965416825__p95121639152510">Size of the thread pool used for force merge operations.</p>
|
|
<p id="EN-US_TOPIC_0000001965416825__p16684856192510">Value range: a positive integer</p>
|
|
<p id="EN-US_TOPIC_0000001965416825__p389469182111">Default value: 1</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="EN-US_TOPIC_0000001965416825__en-us_topic_0000001268594501_row103371728132417"><td class="cellrowborder" valign="top" width="16.541654165416542%" headers="mcps1.3.2.2.5.2.2.4.1.1 "><p id="EN-US_TOPIC_0000001965416825__en-us_topic_0000001268594501_p1933510289248">Custom</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="26.15261526152615%" headers="mcps1.3.2.2.5.2.2.4.1.2 "><p id="EN-US_TOPIC_0000001965416825__en-us_topic_0000001268594501_p33361528142418">Custom parameters</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="57.3057305730573%" headers="mcps1.3.2.2.5.2.2.4.1.3 "><p id="EN-US_TOPIC_0000001965416825__p17391246132619">You can add any custom parameters supported by Elasticsearch.</p>
|
|
<p id="EN-US_TOPIC_0000001965416825__p153554118231">The parameter values must meet the following requirements:</p>
|
|
<ul id="EN-US_TOPIC_0000001965416825__ul812215605513"><li id="EN-US_TOPIC_0000001965416825__li1412216125519">If a custom parameter has multiple values, use a comma (,) and a space to separate them. The input format is [value1, value1, value1...].</li><li id="EN-US_TOPIC_0000001965416825__li5122176175519">Colons (:) are not allowed.</li></ul>
|
|
<div class="warning" id="EN-US_TOPIC_0000001965416825__note104471018175515"><span class="warningtitle"> WARNING: </span><div class="warningbody"><p id="EN-US_TOPIC_0000001965416825__p1132071455520">Set the values of any custom parameters to those supported by Elasticsearch. Otherwise, the cluster may fail to restart. Exercise caution when performing this operation.</p>
|
|
</div></div>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</li><li id="EN-US_TOPIC_0000001965416825__en-us_topic_0000001268594501_li12682102113577">After the change is complete, click <strong id="EN-US_TOPIC_0000001965416825__b22286218154">Submit</strong>.In the displayed dialog box, confirm the settings, select the box indicating "I understand that the modification will take effect after the cluster is restarted." and click <strong id="EN-US_TOPIC_0000001965416825__b10229162117153">Yes</strong>.<p id="EN-US_TOPIC_0000001965416825__en-us_topic_0000001268594501_p0505822115818">If the <strong id="EN-US_TOPIC_0000001965416825__b29981627123218">Status</strong> is <strong id="EN-US_TOPIC_0000001965416825__b799914273322">Succeeded</strong> in the parameter modification list, the modification has been saved. Up to 20 modification records can be displayed.</p>
|
|
</li><li id="EN-US_TOPIC_0000001965416825__en-us_topic_0000001268594501_li195461759181418">Click <strong id="EN-US_TOPIC_0000001965416825__b184118252817">Restart</strong> in the upper right corner to restart the cluster, thus making the change take effect.<ul id="EN-US_TOPIC_0000001965416825__en-us_topic_0000001268594501_ul772201251714"><li id="EN-US_TOPIC_0000001965416825__en-us_topic_0000001268594501_li97281231719">You need to restart the cluster after modification, or <strong id="EN-US_TOPIC_0000001965416825__b579513277194">Configuration not updated</strong> will be displayed in the <strong id="EN-US_TOPIC_0000001965416825__b177952027181918">Task Status</strong> column in the cluster list.</li><li id="EN-US_TOPIC_0000001965416825__en-us_topic_0000001268594501_li77261231712">If you restart the cluster after the modification, and <strong id="EN-US_TOPIC_0000001965416825__b32970381193">Task Status</strong> displays <strong id="EN-US_TOPIC_0000001965416825__b11297133816196">Configuration error</strong> in the cluster list, the parameter configuration file has failed to be modified.</li></ul>
|
|
</li></ol>
|
|
</div>
|
|
</div>
|
|
<div>
|
|
<div class="familylinks">
|
|
<div class="parentlink"><strong>Parent topic:</strong> <a href="css_01_0009.html">Managing Elasticsearch Clusters</a></div>
|
|
</div>
|
|
</div>
|
|
|