{"id":64727,"date":"2026-01-24T00:16:40","date_gmt":"2026-01-23T16:16:40","guid":{"rendered":"https:\/\/www.wsisp.com\/helps\/64727.html"},"modified":"2026-01-24T00:16:40","modified_gmt":"2026-01-23T16:16:40","slug":"%e6%9c%8d%e5%8a%a1%e5%99%a8%e5%8d%a1%e6%ad%bb%e6%8e%92%e6%9f%a5%e6%b5%81%e7%a8%8b","status":"publish","type":"post","link":"https:\/\/www.wsisp.com\/helps\/64727.html","title":{"rendered":"\u670d\u52a1\u5668\u5361\u6b7b\u6392\u67e5\u6d41\u7a0b"},"content":{"rendered":"<p>\u4ee5\u4e0b\u662f Linux \u7269\u7406\u673a\/\u4e91\u670d\u52a1\u5668\u7cfb\u7edf\u5361\u6b7b\u7684\u6807\u51c6\u5316\u6392\u67e5\u6d41\u7a0b&#xff08;\u517c\u987e\u547d\u4ee4\u884c\/\u684c\u9762\u73af\u5883\u3001Docker\/\u670d\u52a1\u90e8\u7f72\u573a\u666f&#xff09;&#xff0c;\u6309\u300c\u7d27\u6025\u6062\u590d\u2192\u65e5\u5fd7\u6eaf\u6e90\u2192\u8d44\u6e90\u6392\u67e5\u2192\u6df1\u5ea6\u5b9a\u4f4d\u2192\u9884\u9632\u4f18\u5316\u300d\u4e94\u6b65\u6267\u884c&#xff0c;\u76f4\u63a5\u590d\u5236\u547d\u4ee4\u5373\u53ef\u64cd\u4f5c&#xff0c;\u8986\u76d6 90% \u5e38\u89c1\u5361\u6b7b\u573a\u666f&#xff1a;<\/p>\n<h4>\u4e00\u3001\u7d27\u6025\u6062\u590d&#xff1a;\u5148\u89e3\u51b3\u300c\u8fde\u4e0d\u4e0a\u300d\u7684\u95ee\u9898&#xff08;5\u5206\u949f\u5185&#xff09;<\/h4>\n<p>\u7cfb\u7edf\u5361\u6b7b\u65f6\u4f18\u5148\u6062\u590d\u53ef\u64cd\u4f5c\u6027&#xff0c;\u518d\u6392\u67e5\u6839\u56e0&#xff1a;<\/p>\n<li>\u7269\u7406\u673a\/\u4e91\u670d\u52a1\u5668\u533a\u5206\u5904\u7406&#xff1a;\n<ul>\n<li>\u7269\u7406\u673a&#xff1a;\u76f4\u63a5\u6309\u7535\u6e90\u952e\u5f3a\u5236\u91cd\u542f&#xff08;\u65e0\u5176\u4ed6\u529e\u6cd5&#xff09;&#xff1b;<\/li>\n<li>\u4e91\u670d\u52a1\u5668&#xff1a;\u901a\u8fc7\u63a7\u5236\u53f0\u300c\u5f3a\u5236\u91cd\u542f\u300d\u2192 \u7528\u7f51\u9875\/VNC\u7ec8\u7aef\u767b\u5f55&#xff08;\u907f\u514d SSH \u4f9d\u8d56&#xff09;\u3002<\/li>\n<\/ul>\n<\/li>\n<li>\u5355\u7528\u6237\u6a21\u5f0f\u5e94\u6025&#xff08;\u53ef\u9009&#xff0c;\u9488\u5bf9\u91cd\u542f\u540e\u4ecd\u5361&#xff09;&#xff1a;<br \/>\n\u91cd\u542f\u65f6\u6309 Shift \u8fdb\u5165 GRUB \u83dc\u5355\u2192\u9009\u4e2d\u7cfb\u7edf\u2192\u6309 e \u7f16\u8f91\u2192\u5728 linux \u884c\u672b\u5c3e\u52a0 init&#061;\/bin\/bash\u2192Ctrl&#043;X \u542f\u52a8&#xff1a;<span class=\"token function\">mount<\/span> -o remount,rw \/  <span class=\"token comment\"># \u6302\u8f7d\u6839\u76ee\u5f55\u4e3a\u53ef\u5199<\/span><br \/>\n<span class=\"token comment\"># \u4e34\u65f6\u7981\u7528\u53ef\u80fd\u51b2\u7a81\u7684\u670d\u52a1&#xff08;\u5982\u663e\u5361\u9a71\u52a8\u3001Docker&#xff09;<\/span><br \/>\n<span class=\"token builtin class-name\">echo<\/span> <span class=\"token string\">&#034;modprobe.blacklist&#061;amdgpu&#034;<\/span> <span class=\"token operator\">&gt;<\/span> \/etc\/modprobe.d\/emergency.conf<br \/>\nsystemctl disable &#8211;now docker  <span class=\"token comment\"># \u82e5\u6000\u7591\u5bb9\u5668\u5360\u7528\u8d44\u6e90<\/span><br \/>\n<span class=\"token builtin class-name\">exec<\/span> \/sbin\/init  <span class=\"token comment\"># \u6062\u590d\u6b63\u5e38\u542f\u52a8<\/span><\/p>\n<\/li>\n<h4>\u4e8c\u3001\u65e5\u5fd7\u6eaf\u6e90&#xff1a;\u5b9a\u4f4d\u5361\u6b7b\u524d\u7684\u5f02\u5e38&#xff08;\u6838\u5fc3\u6b65\u9aa4&#xff0c;10\u5206\u949f&#xff09;<\/h4>\n<p>\u7cfb\u7edf\u91cd\u542f\u540e&#xff0c;\u4f18\u5148\u901a\u8fc7\u65e5\u5fd7\u627e\u300c\u5361\u6b7b\u77ac\u95f4\u7684\u5173\u952e\u62a5\u9519\u300d&#xff0c;\u91cd\u70b9\u770b \u4e0a\u4e00\u6b21\u542f\u52a8\u5468\u671f\u7684\u65e5\u5fd7&#xff1a;<\/p>\n<h5>1. \u7cfb\u7edf\u5185\u6838\/\u5168\u5c40\u65e5\u5fd7&#xff08;\u6700\u6838\u5fc3&#xff09;<\/h5>\n<p><span class=\"token comment\"># \u67e5\u770b\u4e0a\u4e00\u6b21\u542f\u52a8\u7684\u5b8c\u6574\u65e5\u5fd7&#xff08;\u5361\u6b7b\u524d\u7684\u6240\u6709\u8bb0\u5f55&#xff09;<\/span><br \/>\n<span class=\"token function\">sudo<\/span> journalctl -b -1 &#8211;no-pager <span class=\"token operator\">|<\/span> <span class=\"token function\">tee<\/span> last_boot.log<br \/>\n<span class=\"token comment\"># \u8fc7\u6ee4\u5173\u952e\u9519\u8bef\u5173\u952e\u8bcd&#xff08;\u5feb\u901f\u5b9a\u4f4d&#xff09;<\/span><br \/>\n<span class=\"token function\">sudo<\/span> journalctl -b -1 <span class=\"token operator\">|<\/span> <span class=\"token function\">grep<\/span> -E <span class=\"token string\">&#034;oom|kill|panic|error|warn|I\/O error|soft lockup&#034;<\/span> &#8211;color<span class=\"token operator\">&#061;<\/span>auto<\/p>\n<h5>2. \u5173\u952e\u670d\u52a1\u65e5\u5fd7&#xff08;\u6309\u573a\u666f\u7b5b\u9009&#xff09;<\/h5>\n<ul>\n<li>SSH \u65e0\u54cd\u5e94&#xff1a;<span class=\"token function\">sudo<\/span> journalctl -u sshd -b -1  <span class=\"token comment\"># SSH \u670d\u52a1\u65e5\u5fd7<\/span><br \/>\n<span class=\"token function\">sudo<\/span> <span class=\"token function\">grep<\/span> sshd \/var\/log\/auth.log.1  <span class=\"token comment\"># \u767b\u5f55\u65e5\u5fd7\u5907\u4efd<\/span><\/p>\n<\/li>\n<li>\u684c\u9762\u73af\u5883\u5361\u6b7b&#xff1a;<span class=\"token function\">sudo<\/span> journalctl -u gdm -b -1  <span class=\"token comment\"># GNOME \u663e\u793a\u7ba1\u7406\u5668\u65e5\u5fd7<\/span><br \/>\n<span class=\"token function\">sudo<\/span> <span class=\"token function\">cat<\/span> \/var\/log\/Xorg.0.log.old  <span class=\"token comment\"># X \u670d\u52a1\u5668\u65e5\u5fd7<\/span><\/p>\n<\/li>\n<li>Docker\/\u5bb9\u5668\u76f8\u5173&#xff1a;<span class=\"token function\">sudo<\/span> journalctl -u docker -b -1  <span class=\"token comment\"># Docker \u670d\u52a1\u65e5\u5fd7<\/span><br \/>\ndocker logs &#8211;tail <span class=\"token number\">100<\/span> \u53ef\u7591\u5bb9\u5668ID  <span class=\"token comment\"># \u5bb9\u5668\u5f02\u5e38\u65e5\u5fd7<\/span><\/p>\n<\/li>\n<\/ul>\n<h5>3. \u65e5\u5fd7\u5173\u952e\u8bcd\u5bf9\u5e94\u6839\u56e0\u8868<\/h5>\n<table>\n<tr>\u5173\u952e\u8bcd\u5927\u6982\u7387\u6839\u56e0\u5e94\u6025\u5904\u7406<\/tr>\n<tbody>\n<tr>\n<td>Out of memory: Killed<\/td>\n<td>\u5185\u5b58\u8017\u5c3d&#xff08;OOM&#xff09;<\/td>\n<td>\u9650\u5236\u8fdb\u7a0b\u5185\u5b58\/\u589e\u52a0Swap\/\u4f18\u5316\u7a0b\u5e8f<\/td>\n<\/tr>\n<tr>\n<td>kernel panic<\/td>\n<td>\u5185\u6838\u5d29\u6e83&#xff08;\u9a71\u52a8\/\u786c\u4ef6\u51b2\u7a81&#xff09;<\/td>\n<td>\u56de\u6eda\u5185\u6838\/\u7981\u7528\u51b2\u7a81\u9a71\u52a8<\/td>\n<\/tr>\n<tr>\n<td>CPU soft lockup<\/td>\n<td>CPU \u6b7b\u9501&#xff08;\u5185\u6838\/\u8fdb\u7a0b\u5f02\u5e38&#xff09;<\/td>\n<td>\u6740\u6b7b\u5360\u7528CPU\u7684\u8fdb\u7a0b\/\u66f4\u65b0\u5185\u6838<\/td>\n<\/tr>\n<tr>\n<td>I\/O error<\/td>\n<td>\u78c1\u76d8\u6545\u969c\/\u6302\u8f7d\u5f02\u5e38<\/td>\n<td>\u68c0\u67e5\u78c1\u76d8\u5065\u5eb7\/\u91cd\u65b0\u6302\u8f7d\u5206\u533a<\/td>\n<\/tr>\n<tr>\n<td>drm \u91cd\u590d\u521d\u59cb\u5316<\/td>\n<td>\u663e\u5361\u9a71\u52a8\u5f02\u5e38&#xff08;\u5982 amdgpu&#xff09;<\/td>\n<td>\u8c03\u6574\u9a71\u52a8\u53c2\u6570&#xff08;\u5982 runpm&#061;0&#xff09;<\/td>\n<\/tr>\n<tr>\n<td>max sessions reached<\/td>\n<td>SSH \u8fde\u63a5\u6570\u8017\u5c3d<\/td>\n<td>\u589e\u52a0 SSH \u6700\u5927\u8fde\u63a5\u6570\u9650\u5236<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h4>\u4e09\u3001\u8d44\u6e90\u6392\u67e5&#xff1a;\u786e\u8ba4\u662f\u5426\u300c\u8d44\u6e90\u8017\u5c3d\u300d\u5bfc\u81f4\u5361\u6b7b&#xff08;5\u5206\u949f&#xff09;<\/h4>\n<p>\u7cfb\u7edf\u5361\u6b7b\u6700\u5e38\u89c1\u539f\u56e0\u662f CPU\/\u5185\u5b58\/\u78c1\u76d8\u8017\u5c3d&#xff0c;\u91cd\u542f\u540e\u901a\u8fc7\u5de5\u5177\u56de\u6eaf\u5386\u53f2\u72b6\u6001&#xff1a;<\/p>\n<h5>1. \u5185\u5b58\/CPU \u5386\u53f2\u5360\u7528&#xff08;\u9700 sysstat \u5de5\u5177&#xff09;<\/h5>\n<p><span class=\"token comment\"># \u5b89\u88c5 sysstat&#xff08;\u82e5\u672a\u5b89\u88c5&#xff09;<\/span><br \/>\n<span class=\"token function\">sudo<\/span> <span class=\"token function\">apt<\/span> <span class=\"token function\">install<\/span> sysstat -y<br \/>\n<span class=\"token comment\"># \u67e5\u770b\u4e0a\u4e00\u6b21\u542f\u52a8\u7684 CPU \u5360\u7528&#xff08;%idle \u63a5\u8fd10&#061;CPU\u8017\u5c3d&#xff09;<\/span><br \/>\n<span class=\"token function\">sudo<\/span> sar -u -f \/var\/log\/sysstat\/sa<span class=\"token variable\"><span class=\"token variable\">$(<\/span><span class=\"token function\">date<\/span> &#043;%d -d <span class=\"token string\">&#034;yesterday&#034;<\/span><span class=\"token variable\">)<\/span><\/span><br \/>\n<span class=\"token comment\"># \u67e5\u770b\u4e0a\u4e00\u6b21\u542f\u52a8\u7684\u5185\u5b58\u5360\u7528&#xff08;%memused \u63a5\u8fd1100%&#061;\u5185\u5b58\u8017\u5c3d&#xff09;<\/span><br \/>\n<span class=\"token function\">sudo<\/span> sar -r -f \/var\/log\/sysstat\/sa<span class=\"token variable\"><span class=\"token variable\">$(<\/span><span class=\"token function\">date<\/span> &#043;%d -d <span class=\"token string\">&#034;yesterday&#034;<\/span><span class=\"token variable\">)<\/span><\/span><\/p>\n<h5>2. \u78c1\u76d8\u7a7a\u95f4\u4e0e\u5065\u5eb7\u72b6\u6001<\/h5>\n<p><span class=\"token comment\"># \u67e5\u770b\u78c1\u76d8\u5360\u7528&#xff08;\/ \u5206\u533a\u6ee1&#061;\u5361\u6b7b\u5e38\u89c1\u539f\u56e0&#xff09;<\/span><br \/>\n<span class=\"token function\">df<\/span> -h<br \/>\n<span class=\"token comment\"># \u67e5\u627e\u5927\u6587\u4ef6&#xff08;\u65e5\u5fd7\/\u7f13\u5b58\u66b4\u589e&#xff09;<\/span><br \/>\n<span class=\"token function\">sudo<\/span> <span class=\"token function\">find<\/span> \/ -type f -size &#043;1G -mtime -1  <span class=\"token comment\"># 1\u5929\u5185\u65b0\u589e\u76841G&#043;\u6587\u4ef6<\/span><br \/>\n<span class=\"token comment\"># \u68c0\u67e5\u78c1\u76d8\u5065\u5eb7&#xff08;\u7269\u7406\u673a&#xff09;<\/span><br \/>\n<span class=\"token function\">sudo<\/span> <span class=\"token function\">apt<\/span> <span class=\"token function\">install<\/span> smartmontools -y<br \/>\n<span class=\"token function\">sudo<\/span> smartctl -a \/dev\/sda  <span class=\"token comment\"># \u66ff\u6362 \/dev\/sda \u4e3a\u7cfb\u7edf\u78c1\u76d8<\/span><\/p>\n<h5>3. \u8fdb\u7a0b\u5f02\u5e38\u6392\u67e5&#xff08;\u91cd\u542f\u540e\u4ecd\u9ad8\u8d1f\u8f7d&#xff09;<\/h5>\n<p><span class=\"token comment\"># \u5b9e\u65f6\u67e5\u770b\u9ad8\u8d1f\u8f7d\u8fdb\u7a0b<\/span><br \/>\n<span class=\"token function\">top<\/span>  <span class=\"token comment\"># \u6309 P \u6392\u5e8fCPU&#xff0c;\u6309 M \u6392\u5e8f\u5185\u5b58<\/span><br \/>\n<span class=\"token comment\"># \u67e5\u770b\u5386\u53f2\u5360\u7528\u6700\u9ad8\u7684\u8fdb\u7a0b<\/span><br \/>\n<span class=\"token function\">ps<\/span> aux &#8211;sort<span class=\"token operator\">&#061;<\/span>-%cpu <span class=\"token operator\">|<\/span> <span class=\"token function\">head<\/span> -10  <span class=\"token comment\"># CPU \u6700\u9ad8<\/span><br \/>\n<span class=\"token function\">ps<\/span> aux &#8211;sort<span class=\"token operator\">&#061;<\/span>-%mem <span class=\"token operator\">|<\/span> <span class=\"token function\">head<\/span> -10  <span class=\"token comment\"># \u5185\u5b58\u6700\u9ad8<\/span><\/p>\n<h4>\u56db\u3001\u6df1\u5ea6\u5b9a\u4f4d&#xff1a;\u9488\u5bf9\u9ad8\u9891\u573a\u666f\u7684\u4e13\u9879\u6392\u67e5&#xff08;10\u5206\u949f&#xff09;<\/h4>\n<p>\u82e5\u57fa\u7840\u6392\u67e5\u65e0\u7ed3\u679c&#xff0c;\u6309\u573a\u666f\u4e13\u9879\u5b9a\u4f4d&#xff1a;<\/p>\n<h5>1. \u663e\u5361\u9a71\u52a8\u5f02\u5e38&#xff08;\u684c\u9762\u73af\u5883\/\u7269\u7406\u673a&#xff09;<\/h5>\n<p><span class=\"token comment\"># \u67e5\u770b\u663e\u5361\u9a71\u52a8\u72b6\u6001<\/span><br \/>\n<span class=\"token function\">sudo<\/span> lshw -C display  <span class=\"token comment\"># \u786e\u8ba4\u9a71\u52a8\u662f\u5426\u52a0\u8f7d<\/span><br \/>\n<span class=\"token function\">dmesg<\/span> <span class=\"token operator\">|<\/span> <span class=\"token function\">grep<\/span> -i <span class=\"token string\">&#034;drm&#034;<\/span>  <span class=\"token comment\"># \u9a71\u52a8\u521d\u59cb\u5316\u65e5\u5fd7<\/span><br \/>\n<span class=\"token comment\"># \u82e5\u9a71\u52a8\u91cd\u590d\u521d\u59cb\u5316&#xff0c;\u6dfb\u52a0\u4f18\u5316\u53c2\u6570&#xff08;\u5982 amdgpu&#xff09;<\/span><br \/>\n<span class=\"token function\">sudo<\/span> <span class=\"token function\">vi<\/span> \/etc\/default\/grub  <span class=\"token comment\"># \u8ffd\u52a0 amdgpu.runpm&#061;0 \u7b49\u53c2\u6570<\/span><br \/>\n<span class=\"token function\">sudo<\/span> <span class=\"token function\">update-grub<\/span> <span class=\"token operator\">&amp;&amp;<\/span> <span class=\"token function\">sudo<\/span> <span class=\"token function\">reboot<\/span><\/p>\n<h5>2. Docker\/\u5bb9\u5668\u8d44\u6e90\u6cc4\u6f0f<\/h5>\n<p><span class=\"token comment\"># \u67e5\u770b\u5bb9\u5668\u8d44\u6e90\u9650\u5236\u4e0e\u5360\u7528<\/span><br \/>\ndocker stats &#8211;no-stream  <span class=\"token comment\"># \u5b9e\u65f6\u8d44\u6e90\u5360\u7528<\/span><br \/>\ndocker inspect \u5bb9\u5668ID <span class=\"token operator\">|<\/span> <span class=\"token function\">grep<\/span> -i <span class=\"token string\">&#034;memory&#034;<\/span>  <span class=\"token comment\"># \u67e5\u770b\u5185\u5b58\u9650\u5236<\/span><br \/>\n<span class=\"token comment\"># \u6392\u67e5\u5bb9\u5668\u65e5\u5fd7\u66b4\u589e<\/span><br \/>\ndocker system <span class=\"token function\">df<\/span>  <span class=\"token comment\"># \u67e5\u770b\u5bb9\u5668\/\u955c\u50cf\u5360\u7528<\/span><br \/>\n<span class=\"token function\">sudo<\/span> <span class=\"token function\">du<\/span> -sh \/var\/lib\/docker\/containers\/*  <span class=\"token comment\"># \u5bb9\u5668\u65e5\u5fd7\u5927\u5c0f<\/span><\/p>\n<h5>3. \u5185\u6838\/\u786c\u4ef6\u517c\u5bb9\u6027\u95ee\u9898<\/h5>\n<p><span class=\"token comment\"># \u67e5\u770b\u5185\u6838\u7248\u672c<\/span><br \/>\n<span class=\"token function\">uname<\/span> -r<br \/>\n<span class=\"token comment\"># \u67e5\u770b\u5185\u6838\u9519\u8bef\u65e5\u5fd7<\/span><br \/>\n<span class=\"token function\">dmesg<\/span> <span class=\"token operator\">|<\/span> <span class=\"token function\">grep<\/span> -i <span class=\"token string\">&#034;bug\\\\|warn\\\\|error&#034;<\/span><br \/>\n<span class=\"token comment\"># \u68c0\u67e5\u786c\u4ef6\u6e29\u5ea6&#xff08;\u7269\u7406\u673a&#xff09;<\/span><br \/>\n<span class=\"token function\">sudo<\/span> <span class=\"token function\">apt<\/span> <span class=\"token function\">install<\/span> lm-sensors -y<br \/>\n<span class=\"token function\">sudo<\/span> sensors  <span class=\"token comment\"># CPU\/\u663e\u5361\u6e29\u5ea6\u8fc7\u9ad8&#061;\u5361\u6b7b\u98ce\u9669<\/span><\/p>\n<h5>4. \u670d\u52a1\u6b7b\u9501\/\u7aef\u53e3\u5360\u7528<\/h5>\n<p><span class=\"token comment\"># \u67e5\u770b\u670d\u52a1\u72b6\u6001<\/span><br \/>\n<span class=\"token function\">sudo<\/span> systemctl list-units &#8211;type<span class=\"token operator\">&#061;<\/span>service &#8211;state<span class=\"token operator\">&#061;<\/span>failed  <span class=\"token comment\"># \u5931\u8d25\u670d\u52a1<\/span><br \/>\n<span class=\"token comment\"># \u67e5\u770b\u7aef\u53e3\u5360\u7528&#xff08;\u907f\u514d\u7aef\u53e3\u51b2\u7a81\u5bfc\u81f4\u670d\u52a1\u5f02\u5e38&#xff09;<\/span><br \/>\n<span class=\"token function\">sudo<\/span> <span class=\"token function\">netstat<\/span> -tulpn <span class=\"token operator\">|<\/span> <span class=\"token function\">grep<\/span> -E <span class=\"token string\">&#034;:22|:80|:3306&#034;<\/span>  <span class=\"token comment\"># \u5e38\u7528\u7aef\u53e3<\/span><\/p>\n<h4>\u4e94\u3001\u9884\u9632\u4f18\u5316&#xff1a;\u907f\u514d\u518d\u6b21\u5361\u6b7b&#xff08;\u957f\u671f\u4fdd\u969c&#xff09;<\/h4>\n<p>\u6392\u67e5\u5b8c\u540e&#xff0c;\u6267\u884c\u4ee5\u4e0b\u4f18\u5316\u907f\u514d\u590d\u53d1&#xff1a;<\/p>\n<li>\u8d44\u6e90\u9650\u5236&#xff1a;\n<ul>\n<li>Docker \u5bb9\u5668\u6dfb\u52a0\u5185\u5b58\/CPU\u9650\u5236&#xff1a;docker run &#8211;memory&#061;4G &#8211;cpus&#061;2 &#8230;&#xff1b;<\/li>\n<li>\u7ed9\u8fdb\u7a0b\u8bbe\u7f6e OOM \u4f18\u5148\u7ea7&#xff1a;echo &#034;-1000&#034; &gt; \/proc\/\u8fdb\u7a0bID\/oom_score_adj&#xff08;\u907f\u514d\u6838\u5fc3\u670d\u52a1\u88ab\u6740\u6b7b&#xff09;\u3002<\/li>\n<\/ul>\n<\/li>\n<li>\u65e5\u5fd7\u7ba1\u7406&#xff1a;\n<ul>\n<li>\u914d\u7f6e logrotate \u81ea\u52a8\u8f6e\u8f6c\u65e5\u5fd7&#xff08;\u907f\u514d\u65e5\u5fd7\u5360\u6ee1\u78c1\u76d8&#xff09;&#xff1b;<\/li>\n<li>\u9650\u5236 Docker \u5bb9\u5668\u65e5\u5fd7\u5927\u5c0f&#xff1a;docker run &#8211;log-opt max-size&#061;100m &#8211;log-opt max-file&#061;3 &#8230;\u3002<\/li>\n<\/ul>\n<\/li>\n<li>\u76d1\u63a7\u544a\u8b66&#xff1a;\n<ul>\n<li>\u5b89\u88c5 zabbix\/prometheus \u76d1\u63a7 CPU\/\u5185\u5b58\/\u78c1\u76d8&#xff1b;<\/li>\n<li>\u7b80\u5355\u811a\u672c\u544a\u8b66&#xff08;\u793a\u4f8b&#xff1a;\u5185\u5b58\u5360\u7528\u8d85 90% \u53d1\u90ae\u4ef6&#xff09;\u3002<\/li>\n<\/ul>\n<\/li>\n<li>\u5185\u6838\u4e0e\u9a71\u52a8&#xff1a;\n<ul>\n<li>\u7269\u7406\u673a\u4f7f\u7528 LTS \u5185\u6838&#xff08;\u5982 Ubuntu 22.04 \u7684 5.15 \u5185\u6838&#xff09;&#xff1b;<\/li>\n<li>\u663e\u5361\u9a71\u52a8\u4f18\u5148\u4f7f\u7528\u5b98\u65b9\u7a33\u5b9a\u7248&#xff0c;\u907f\u514d\u76f2\u76ee\u66f4\u65b0\u3002<\/li>\n<\/ul>\n<\/li>\n<h4>\u603b\u7ed3&#xff1a;\u6392\u67e5\u6d41\u7a0b\u901f\u8bb0&#xff08;\u6309\u4f18\u5148\u7ea7&#xff09;<\/h4>\n<li>\u7d27\u6025\u91cd\u542f\u2192\u7f51\u9875\/VNC\u767b\u5f55&#xff1b;<\/li>\n<li>\u67e5\u4e0a\u4e00\u6b21\u542f\u52a8\u65e5\u5fd7&#xff08;journalctl -b -1&#xff09;&#xff1b;<\/li>\n<li>\u7528 sar \u770b\u8d44\u6e90\u5360\u7528\u5386\u53f2&#xff1b;<\/li>\n<li>\u6309\u573a\u666f\u4e13\u9879\u6392\u67e5&#xff08;\u9a71\u52a8\/Docker\/\u78c1\u76d8&#xff09;&#xff1b;<\/li>\n<li>\u4f18\u5316\u914d\u7f6e\u907f\u514d\u590d\u53d1\u3002<\/li>\n<p>\u6309\u6b64\u6d41\u7a0b&#xff0c;\u53ef\u5728 30 \u5206\u949f\u5185\u5b9a\u4f4d 90% \u4ee5\u4e0a\u7684\u7cfb\u7edf\u5361\u6b7b\u95ee\u9898&#xff0c;\u4e14\u6240\u6709\u64cd\u4f5c\u5747\u4e3a\u547d\u4ee4\u884c\u6267\u884c&#xff0c;\u65e0\u9700\u590d\u6742\u5de5\u5177&#xff0c;\u9002\u5408\u6280\u672f\u4eba\u5458\u5feb\u901f\u843d\u5730\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u4ee5\u4e0b\u662f Linux \u7269\u7406\u673a\/\u4e91\u670d\u52a1\u5668\u7cfb\u7edf\u5361\u6b7b\u7684\u6807\u51c6\u5316\u6392\u67e5\u6d41\u7a0b&#xff08;\u517c\u987e\u547d\u4ee4\u884c\/\u684c\u9762\u73af\u5883\u3001Docker\/\u670d\u52a1\u90e8\u7f72\u573a\u666f&#xff09;&#xff0c;\u6309\u300c\u7d27\u6025\u6062\u590d\u2192\u65e5\u5fd7\u6eaf\u6e90\u2192\u8d44\u6e90\u6392\u67e5\u2192\u6df1\u5ea6\u5b9a\u4f4d\u2192\u9884\u9632\u4f18\u5316\u300d\u4e94\u6b65\u6267\u884c&#xff0c;\u76f4\u63a5\u590d\u5236\u547d\u4ee4\u5373\u53ef\u64cd\u4f5c&#xff0c;\u8986\u76d6 90% \u5e38\u89c1\u5361\u6b7b\u573a\u666f&#xff1a;<br \/>\n\u4e00\u3001\u7d27\u6025\u6062\u590d&#xff1a;\u5148\u89e3\u51b3\u300c\u8fde\u4e0d\u4e0a\u300d\u7684\u95ee\u9898&#xff08;5\u5206\u949f\u5185&#xff09;<br \/>\n\u7cfb\u7edf\u5361\u6b7b\u65f6\u4f18\u5148\u6062\u590d\u53ef\u64cd\u4f5c\u6027&#xff0c;\u518d\u6392\u67e5\u6839\u56e0&#xff1a;<br \/>\n\u7269\u7406<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[43,44],"topic":[],"class_list":["post-64727","post","type-post","status-publish","format-standard","hentry","category-server","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>\u670d\u52a1\u5668\u5361\u6b7b\u6392\u67e5\u6d41\u7a0b - \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\/64727.html\" \/>\n<meta property=\"og:locale\" content=\"zh_CN\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"\u670d\u52a1\u5668\u5361\u6b7b\u6392\u67e5\u6d41\u7a0b - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\" \/>\n<meta property=\"og:description\" content=\"\u4ee5\u4e0b\u662f Linux \u7269\u7406\u673a\/\u4e91\u670d\u52a1\u5668\u7cfb\u7edf\u5361\u6b7b\u7684\u6807\u51c6\u5316\u6392\u67e5\u6d41\u7a0b&#xff08;\u517c\u987e\u547d\u4ee4\u884c\/\u684c\u9762\u73af\u5883\u3001Docker\/\u670d\u52a1\u90e8\u7f72\u573a\u666f&#xff09;&#xff0c;\u6309\u300c\u7d27\u6025\u6062\u590d\u2192\u65e5\u5fd7\u6eaf\u6e90\u2192\u8d44\u6e90\u6392\u67e5\u2192\u6df1\u5ea6\u5b9a\u4f4d\u2192\u9884\u9632\u4f18\u5316\u300d\u4e94\u6b65\u6267\u884c&#xff0c;\u76f4\u63a5\u590d\u5236\u547d\u4ee4\u5373\u53ef\u64cd\u4f5c&#xff0c;\u8986\u76d6 90% \u5e38\u89c1\u5361\u6b7b\u573a\u666f&#xff1a; \u4e00\u3001\u7d27\u6025\u6062\u590d&#xff1a;\u5148\u89e3\u51b3\u300c\u8fde\u4e0d\u4e0a\u300d\u7684\u95ee\u9898&#xff08;5\u5206\u949f\u5185&#xff09; \u7cfb\u7edf\u5361\u6b7b\u65f6\u4f18\u5148\u6062\u590d\u53ef\u64cd\u4f5c\u6027&#xff0c;\u518d\u6392\u67e5\u6839\u56e0&#xff1a; \u7269\u7406\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.wsisp.com\/helps\/64727.html\" \/>\n<meta property=\"og:site_name\" content=\"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\" \/>\n<meta property=\"article:published_time\" content=\"2026-01-23T16:16:40+00:00\" \/>\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=\"2 \u5206\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/64727.html\",\"url\":\"https:\/\/www.wsisp.com\/helps\/64727.html\",\"name\":\"\u670d\u52a1\u5668\u5361\u6b7b\u6392\u67e5\u6d41\u7a0b - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\",\"isPartOf\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/#website\"},\"datePublished\":\"2026-01-23T16:16:40+00:00\",\"dateModified\":\"2026-01-23T16:16:40+00:00\",\"author\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41\"},\"breadcrumb\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/64727.html#breadcrumb\"},\"inLanguage\":\"zh-Hans\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.wsisp.com\/helps\/64727.html\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/64727.html#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"\u9996\u9875\",\"item\":\"https:\/\/www.wsisp.com\/helps\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"\u670d\u52a1\u5668\u5361\u6b7b\u6392\u67e5\u6d41\u7a0b\"}]},{\"@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":"\u670d\u52a1\u5668\u5361\u6b7b\u6392\u67e5\u6d41\u7a0b - \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\/64727.html","og_locale":"zh_CN","og_type":"article","og_title":"\u670d\u52a1\u5668\u5361\u6b7b\u6392\u67e5\u6d41\u7a0b - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","og_description":"\u4ee5\u4e0b\u662f Linux \u7269\u7406\u673a\/\u4e91\u670d\u52a1\u5668\u7cfb\u7edf\u5361\u6b7b\u7684\u6807\u51c6\u5316\u6392\u67e5\u6d41\u7a0b&#xff08;\u517c\u987e\u547d\u4ee4\u884c\/\u684c\u9762\u73af\u5883\u3001Docker\/\u670d\u52a1\u90e8\u7f72\u573a\u666f&#xff09;&#xff0c;\u6309\u300c\u7d27\u6025\u6062\u590d\u2192\u65e5\u5fd7\u6eaf\u6e90\u2192\u8d44\u6e90\u6392\u67e5\u2192\u6df1\u5ea6\u5b9a\u4f4d\u2192\u9884\u9632\u4f18\u5316\u300d\u4e94\u6b65\u6267\u884c&#xff0c;\u76f4\u63a5\u590d\u5236\u547d\u4ee4\u5373\u53ef\u64cd\u4f5c&#xff0c;\u8986\u76d6 90% \u5e38\u89c1\u5361\u6b7b\u573a\u666f&#xff1a; \u4e00\u3001\u7d27\u6025\u6062\u590d&#xff1a;\u5148\u89e3\u51b3\u300c\u8fde\u4e0d\u4e0a\u300d\u7684\u95ee\u9898&#xff08;5\u5206\u949f\u5185&#xff09; \u7cfb\u7edf\u5361\u6b7b\u65f6\u4f18\u5148\u6062\u590d\u53ef\u64cd\u4f5c\u6027&#xff0c;\u518d\u6392\u67e5\u6839\u56e0&#xff1a; \u7269\u7406","og_url":"https:\/\/www.wsisp.com\/helps\/64727.html","og_site_name":"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","article_published_time":"2026-01-23T16:16:40+00:00","author":"admin","twitter_card":"summary_large_image","twitter_misc":{"\u4f5c\u8005":"admin","\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4":"2 \u5206"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/www.wsisp.com\/helps\/64727.html","url":"https:\/\/www.wsisp.com\/helps\/64727.html","name":"\u670d\u52a1\u5668\u5361\u6b7b\u6392\u67e5\u6d41\u7a0b - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","isPartOf":{"@id":"https:\/\/www.wsisp.com\/helps\/#website"},"datePublished":"2026-01-23T16:16:40+00:00","dateModified":"2026-01-23T16:16:40+00:00","author":{"@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41"},"breadcrumb":{"@id":"https:\/\/www.wsisp.com\/helps\/64727.html#breadcrumb"},"inLanguage":"zh-Hans","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.wsisp.com\/helps\/64727.html"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.wsisp.com\/helps\/64727.html#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"\u9996\u9875","item":"https:\/\/www.wsisp.com\/helps"},{"@type":"ListItem","position":2,"name":"\u670d\u52a1\u5668\u5361\u6b7b\u6392\u67e5\u6d41\u7a0b"}]},{"@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\/64727","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=64727"}],"version-history":[{"count":0,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts\/64727\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/media?parent=64727"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/categories?post=64727"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/tags?post=64727"},{"taxonomy":"topic","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/topic?post=64727"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}