Files
doc-exports/docs/css/umn/css_01_0489.html
zhengxiu 2125539080 css umn 25.1.0 version
Reviewed-by: Pruthi, Vineet <vineet.pruthi@t-systems.com>
Co-authored-by: zhengxiu <zhengxiu@huawei.com>
Co-committed-by: zhengxiu <zhengxiu@huawei.com>
2025-07-04 09:10:17 +00:00

101 lines
14 KiB
HTML

<a name="css_01_0489"></a><a name="css_01_0489"></a>
<h1 class="topictitle1">Configuring Default Parameters in the .yml Configuration File of an OpenSearch Cluster</h1>
<div id="body0000001992205845"><p id="css_01_0489__p18201144182511">You can modify an OpenSearch cluster's configuration file for purposes like accelerating queries, enabling cross-domain access, adjusting the internal cache size, and managing the task queue size. The core configuration information of an OpenSearch cluster is stored in a named <span class="filepath" id="css_01_0489__filepath516311462015"><b>opensearch.yml</b></span>. You can modify specific parameters in this file on the CSS management console.</p>
<div class="section" id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_section1846352754911"><h4 class="sectiontitle">Configuring the .yml File</h4><ol id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_ol8194123694919"><li id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_li1142971461017">Log in to the CSS management console.</li><li id="css_01_0489__li4250043448">In the navigation pane on the left, choose <span class="uicontrol" id="css_01_0489__uicontrol15356194911514"><b>Clusters &gt; OpenSearch</b></span>.</li><li id="css_01_0489__en-us_topic_0000001268154521_li6012554340">In the cluster list, click the target cluster name to switch to the <strong id="css_01_0489__b5828151752">Cluster Information</strong> page.</li><li id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_li1277611425215">Click <strong id="css_01_0489__css_01_0080_b186077386324">Parameter Configurations</strong> and click <strong id="css_01_0489__css_01_0080_b6169154133313">Edit</strong> to modify module parameters as required.
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_table53371628162416" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Module parameters</caption><thead align="left"><tr id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_row103280287249"><th align="left" class="cellrowborder" valign="top" width="16.541654165416542%" id="mcps1.3.2.2.4.3.2.4.1.1"><p id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_p932842832419">Module Name</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="26.15261526152615%" id="mcps1.3.2.2.4.3.2.4.1.2"><p id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_p33281528192417">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="57.3057305730573%" id="mcps1.3.2.2.4.3.2.4.1.3"><p id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_p20328132810245">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_row19330192810243"><td class="cellrowborder" rowspan="6" valign="top" width="16.541654165416542%" headers="mcps1.3.2.2.4.3.2.4.1.1 "><p id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_p183291528122417">Cross-domain Access</p>
</td>
<td class="cellrowborder" valign="top" width="26.15261526152615%" headers="mcps1.3.2.2.4.3.2.4.1.2 "><p id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_p11329162882415">http.cors.allow-credentials</p>
</td>
<td class="cellrowborder" valign="top" width="57.3057305730573%" headers="mcps1.3.2.2.4.3.2.4.1.3 "><p id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_p17329162892417">Whether to return the Access-Control-Allow-Credentials of the header during cross-domain access</p>
<p id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_p16330628132414">Value: <strong id="css_01_0489__css_01_0080_b2063403017464">true</strong> or <strong id="css_01_0489__css_01_0080_b863413074618">false</strong></p>
<p id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_p11330112816244">Default value: <strong id="css_01_0489__css_01_0080_b73311441121319">false</strong></p>
</td>
</tr>
<tr id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_row1330428132419"><td class="cellrowborder" valign="top" headers="mcps1.3.2.2.4.3.2.4.1.1 "><p id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_p933042832410">http.cors.allow-origin</p>
</td>
<td class="cellrowborder" valign="top" headers="mcps1.3.2.2.4.3.2.4.1.2 "><p id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_p333032802416">Origin IP address allowed for cross-domain access, for example, <span class="parmvalue" id="css_01_0489__parmvalue62375114717"><b>192.168.122.122:9200</b></span></p>
</td>
</tr>
<tr id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_row8330728192417"><td class="cellrowborder" valign="top" headers="mcps1.3.2.2.4.3.2.4.1.1 "><p id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_p63301428132410">http.cors.max-age</p>
</td>
<td class="cellrowborder" valign="top" headers="mcps1.3.2.2.4.3.2.4.1.2 "><p id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_p73301128122415">Cache duration of the browser. The cache is automatically cleared after the time range you specify.</p>
<p id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_p19330328172417">Unit: s</p>
<p id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_p8330328142412">Default value: <strong id="css_01_0489__b3651116575">1728000</strong></p>
</td>
</tr>
<tr id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_row133010281246"><td class="cellrowborder" valign="top" headers="mcps1.3.2.2.4.3.2.4.1.1 "><p id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_p73307287241">http.cors.allow-headers</p>
</td>
<td class="cellrowborder" valign="top" headers="mcps1.3.2.2.4.3.2.4.1.2 "><p id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_p933022852417">Headers allowed for cross-domain access, including <strong id="css_01_0489__css_01_0080_b1976310163919">X-Requested-With</strong>, <strong id="css_01_0489__css_01_0080_b3802192113913">Content-Type</strong>, and <strong id="css_01_0489__css_01_0080_b178683443912">Content-Length</strong>. Use commas (,) and spaces to separate headers.</p>
</td>
</tr>
<tr id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_row123301728142417"><td class="cellrowborder" valign="top" headers="mcps1.3.2.2.4.3.2.4.1.1 "><p id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_p833013283249">http.cors.enabled</p>
</td>
<td class="cellrowborder" valign="top" headers="mcps1.3.2.2.4.3.2.4.1.2 "><p id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_p63301228112415">Whether to allow cross-domain access</p>
<p id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_p11330162812246">Value: <strong id="css_01_0489__css_01_0080_b4531153634618">true</strong> or <strong id="css_01_0489__css_01_0080_b4531836134617">false</strong></p>
<p id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_p123302028142416">Default value: <strong id="css_01_0489__css_01_0080_b1979382562110">false</strong></p>
</td>
</tr>
<tr id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_row833113287248"><td class="cellrowborder" valign="top" headers="mcps1.3.2.2.4.3.2.4.1.1 "><p id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_p13301828172410">http.cors.allow-methods</p>
</td>
<td class="cellrowborder" valign="top" headers="mcps1.3.2.2.4.3.2.4.1.2 "><p id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_p8330132814241">Methods allowed for cross-domain access, including <strong id="css_01_0489__css_01_0080_b210620233371">OPTIONS</strong>, <strong id="css_01_0489__css_01_0080_b19139257377">HEAD</strong>, <strong id="css_01_0489__css_01_0080_b1664917277374">GET</strong>, <strong id="css_01_0489__css_01_0080_b1543314299371">POST</strong>, <strong id="css_01_0489__css_01_0080_b3706133110374">PUT</strong>, and <strong id="css_01_0489__css_01_0080_b6825163318371">DELETE</strong>. Use commas (,) and spaces to separate methods.</p>
</td>
</tr>
<tr id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_row12333192812418"><td class="cellrowborder" valign="top" width="16.541654165416542%" headers="mcps1.3.2.2.4.3.2.4.1.1 "><p id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_p183319285248">Reindexing</p>
</td>
<td class="cellrowborder" valign="top" width="26.15261526152615%" headers="mcps1.3.2.2.4.3.2.4.1.2 "><p id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_p33319289247">reindex.remote.whitelist</p>
</td>
<td class="cellrowborder" valign="top" width="57.3057305730573%" headers="mcps1.3.2.2.4.3.2.4.1.3 "><p id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_p233152818246">Configure this parameter to migrate data from the current cluster to the destination cluster through the reindex API. Example value: <span class="parmvalue" id="css_01_0489__parmvalue18904182318718"><b>192.168.122.122:9200</b></span>.</p>
</td>
</tr>
<tr id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_row12334228112416"><td class="cellrowborder" valign="top" width="16.541654165416542%" headers="mcps1.3.2.2.4.3.2.4.1.1 "><p id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_p1433382862410">Custom Cache</p>
</td>
<td class="cellrowborder" valign="top" width="26.15261526152615%" headers="mcps1.3.2.2.4.3.2.4.1.2 "><p id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_p1633332814245">indices.queries.cache.size</p>
</td>
<td class="cellrowborder" valign="top" width="57.3057305730573%" headers="mcps1.3.2.2.4.3.2.4.1.3 "><p id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_p17333112812243">Cache size in the query phase</p>
<p id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_p73331128162414">Value range: 1 to 100</p>
<p id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_p7333928142415">Unit: %</p>
<p id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_p63332028162413">Default value: <strong id="css_01_0489__css_01_0080_b3745444181210">10%</strong></p>
</td>
</tr>
<tr id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_row83359287248"><td class="cellrowborder" valign="top" width="16.541654165416542%" headers="mcps1.3.2.2.4.3.2.4.1.1 "><p id="css_01_0489__css_01_0080_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.4.3.2.4.1.2 "><p id="css_01_0489__css_01_0080_p8711855420">thread_pool.force_merge.size</p>
</td>
<td class="cellrowborder" valign="top" width="57.3057305730573%" headers="mcps1.3.2.2.4.3.2.4.1.3 "><p id="css_01_0489__css_01_0080_p1871110514413">Queue size in the force merge thread pool. The value is an integer.</p>
<p id="css_01_0489__css_01_0080_p1711451044">Default value: <strong id="css_01_0489__css_01_0080_b102681458202517">1</strong></p>
</td>
</tr>
<tr id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_row103371728132417"><td class="cellrowborder" valign="top" width="16.541654165416542%" headers="mcps1.3.2.2.4.3.2.4.1.1 "><p id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_p1933510289248">Customize</p>
</td>
<td class="cellrowborder" valign="top" width="26.15261526152615%" headers="mcps1.3.2.2.4.3.2.4.1.2 "><p id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_p33361528142418">You can add parameters based on your needs.</p>
</td>
<td class="cellrowborder" valign="top" width="57.3057305730573%" headers="mcps1.3.2.2.4.3.2.4.1.3 "><p id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_p13364287245">Customized parameters</p>
<ul id="css_01_0489__ul1547684916573"><li id="css_01_0489__li1747654985714">Enter multiple values in the format <strong id="css_01_0489__b5316537474">[value1, value2, value3...]</strong>.</li><li id="css_01_0489__li13476114985714">Separate different values using commas (,) and spaces.</li><li id="css_01_0489__li1947614920573">Colons (:) are not allowed.</li></ul>
<div class="warning" id="css_01_0489__note145558118587"><span class="warningtitle"> WARNING: </span><div class="warningbody"><p id="css_01_0489__p183991856145710">Set the values of any custom parameters to those supported by OpenSearch. Otherwise, the cluster may fail to restart. Exercise caution when performing this operation.</p>
</div></div>
</td>
</tr>
</tbody>
</table>
</div>
</li><li id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_li12682102113577">After the modification is complete, click <strong id="css_01_0489__css_01_0080_b1380472273212">Submit</strong>. In the displayed <strong id="css_01_0489__css_01_0080_b118121322123211">Submit Configuration</strong> dialog box, select the box indicating "I understand that the modification will take effect after the cluster is restarted." and click <strong id="css_01_0489__css_01_0080_b28131122133220">Yes</strong>.<p id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_p0505822115818">If the <strong id="css_01_0489__css_01_0080_b29981627123218">Status</strong> is <strong id="css_01_0489__css_01_0080_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="css_01_0489__css_01_0080_en-us_topic_0000001268594501_li195461759181418">Return to the cluster list and choose <strong id="css_01_0489__css_01_0080_b284113793318">More</strong> &gt; <strong id="css_01_0489__css_01_0080_b1184357163314">Restart</strong> in the <strong id="css_01_0489__css_01_0080_b2845871335">Operation</strong> column to restart the cluster and make the modification take effect.<ul id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_ul772201251714"><li id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_li97281231719">You need to restart the cluster after modification, or <strong id="css_01_0489__css_01_0080_b1442671114337">Configuration not updated</strong> will be displayed in the <strong id="css_01_0489__css_01_0080_b17427101153315">Task Status</strong> column on the <strong id="css_01_0489__css_01_0080_b2427151112339">Clusters</strong> page.</li><li id="css_01_0489__css_01_0080_en-us_topic_0000001268594501_li77261231712">If you restart the cluster after the modification, and <strong id="css_01_0489__css_01_0080_b1400811181115">Task Status</strong> displays <strong id="css_01_0489__css_01_0080_b46078383115">Configuration error</strong>, the parameter configuration file fails to be modified.</li></ul>
</li></ol>
</div>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="css_01_0486.html">Managing OpenSearch Clusters</a></div>
</div>
</div>