Skip to content

Commit 7bf62ad

Browse files
committed
Site updated: 2024-01-20 10:19:02
1 parent 33c6fda commit 7bf62ad

File tree

197 files changed

+5556
-3314
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

197 files changed

+5556
-3314
lines changed

2022/02/26/The-Art-Of-Java-Concurrency-Programming/The-Art-Of-Java-Concurrency-Programming-Reading-2-Java并发机制的底层实现机制/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -625,7 +625,7 @@ <h2 id="44-使用锁实现原子操作"><a class="markdownIt-Anchor" href="#44-
625625
<article class="post-prev col-6">
626626

627627

628-
<a href="/2022/04/06/Apache%20IoTDB/%E4%B8%80%E6%96%87%E5%B8%A6%E4%BD%A0%E4%BD%BF%E7%94%A8Apache%20IoTDB%E7%B3%BB%E7%BB%9F%E7%9B%91%E6%8E%A7/" title="一文带你使用Apache IoTDB系统监控模块">
628+
<a href="/2022/04/06/Apache%20IoTDB/metric/%E4%B8%80%E6%96%87%E5%B8%A6%E4%BD%A0%E4%BD%BF%E7%94%A8Apache%20IoTDB%E7%B3%BB%E7%BB%9F%E7%9B%91%E6%8E%A7/" title="一文带你使用Apache IoTDB系统监控模块">
629629
<i class="iconfont icon-arrowleft"></i>
630630
<span class="hidden-mobile">一文带你使用Apache IoTDB系统监控模块</span>
631631
<span class="visible-mobile">上一篇</span>

2022/04/06/Apache IoTDB/一文带你使用Apache IoTDB系统监控/index.html renamed to 2022/04/06/Apache IoTDB/metric/一文带你使用Apache IoTDB系统监控/index.html

Lines changed: 31 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
<meta name="description" content="从Apache IoTDB 0.13.0版本之后可以启动监控模块对系统进行监控,并且可以使用Prometheus、Grafana等工具进行可视化">
2020
<meta property="og:type" content="article">
2121
<meta property="og:title" content="一文带你使用Apache IoTDB系统监控模块">
22-
<meta property="og:url" content="https://spricoder.github.io/2022/04/06/Apache%20IoTDB/%E4%B8%80%E6%96%87%E5%B8%A6%E4%BD%A0%E4%BD%BF%E7%94%A8Apache%20IoTDB%E7%B3%BB%E7%BB%9F%E7%9B%91%E6%8E%A7/index.html">
22+
<meta property="og:url" content="https://spricoder.github.io/2022/04/06/Apache%20IoTDB/metric/%E4%B8%80%E6%96%87%E5%B8%A6%E4%BD%A0%E4%BD%BF%E7%94%A8Apache%20IoTDB%E7%B3%BB%E7%BB%9F%E7%9B%91%E6%8E%A7/index.html">
2323
<meta property="og:site_name" content="SpriCoder的博客">
2424
<meta property="og:description" content="从Apache IoTDB 0.13.0版本之后可以启动监控模块对系统进行监控,并且可以使用Prometheus、Grafana等工具进行可视化">
2525
<meta property="og:locale" content="zh_CN">
@@ -281,85 +281,77 @@ <h1 style="display: none">一文带你使用Apache IoTDB系统监控模块</h1>
281281

282282
<div class="markdown-body">
283283

