Yang, Tong 48706b7552 MRS COMP-LTS 320-lts.1 version
Reviewed-by: Kacur, Michal <michal.kacur@t-systems.com>
Co-authored-by: Yang, Tong <yangtong2@huawei.com>
Co-committed-by: Yang, Tong <yangtong2@huawei.com>
2024-04-12 12:51:10 +00:00

42 lines
3.5 KiB
HTML

<a name="mrs_01_24855"></a><a name="mrs_01_24855"></a>
<h1 class="topictitle1">Accelerating TTL Operations</h1>
<div id="body0000001583555425"><p id="mrs_01_24855__p649472534714">When TTL is triggered in ClickHouse, a large amount of CPU and memory are consumed.</p>
<p id="mrs_01_24855__p141571070513">Log in to FusionInsight Manager and choose <strong id="mrs_01_24855__b176851247165218">Cluster</strong> &gt; <strong id="mrs_01_24855__b168684715211">Services</strong> &gt; <strong id="mrs_01_24855__b15686194755214">ClickHouse</strong>. Click <strong id="mrs_01_24855__b8687947105217">Configurations</strong> then <strong id="mrs_01_24855__b13687164735210">All Configurations</strong>. Click <strong id="mrs_01_24855__b17688184765218">ClickHouseServer</strong> &gt; <strong id="mrs_01_24855__b17688134717529">Customization</strong>, find the <strong id="mrs_01_24855__b868954715215">clickhouse-config-customize</strong> parameter, add the following parameters, save the configuration, and restart the service.</p>
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="mrs_01_24855__table9493101517506" frame="border" border="1" rules="all"><thead align="left"><tr id="mrs_01_24855__row17494181516507"><th align="left" class="cellrowborder" valign="top" width="33.33333333333333%" id="mcps1.3.3.1.4.1.1"><p id="mrs_01_24855__p1849471565012">Configuration Item</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="33.33333333333333%" id="mcps1.3.3.1.4.1.2"><p id="mrs_01_24855__p54941315125017">Reference Value</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="33.33333333333333%" id="mcps1.3.3.1.4.1.3"><p id="mrs_01_24855__p6495191510507">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="mrs_01_24855__row94956158504"><td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.3.1.4.1.1 "><p id="mrs_01_24855__p74951915135017">merge_tree.max_replicated_merges_with_ttl_in_queue</p>
</td>
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.3.1.4.1.2 "><p id="mrs_01_24855__p5495915175019">Half of number of CPU cores</p>
</td>
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.3.1.4.1.3 "><p id="mrs_01_24855__p1349531512509">Number of tasks that allow TTL to merge parts concurrently in the ReplicatedMergeTree queue.</p>
</td>
</tr>
<tr id="mrs_01_24855__row1849521517508"><td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.3.1.4.1.1 "><p id="mrs_01_24855__p11495415135019">merge_tree.max_number_of_merges_with_ttl_in_pool</p>
</td>
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.3.1.4.1.2 "><p id="mrs_01_24855__p1049511153505">Number of CPU cores</p>
</td>
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.3.1.4.1.3 "><p id="mrs_01_24855__p3495101513505">The thread pool that allows TTL to merge parts in the ReplicatedMergeTree queue.</p>
</td>
</tr>
</tbody>
</table>
</div>
<div class="note" id="mrs_01_24855__note9491105414513"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="mrs_01_24855__p3493854145114">Do not modify these configurations when the cluster writes heavily. Idle threads need to be reserved for regular Merge operations to avoid the "Too many parts" issue.</p>
</div></div>
<p id="mrs_01_24855__p8060118"></p>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="mrs_01_24848.html">ClickHouse Performance Tuning</a></div>
</div>
</div>