forked from docs/doc-exports
Reviewed-by: Goncharov, Artem <artem.goncharov@t-systems.com> Co-authored-by: gtema <artem.goncharov@gmail.com> Co-committed-by: gtema <artem.goncharov@gmail.com>
53 lines
3.9 KiB
HTML
53 lines
3.9 KiB
HTML
<a name="css_01_0079"></a><a name="css_01_0079"></a>
|
|
|
|
<h1 class="topictitle1">Hot and Cold Data Storage</h1>
|
|
<div id="body0000001334459449"><p id="css_01_0079__p8060118">CSS provides you with cold data nodes. You can store data that requires query response in seconds on high-performance nodes and store data that requires query response in minutes on cold data nodes with large capacity and low specifications.</p>
|
|
<div class="note" id="css_01_0079__note176094262315"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><ul id="css_01_0079__ul10717930132"><li id="css_01_0079__li887811975820">When creating a cluster, you need to configure nodes as data nodes. When you enable the cold data node function, data nodes become hot nodes.</li><li id="css_01_0079__li1958302314582">You can enable the cold data node, master node, and client node functions at the same time.</li><li id="css_01_0079__li1971753019317">You can increase nodes and expand storage capacity of cold data nodes. The maximum storage capacity is determined by the node specifications. Local disks do not support storage capacity expansion.</li></ul>
|
|
</div></div>
|
|
<div class="section" id="css_01_0079__section298814466206"><h4 class="sectiontitle">Hot and Cold Data Node Switchover</h4><p id="css_01_0079__p98144288338">After you enable the cold data node function, the cold data node is labeled with <strong id="css_01_0079__b1543173513118">cold</strong>. In addition, data nodes are labeled with <strong id="css_01_0079__b12864146191117">hot</strong> and become hot nodes. You can specify indices to distribute data to cold or hot nodes.</p>
|
|
<p id="css_01_0079__p1034019214245">You can configure a template to store indices on the specified cold or hot node.</p>
|
|
<p id="css_01_0079__p1234011213243">The following figure shows this process. Log in to the <strong id="css_01_0079__b62308371888">Kibana </strong><strong id="css_01_0079__b3619325368">Console</strong> page of the cluster, modify the template by configuring the index starting with <strong id="css_01_0079__b297018420378">myindex</strong>, and store the indices on the cold node. In this case, the <strong id="css_01_0079__b58687221425">myindex*</strong> date is stored on the cold data node by modifying the template.</p>
|
|
<ul id="css_01_0079__ul1672811231355"><li id="css_01_0079__li197281423651">For the 5.<em id="css_01_0079__i105666446500">x</em> version, run the following command to create a template:<pre class="screen" id="css_01_0079__screen1349715413531">PUT _template/test
|
|
{
|
|
"order": 1,
|
|
"template": "myindex*",
|
|
"settings": {
|
|
"index": {
|
|
"refresh_interval": "30s",
|
|
"number_of_shards": "3",
|
|
"number_of_replicas": "1",
|
|
"routing.allocation.require.box_type": "cold"
|
|
}
|
|
}
|
|
}</pre>
|
|
</li><li id="css_01_0079__li162832403514">For the 6.<em id="css_01_0079__i16711253165017">x</em> and later versions, run the following command to create a template:<pre class="screen" id="css_01_0079__screen263614110017">PUT _template/test
|
|
{
|
|
"order": 1,
|
|
"index_patterns": "myindex*",
|
|
"settings": {
|
|
"refresh_interval": "30s",
|
|
"number_of_shards": "3",
|
|
"number_of_replicas": "1",
|
|
"routing.allocation.require.box_type": "cold"
|
|
}
|
|
}</pre>
|
|
</li></ul>
|
|
<p id="css_01_0079__p12340126246">You can perform operations on the created index.</p>
|
|
<pre class="screen" id="css_01_0079__screen134020232415">PUT myindex/_settings
|
|
{
|
|
"index.routing.allocation.require.box_type": "cold"
|
|
}</pre>
|
|
<p id="css_01_0079__p83409232415">You can cancel the configurations of hot and cold data nodes.</p>
|
|
<pre class="screen" id="css_01_0079__screen63401826247">PUT myindex/_settings
|
|
{
|
|
"index.routing.allocation.require.box_type": null
|
|
}</pre>
|
|
</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>
|
|
|