284-
<h2 id="一文带你使用apache-iotdb系统监控模块"><a class="markdownIt-Anchor" href="#一文带你使用apache-iotdb系统监控模块"></a> 一文带你使用Apache IoTDB系统监控模块</h2>
285-
<p>在Apache IoTDB 0.13.0版本开始,我们引入了系统监控模块,本文主要介绍了如何在单机版开启系统监控模块,并且使用Prometheus + Grafana完成系统监控的可视化。</p>
286-
<h1 id="相关配置信息"><a class="markdownIt-Anchor" href="#相关配置信息"></a> 相关配置信息</h1>
287-
<ol>
284+
<h2 id="一文带你使用Apache-IoTDB系统监控模块"><a href="#一文带你使用Apache-IoTDB系统监控模块" class="headerlink" title="一文带你使用Apache IoTDB系统监控模块"></a>一文带你使用Apache IoTDB系统监控模块</h2><p>在Apache IoTDB 0.13.0版本开始,我们引入了系统监控模块,本文主要介绍了如何在单机版开启系统监控模块,并且使用Prometheus + Grafana完成系统监控的可视化。</p>
285+
<h1 id="相关配置信息"><a href="#相关配置信息" class="headerlink" title="相关配置信息"></a>相关配置信息</h1><ol>
288286
<li>Apache IoTDB:0.13.0,可以前往官网下载:<a target="_blank" rel="noopener" href="https://iotdb.apache.org/Download/">https://iotdb.apache.org/Download/</a></li>
289287
<li>Prometheus:2.30.3,可以前往官网下载:<a target="_blank" rel="noopener" href="https://prometheus.io/download/">https://prometheus.io/download/</a></li>
290288
<li>Grafana:8.4.2,可以前往官网下载:<a target="_blank" rel="noopener" href="https://grafana.com/grafana/download">https://grafana.com/grafana/download</a></li>
291289
</ol>
292-
<h1 id="修改配置文件启动iotdb"><a class="markdownIt-Anchor" href="#修改配置文件启动iotdb"></a> 修改配置文件,启动IoTDB</h1>
293-
<ol>
290+
<h1 id="修改配置文件,启动IoTDB"><a href="#修改配置文件,启动IoTDB" class="headerlink" title="修改配置文件,启动IoTDB"></a>修改配置文件,启动IoTDB</h1><ol>
294291
<li>首先,进入到<code>apache-iotdb-0.13.0-all-bin</code></li>
295292
<li>找到监控相关配置文件<code>conf/iotdb-metric.yml</code>,修改如下配置,其他配置保持不变:</li>
296293
</ol>
297294
<figure class="highlight yml"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br></pre></td><td class="code"><pre><code class="hljs yml"><span class="hljs-comment"># whether enable the module</span><br><span class="hljs-attr">enableMetric:</span> <span class="hljs-literal">true</span><br></code></pre></td></tr></table></figure>
298-
<ol start="3">
295+
<ol>
299296
<li>运行脚本启动IoTDB:<code>./sbin/start-server.sh</code>,出现如下提示则为启动成功</li>
300297
</ol>
301-
<p><img src="https://spricoder.oss-cn-shanghai.aliyuncs.com/Apache%20IoTDB/metric/introduce/1.png" srcset="/img/loading.gif" lazyload alt="" /></p>
302-
<ol start="4">
298+
<p><img src="https://spricoder.oss-cn-shanghai.aliyuncs.com/Apache%20IoTDB/metric/introduce/1.png" srcset="/img/loading.gif" lazyload alt=""></p>
299+
<ol>
303300
<li>在浏览器进入<code>http://localhost:9091/metrics</code>网址,可以查看到如下的监控项信息:</li>
304301
</ol>
305-
<p><img src="https://spricoder.oss-cn-shanghai.aliyuncs.com/Apache%20IoTDB/metric/introduce/2.png" srcset="/img/loading.gif" lazyload alt="" /></p>
306-
<h1 id="配置prometheus进行数据采集"><a class="markdownIt-Anchor" href="#配置prometheus进行数据采集"></a> 配置Prometheus进行数据采集</h1>
307-
<ol>
302+
<p><img src="https://spricoder.oss-cn-shanghai.aliyuncs.com/Apache%20IoTDB/metric/introduce/2.png" srcset="/img/loading.gif" lazyload alt=""></p>
303+
<h1 id="配置Prometheus进行数据采集"><a href="#配置Prometheus进行数据采集" class="headerlink" title="配置Prometheus进行数据采集"></a>配置Prometheus进行数据采集</h1><ol>
308304
<li>下载Prometheus的二进制包到本地,解压后进入对应文件夹:</li>
309305
</ol>
310306
<figure class="highlight sh"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br></pre></td><td class="code"><pre><code class="hljs sh">tar xvfz prometheus-*.tar.gz<br><span class="hljs-built_in">cd</span> prometheus-*<br></code></pre></td></tr></table></figure>
311-
<ol start="2">
307+
<ol>
312308
<li>首先,我们修改Prometheus的配置文件<code>prometheus.yml</code>如下:新增<code>iotdb</code>任务收集IoTDB的监控数据</li>
313309
</ol>
314310
<figure class="highlight yml"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br></pre></td><td class="code"><pre><code class="hljs yml"><span class="hljs-attr">global:</span><br> <span class="hljs-attr">scrape_interval:</span> <span class="hljs-string">15s</span><br><br><span class="hljs-attr">scrape_configs:</span><br> <span class="hljs-bullet">-</span> <span class="hljs-attr">job_name:</span> <span class="hljs-string">&quot;iotdb&quot;</span><br> <span class="hljs-attr">static_configs:</span><br> <span class="hljs-bullet">-</span> <span class="hljs-attr">targets:</span> [<span class="hljs-string">&quot;localhost:9091&quot;</span>]<br></code></pre></td></tr></table></figure>
315-
<ol start="3">
311+
<ol>
316312
<li>启动Promethues:</li>
317313
</ol>
318314
<figure class="highlight sh"><table><tr><td class="gutter"><pre><span class="line">1</span><br></pre></td><td class="code"><pre><code class="hljs sh">./prometheus --config.file=prometheus.yml<br></code></pre></td></tr></table></figure>
319-
<ol start="4">
320-
<li>在浏览器中输入 <a target="_blank" rel="noopener" href="http://localhost:9090">http://localhost:9090</a>,进入Prometheus</li>
315+
<ol>
316+
<li>在浏览器中输入 <a href="http://localhost:9090,进入Prometheus">http://localhost:9090,进入Prometheus</a></li>
321317
<li>查看配置是否成功:我们点击进入Status下的Target界面</li>
322318
</ol>
323-
<p><img src="https://spricoder.oss-cn-shanghai.aliyuncs.com/Apache%20IoTDB/metric/introduce/3.png" srcset="/img/loading.gif" lazyload alt="" /></p>
324-
<ol start="6">
319+
<p><img src="https://spricoder.oss-cn-shanghai.aliyuncs.com/Apache%20IoTDB/metric/introduce/3.png" srcset="/img/loading.gif" lazyload alt=""></p>
320+
<ol>
325321
<li>当我们看到如下图State为Up时表示配置成功并已经联通</li>
326322
</ol>
327-
<p><img src="https://spricoder.oss-cn-shanghai.aliyuncs.com/Apache%20IoTDB/metric/introduce/4.png" srcset="/img/loading.gif" lazyload alt="" /></p>
328-
<h1 id="使用grafana进行数据可视化"><a class="markdownIt-Anchor" href="#使用grafana进行数据可视化"></a> 使用Grafana进行数据可视化</h1>
329-
<h2 id="grafana启动与配置"><a class="markdownIt-Anchor" href="#grafana启动与配置"></a> Grafana启动与配置</h2>
330-
<ol>
323+
<p><img src="https://spricoder.oss-cn-shanghai.aliyuncs.com/Apache%20IoTDB/metric/introduce/4.png" srcset="/img/loading.gif" lazyload alt=""></p>
324+
<h1 id="使用Grafana进行数据可视化"><a href="#使用Grafana进行数据可视化" class="headerlink" title="使用Grafana进行数据可视化"></a>使用Grafana进行数据可视化</h1><h2 id="Grafana启动与配置"><a href="#Grafana启动与配置" class="headerlink" title="Grafana启动与配置"></a>Grafana启动与配置</h2><ol>
331325
<li>下载Grafana的二进制包到本地,解压后进入对应文件夹:</li>
332326
</ol>
333327
<figure class="highlight sh"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br></pre></td><td class="code"><pre><code class="hljs sh">tar -zxvf grafana-*.tar.gz<br><span class="hljs-built_in">cd</span> grafana-*<br></code></pre></td></tr></table></figure>
334-
<ol start="2">
328+
<ol>
335329
<li>启动Grafana:</li>
336330
</ol>
337331
<figure class="highlight sh"><table><tr><td class="gutter"><pre><span class="line">1</span><br></pre></td><td class="code"><pre><code class="hljs sh">./bin/grafana-server web <br></code></pre></td></tr></table></figure>
338-
<ol start="3">
339-
<li>在浏览器中输入 <a target="_blank" rel="noopener" href="http://localhost:3000">http://localhost:3000</a>,进入Prometheus</li>
332+
<ol>
333+
<li>在浏览器中输入 <a href="http://localhost:3000,进入Prometheus">http://localhost:3000,进入Prometheus</a></li>
340334
<li>首先我们在Configuration中配置Data Source为Prometheus</li>
341335
</ol>
342-
<p><img src="https://spricoder.oss-cn-shanghai.aliyuncs.com/Apache%20IoTDB/metric/introduce/5.png" srcset="/img/loading.gif" lazyload alt="" /></p>
343-
<ol start="5">
336+
<p><img src="https://spricoder.oss-cn-shanghai.aliyuncs.com/Apache%20IoTDB/metric/introduce/5.png" srcset="/img/loading.gif" lazyload alt=""></p>
337+
<ol>
344338
<li>在配置Data Source时注意Prometheus所在的URL,配置好后点击Save &amp; Test 出现Data source is working提示则为配置成功</li>
345339
</ol>
346-
<p><img src="https://spricoder.oss-cn-shanghai.aliyuncs.com/Apache%20IoTDB/metric/introduce/6.png" srcset="/img/loading.gif" lazyload alt="" /></p>
347-
<h2 id="在grafana中创建dashboard进行数据可视化"><a class="markdownIt-Anchor" href="#在grafana中创建dashboard进行数据可视化"></a> 在Grafana中创建Dashboard进行数据可视化</h2>
348-
<ol>
340+
<p><img src="https://spricoder.oss-cn-shanghai.aliyuncs.com/Apache%20IoTDB/metric/introduce/6.png" srcset="/img/loading.gif" lazyload alt=""></p>
341+
<h2 id="在Grafana中创建Dashboard进行数据可视化"><a href="#在Grafana中创建Dashboard进行数据可视化" class="headerlink" title="在Grafana中创建Dashboard进行数据可视化"></a>在Grafana中创建Dashboard进行数据可视化</h2><ol>
349342
<li>首先创建Dashboard,然后创建Panel</li>
350343
</ol>
351-
<p><img src="https://spricoder.oss-cn-shanghai.aliyuncs.com/Apache%20IoTDB/metric/introduce/7.png" srcset="/img/loading.gif" lazyload alt="" /></p>
352-
<ol start="2">
344+
<p><img src="https://spricoder.oss-cn-shanghai.aliyuncs.com/Apache%20IoTDB/metric/introduce/7.png" srcset="/img/loading.gif" lazyload alt=""></p>
345+
<ol>
353346
<li>之后就可以在面板根据自己的需求对监控相关的数据进行可视化(所有相关的监控指标可以先在job中选择iotdb筛选)</li>
354347
</ol>
355-
<p><img src="https://spricoder.oss-cn-shanghai.aliyuncs.com/Apache%20IoTDB/metric/introduce/8.png" srcset="/img/loading.gif" lazyload alt="" /></p>
356-
<ol start="3">
348+
<p><img src="https://spricoder.oss-cn-shanghai.aliyuncs.com/Apache%20IoTDB/metric/introduce/8.png" srcset="/img/loading.gif" lazyload alt=""></p>
349+
<ol>
357350
<li>选择关注的监控指标可视化完成后,我们就得到了这样的面板:</li>
358351
</ol>
359-
<p><img src="https://spricoder.oss-cn-shanghai.aliyuncs.com/Apache%20IoTDB/metric/introduce/9.png" srcset="/img/loading.gif" lazyload alt="" /></p>
352+
<p><img src="https://spricoder.oss-cn-shanghai.aliyuncs.com/Apache%20IoTDB/metric/introduce/9.png" srcset="/img/loading.gif" lazyload alt=""></p>
360353
<p>后续我们还会继续分享Apache IoTDB监控模块,敬请期待!</p>
361-
<h1 id="参考"><a class="markdownIt-Anchor" href="#参考"></a> 参考</h1>
362-
<p><a target="_blank" rel="noopener" href="https://iotdb.apache.org/UserGuide/Master/Maintenance-Tools/Metric-Tool.html">https://iotdb.apache.org/UserGuide/Master/Maintenance-Tools/Metric-Tool.html</a></p>
354+
<h1 id="参考"><a href="#参考" class="headerlink" title="参考"></a>参考</h1><p><a target="_blank" rel="noopener" href="https://iotdb.apache.org/UserGuide/Master/Maintenance-Tools/Metric-Tool.html">https://iotdb.apache.org/UserGuide/Master/Maintenance-Tools/Metric-Tool.html</a></p>
363355

