{"id":70452,"date":"2026-02-01T23:17:57","date_gmt":"2026-02-01T15:17:57","guid":{"rendered":"https:\/\/www.wsisp.com\/helps\/70452.html"},"modified":"2026-02-01T23:17:57","modified_gmt":"2026-02-01T15:17:57","slug":"%e5%91%8a%e5%88%ab%e6%9c%8d%e5%8a%a1%e5%99%a8%e5%a4%b1%e8%81%94%ef%bc%81prometheusalertmanagercpolar-%e8%ae%a9%e7%9b%91%e6%8e%a7%e5%91%8a%e8%ad%a6%e4%b8%8d%e5%b1%80%e9%99%90%e4%ba%8e%e5%86%85","status":"publish","type":"post","link":"https:\/\/www.wsisp.com\/helps\/70452.html","title":{"rendered":"\u544a\u522b\u670d\u52a1\u5668\u5931\u8054\uff01Prometheus+Alertmanager+cpolar \u8ba9\u76d1\u63a7\u544a\u8b66\u4e0d\u5c40\u9650\u4e8e\u5185\u7f51"},"content":{"rendered":"<p><img decoding=\"async\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260201151750-697f6e9e16204.png\" alt=\"\u5728\u8fd9\u91cc\u63d2\u5165\u56fe\u7247\u63cf\u8ff0\" \/><\/p>\n<p>Prometheus\u3001node_exporter\u3001Alertmanager \u8fd9\u5957\u76d1\u63a7\u7ec4\u5408&#xff0c;\u6838\u5fc3\u529f\u80fd\u8986\u76d6\u4e86\u670d\u52a1\u5668\u6307\u6807\u91c7\u96c6\u3001\u5f02\u5e38\u68c0\u6d4b\u4e0e\u544a\u8b66\u5206\u53d1&#xff0c;Prometheus \u53ef\u5b9e\u65f6\u6293\u53d6 CPU\u3001\u5185\u5b58\u7b49\u786c\u4ef6\u6570\u636e\u5e76\u81ea\u5b9a\u4e49\u544a\u8b66\u89c4\u5219&#xff0c;node_exporter \u8f7b\u91cf\u91c7\u96c6\u670d\u52a1\u5668\u72b6\u6001&#xff0c;Alertmanager \u5219\u80fd\u5206\u7c7b\u63a8\u9001\u544a\u8b66\u4fe1\u606f&#xff0c;\u9002\u5408\u4e2a\u4eba\u670d\u52a1\u5668\u6301\u6709\u8005\u3001\u5c0f\u56e2\u961f\u8fd0\u7ef4\u4eba\u5458\u4f7f\u7528&#xff0c;\u4f18\u70b9\u662f\u5f00\u6e90\u514d\u8d39\u3001\u914d\u7f6e\u7075\u6d3b&#xff0c;7\u00d724 \u5c0f\u65f6\u81ea\u52a8\u76d1\u63a7\u65e0\u9700\u4eba\u5de5\u503c\u5b88\u3002<\/p>\n<p>\u4f7f\u7528\u8fd9\u5957\u76d1\u63a7\u5de5\u5177\u65f6\u53d1\u73b0&#xff0c;\u9700\u6ce8\u610f\u544a\u8b66\u89c4\u5219\u7684\u9608\u503c\u8bbe\u7f6e\u8981\u8d34\u5408\u5b9e\u9645&#xff0c;\u6bd4\u5982 CPU \u544a\u8b66\u9608\u503c\u8bbe\u5f97\u8fc7\u4f4e\u6613\u89e6\u53d1\u65e0\u6548\u544a\u8b66&#xff0c;\u8fc7\u9ad8\u5219\u4f1a\u9057\u6f0f\u5f02\u5e38&#xff1b;\u53e6\u5916&#xff0c;\u521d\u6b21\u90e8\u7f72\u65f6\u82e5\u4e0d\u719f\u6089\u914d\u7f6e\u903b\u8f91&#xff0c;\u5bb9\u6613\u51fa\u73b0 Prometheus \u4e0e Alertmanager \u901a\u4fe1\u5931\u8d25\u7684\u60c5\u51b5&#xff0c;\u5efa\u8bae\u5148\u4ece\u7b80\u5355\u7684\u5b95\u673a\u544a\u8b66\u89c4\u5219\u5f00\u59cb\u8c03\u8bd5\u3002<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260201151751-697f6e9f53913.png\" alt=\"\u5728\u8fd9\u91cc\u63d2\u5165\u56fe\u7247\u63cf\u8ff0\" \/><\/p>\n<p>\u4f46\u8fd9\u5957\u5de5\u5177\u9ed8\u8ba4\u53ea\u80fd\u5728\u5c40\u57df\u7f51\u5185\u8bbf\u95ee&#xff0c;\u5e26\u6765\u4e86\u4e0d\u5c11\u9ebb\u70e6&#xff1a;\u6bd4\u5982\u4e2a\u4eba\u642d\u5efa\u7684\u5bb6\u7528\u670d\u52a1\u5668&#xff0c;\u51fa\u95e8\u5728\u5916\u65e2\u770b\u4e0d\u5230\u76d1\u63a7\u6570\u636e&#xff0c;\u4e5f\u6536\u4e0d\u5230\u53ca\u65f6\u544a\u8b66&#xff0c;\u53ea\u80fd\u7b49\u670d\u52a1\u5668\u51fa\u95ee\u9898\u540e\u88ab\u52a8\u53d1\u73b0&#xff1b;\u5c0f\u56e2\u961f\u91cc\u6210\u5458\u4e0d\u5728\u5185\u7f51\u73af\u5883\u65f6&#xff0c;\u4e5f\u65e0\u6cd5\u534f\u4f5c\u5904\u7406\u670d\u52a1\u5668\u5f02\u5e38&#xff0c;\u9519\u8fc7\u6700\u4f73\u6392\u67e5\u65f6\u673a\u3002<\/p>\n<p>\u800c\u5c06\u8fd9\u5957\u76d1\u63a7\u7cfb\u7edf\u4e0e cpolar \u7ed3\u5408\u540e&#xff0c;\u5f7b\u5e95\u89e3\u51b3\u4e86\u5c40\u57df\u7f51\u9650\u5236\u7684\u95ee\u9898\u3002\u65e0\u9700\u7533\u8bf7\u516c\u7f51 IP\u3001\u4e0d\u7528\u914d\u7f6e\u8def\u7531\u5668\u7aef\u53e3\u6620\u5c04&#xff0c;\u5c31\u80fd\u7ed9\u76d1\u63a7\u7cfb\u7edf\u5206\u914d\u516c\u7f51\u5730\u5740&#xff0c;\u4e0d\u7ba1\u662f\u5728\u5bb6\u8fd8\u662f\u5916\u51fa&#xff0c;\u624b\u673a\u3001\u5e73\u677f\u90fd\u80fd\u968f\u65f6\u67e5\u770b\u670d\u52a1\u5668\u72b6\u6001&#xff0c;\u56e2\u961f\u6210\u5458\u4e5f\u80fd\u901a\u8fc7\u516c\u7f51\u5730\u5740\u534f\u540c\u5904\u7406\u544a\u8b66&#xff0c;\u8ba9\u76d1\u63a7\u4ece \u201c\u672c\u5730\u53ef\u7528\u201d \u53d8\u6210 \u201c\u5168\u7f51\u53ef\u53ca\u201d\u3002<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260201151752-697f6ea0c5f56.png\" alt=\"\u5728\u8fd9\u91cc\u63d2\u5165\u56fe\u7247\u63cf\u8ff0\" \/><\/p>\n<h4>1&#043;1&#043;1&#043;1&#xff1e;4&#xff0c;\u8fd9\u5c31\u662f\u8f6f\u4ef6\u4e4b\u95f4\u7ec4\u5408\u7684\u9b45\u529b\u3002\u65b9\u6cd5\u5982\u4e0b&#xff0c;\u8bf7\u7b11\u7eb3&#x1f60a;<\/h4>\n<h3>1.\u5728Centos7\u4e0a\u5b89\u88c5Alertmanager<\/h3>\n<p>\u5728\u5b89\u88c5alertmanager\u524d\u9700\u8981\u5b89\u88c5node_exporter\u548cprometheus&#xff0c;\u6ca1\u6709\u5b89\u88c5\u7684\u5c0f\u4f19\u4f34\u53ef\u4ee5\u53c2\u8003\u8fd9\u7bc7\u6587\u7ae0&#xff01;<\/p>\n<p>prometheus&#xff1a;\u76d1\u63a7\u4e0d\u518d\u5c40\u57df\u7f51&#xff01;Cpolar \u8ba9 Prometheus \u8d70\u51fa\u5185\u7f51\u9650\u5236&#xff01; &#8211; cpolar \u6781\u70b9\u4e91\u5b98\u7f51<\/p>\n<p>node_exporter&#xff1a;\u65e0\u9700\u516c\u7f51IP:\u5229\u7528node_exporter\u548ccpolar\u5b9e\u73b0\u670d\u52a1\u5668\u72b6\u6001\u7684\u8fdc\u7a0b\u76d1\u63a7<\/p>\n<p>\u63a5\u4e0b\u6765\u8ddf\u6211\u8fdb\u5165\u76d1\u63a7\u544a\u8b66\u7684\u4e16\u754c\u5427&#xff01;<\/p>\n<p>\u53bb\u5b98\u7f51\u4e0b\u8f7d\u5b89\u88c5\u6587\u4ef6&#xff1a;https:\/\/prometheus.io\/download\/<\/p>\n<p>\u627e\u5230linux\u7248&#xff0c;\u4e0b\u8f7d&#xff1a;<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260201151754-697f6ea23a70d.png\" alt=\"761b1e9a0f02ded41caeaea93e32d864\" \/><\/p>\n<p>\u4e0b\u8f7d\u5b8c\u6210\u540e\u8bb0\u4f4f\u4e0b\u8f7d\u8def\u5f84\u3002<\/p>\n<p>\u521b\u5efaalertmanager\u7684\u76ee\u5f55&#xff1a;<\/p>\n<p><span class=\"token function\">mkdir<\/span> -p \/app\/alertmanager<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260201151754-697f6ea26a7b5.png\" alt=\"f8c717b425a395107773cf778bd8d6b8\" \/><\/p>\n<p>\u8fdb\u5165\u5230\u8fd9\u4e2a\u76ee\u5f55&#xff1a;<\/p>\n<p><span class=\"token builtin class-name\">cd<\/span> \/app\/alertmanager<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260201151754-697f6ea273ca0.png\" alt=\"94ecb4db880bb7bf6ae9aca7d7910084\" \/><\/p>\n<p>\u624b\u52a8\u4e0a\u4f20\u4e0b\u8f7d\u597d\u7684alertmanager\u6587\u4ef6\u3002<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260201151754-697f6ea27dbc0.png\" alt=\"fe4692990117466cc90b00ba65d33f83\" \/><\/p>\n<p><img decoding=\"async\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260201151754-697f6ea283a2a.png\" alt=\"044d074a697f7f58fa3b334bc2b19073\" \/><\/p>\n<p><img decoding=\"async\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260201151754-697f6ea2abe18.png\" alt=\"36051d12c8d2ff92181d77519c859366\" \/><\/p>\n<p>\u4e0a\u4f20\u6210\u529f\u540e\u89e3\u538b&#xff1a;<\/p>\n<p><span class=\"token function\">tar<\/span> -vxzf alertmanager-0.28.1.linux-amd64.tar.gz<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260201151754-697f6ea2b4375.png\" alt=\"f90907fcfee2cffaea4a840fbee5f8b3\" \/><\/p>\n<p>\u6539\u540d\u65b9\u4fbf\u8bb0\u5fc6&#xff1a;<\/p>\n<p><span class=\"token function\">mv<\/span> alertmanager-0.28.1.linux-amd64 alertmanager<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260201151754-697f6ea2be88f.png\" alt=\"af6d82c62279373693371737d0f54502\" \/><\/p>\n<p>\u5c06Altermanager\u914d\u7f6e\u4e3a\u7cfb\u7edf\u670d\u52a1:<\/p>\n<p><span class=\"token builtin class-name\">cd<\/span> \/usr\/lib\/systemd\/system<\/p>\n<p><span class=\"token function\">vim<\/span> alertmanager.service<\/p>\n<p><span class=\"token punctuation\">[<\/span>Unit<span class=\"token punctuation\">]<\/span><br \/>\n<span class=\"token assign-left variable\">Description<\/span><span class=\"token operator\">&#061;<\/span>https:\/\/prometheus.io<\/p>\n<p><span class=\"token punctuation\">[<\/span>Service<span class=\"token punctuation\">]<\/span><br \/>\n<span class=\"token assign-left variable\">Restart<\/span><span class=\"token operator\">&#061;<\/span>on-failure<br \/>\n<span class=\"token assign-left variable\">ExecStart<\/span><span class=\"token operator\">&#061;<\/span>\/app\/alertmanager\/alertmanager &#8211;config.file<span class=\"token operator\">&#061;<\/span>\/app\/alertmanager\/alertmanager.yml<\/p>\n<p><span class=\"token punctuation\">[<\/span>Install<span class=\"token punctuation\">]<\/span><br \/>\n<span class=\"token assign-left variable\">WantedBy<\/span><span class=\"token operator\">&#061;<\/span>multi-user.target<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260201151754-697f6ea2c83fd.png\" alt=\"59dc63e6bcee33da5b24b5d6358c2e2e\" \/><\/p>\n<p>\u52a0\u8f7dsystem\u6587\u4ef6&#xff0c;\u542f\u52a8alertmanager\u8fd9\u4e2a\u670d\u52a1&#xff0c;\u5e76\u8bbe\u7f6e\u5f00\u673a\u542f\u52a8&#xff1a;<\/p>\n<p>systemctl daemon-reload<br \/>\nsystemctl start alertmanager.service<br \/>\nsystemctl <span class=\"token builtin class-name\">enable<\/span> alertmanager.service<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260201151754-697f6ea2d7507.png\" alt=\"b0e1e9484b6e2b3d6030d33858bb96c2\" \/><\/p>\n<p>\u4e5f\u53ef\u4ee5\u540e\u53f0\u624b\u52a8\u542f\u52a8&#xff1a;<\/p>\n<p><span class=\"token function\">nohup<\/span> .\/alertmanager &#8211;config.file<span class=\"token operator\">&#061;<\/span>alertmanager.yml <span class=\"token operator\">&gt;&gt;<\/span> \/app\/alertmanager\/alertmanager\/alertmanager.out <span class=\"token operator\"><span class=\"token file-descriptor important\">2<\/span>&gt;<\/span><span class=\"token file-descriptor important\">&amp;1<\/span> <span class=\"token operator\">&amp;<\/span><br \/>\n<span class=\"token function\">cat<\/span> alertmanager.out<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260201151754-697f6ea2ebf7b.png\" alt=\"4bf5cbad0d069199181e2444efe8db21\" \/><\/p>\n<p>\u542f\u52a8\u6210\u529f\u540e&#xff0c;\u8bbf\u95eeAltermanager&#xff0c;ip&#043;9093&#xff0c;\u9ed8\u8ba4\u7aef\u53e3\u4e3a 9093\u3002<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260201151755-697f6ea32a160.png\" alt=\"737d29235bf3c4e7a16ec3486d097511\" \/><\/p>\n<p>\u5047\u5982&#xff0c;\u6211\u4eec\u60f3\u7528\u624b\u673a\u6216\u8005\u5e73\u677f&#xff0c;\u968f\u65f6\u968f\u5730\u53ef\u4ee5\u67e5\u770b\u544a\u8b66\u6d88\u606f&#xff0c;\u6211\u4eec\u5e94\u8be5\u600e\u4e48\u505a\u5462&#xff1f;\u63a5\u4e0b\u6765cpolar\u5c31\u6d3e\u4e0a\u7528\u573a\u5566&#xff01;<\/p>\n<h3>2.\u5b89\u88c5cpolar\u5b9e\u73b0\u968f\u65f6\u968f\u5730\u5f00\u53d1<\/h3>\n<p>cpolar \u53ef\u4ee5\u5c06\u4f60\u672c\u5730\u7535\u8111\u4e2d\u7684\u670d\u52a1&#xff08;\u5982 SSH\u3001Web\u3001\u6570\u636e\u5e93&#xff09;\u6620\u5c04\u5230\u516c\u7f51\u3002\u5373\u4f7f\u4f60\u5728\u5bb6\u91cc\u6216\u5916\u51fa\u65f6&#xff0c;\u4e5f\u53ef\u4ee5\u901a\u8fc7\u516c\u7f51\u5730\u5740\u8fde\u63a5\u56de\u672c\u5730\u8fd0\u884c\u7684\u5f00\u53d1\u73af\u5883\u3002<\/p>\n<p>\u2764\ufe0f\u4ee5\u4e0b\u662f\u5b89\u88c5cpolar\u6b65\u9aa4&#xff1a;<\/p>\n<p>\u5b98\u7f51\u5728\u6b64&#xff1a;https:\/\/www.cpolar.com<\/p>\n<p>\u4f7f\u7528\u4e00\u952e\u811a\u672c\u5b89\u88c5\u547d\u4ee4&#xff1a;<\/p>\n<p><span class=\"token function\">sudo<\/span> <span class=\"token function\">curl<\/span> https:\/\/get.cpolar.sh <span class=\"token operator\">|<\/span> <span class=\"token function\">sh<\/span><\/p>\n<p><img decoding=\"async\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260201151755-697f6ea3b217e.png\" alt=\"4dd1a1c4a992b859e849d305dcb43014\" \/><\/p>\n<p>\u5b89\u88c5\u5b8c\u6210\u540e&#xff0c;\u6267\u884c\u4e0b\u65b9\u547d\u4ee4\u67e5\u770bcpolar\u670d\u52a1\u72b6\u6001&#xff1a;&#xff08;\u5982\u56fe\u6240\u793a\u5373\u4e3a\u6b63\u5e38\u542f\u52a8&#xff09;<\/p>\n<p><span class=\"token function\">sudo<\/span> systemctl status cpolar<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260201151755-697f6ea3c7203.png\" alt=\"22e5adfaf290a17fc3384bb296055259\" \/><\/p>\n<p>Cpolar\u5b89\u88c5\u548c\u6210\u529f\u542f\u52a8\u670d\u52a1\u540e&#xff0c;\u5728\u6d4f\u89c8\u5668\u4e0a\u8f93\u5165\u865a\u62df\u673a\u4e3b\u673aIP\u52a09200\u7aef\u53e3\u5373:\u3010http:\/\/192.168.42.101:9200\u3011\u8bbf\u95eeCpolar\u7ba1\u7406\u754c\u9762&#xff0c;\u4f7f\u7528Cpolar\u5b98\u7f51\u6ce8\u518c\u7684\u8d26\u53f7\u767b\u5f55,\u767b\u5f55\u540e\u5373\u53ef\u770b\u5230cpolar web \u914d\u7f6e\u754c\u9762,\u63a5\u4e0b\u6765\u5728web \u754c\u9762\u914d\u7f6e\u5373\u53ef&#xff1a;<\/p>\n<p>\u6253\u5f00\u6d4f\u89c8\u5668\u8bbf\u95ee\u672c\u57309200\u7aef\u53e3&#xff0c;\u4f7f\u7528cpolar\u8d26\u6237\u5bc6\u7801\u767b\u5f55\u5373\u53ef,\u767b\u5f55\u540e\u5373\u53ef\u5bf9\u96a7\u9053\u8fdb\u884c\u7ba1\u7406\u3002<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260201151755-697f6ea3e4774.png\" alt=\"8a6698b1bf26d64ba3645827fbfb1c29\" \/><\/p>\n<h3>3.\u914d\u7f6e\u516c\u7f51\u5730\u5740<\/h3>\n<p>\u767b\u5f55cpolar web UI\u7ba1\u7406\u754c\u9762\u540e,\u70b9\u51fb\u5de6\u4fa7\u4eea\u8868\u76d8\u7684\u96a7\u9053\u7ba1\u7406\u2014\u2014\u521b\u5efa\u96a7\u9053&#xff1a;<\/p>\n<ul>\n<li>\n<p>\u96a7\u9053\u540d\u79f0&#xff1a;\u53ef\u81ea\u5b9a\u4e49&#xff0c;\u672c\u4f8b\u4f7f\u7528\u4e86:alertmanager&#xff0c;\u6ce8\u610f\u4e0d\u8981\u4e0e\u5df2\u6709\u7684\u96a7\u9053\u540d\u79f0\u91cd\u590d<\/p>\n<\/li>\n<li>\n<p>\u534f\u8bae&#xff1a;http<\/p>\n<\/li>\n<li>\n<p>\u672c\u5730\u5730\u5740&#xff1a;9093<\/p>\n<\/li>\n<li>\n<p>\u57df\u540d\u7c7b\u578b&#xff1a;\u968f\u673a\u57df\u540d<\/p>\n<\/li>\n<li>\n<p>\u5730\u533a&#xff1a;\u9009\u62e9China Top<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260201151756-697f6ea435cfa.png\" alt=\"image-20250820160631504\" \/><\/p>\n<\/li>\n<\/ul>\n<p>\u521b\u5efa\u6210\u529f\u540e&#xff0c;\u6253\u5f00\u5de6\u4fa7\u5728\u7ebf\u96a7\u9053\u5217\u8868,\u53ef\u4ee5\u770b\u5230\u521a\u521a\u901a\u8fc7\u521b\u5efa\u96a7\u9053\u751f\u6210\u4e86\u516c\u7f51\u5730\u5740&#xff0c;\u63a5\u4e0b\u6765\u5c31\u53ef\u4ee5\u5728\u5176\u4ed6\u7535\u8111\u6216\u8005\u79fb\u52a8\u7aef\u8bbe\u5907&#xff08;\u5f02\u5730&#xff09;\u4e0a&#xff0c;\u4f7f\u7528\u5730\u5740\u8bbf\u95ee\u3002<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260201151756-697f6ea466506.png\" alt=\"image-20250820160715032\" \/><\/p>\n<p>\u8bbf\u95ee\u6210\u529f\u3002<\/p>\n<p><img decoding=\"async\" src=\"2026-02-01d2plziyjqik.png\" alt=\"image-20250820160752997\" \/><\/p>\n<h3>4.\u5728prometheus\u4e0a\u914d\u7f6ealertmanager<\/h3>\n<p>\u8fdb\u5165prometheus\u7684\u914d\u7f6e\u6587\u4ef6&#xff0c;\u52a0\u5165alertmanager\u544a\u8b66\u89c4\u5219&#xff1a;<\/p>\n<p><span class=\"token function\">vi<\/span> \/app\/prometheus\/prometheus.yml<\/p>\n<p>\u52a0\u5165\u4ee5\u4e0b\u5185\u5bb9\u540e&#xff1a;Prometheus\u53ef\u4ee5\u901a\u8fc7\u8fd9\u4e2a\u516c\u7f51\u5730\u57404246d47e.r2.cpolar.top&#xff08;\u521a\u624d\u7528cpolar\u6253\u901a\u7684\u516c\u7f51\u5730\u5740&#xff0c;\u4e5f\u53ef\u4ee5\u7528localhost:9093&#xff09;\u8bbf\u95ee\u5230\u8fd0\u884c\u5728\u672c\u57309093\u7aef\u53e3\u7684Alertmanager\u670d\u52a1&#xff0c;\u4ece\u800c\u6293\u53d6\u7cfb\u7edf\u6307\u6807\u3002<\/p>\n<p>      &#8211; targets: <span class=\"token punctuation\">[<\/span><span class=\"token string\">&#034;4246d47e.r2.cpolar.top&#034;<\/span><span class=\"token punctuation\">]<\/span><br \/>\n        labels:<br \/>\n          app: <span class=\"token string\">&#034;alertmanager&#034;<\/span><\/p>\n<p>\u8fd9\u4e00\u6b65\u914d\u7f6e\u7684\u4f5c\u7528\u662f&#xff1a;\u544a\u8bc9 Prometheus&#xff0c;\u5f53\u76d1\u63a7\u89c4\u5219\u89e6\u53d1\u544a\u8b66\u65f6&#xff0c;\u5e94\u8be5\u628a\u544a\u8b66\u4fe1\u606f\u53d1\u9001\u5230\u54ea\u4e2a Alertmanager \u670d\u52a1\u8fdb\u884c\u5904\u7406&#xff08;\u4fbf\u4e8e\u4e00\u4f1a\u76d1\u63a7node_exporter&#xff0c;\u4e5f\u53ef\u4ee5\u76d1\u63a7mysqld_exporter\u7b49\u7b49&#xff09;\u3002<\/p>\n<p>alerting:<br \/>\n  alertmanagers:<br \/>\n    &#8211; static_configs:<br \/>\n        &#8211; targets: <span class=\"token punctuation\">[<\/span><span class=\"token string\">&#034;4246d47e.r2.cpolar.top&#034;<\/span><span class=\"token punctuation\">]<\/span><\/p>\n<p><img decoding=\"async\" src=\"2026-02-01oozbn4nmjil.png\" alt=\"image-20250820161344244\" \/><\/p>\n<p>\u91cd\u65b0\u542f\u52a8prometheus&#xff1a;<\/p>\n<p>systemctl restart prometheus<\/p>\n<p>\u6293\u53d6\u6210\u529f&#xff01;<\/p>\n<p><img decoding=\"async\" src=\"2026-02-01qbb2xpz14yg.png\" alt=\"image-20250820162324249\" \/><\/p>\n<h3>5.\u5229\u7528alertmanager\u6765\u914d\u7f6enode_exporter\u544a\u8b66<\/h3>\n<p>\u5728\u7b2c\u56db\u7ae0\u8282&#xff0c;\u6211\u4eec\u5df2\u7ecf\u6210\u529f\u914d\u7f6e\u544a\u8b66\u4fe1\u606f\u53d1\u9001\u5230alertmanager&#xff0c;\u63a5\u4e0b\u6765\u6211\u4eec\u6765\u9a8c\u8bc1\u4e00\u4e0b&#xff0c;\u662f\u5426\u53ef\u4ee5\u6210\u529f\u53d1\u9001&#xff01;<\/p>\n<p>\u6211\u4eec\u8fd9\u91cc\u4e3e\u4f8b&#xff0c;\u5018\u82e5node_exporter\u5173\u95ed\u5219\u53d1\u9001\u544a\u8b66\u3002<\/p>\n<p>node_exporter\u8fd8\u53ef\u4ee5\u76d1\u63a7\u4e3b\u673a\u7684 CPU \u4f7f\u7528\u7387&#xff0c;\u5185\u5b58\u4f7f\u7528\u91cf&#xff0c;\u6587\u4ef6\u7cfb\u7edf\u7528\u91cf\u7b49\u7b49\u3002<\/p>\n<p>\u6211\u4eec\u5148\u6539\u5199prometheus\u7684\u914d\u7f6e\u6587\u4ef6&#xff0c;\u6539\u4ee5\u4e0b\u5185\u5bb9&#xff1a;<\/p>\n<p><span class=\"token function\">vi<\/span> \/app\/prometheus\/promethues.yml<\/p>\n<p><img decoding=\"async\" src=\"2026-02-01yx0iddqi415.png\" alt=\"23fec955b3a101ae95c1a5ce836c15f2\" \/><\/p>\n<p>\u8fdb\u5165\u5230prometheus\u914d\u7f6e\u76ee\u5f55\u4e0b&#xff0c;\u5199\u4e00\u4e2a\u914d\u7f6e\u6587\u4ef61.yml&#xff1a;<\/p>\n<p><span class=\"token function\">vi<\/span> \/app\/prometheus\/1.yml<\/p>\n<p>groups:<br \/>\n&#8211; name: node-alerts<br \/>\n  rules:<br \/>\n  <span class=\"token comment\"># \u5b9e\u4f8b\u5b95\u673a<\/span><br \/>\n  &#8211; alert: node_exporter\u5b9e\u4f8b\u5b95\u673a<br \/>\n    expr: up<span class=\"token punctuation\">{<\/span>job<span class=\"token operator\">&#061;<\/span><span class=\"token string\">&#034;node_exporter&#034;<\/span>,instance<span class=\"token operator\">&#061;<\/span><span class=\"token string\">&#034;localhost:9100&#034;<\/span><span class=\"token punctuation\">}<\/span> <span class=\"token operator\">&#061;&#061;<\/span> <span class=\"token number\">0<\/span><br \/>\n    for: 15s<br \/>\n    labels:<br \/>\n      severity: critical<br \/>\n    annotations:<br \/>\n      summary: <span class=\"token string\">&#034;\u5b9e\u4f8b {{ <span class=\"token variable\">$labels<\/span>.instance }} \u5df2\u505c\u6b62\u8fd0\u884c\u8d85\u8fc7 15 \u79d2&#xff01;&#034;<\/span><br \/>\n      description: <span class=\"token string\">&#034;\u4f5c\u4e1a {{ <span class=\"token variable\">$labels<\/span>.job }} \u7684\u5b9e\u4f8b {{ <span class=\"token variable\">$labels<\/span>.instance }} \u65e0\u6cd5\u6293\u53d6\u3002&#034;<\/span><br \/>\n&#8211; name: prometheus<br \/>\n  rules:<br \/>\n  <span class=\"token comment\"># \u5b9e\u4f8b\u5b95\u673a<\/span><br \/>\n  &#8211; alert: \u5b9e\u4f8b\u5b95\u673a<br \/>\n    expr: up<span class=\"token punctuation\">{<\/span>job<span class=\"token operator\">&#061;<\/span><span class=\"token string\">&#034;prometheus&#034;<\/span><span class=\"token punctuation\">}<\/span> <span class=\"token operator\">&#061;&#061;<\/span> <span class=\"token number\">0<\/span><br \/>\n    for: 15s<br \/>\n    labels:<br \/>\n      severity: critical<br \/>\n    annotations:<br \/>\n      summary: <span class=\"token string\">&#034;\u5b9e\u4f8b {{ <span class=\"token variable\">$labels<\/span>.instance }} \u5df2\u505c\u6b62\u8fd0\u884c\u8d85\u8fc7 15 \u79d2&#xff01;&#034;<\/span><br \/>\n      description: <span class=\"token string\">&#034;\u4f5c\u4e1a {{ <span class=\"token variable\">$labels<\/span>.job }} \u7684\u5b9e\u4f8b {{ <span class=\"token variable\">$labels<\/span>.instance }} \u65e0\u6cd5\u6293\u53d6\u3002&#034;<\/span><\/p>\n<p><img decoding=\"async\" src=\"2026-02-012zhmhyqruid.png\" alt=\"f292d77a12edffc887e26bfb63a48b7a\" \/><\/p>\n<p>\u91cd\u542fprometheus&#xff1a;<\/p>\n<p>systemctl restart prometheus<\/p>\n<p>\u6253\u5f00prometheus\u7f51\u9875&#xff0c;\u53d1\u73b0\u52a0\u5165\u6210\u529f\u3002<\/p>\n<p><img decoding=\"async\" src=\"2026-02-01trh4qwchwyy.png\" alt=\"image-20250820163514504\" \/><\/p>\n<p>\u63a5\u4e0b\u6765&#xff0c;\u6211\u4eec\u9a8c\u8bc1\u4e00\u4e0b&#xff0c;\u5173\u95ednode_exporter&#xff0c;\u4f1a\u4e0d\u4f1a\u544a\u8b66&#xff1a;<\/p>\n<p>systemctl stop node_exporter<\/p>\n<p><img decoding=\"async\" src=\"2026-02-015czmh1mvm15.png\" alt=\"b89182bfc1e62f8169f5c591577709fc\" \/><\/p>\n<p>\u518d\u6b21\u6253\u5f00prometheus\u7f51\u9875&#xff0c;\u544a\u8b66\u6210\u529f&#xff1a;<\/p>\n<p><img decoding=\"async\" src=\"2026-02-01ufzfbzvv440.png\" alt=\"image-20250820163952571\" \/><\/p>\n<p>\u6253\u5f00alertmanager\u7f51\u9875&#xff0c;\u6211\u4eec\u53d1\u73b0\u90a3\u4e24\u6761\u544a\u8b66\u4e5f\u663e\u793a\u6210\u529f\u3002<\/p>\n<p><img decoding=\"async\" src=\"2026-02-01ailtsu05wlw.png\" alt=\"image-20250820164333859\" \/><\/p>\n<p>\u8fd9\u6837\u6211\u4eec\u5c31\u6210\u529f\u914d\u7f6eprometheus\u544a\u8b66\u5566&#xff01;<\/p>\n<h3>6.\u4f7f\u7528Alertmanager\u53d1\u9001\u670d\u52a1\u5668\u544a\u8b66\u81f3QQ\u90ae\u7bb1<\/h3>\n<p>QQ \u90ae\u7bb1\u9ed8\u8ba4\u4e0d\u5141\u8bb8\u5916\u90e8\u5e94\u7528\u76f4\u63a5\u4f7f\u7528\u5bc6\u7801\u767b\u5f55SMTP\u670d\u52a1\u5668&#xff0c;\u56e0\u6b64\u4f60\u9700\u8981\u83b7\u53d6\u4e00\u4e2a\u6388\u6743\u7801&#xff1a;<\/p>\n<ul>\n<li>\u767b\u5f55QQ \u90ae\u7bb1&#xff0c;\u8fdb\u5165\u8bbe\u7f6e -&gt; \u8d26\u6237\u3002<\/li>\n<li>\u627e\u5230 SMTP\/IMAP\/POP3\/Exchange \u670d\u52a1&#xff0c;\u5f00\u542f SMTP \u670d\u52a1\u3002<\/li>\n<li>\u5f00\u542f\u540e&#xff0c;\u4f1a\u63d0\u793a\u4f60\u83b7\u53d6\u4e00\u4e2a\u6388\u6743\u7801\u3002<\/li>\n<\/ul>\n<p><img decoding=\"async\" src=\"2026-02-01wzfrx5513oo.png\" alt=\"b4188ced377a1f22dee5d12fb14f0f8f\" \/><\/p>\n<p><img decoding=\"async\" src=\"2026-02-01todntal3ch4.png\" alt=\"59e1c190c33df3f374338acba306985e\" \/><\/p>\n<p><img decoding=\"async\" src=\"2026-02-01rxxuetg0vgx.png\" alt=\"f9c9f7206ec378e2ebc82c24e02957e3\" \/><\/p>\n<p>\u63a5\u4e0b\u6765&#xff0c;\u6211\u4eec\u8fdb\u5165alertmanager\u5b89\u88c5\u76ee\u5f55&#xff0c;\u4fee\u6539alertmanager\u914d\u7f6e\u6587\u4ef6alertmanager.yml&#xff1a;<\/p>\n<p><span class=\"token function\">vi<\/span> \/app\/alertmanager\/alertmanager\/alertmanager.yml<\/p>\n<p>\u6dfb\u52a0\u4ee5\u4e0b\u5185\u5bb9\u6765\u914d\u7f6e\u544a\u8b66\u89c4\u5219&#xff1a;<\/p>\n<p>global:<br \/>\n  resolve_timeout: 5m<br \/>\n  smtp_from: <span class=\"token string\">&#039;\u4f60\u7684QQ\u90ae\u7bb1&#039;<\/span><br \/>\n  smtp_smarthost: <span class=\"token string\">&#039;smtp.qq.com:465&#039;<\/span><br \/>\n  smtp_auth_username: <span class=\"token string\">&#039;\u4f60\u7684QQ\u90ae\u7bb1&#039;<\/span><br \/>\n  smtp_auth_password: <span class=\"token string\">&#039;\u4f60\u7684QQ\u90ae\u7bb1\u6388\u6743\u7801&#039;<\/span><br \/>\n  smtp_require_tls: <span class=\"token boolean\">false<\/span><br \/>\n  smtp_hello: <span class=\"token string\">&#039;qq.com&#039;<\/span><\/p>\n<p>route:<br \/>\n  group_by: <span class=\"token punctuation\">[<\/span><span class=\"token string\">&#039;alertname&#039;<\/span><span class=\"token punctuation\">]<\/span><br \/>\n  group_wait: 5s<br \/>\n  group_interval: 5s<br \/>\n  repeat_interval: 5m<br \/>\n  receiver: <span class=\"token string\">&#039;email&#039;<\/span><\/p>\n<p>receivers:<br \/>\n&#8211; name: <span class=\"token string\">&#039;email&#039;<\/span><br \/>\n  email_configs:<br \/>\n  &#8211; to: <span class=\"token string\">&#039;\u4f60\u7684QQ\u90ae\u7bb1&#039;<\/span><br \/>\n    send_resolved: <span class=\"token boolean\">true<\/span><\/p>\n<p><img decoding=\"async\" src=\"2026-02-01j02niho4zut.png\" alt=\"c09676a8fb0e2127a78eb8c2d9d5a144\" \/><\/p>\n<p>\u8fd9\u6837\u6709\u544a\u8b66\u6d88\u606f\u5c31\u53ef\u4ee5\u53d1\u9001\u5230QQ\u90ae\u7bb1\u5566&#xff01;<\/p>\n<p>\u6211\u4eec\u6765\u9a8c\u8bc1\u4e00\u4e0b&#xff0c;\u914d\u7f6e\u6709\u6ca1\u6709\u95ee\u9898&#xff1a;<\/p>\n<p>.\/alertmanager &#8211;config.file<span class=\"token operator\">&#061;<\/span>alertmanager.yml &#8211;log.level<span class=\"token operator\">&#061;<\/span>debug<\/p>\n<p>\u624b\u52a8\u8fd0\u884c\u6d4b\u8bd5&#xff0c;\u6ca1\u62a5\u9519\u5373\u6b63\u786e&#xff01;<\/p>\n<p><img decoding=\"async\" src=\"2026-02-01t3fnw5xj14b.png\" alt=\"e97ebe6d94284ca4025ad5d85664f3e3\" \/><\/p>\n<p>\u91cd\u542falertmanager&#xff1a;<\/p>\n<p>systemctl restart alertmanager<br \/>\nsystemctl status alertmanager<\/p>\n<p><img decoding=\"async\" src=\"2026-02-01pbwedjvr1sj.png\" alt=\"6cc7b74df7722d9c71fb3b1d934bcd86\" \/><\/p>\n<p>\u767b\u5f55\u90ae\u7bb1\u67e5\u770b&#xff0c;node_exporter\u6302\u673a\u662f\u5426\u53d1\u90ae\u4ef6&#xff1a;<\/p>\n<p><img decoding=\"async\" src=\"2026-02-01egqsahn2bdu.png\" alt=\"2c07dc281f66cbfb77f17aa35eb1f5bf\" \/><\/p>\n<p>\u63a5\u6536\u5230\u90ae\u4ef6&#xff0c;\u8bf4\u660e\u6211\u4eec\u914d\u7f6e\u6b63\u786e&#xff01;<\/p>\n<p>\u8fd9\u6837\u6211\u4eec\u5c31\u53ef\u4ee5\u968f\u65f6\u968f\u5730\u67e5\u770b\u544a\u8b66\u4fe1\u606f\u4e86&#xff01;<\/p>\n<h3>7.\u4fdd\u7559\u56fa\u5b9a\u516c\u7f51\u5730\u5740<\/h3>\n<p>\u4f7f\u7528cpolar\u4e3a\u5176\u914d\u7f6e\u4e8c\u7ea7\u5b50\u57df\u540d&#xff0c;\u8be5\u5730\u5740\u4e3a\u56fa\u5b9a\u5730\u5740&#xff0c;\u4e0d\u4f1a\u968f\u673a\u53d8\u5316\u3002<\/p>\n<p><img decoding=\"async\" src=\"2026-02-01qcljvwnb31w.png\" alt=\"image-20250820165519668\" \/><\/p>\n<p>\u70b9\u51fb\u5de6\u4fa7\u7684\u9884\u7559&#xff0c;\u9009\u62e9\u4fdd\u7559\u4e8c\u7ea7\u5b50\u57df\u540d&#xff0c;\u5730\u533a\u9009\u62e9china Top&#xff0c;\u7136\u540e\u8bbe\u7f6e\u4e00\u4e2a\u4e8c\u7ea7\u5b50\u57df\u540d\u540d\u79f0&#xff0c;\u6211\u8fd9\u91cc\u6f14\u793a\u4f7f\u7528\u7684\u662falertmanager&#xff0c;\u5927\u5bb6\u53ef\u4ee5\u81ea\u5b9a\u4e49\u3002\u586b\u5199\u5907\u6ce8\u4fe1\u606f&#xff0c;\u70b9\u51fb\u4fdd\u7559\u3002<\/p>\n<p><img decoding=\"async\" src=\"2026-02-013l0p45aavgg.png\" alt=\"image-20250820165619773\" \/><\/p>\n<p>\u767b\u5f55cpolar web UI\u7ba1\u7406\u754c\u9762&#xff0c;\u70b9\u51fb\u5de6\u4fa7\u4eea\u8868\u76d8\u7684\u96a7\u9053\u7ba1\u7406\u2014\u2014\u96a7\u9053\u5217\u8868&#xff0c;\u627e\u5230\u6240\u8981\u914d\u7f6e\u7684\u96a7\u9053alertmanager&#xff0c;\u70b9\u51fb\u53f3\u4fa7\u7684\u7f16\u8f91\u3002<\/p>\n<p><img decoding=\"async\" src=\"2026-02-01zjqqup15az2.png\" alt=\"image-20250820165703610\" \/><\/p>\n<p>\u4fee\u6539\u96a7\u9053\u4fe1\u606f&#xff0c;\u5c06\u4fdd\u7559\u6210\u529f\u7684\u4e8c\u7ea7\u5b50\u57df\u540d\u914d\u7f6e\u5230\u96a7\u9053\u4e2d<\/p>\n<ul>\n<li>\u57df\u540d\u7c7b\u578b&#xff1a;\u9009\u62e9\u4e8c\u7ea7\u5b50\u57df\u540d<\/li>\n<li>Sub Domain&#xff1a;\u586b\u5199\u4fdd\u7559\u6210\u529f\u7684\u4e8c\u7ea7\u5b50\u57df\u540d<\/li>\n<li>\u5730\u533a: China Top<\/li>\n<\/ul>\n<p>\u70b9\u51fb\u66f4\u65b0<\/p>\n<p><img decoding=\"async\" src=\"2026-02-01j0tiqlyfztd.png\" alt=\"image-20250820165758226\" \/><\/p>\n<p>\u66f4\u65b0\u5b8c\u6210\u540e&#xff0c;\u6253\u5f00\u5728\u7ebf\u96a7\u9053\u5217\u8868&#xff0c;\u6b64\u65f6\u53ef\u4ee5\u770b\u5230\u968f\u673a\u7684\u516c\u7f51\u5730\u5740\u5df2\u7ecf\u53d1\u751f\u53d8\u5316&#xff0c;\u5730\u5740\u540d\u79f0\u4e5f\u53d8\u6210\u4e86\u4fdd\u7559\u548c\u56fa\u5b9a\u7684\u4e8c\u7ea7\u5b50\u57df\u540d\u540d\u79f0\u3002<\/p>\n<p><img decoding=\"async\" src=\"2026-02-01s1jlyfzisai.png\" alt=\"image-20250820165831585\" \/><\/p>\n<p>\u6700\u540e&#xff0c;\u6211\u4eec\u4f7f\u7528\u56fa\u5b9a\u7684\u516c\u7f51\u5730\u5740\u5728\u4efb\u610f\u8bbe\u5907\u7684\u6d4f\u89c8\u5668\u4e2d\u8bbf\u95ee&#xff0c;\u53ef\u4ee5\u770b\u5230\u6210\u529f\u8bbf\u95ee\u672c\u5730\u90e8\u7f72\u7684alertmanager\u9875\u9762&#xff0c;\u8fd9\u6837\u4e00\u4e2a\u6c38\u4e45\u4e0d\u4f1a\u53d8\u5316\u7684\u4e8c\u7ea7\u5b50\u57df\u540d\u516c\u7f51\u7f51\u5740\u5373\u8bbe\u7f6e\u597d\u4e86\u3002<\/p>\n<p><img decoding=\"async\" src=\"2026-02-01uxa5dgq33r4.png\" alt=\"image-20250820165919036\" \/><\/p>\n<p>\u6709\u4e86cpolar\u6211\u4eec\u53ef\u4ee5\u5728\u4efb\u610f\u4e00\u53f0\u670d\u52a1\u5668&#xff0c;\u4f7f\u7528\u6b64alertmanager\u76d1\u63a7&#xff0c;\u4f60\u7684\u540c\u4e8b&#061;\u4e5f\u53ef\u4ee5\u4e00\u952e\u76d1\u63a7&#xff01;\u662f\u4e0d\u662f\u7279\u522b\u65b9\u4fbf\u5462~<\/p>\n<h3>\u7ed3\u5c3e<\/h3>\n<p>\u606d\u559c\u4f60&#xff01;\u901a\u8fc7\u8fd9\u7bc7\u4fdd\u59c6\u7ea7\u6559\u7a0b&#xff0c;\u4f60\u5df2\u7ecf\u6210\u529f\u642d\u5efa\u4e86\u4e00\u5957\u5b8c\u6574\u3001\u53ef\u843d\u5730\u7684\u670d\u52a1\u5668\u76d1\u63a7\u4e0e\u544a\u8b66\u7cfb\u7edf\u3002\u65e0\u9700\u6df1\u539a\u7684\u8fd0\u7ef4\u80cc\u666f&#xff0c;\u4e5f\u4e0d\u4f9d\u8d56\u6602\u8d35\u7684\u5546\u4e1a\u5de5\u5177&#xff0c;\u4ec5\u51ed Prometheus \u7684\u5f3a\u5927\u91c7\u96c6\u80fd\u529b\u3001Node_Exporter \u7684\u8f7b\u91cf\u6307\u6807\u66b4\u9732\u3001Alertmanager \u7684\u7075\u6d3b\u544a\u8b66\u7ba1\u7406&#xff0c;\u518d\u501f\u52a9 cpolar \u7684\u5185\u7f51\u7a7f\u900f\u80fd\u529b&#xff0c;\u4f60\u5c31\u5b9e\u73b0\u4e86&#xff1a;<\/p>\n<ul>\n<li>\u5b9e\u65f6\u76d1\u63a7 CPU\u3001\u5185\u5b58\u3001\u78c1\u76d8\u7b49\u6838\u5fc3\u6307\u6807<\/li>\n<li>\u81ea\u5b9a\u4e49\u544a\u8b66\u89c4\u5219&#xff0c;\u5f02\u5e38\u81ea\u52a8\u89e6\u53d1<\/li>\n<li>\u901a\u8fc7\u90ae\u4ef6\u65b9\u5f0f&#xff0c;\u8ba9\u544a\u8b66\u4fe1\u606f\u968f\u65f6\u968f\u5730\u89e6\u8fbe\u624b\u4e2d<\/li>\n<li>\u5373\u4f7f\u670d\u52a1\u5668\u5728\u672c\u5730\u3001\u5728\u5bb6&#xff0c;\u4e5f\u80fd\u88ab\u4e91\u4e0a\u7684 Prometheus \u5b89\u5168\u8bbf\u95ee<\/li>\n<\/ul>\n<p>\u8fd9\u5957\u76d1\u63a7\u544a\u8b66\u7ec4\u5408\u642d\u914d cpolar \u5185\u7f51\u7a7f\u900f&#xff0c;\u65e2\u6ee1\u8db3\u4e86\u670d\u52a1\u5668\u5b9e\u65f6\u76d1\u63a7\u3001\u5f02\u5e38\u544a\u8b66\u7684\u6838\u5fc3\u9700\u6c42&#xff0c;\u53c8\u6253\u7834\u4e86\u5c40\u57df\u7f51\u7684\u4f7f\u7528\u9650\u5236\u3002\u65e0\u8bba\u662f\u4e2a\u4eba\u7ba1\u7406\u670d\u52a1\u5668&#xff0c;\u8fd8\u662f\u5c0f\u56e2\u961f\u65e5\u5e38\u8fd0\u7ef4&#xff0c;\u90fd\u80fd\u4ee5\u4f4e\u6210\u672c\u5b9e\u73b0\u9ad8\u6548\u7684\u670d\u52a1\u5668\u5b88\u62a4&#xff0c;\u8ba9\u8fd0\u7ef4\u5de5\u4f5c\u66f4\u7701\u5fc3\u3001\u66f4\u7075\u6d3b\u3002<\/p>\n<p>\u73b0\u5728&#xff0c;\u5c31\u53bb\u559d\u676f\u5496\u5561&#xff0c;\u5b89\u5fc3\u7b49\u5f85\u7b2c\u4e00\u6761\u544a\u8b66\u5427 \u2014\u2014 \u56e0\u4e3a\u4f60\u77e5\u9053&#xff0c;\u7cfb\u7edf\u6b63\u5728\u66ff\u4f60\u7ad9\u5c97&#xff01;&#x1f60e;<\/p>\n<p>\u611f\u8c22\u60a8\u5bf9\u672c\u7bc7\u6587\u7ae0\u7684\u559c\u7231&#xff0c;\u6709\u4efb\u4f55\u95ee\u9898\u6b22\u8fce\u7559\u8a00\u4ea4\u6d41\u3002cpolar\u5b98\u7f51-\u5b89\u5168\u7684\u5185\u7f51\u7a7f\u900f\u5de5\u5177 | \u65e0\u9700\u516c\u7f51ip | \u8fdc\u7a0b\u8bbf\u95ee | \u642d\u5efa\u7f51\u7ad9<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Prometheus\u3001node_exporter\u3001Alertmanager \u8fd9\u5957\u76d1\u63a7\u7ec4\u5408&#xff0c;\u6838\u5fc3\u529f\u80fd\u8986\u76d6\u4e86\u670d\u52a1\u5668\u6307\u6807\u91c7\u96c6\u3001\u5f02\u5e38\u68c0\u6d4b\u4e0e\u544a\u8b66\u5206\u53d1&#xff0c;Prometheus \u53ef\u5b9e\u65f6\u6293\u53d6 CPU\u3001\u5185\u5b58\u7b49\u786c\u4ef6\u6570\u636e\u5e76\u81ea\u5b9a\u4e49\u544a\u8b66\u89c4\u5219&#xff0c;node_exporter \u8f7b\u91cf\u91c7\u96c6\u670d\u52a1\u5668\u72b6\u6001&#xff0c;Alertmanager \u5219\u80fd\u5206\u7c7b\u63a8\u9001\u544a\u8b66\u4fe1\u606f&#xff0c;\u9002\u5408\u4e2a\u4eba\u670d\u52a1\u5668\u6301\u6709\u8005\u3001\u5c0f\u56e2\u961f\u8fd0\u7ef4\u4eba\u5458\u4f7f\u7528&#xff0c;\u4f18\u70b9\u662f\u5f00\u6e90\u514d\u8d39\u3001\u914d\u7f6e\u7075\u6d3b&#xff0c;7\u00d7<\/p>\n","protected":false},"author":2,"featured_media":70432,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[678,43,44],"topic":[],"class_list":["post-70452","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-server","tag-prometheus","tag-43","tag-44"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v20.3 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>\u544a\u522b\u670d\u52a1\u5668\u5931\u8054\uff01Prometheus+Alertmanager+cpolar \u8ba9\u76d1\u63a7\u544a\u8b66\u4e0d\u5c40\u9650\u4e8e\u5185\u7f51 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.wsisp.com\/helps\/70452.html\" \/>\n<meta property=\"og:locale\" content=\"zh_CN\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"\u544a\u522b\u670d\u52a1\u5668\u5931\u8054\uff01Prometheus+Alertmanager+cpolar \u8ba9\u76d1\u63a7\u544a\u8b66\u4e0d\u5c40\u9650\u4e8e\u5185\u7f51 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\" \/>\n<meta property=\"og:description\" content=\"Prometheus\u3001node_exporter\u3001Alertmanager \u8fd9\u5957\u76d1\u63a7\u7ec4\u5408&#xff0c;\u6838\u5fc3\u529f\u80fd\u8986\u76d6\u4e86\u670d\u52a1\u5668\u6307\u6807\u91c7\u96c6\u3001\u5f02\u5e38\u68c0\u6d4b\u4e0e\u544a\u8b66\u5206\u53d1&#xff0c;Prometheus \u53ef\u5b9e\u65f6\u6293\u53d6 CPU\u3001\u5185\u5b58\u7b49\u786c\u4ef6\u6570\u636e\u5e76\u81ea\u5b9a\u4e49\u544a\u8b66\u89c4\u5219&#xff0c;node_exporter \u8f7b\u91cf\u91c7\u96c6\u670d\u52a1\u5668\u72b6\u6001&#xff0c;Alertmanager \u5219\u80fd\u5206\u7c7b\u63a8\u9001\u544a\u8b66\u4fe1\u606f&#xff0c;\u9002\u5408\u4e2a\u4eba\u670d\u52a1\u5668\u6301\u6709\u8005\u3001\u5c0f\u56e2\u961f\u8fd0\u7ef4\u4eba\u5458\u4f7f\u7528&#xff0c;\u4f18\u70b9\u662f\u5f00\u6e90\u514d\u8d39\u3001\u914d\u7f6e\u7075\u6d3b&#xff0c;7\u00d7\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.wsisp.com\/helps\/70452.html\" \/>\n<meta property=\"og:site_name\" content=\"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\" \/>\n<meta property=\"article:published_time\" content=\"2026-02-01T15:17:57+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260201151750-697f6e9e16204.png\" \/>\n<meta name=\"author\" content=\"admin\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"\u4f5c\u8005\" \/>\n\t<meta name=\"twitter:data1\" content=\"admin\" \/>\n\t<meta name=\"twitter:label2\" content=\"\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4\" \/>\n\t<meta name=\"twitter:data2\" content=\"4 \u5206\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/70452.html\",\"url\":\"https:\/\/www.wsisp.com\/helps\/70452.html\",\"name\":\"\u544a\u522b\u670d\u52a1\u5668\u5931\u8054\uff01Prometheus+Alertmanager+cpolar \u8ba9\u76d1\u63a7\u544a\u8b66\u4e0d\u5c40\u9650\u4e8e\u5185\u7f51 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\",\"isPartOf\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/#website\"},\"datePublished\":\"2026-02-01T15:17:57+00:00\",\"dateModified\":\"2026-02-01T15:17:57+00:00\",\"author\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41\"},\"breadcrumb\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/70452.html#breadcrumb\"},\"inLanguage\":\"zh-Hans\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.wsisp.com\/helps\/70452.html\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/70452.html#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"\u9996\u9875\",\"item\":\"https:\/\/www.wsisp.com\/helps\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"\u544a\u522b\u670d\u52a1\u5668\u5931\u8054\uff01Prometheus+Alertmanager+cpolar \u8ba9\u76d1\u63a7\u544a\u8b66\u4e0d\u5c40\u9650\u4e8e\u5185\u7f51\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#website\",\"url\":\"https:\/\/www.wsisp.com\/helps\/\",\"name\":\"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\",\"description\":\"\u9999\u6e2f\u670d\u52a1\u5668_\u9999\u6e2f\u4e91\u670d\u52a1\u5668\u8d44\u8baf_\u670d\u52a1\u5668\u5e2e\u52a9\u6587\u6863_\u670d\u52a1\u5668\u6559\u7a0b\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.wsisp.com\/helps\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"zh-Hans\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41\",\"name\":\"admin\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"zh-Hans\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery\",\"contentUrl\":\"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery\",\"caption\":\"admin\"},\"sameAs\":[\"http:\/\/wp.wsisp.com\"],\"url\":\"https:\/\/www.wsisp.com\/helps\/author\/admin\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"\u544a\u522b\u670d\u52a1\u5668\u5931\u8054\uff01Prometheus+Alertmanager+cpolar \u8ba9\u76d1\u63a7\u544a\u8b66\u4e0d\u5c40\u9650\u4e8e\u5185\u7f51 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.wsisp.com\/helps\/70452.html","og_locale":"zh_CN","og_type":"article","og_title":"\u544a\u522b\u670d\u52a1\u5668\u5931\u8054\uff01Prometheus+Alertmanager+cpolar \u8ba9\u76d1\u63a7\u544a\u8b66\u4e0d\u5c40\u9650\u4e8e\u5185\u7f51 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","og_description":"Prometheus\u3001node_exporter\u3001Alertmanager \u8fd9\u5957\u76d1\u63a7\u7ec4\u5408&#xff0c;\u6838\u5fc3\u529f\u80fd\u8986\u76d6\u4e86\u670d\u52a1\u5668\u6307\u6807\u91c7\u96c6\u3001\u5f02\u5e38\u68c0\u6d4b\u4e0e\u544a\u8b66\u5206\u53d1&#xff0c;Prometheus \u53ef\u5b9e\u65f6\u6293\u53d6 CPU\u3001\u5185\u5b58\u7b49\u786c\u4ef6\u6570\u636e\u5e76\u81ea\u5b9a\u4e49\u544a\u8b66\u89c4\u5219&#xff0c;node_exporter \u8f7b\u91cf\u91c7\u96c6\u670d\u52a1\u5668\u72b6\u6001&#xff0c;Alertmanager \u5219\u80fd\u5206\u7c7b\u63a8\u9001\u544a\u8b66\u4fe1\u606f&#xff0c;\u9002\u5408\u4e2a\u4eba\u670d\u52a1\u5668\u6301\u6709\u8005\u3001\u5c0f\u56e2\u961f\u8fd0\u7ef4\u4eba\u5458\u4f7f\u7528&#xff0c;\u4f18\u70b9\u662f\u5f00\u6e90\u514d\u8d39\u3001\u914d\u7f6e\u7075\u6d3b&#xff0c;7\u00d7","og_url":"https:\/\/www.wsisp.com\/helps\/70452.html","og_site_name":"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","article_published_time":"2026-02-01T15:17:57+00:00","og_image":[{"url":"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260201151750-697f6e9e16204.png"}],"author":"admin","twitter_card":"summary_large_image","twitter_misc":{"\u4f5c\u8005":"admin","\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4":"4 \u5206"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/www.wsisp.com\/helps\/70452.html","url":"https:\/\/www.wsisp.com\/helps\/70452.html","name":"\u544a\u522b\u670d\u52a1\u5668\u5931\u8054\uff01Prometheus+Alertmanager+cpolar \u8ba9\u76d1\u63a7\u544a\u8b66\u4e0d\u5c40\u9650\u4e8e\u5185\u7f51 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","isPartOf":{"@id":"https:\/\/www.wsisp.com\/helps\/#website"},"datePublished":"2026-02-01T15:17:57+00:00","dateModified":"2026-02-01T15:17:57+00:00","author":{"@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41"},"breadcrumb":{"@id":"https:\/\/www.wsisp.com\/helps\/70452.html#breadcrumb"},"inLanguage":"zh-Hans","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.wsisp.com\/helps\/70452.html"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.wsisp.com\/helps\/70452.html#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"\u9996\u9875","item":"https:\/\/www.wsisp.com\/helps"},{"@type":"ListItem","position":2,"name":"\u544a\u522b\u670d\u52a1\u5668\u5931\u8054\uff01Prometheus+Alertmanager+cpolar \u8ba9\u76d1\u63a7\u544a\u8b66\u4e0d\u5c40\u9650\u4e8e\u5185\u7f51"}]},{"@type":"WebSite","@id":"https:\/\/www.wsisp.com\/helps\/#website","url":"https:\/\/www.wsisp.com\/helps\/","name":"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","description":"\u9999\u6e2f\u670d\u52a1\u5668_\u9999\u6e2f\u4e91\u670d\u52a1\u5668\u8d44\u8baf_\u670d\u52a1\u5668\u5e2e\u52a9\u6587\u6863_\u670d\u52a1\u5668\u6559\u7a0b","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.wsisp.com\/helps\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"zh-Hans"},{"@type":"Person","@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41","name":"admin","image":{"@type":"ImageObject","inLanguage":"zh-Hans","@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/image\/","url":"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery","contentUrl":"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery","caption":"admin"},"sameAs":["http:\/\/wp.wsisp.com"],"url":"https:\/\/www.wsisp.com\/helps\/author\/admin"}]}},"_links":{"self":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts\/70452","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/comments?post=70452"}],"version-history":[{"count":0,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts\/70452\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/media\/70432"}],"wp:attachment":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/media?parent=70452"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/categories?post=70452"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/tags?post=70452"},{"taxonomy":"topic","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/topic?post=70452"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}