Yang, Tong 6182f91ba8 MRS component operation guide_normal 2.0.38.SP20 version
Reviewed-by: Hasko, Vladimir <vladimir.hasko@t-systems.com>
Co-authored-by: Yang, Tong <yangtong2@huawei.com>
Co-committed-by: Yang, Tong <yangtong2@huawei.com>
2022-12-09 14:55:21 +00:00

139 lines
14 KiB
HTML

<a name="mrs_01_2399"></a><a name="mrs_01_2399"></a>
<h1 class="topictitle1">ClickHouse Log Overview</h1>
<div id="body0000001127872551"><div class="section" id="mrs_01_2399__s7c10a70635c744399005f0b474e3cc1f"><h4 class="sectiontitle">Log Description</h4><p id="mrs_01_2399__en-us_topic_0046736730_p7703550"><strong id="mrs_01_2399__b1327154818479">Log path</strong>: The default storage path of ClickHouse log files is as follows: <strong id="mrs_01_2399__b438163464812">${BIGDATA_LOG_HOME}/clickhouse</strong></p>
<p id="mrs_01_2399__en-us_topic_0046736730_p6167913"><strong id="mrs_01_2399__b1880318514495">Log archive rule</strong>: The automatic ClickHouse log compression function is enabled. By default, when the size of logs exceeds 100 MB, logs are automatically compressed into a log file named in the following format: <em id="mrs_01_2399__i2080820518495">&lt;Original log name&gt;</em><strong id="mrs_01_2399__b198451937195314">.</strong><em id="mrs_01_2399__i1809175114913">[ID]</em><strong id="mrs_01_2399__b13809155120490">.gz</strong>. A maximum of 10 latest compressed files are reserved by default. The number of compressed files can be configured on Manager.</p>
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="mrs_01_2399__table15132841115112" width="100%" frame="border" border="1" rules="all"><caption><b>Table 1 </b>ClickHouse log list</caption><thead align="left"><tr id="mrs_01_2399__row1313234175112"><th align="left" class="cellrowborder" valign="top" width="14.211421142114212%" id="mcps1.3.1.4.2.4.1.1"><p id="mrs_01_2399__p6132134115110"><strong id="mrs_01_2399__b1970613461905">Log Type</strong></p>
</th>
<th align="left" class="cellrowborder" valign="top" width="57.165716571657164%" id="mcps1.3.1.4.2.4.1.2"><p id="mrs_01_2399__p8132194135120"><strong id="mrs_01_2399__en-us_topic_0046736730_b18874618">Log File Name</strong></p>
</th>
<th align="left" class="cellrowborder" valign="top" width="28.622862286228624%" id="mcps1.3.1.4.2.4.1.3"><p id="mrs_01_2399__p101321441205117"><strong id="mrs_01_2399__en-us_topic_0046736730_b2279597">Description</strong></p>
</th>
</tr>
</thead>
<tbody><tr id="mrs_01_2399__row131321441185118"><td class="cellrowborder" rowspan="6" valign="top" width="14.211421142114212%" headers="mcps1.3.1.4.2.4.1.1 "><p id="mrs_01_2399__p1313214155114">Run logs</p>
</td>
<td class="cellrowborder" valign="top" width="57.165716571657164%" headers="mcps1.3.1.4.2.4.1.2 "><p id="mrs_01_2399__p71321241125119">/var/log/Bigdata/clickhouse/clickhouseServer/clickhouse-server.err.log</p>
</td>
<td class="cellrowborder" valign="top" width="28.622862286228624%" headers="mcps1.3.1.4.2.4.1.3 "><p id="mrs_01_2399__p613264115519">Path of ClickHouseServer error log files.</p>
</td>
</tr>
<tr id="mrs_01_2399__row3132941115115"><td class="cellrowborder" valign="top" headers="mcps1.3.1.4.2.4.1.1 "><p id="mrs_01_2399__p161321641125112">/var/log/Bigdata/clickhouse/clickhouseServer/checkService.log</p>
</td>
<td class="cellrowborder" rowspan="2" valign="top" headers="mcps1.3.1.4.2.4.1.2 "><p id="mrs_01_2399__p1013294145114">Path of key ClickHouseServer run log files.</p>
</td>
</tr>
<tr id="mrs_01_2399__row1791916141712"><td class="cellrowborder" valign="top" headers="mcps1.3.1.4.2.4.1.1 "><p id="mrs_01_2399__p7817162231710">/var/log/Bigdata/clickhouse/clickhouseServer/clickhouse-server.log</p>
</td>
</tr>
<tr id="mrs_01_2399__row149782353466"><td class="cellrowborder" valign="top" headers="mcps1.3.1.4.2.4.1.1 "><p id="mrs_01_2399__p2957643114613">/var/log/Bigdata/clickhouse/balance/start.log</p>
</td>
<td class="cellrowborder" valign="top" headers="mcps1.3.1.4.2.4.1.2 "><p id="mrs_01_2399__p1797814356465">Path of ClickHouseBalancer startup log files.</p>
</td>
</tr>
<tr id="mrs_01_2399__row934418393467"><td class="cellrowborder" valign="top" headers="mcps1.3.1.4.2.4.1.1 "><p id="mrs_01_2399__p106434448468">/var/log/Bigdata/clickhouse/balance/error.log</p>
</td>
<td class="cellrowborder" valign="top" headers="mcps1.3.1.4.2.4.1.2 "><p id="mrs_01_2399__p53441839184617">Path of ClickHouseBalancer error log files.</p>
</td>
</tr>
<tr id="mrs_01_2399__row1518042119471"><td class="cellrowborder" valign="top" headers="mcps1.3.1.4.2.4.1.1 "><p id="mrs_01_2399__p163325542474">/var/log/Bigdata/clickhouse/balance/access_http.log</p>
</td>
<td class="cellrowborder" valign="top" headers="mcps1.3.1.4.2.4.1.2 "><p id="mrs_01_2399__p218110212475">Path of ClickHouseBalancer run log files.</p>
</td>
</tr>
<tr id="mrs_01_2399__row1929865811294"><td class="cellrowborder" rowspan="2" valign="top" width="14.211421142114212%" headers="mcps1.3.1.4.2.4.1.1 "><p id="mrs_01_2399__p1422511493020">Data migration logs</p>
<p id="mrs_01_2399__p17617145903612"></p>
</td>
<td class="cellrowborder" valign="top" width="57.165716571657164%" headers="mcps1.3.1.4.2.4.1.2 "><p id="mrs_01_2399__p17779958141111">/var/log/Bigdata/clickhouse/migration/<em id="mrs_01_2399__i14530134171219">Data migration task name</em>/clickhouse-copier_{timestamp}_{processId}/copier.log</p>
</td>
<td class="cellrowborder" valign="top" width="28.622862286228624%" headers="mcps1.3.1.4.2.4.1.3 "><p id="mrs_01_2399__p3298175814299">Run logs generated when you use the migration tool by referring to <a href="mrs_01_24198.html">Using the ClickHouse Data Migration Tool</a>.</p>
</td>
</tr>
<tr id="mrs_01_2399__row14616559173617"><td class="cellrowborder" valign="top" headers="mcps1.3.1.4.2.4.1.1 "><p id="mrs_01_2399__p849211272395">/var/log/Bigdata/clickhouse/migration/<em id="mrs_01_2399__i37941551151219">Data migration task name</em>/clickhouse-copier_{timestamp}_{processId}/copier.err.log</p>
</td>
<td class="cellrowborder" valign="top" headers="mcps1.3.1.4.2.4.1.2 "><p id="mrs_01_2399__p11336191914374">Error logs generated when you use the migration tool by referring to <a href="mrs_01_24198.html">Using the ClickHouse Data Migration Tool</a>.</p>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="section" id="mrs_01_2399__section565352319337"><h4 class="sectiontitle">Log Level</h4><p id="mrs_01_2399__en-us_topic_0046736730_p60201314"><a href="#mrs_01_2399__tc09b739e3eb34797a6da936a37654e97">Table 2</a> describes the log levels supported by ClickHouse.</p>
<p id="mrs_01_2399__en-us_topic_0046736730_p44468229">Levels of run logs are error, warning, trace, information, and debug from the highest to the lowest priority. Run logs of equal or higher levels are recorded. The higher the specified log level, the fewer the logs recorded.</p>
<div class="tablenoborder"><a name="mrs_01_2399__tc09b739e3eb34797a6da936a37654e97"></a><a name="tc09b739e3eb34797a6da936a37654e97"></a><table cellpadding="4" cellspacing="0" summary="" id="mrs_01_2399__tc09b739e3eb34797a6da936a37654e97" frame="border" border="1" rules="all"><caption><b>Table 2 </b>Log levels</caption><thead align="left"><tr id="mrs_01_2399__en-us_topic_0046736730_row63443418"><th align="left" class="cellrowborder" valign="top" width="33.333333333333336%" id="mcps1.3.2.4.2.4.1.1"><p id="mrs_01_2399__en-us_topic_0046736730_p38643240"><strong id="mrs_01_2399__en-us_topic_0046736730_b12244848">Log Type</strong></p>
</th>
<th align="left" class="cellrowborder" valign="top" width="33.333333333333336%" id="mcps1.3.2.4.2.4.1.2"><p id="mrs_01_2399__en-us_topic_0046736730_p52308663"><strong id="mrs_01_2399__en-us_topic_0046736730_b1015919">Level</strong></p>
</th>
<th align="left" class="cellrowborder" valign="top" width="33.333333333333336%" id="mcps1.3.2.4.2.4.1.3"><p id="mrs_01_2399__en-us_topic_0046736730_p15180599"><strong id="mrs_01_2399__en-us_topic_0046736730_b2407664">Description</strong></p>
</th>
</tr>
</thead>
<tbody><tr id="mrs_01_2399__row9239421124812"><td class="cellrowborder" rowspan="5" valign="top" width="33.333333333333336%" headers="mcps1.3.2.4.2.4.1.1 "><p id="mrs_01_2399__p4240192119486">Run log</p>
</td>
<td class="cellrowborder" valign="top" width="33.333333333333336%" headers="mcps1.3.2.4.2.4.1.2 "><p id="mrs_01_2399__p19240021134811">error</p>
</td>
<td class="cellrowborder" valign="top" width="33.333333333333336%" headers="mcps1.3.2.4.2.4.1.3 "><p id="mrs_01_2399__p11240142113485">Logs of this level record error information about system running.</p>
</td>
</tr>
<tr id="mrs_01_2399__en-us_topic_0046736730_row60803124"><td class="cellrowborder" valign="top" headers="mcps1.3.2.4.2.4.1.1 "><p id="mrs_01_2399__en-us_topic_0046736730_p34212241">warning</p>
</td>
<td class="cellrowborder" valign="top" headers="mcps1.3.2.4.2.4.1.2 "><p id="mrs_01_2399__p85517215020">Logs of this level record exception information about the current event processing.</p>
</td>
</tr>
<tr id="mrs_01_2399__en-us_topic_0046736730_row43335374"><td class="cellrowborder" valign="top" headers="mcps1.3.2.4.2.4.1.1 "><p id="mrs_01_2399__en-us_topic_0046736730_p20504385">trace</p>
</td>
<td class="cellrowborder" valign="top" headers="mcps1.3.2.4.2.4.1.2 "><p id="mrs_01_2399__en-us_topic_0046736730_p50242460">Logs of this level record trace information about the current event processing.</p>
</td>
</tr>
<tr id="mrs_01_2399__en-us_topic_0046736730_row49528960"><td class="cellrowborder" valign="top" headers="mcps1.3.2.4.2.4.1.1 "><p id="mrs_01_2399__en-us_topic_0046736730_p52422860">information</p>
</td>
<td class="cellrowborder" valign="top" headers="mcps1.3.2.4.2.4.1.2 "><p id="mrs_01_2399__en-us_topic_0046736730_p18393235">Logs of this level record normal running status information about the system and events.</p>
</td>
</tr>
<tr id="mrs_01_2399__en-us_topic_0046736730_row31321393"><td class="cellrowborder" valign="top" headers="mcps1.3.2.4.2.4.1.1 "><p id="mrs_01_2399__en-us_topic_0046736730_p54004927">debug</p>
</td>
<td class="cellrowborder" valign="top" headers="mcps1.3.2.4.2.4.1.2 "><p id="mrs_01_2399__en-us_topic_0046736730_p12322941">Logs of this level record system running and debugging information.</p>
</td>
</tr>
</tbody>
</table>
</div>
<p id="mrs_01_2399__en-us_topic_0046736730_p43797605">To modify log levels, perform the following operations:</p>
<ol id="mrs_01_2399__ol2049469418545"><li id="mrs_01_2399__ld709c225878548f3af2da8bc9d7ac71e"><span>Log in to FusionInsight Manager.</span></li><li id="mrs_01_2399__lf3b434e1f6d04218b284807ec30eb2ea"><span>Choose <span id="mrs_01_2399__text1775843617617"><strong id="mrs_01_2399__b177531836761">Cluster</strong></span> &gt; <strong id="mrs_01_2399__b117588361661">Services</strong> &gt; <strong id="mrs_01_2399__b67586361862">ClickHouse</strong> &gt; <strong id="mrs_01_2399__b775919361663">Configurations</strong>.</span></li><li id="mrs_01_2399__le99e6d2e91d442f6a738726fcef09e22"><span>Select <strong id="mrs_01_2399__b88687466353357">All Configurations</strong>.</span></li><li id="mrs_01_2399__li1026083201512"><span>On the menu bar on the left, select the log menu of the target role.</span></li><li id="mrs_01_2399__la66d9926fc274e2f8e77edcee5598e25"><span>Select a desired log level.</span></li><li id="mrs_01_2399__li1719026918545"><span>Click <strong id="mrs_01_2399__b27691691976">Save</strong>. Then, click <strong id="mrs_01_2399__b167751891712">OK</strong>.</span></li></ol>
<div class="note" id="mrs_01_2399__note199281245114918"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="mrs_01_2399__p1292912455494">The configurations take effect immediately without the need to restart the service.</p>
</div></div>
</div>
<div class="section" id="mrs_01_2399__s70eeb581418c4885b24bf52a5037ed2a"><h4 class="sectiontitle">Log Format</h4><p id="mrs_01_2399__en-us_topic_0046736730_p51681963">The following table lists the ClickHouse log format:</p>
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="mrs_01_2399__en-us_topic_0046736730_table62484483" frame="border" border="1" rules="all"><caption><b>Table 3 </b>Log formats</caption><thead align="left"><tr id="mrs_01_2399__en-us_topic_0046736730_row6057523"><th align="left" class="cellrowborder" valign="top" width="33.33333333333333%" id="mcps1.3.3.3.2.4.1.1"><p id="mrs_01_2399__en-us_topic_0046736730_p20897367"><strong id="mrs_01_2399__en-us_topic_0046736730_b53858575">Log Type</strong></p>
</th>
<th align="left" class="cellrowborder" valign="top" width="33.33333333333333%" id="mcps1.3.3.3.2.4.1.2"><p id="mrs_01_2399__en-us_topic_0046736730_p468450"><strong id="mrs_01_2399__en-us_topic_0046736730_b4216055">Format</strong></p>
</th>
<th align="left" class="cellrowborder" valign="top" width="33.33333333333333%" id="mcps1.3.3.3.2.4.1.3"><p id="mrs_01_2399__en-us_topic_0046736730_p5956164"><strong id="mrs_01_2399__en-us_topic_0046736730_b53605478">Example</strong></p>
</th>
</tr>
</thead>
<tbody><tr id="mrs_01_2399__en-us_topic_0046736730_row47076455"><td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.3.3.2.4.1.1 "><p id="mrs_01_2399__en-us_topic_0046736730_p55096476">Run log</p>
</td>
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.3.3.2.4.1.2 "><p id="mrs_01_2399__en-us_topic_0046736730_p33629549">&lt;<em id="mrs_01_2399__i18149155314911">yyyy-MM-dd HH:mm:ss,SSS</em>&gt;|&lt;<em id="mrs_01_2399__i1115013531898">Log level</em>&gt;|&lt;<em id="mrs_01_2399__i1150853294">Name of the thread that generates the log</em>&gt;|&lt;<em id="mrs_01_2399__i315019531691">Message in the log</em>&gt;|&lt;<em id="mrs_01_2399__i4150145315912">Location where the log event occurs</em>&gt;</p>
</td>
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.3.3.2.4.1.3 "><p id="mrs_01_2399__p172616571057">2021.02.23 15:26:30.691301 [ 6085 ] {} &lt;Error&gt; DynamicQueryHandler: Code: 516, e.displayText() = DB::Exception: default: Authentication failed: password is incorrect or there is no user with such name, Stack trace (when copying this</p>
<p id="mrs_01_2399__p426119571859">message, always include the lines below):</p>
<p id="mrs_01_2399__p126118571559"></p>
<p id="mrs_01_2399__p1826125710511">0. Poco::Exception::Exception(std::__1::basic_string&lt;char, std::__1::char_traits&lt;char&gt;, std::__1::allocator&lt;char&gt; &gt; const&amp;, int) @ 0x1250e59c</p>
</td>
</tr>
</tbody>
</table>
</div>
</div>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="mrs_01_2344.html">Using ClickHouse</a></div>
</div>
</div>