364356

365357
</div>
@@ -405,7 +397,7 @@ <h1 id="参考"><a class="markdownIt-Anchor" href="#参考"></a> 参考</h1>
405397
<div class="license-box my-3">
406398
<div class="license-title">
407399
<div>一文带你使用Apache IoTDB系统监控模块</div>
408-
<div>https://spricoder.github.io/2022/04/06/Apache%20IoTDB/%E4%B8%80%E6%96%87%E5%B8%A6%E4%BD%A0%E4%BD%BF%E7%94%A8Apache%20IoTDB%E7%B3%BB%E7%BB%9F%E7%9B%91%E6%8E%A7/</div>
400+
<div>https://spricoder.github.io/2022/04/06/Apache%20IoTDB/metric/%E4%B8%80%E6%96%87%E5%B8%A6%E4%BD%A0%E4%BD%BF%E7%94%A8Apache%20IoTDB%E7%B3%BB%E7%BB%9F%E7%9B%91%E6%8E%A7/</div>
409401
</div>
410402
<div class="license-meta">
411403

2022/04/13/Spring-Boot/0-Spring-Boot-推荐阅读/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -539,7 +539,7 @@ <h1 id="7-spring-boot-框架问题"><a class="markdownIt-Anchor" href="#7-spring
539539
<article class="post-prev col-6">
540540

541541

542-
<a href="/2023/01/02/Apache%20IoTDB/How-to-Use-Cluster-Metric/" title="如何使用 Apache IoTDB 分布式系统监控">
542+
<a href="/2023/01/02/Apache%20IoTDB/metric/How-to-Use-Cluster-Metric/" title="如何使用 Apache IoTDB 分布式系统监控">
543543
<i class="iconfont icon-arrowleft"></i>
544544
<span class="hidden-mobile">如何使用 Apache IoTDB 分布式系统监控</span>
545545
<span class="visible-mobile">上一篇</span>

2022/04/13/Spring-Boot/1-Spring-Boot-基础/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -474,7 +474,7 @@ <h2 id="33-spring-mvc执行流程"><a class="markdownIt-Anchor" href="#33-spring
474474
<article class="post-next col-6">
475475

476476

477-
<a href="/2022/04/06/Apache%20IoTDB/%E4%B8%80%E6%96%87%E5%B8%A6%E4%BD%A0%E4%BD%BF%E7%94%A8Apache%20IoTDB%E7%B3%BB%E7%BB%9F%E7%9B%91%E6%8E%A7/" title="一文带你使用Apache IoTDB系统监控模块">
477+
<a href="/2022/04/06/Apache%20IoTDB/metric/%E4%B8%80%E6%96%87%E5%B8%A6%E4%BD%A0%E4%BD%BF%E7%94%A8Apache%20IoTDB%E7%B3%BB%E7%BB%9F%E7%9B%91%E6%8E%A7/" title="一文带你使用Apache IoTDB系统监控模块">
478478
<span class="hidden-mobile">一文带你使用Apache IoTDB系统监控模块</span>
479479
<span class="visible-mobile">下一篇</span>
480480
<i class="iconfont icon-arrowright"></i>

0 commit comments

Comments
 (0)