{"id":108557,"date":"2026-09-22T05:24:41","date_gmt":"2026-09-21T21:24:41","guid":{"rendered":"https:\/\/www.wsisp.com\/helps\/108557.html"},"modified":"2026-09-22T05:24:41","modified_gmt":"2026-09-21T21:24:41","slug":"%e6%9c%8d%e5%8a%a1%e5%99%a8%e5%ad%98%e5%82%a8%e7%b3%bb%e7%bb%9f%e5%8e%9f%e7%90%86%e4%b8%8e%e8%bf%90%e7%bb%b4%e5%ae%9e%e8%b7%b5%e8%a7%a3%e6%9e%90","status":"publish","type":"post","link":"https:\/\/www.wsisp.com\/helps\/108557.html","title":{"rendered":"\u670d\u52a1\u5668\u5b58\u50a8\u7cfb\u7edf\u539f\u7406\u4e0e\u8fd0\u7ef4\u5b9e\u8df5\u89e3\u6790"},"content":{"rendered":"<p>\u4e86\u89e3\u66f4\u591a\u94f6\u6cb3\u9e92\u9e9f\u64cd\u4f5c\u7cfb\u7edf\u5168\u65b0\u4ea7\u54c1&#xff0c;\u8bf7\u70b9\u51fb\u8bbf\u95ee&#xff1a;<\/p>\n<p>\u9e92\u9e9f\u8f6f\u4ef6\u4ea7\u54c1\u4e13\u533a&#xff1a;https:\/\/www.kylinos.cn\/productPc\/<\/p>\n<p>\u5f00\u53d1\u8005\u4e13\u533a&#xff1a;https:\/\/developer.kylinos.cn\/<\/p>\n<p>\u6587\u6863\u4e2d\u5fc3&#xff1a;https:\/\/document.kylinos.cn\/document\/center<\/p>\n<hr \/>\n<h2 id=\"main-toc\">\u76ee\u5f55<\/h2>\n<p id=\"%E4%B8%80%E3%80%81%20%E6%96%87%E6%A1%A3%E6%A6%82%E8%BF%B0-toc\" style=\"margin-left:0px\">\u4e00\u3001 \u6587\u6863\u6982\u8ff0<\/p>\n<p id=\"%E4%BA%8C%E3%80%81%20%E4%B8%BB%E8%A6%81%E5%86%85%E5%AE%B9-toc\" style=\"margin-left:0px\">\u4e8c\u3001 \u4e3b\u8981\u5185\u5bb9<\/p>\n<p id=\"1.%20Linux%E5%AD%98%E5%82%A8%E7%B3%BB%E7%BB%9F%E6%A0%B8%E5%BF%83%E6%9E%B6%E6%9E%84%E5%8E%9F%E7%90%86-toc\" style=\"margin-left:40px\">1. Linux\u5b58\u50a8\u7cfb\u7edf\u6838\u5fc3\u67b6\u6784\u539f\u7406<\/p>\n<p id=\"1.1%20%E5%88%86%E5%B1%82%E6%9E%B6%E6%9E%84%E8%A7%A3%E6%9E%90-toc\" style=\"margin-left:80px\">1.1 \u5206\u5c42\u67b6\u6784\u89e3\u6790<\/p>\n<p id=\"1.2%20%E6%A0%B8%E5%BF%83%E6%95%B0%E6%8D%AE%E6%B5%81%E8%BD%AC%E6%9C%BA%E5%88%B6-toc\" style=\"margin-left:80px\">1.2 \u6838\u5fc3\u6570\u636e\u6d41\u8f6c\u673a\u5236<\/p>\n<p id=\"2.%20%E4%B8%BB%E6%B5%81%E6%96%87%E4%BB%B6%E7%B3%BB%E7%BB%9F%E5%8E%9F%E7%90%86%E4%B8%8E%E5%AF%B9%E6%AF%94-toc\" style=\"margin-left:40px\">2. \u4e3b\u6d41\u6587\u4ef6\u7cfb\u7edf\u539f\u7406\u4e0e\u5bf9\u6bd4<\/p>\n<p id=\"2.1%20%E6%A0%B8%E5%BF%83%E8%AE%BE%E8%AE%A1%E5%8E%9F%E7%90%86%E5%B7%AE%E5%BC%82-toc\" style=\"margin-left:80px\">2.1 \u6838\u5fc3\u8bbe\u8ba1\u539f\u7406\u5dee\u5f02<\/p>\n<p id=\"2.1.1%20ext4%E6%96%87%E4%BB%B6%E7%B3%BB%E7%BB%9F-toc\" style=\"margin-left:120px\">2.1.1 ext4\u6587\u4ef6\u7cfb\u7edf<\/p>\n<p id=\"2.1.2%20XFS%E6%96%87%E4%BB%B6%E7%B3%BB%E7%BB%9F-toc\" style=\"margin-left:120px\">2.1.2 XFS\u6587\u4ef6\u7cfb\u7edf<\/p>\n<p id=\"2.1.3%20Btrfs%E6%96%87%E4%BB%B6%E7%B3%BB%E7%BB%9F-toc\" style=\"margin-left:120px\">2.1.3 Btrfs\u6587\u4ef6\u7cfb\u7edf<\/p>\n<p id=\"2.2%20%E9%80%82%E7%94%A8%E5%9C%BA%E6%99%AF%E5%AF%B9%E6%AF%94-toc\" style=\"margin-left:80px\">2.2 \u9002\u7528\u573a\u666f\u5bf9\u6bd4<\/p>\n<p id=\"3.%20%E5%AD%98%E5%82%A8%E5%B8%B8%E8%A7%81%E9%97%AE%E9%A2%98%E5%88%86%E6%9E%90%E4%B8%8E%E6%A0%B9%E5%9B%A0%E5%AE%9A%E4%BD%8D-toc\" style=\"margin-left:40px\">3. \u5b58\u50a8\u5e38\u89c1\u95ee\u9898\u5206\u6790\u4e0e\u6839\u56e0\u5b9a\u4f4d<\/p>\n<p id=\"3.1%20%E7%A3%81%E7%9B%98%E6%95%85%E9%9A%9C%E9%97%AE%E9%A2%98-toc\" style=\"margin-left:80px\">3.1 \u78c1\u76d8\u6545\u969c\u95ee\u9898<\/p>\n<p id=\"3.2%20inode%E8%80%97%E5%B0%BD%E9%97%AE%E9%A2%98-toc\" style=\"margin-left:80px\">3.2 inode\u8017\u5c3d\u95ee\u9898<\/p>\n<p id=\"3.3%20IO%E6%80%A7%E8%83%BD%E5%8D%A1%E9%A1%BF%E9%97%AE%E9%A2%98-toc\" style=\"margin-left:80px\">3.3 IO\u6027\u80fd\u5361\u987f\u95ee\u9898<\/p>\n<p id=\"4.%20%E5%AD%98%E5%82%A8%E7%B3%BB%E7%BB%9F%E4%BC%98%E5%8C%96%E5%AE%9E%E8%B7%B5%E4%B8%8E%E5%BF%83%E5%BE%97-toc\" style=\"margin-left:40px\">4. \u5b58\u50a8\u7cfb\u7edf\u4f18\u5316\u5b9e\u8df5\u4e0e\u5fc3\u5f97<\/p>\n<p id=\"4.1%20%E7%A1%AC%E4%BB%B6%E9%80%89%E5%9E%8B%E6%A0%B8%E5%BF%83%E5%8E%9F%E5%88%99-toc\" style=\"margin-left:80px\">4.1 \u786c\u4ef6\u9009\u578b\u6838\u5fc3\u539f\u5219<\/p>\n<p id=\"4.2%20%E5%86%85%E6%A0%B8%E4%B8%8E%E6%96%87%E4%BB%B6%E7%B3%BB%E7%BB%9F%E8%B0%83%E4%BC%98%E5%AE%9E%E6%88%98-toc\" style=\"margin-left:80px\">4.2 \u5185\u6838\u4e0e\u6587\u4ef6\u7cfb\u7edf\u8c03\u4f18\u5b9e\u6218<\/p>\n<p id=\"4.2.2%20%E6%96%87%E4%BB%B6%E7%B3%BB%E7%BB%9F%E9%85%8D%E7%BD%AE%E4%BC%98%E5%8C%96-toc\" style=\"margin-left:120px\">4.2.2 \u6587\u4ef6\u7cfb\u7edf\u914d\u7f6e\u4f18\u5316<\/p>\n<p id=\"4.3%20%E8%BF%90%E7%BB%B4%E5%AE%9E%E8%B7%B5%E5%BF%83%E5%BE%97-toc\" style=\"margin-left:80px\">4.3 \u8fd0\u7ef4\u5b9e\u8df5\u5fc3\u5f97<\/p>\n<p id=\"%E4%B8%89%E3%80%81%20%E9%99%84%E5%BD%95-toc\" style=\"margin-left:0px\">\u4e09\u3001 \u9644\u5f55<\/p>\n<hr \/>\n<h2 id=\"%E4%B8%80%E3%80%81%20%E6%96%87%E6%A1%A3%E6%A6%82%E8%BF%B0\">\u4e00\u3001 \u6587\u6863\u6982\u8ff0<\/h2>\n<p>\u672c\u624b\u518c\u65e8\u5728\u6df1\u5165\u89e3\u6790\u670d\u52a1\u5668\u5b58\u50a8\u7cfb\u7edf\u7684\u5e95\u5c42\u67b6\u6784\u4e0e\u6838\u5fc3\u539f\u7406&#xff0c;\u4e3a\u8fd0\u7ef4\u4eba\u5458\u63d0\u4f9b\u7cfb\u7edf\u7684\u5b58\u50a8\u7ba1\u7406\u77e5\u8bc6\u4f53\u7cfb\u3002\u7f16\u5199\u80cc\u666f\u6e90\u4e8e\u751f\u4ea7\u73af\u5883\u4e2d\u9891\u7e41\u51fa\u73b0\u7684\u5b58\u50a8\u6027\u80fd\u74f6\u9888\u3001\u6587\u4ef6\u7cfb\u7edf\u635f\u574f\u3001\u78c1\u76d8\u6545\u969c\u5bfc\u81f4\u7684\u6570\u636e\u4e22\u5931\u7b49\u95ee\u9898&#xff0c;\u591a\u6570\u95ee\u9898\u6839\u6e90\u5728\u4e8e\u8fd0\u7ef4\u4eba\u5458\u5bf9\u5b58\u50a8\u7cfb\u7edf\u7684\u5206\u5c42\u67b6\u6784\u3001\u6587\u4ef6\u7cfb\u7edf\u5de5\u4f5c\u673a\u5236\u53ca\u5b58\u50a8IO\u8c03\u5ea6\u903b\u8f91\u7406\u89e3\u4e0d\u900f\u5f7b&#xff0c;\u5bfc\u81f4\u6545\u969c\u6392\u67e5\u6548\u7387\u4f4e\u3001\u4f18\u5316\u63aa\u65bd\u9488\u5bf9\u6027\u4e0d\u8db3\u3002<\/p>\n<p>\u624b\u518c\u6838\u5fc3\u5185\u5bb9\u5305\u62ecLinux\u5b58\u50a8\u7cfb\u7edf\u7684\u201c\u786c\u4ef6-\u5185\u6838-\u6587\u4ef6\u7cfb\u7edf-\u5e94\u7528\u201d\u56db\u5c42\u67b6\u6784\u539f\u7406\u3001\u4e3b\u6d41\u6587\u4ef6\u7cfb\u7edf&#xff08;ext4\/XFS\/Btrfs&#xff09;\u7684\u5e95\u5c42\u5dee\u5f02\u3001\u5b58\u50a8IO\u8c03\u5ea6\u673a\u5236\u3001\u5e38\u89c1\u5b58\u50a8\u95ee\u9898&#xff08;\u5982\u78c1\u76d8\u574f\u9053\u3001inode\u8017\u5c3d\u3001IO\u5361\u987f&#xff09;\u7684\u6839\u56e0\u5206\u6790\u65b9\u6cd5&#xff0c;\u4ee5\u53ca\u9488\u5bf9\u4e0d\u540c\u4e1a\u52a1\u573a\u666f&#xff08;\u5982\u6570\u636e\u5e93\u3001\u5927\u6570\u636e\u3001\u9759\u6001\u8d44\u6e90\u5b58\u50a8&#xff09;\u7684\u5b58\u50a8\u4f18\u5316\u65b9\u6848\u4e0e\u8fd0\u7ef4\u5fc3\u5f97\u3002\u901a\u8fc7\u672c\u624b\u518c&#xff0c;\u53ef\u5e2e\u52a9\u8fd0\u7ef4\u4eba\u5458\u4ece\u539f\u7406\u5c42\u9762\u638c\u63e1\u5b58\u50a8\u7cfb\u7edf\u89c4\u5f8b&#xff0c;\u63d0\u5347\u5b58\u50a8\u76f8\u5173\u6545\u969c\u7684\u6392\u67e5\u6548\u7387\u4e0e\u4f18\u5316\u80fd\u529b&#xff0c;\u964d\u4f4e\u6570\u636e\u4e22\u5931\u98ce\u9669\u3002<\/p>\n<\/p>\n<h2 id=\"%E4%BA%8C%E3%80%81%20%E4%B8%BB%E8%A6%81%E5%86%85%E5%AE%B9\">\u4e8c\u3001 \u4e3b\u8981\u5185\u5bb9<\/h2>\n<h3 id=\"1.%20Linux%E5%AD%98%E5%82%A8%E7%B3%BB%E7%BB%9F%E6%A0%B8%E5%BF%83%E6%9E%B6%E6%9E%84%E5%8E%9F%E7%90%86\">1. Linux\u5b58\u50a8\u7cfb\u7edf\u6838\u5fc3\u67b6\u6784\u539f\u7406<\/h3>\n<p>Linux\u5b58\u50a8\u7cfb\u7edf\u91c7\u7528\u5206\u5c42\u67b6\u6784\u8bbe\u8ba1&#xff0c;\u4ece\u5e95\u5c42\u5230\u4e0a\u5c42\u4f9d\u6b21\u4e3a\u201c\u786c\u4ef6\u5c42-\u5185\u6838\u5b58\u50a8\u5b50\u7cfb\u7edf\u5c42-\u6587\u4ef6\u7cfb\u7edf\u5c42-\u5e94\u7528\u5c42\u201d&#xff0c;\u5404\u5c42\u7ea7\u901a\u8fc7\u6807\u51c6\u5316\u63a5\u53e3\u534f\u540c\u5de5\u4f5c&#xff0c;\u65e2\u4fdd\u8bc1\u4e86\u786c\u4ef6\u7684\u517c\u5bb9\u6027&#xff0c;\u53c8\u4e3a\u5e94\u7528\u63d0\u4f9b\u4e86\u7edf\u4e00\u7684\u5b58\u50a8\u8bbf\u95ee\u63a5\u53e3\u3002\u8fd9\u79cd\u5206\u5c42\u67b6\u6784\u7684\u6838\u5fc3\u4f18\u52bf\u662f\u201c\u89e3\u8026\u201d&#xff0c;\u67d0\u4e00\u5c42\u7ea7\u7684\u53d8\u66f4&#xff08;\u5982\u66f4\u6362\u78c1\u76d8\u54c1\u724c\u3001\u5207\u6362\u6587\u4ef6\u7cfb\u7edf&#xff09;\u4e0d\u4f1a\u5f71\u54cd\u5176\u4ed6\u5c42\u7ea7\u7684\u6b63\u5e38\u8fd0\u884c\u3002<\/p>\n<h4 id=\"1.1%20%E5%88%86%E5%B1%82%E6%9E%B6%E6%9E%84%E8%A7%A3%E6%9E%90\">1.1 \u5206\u5c42\u67b6\u6784\u89e3\u6790<\/h4>\n<li>\u786c\u4ef6\u5c42&#xff1a;\u5b58\u50a8\u7cfb\u7edf\u7684\u7269\u7406\u57fa\u7840&#xff0c;\u5305\u62ec\u672c\u5730\u5b58\u50a8&#xff08;\u673a\u68b0\u786c\u76d8HDD\u3001\u56fa\u6001\u786c\u76d8SSD\u3001NVMe\u786c\u76d8&#xff09;\u548c\u7f51\u7edc\u5b58\u50a8&#xff08;SAN\u3001NAS\u3001\u5206\u5e03\u5f0f\u5b58\u50a8\u5982Ceph&#xff09;\u3002\u4e0d\u540c\u786c\u4ef6\u7684\u6027\u80fd\u5dee\u5f02\u663e\u8457&#xff0c;HDD\u4f9d\u8d56\u673a\u68b0\u81c2\u5bfb\u9053&#xff0c;\u968f\u673aIO\u6027\u80fd\u8f83\u5f31&#xff08;IOPS\u7ea6100-200&#xff09;&#xff1b;SSD\u57fa\u4e8e\u95ea\u5b58\u82af\u7247&#xff0c;\u968f\u673aIO\u6027\u80fd\u63d0\u534710-100\u500d&#xff08;IOPS\u7ea61\u4e07-10\u4e07&#xff09;&#xff1b;NVMe\u786c\u76d8\u901a\u8fc7PCIe\u76f4\u8fde&#xff0c;\u6027\u80fd\u518d\u63d0\u5347\u4e00\u4e2a\u91cf\u7ea7&#xff08;IOPS\u53ef\u8fbe10\u4e07-100\u4e07&#xff09;\u3002<\/li>\n<li>\u5185\u6838\u5b58\u50a8\u5b50\u7cfb\u7edf\u5c42&#xff1a;\u8fde\u63a5\u786c\u4ef6\u4e0e\u6587\u4ef6\u7cfb\u7edf\u7684\u6838\u5fc3\u6865\u6881&#xff0c;\u5305\u62ec\u8bbe\u5907\u9a71\u52a8\u3001IO\u8c03\u5ea6\u5668\u3001\u5757\u8bbe\u5907\u5c42\u3002\u8bbe\u5907\u9a71\u52a8\u8d1f\u8d23\u4e0e\u786c\u4ef6\u4ea4\u4e92&#xff0c;\u5c06\u786c\u4ef6\u6307\u4ee4\u8f6c\u6362\u4e3a\u5185\u6838\u53ef\u8bc6\u522b\u7684\u6807\u51c6\u63a5\u53e3&#xff1b;IO\u8c03\u5ea6\u5668\u8d1f\u8d23\u5bf9\u5e94\u7528\u4e0b\u53d1\u7684IO\u8bf7\u6c42\u8fdb\u884c\u6392\u5e8f\u548c\u5408\u5e76&#xff0c;\u4f18\u5316\u78c1\u76d8\u5bfb\u9053\u6548\u7387&#xff1b;\u5757\u8bbe\u5907\u5c42\u5c06\u4e0d\u540c\u786c\u4ef6\u62bd\u8c61\u4e3a\u7edf\u4e00\u7684\u5757\u8bbe\u5907&#xff08;\u5982\/dev\/sda\u3001\/dev\/nvme0n1&#xff09;&#xff0c;\u4e3a\u4e0a\u5c42\u6587\u4ef6\u7cfb\u7edf\u63d0\u4f9b\u7edf\u4e00\u7684\u8bbf\u95ee\u63a5\u53e3\u3002<\/li>\n<li>\u6587\u4ef6\u7cfb\u7edf\u5c42&#xff1a;\u8d1f\u8d23\u5c06\u5757\u8bbe\u5907\u7684\u539f\u59cb\u5b58\u50a8\u7a7a\u95f4\u62bd\u8c61\u4e3a\u201c\u6587\u4ef6-\u76ee\u5f55\u201d\u7684\u6811\u5f62\u7ed3\u6784&#xff0c;\u7ba1\u7406\u6587\u4ef6\u7684\u5143\u6570\u636e&#xff08;\u6743\u9650\u3001\u5927\u5c0f\u3001\u4fee\u6539\u65f6\u95f4&#xff09;\u548c\u6570\u636e\u5b58\u50a8\u4f4d\u7f6e\u3002\u5176\u6838\u5fc3\u4f5c\u7528\u662f\u89e3\u51b3\u201c\u5982\u4f55\u9ad8\u6548\u7ec4\u7ec7\u548c\u7ba1\u7406\u78c1\u76d8\u7a7a\u95f4\u201d\u7684\u95ee\u9898&#xff0c;\u4e0d\u540c\u6587\u4ef6\u7cfb\u7edf\u7684\u7ec4\u7ec7\u65b9\u5f0f\u5dee\u5f02\u76f4\u63a5\u51b3\u5b9a\u4e86\u5b58\u50a8\u6027\u80fd\u548c\u529f\u80fd&#xff08;\u5982\u662f\u5426\u652f\u6301\u5feb\u7167\u3001\u6269\u5bb9&#xff09;\u3002<\/li>\n<li>\u5e94\u7528\u5c42&#xff1a;\u901a\u8fc7\u7cfb\u7edf\u8c03\u7528&#xff08;\u5982open\u3001read\u3001write&#xff09;\u8bbf\u95ee\u6587\u4ef6\u7cfb\u7edf&#xff0c;\u65e0\u9700\u5173\u6ce8\u5e95\u5c42\u786c\u4ef6\u7ec6\u8282\u3002\u4e0d\u540c\u5e94\u7528\u7684IO\u7279\u5f81\u5dee\u5f02\u663e\u8457&#xff0c;\u5982\u6570\u636e\u5e93&#xff08;MySQL&#xff09;\u4ee5\u5c0f\u6587\u4ef6\u968f\u673a\u8bfb\u5199\u4e3a\u4e3b&#xff0c;\u89c6\u9891\u670d\u52a1\u5668\u4ee5\u5927\u6587\u4ef6\u987a\u5e8f\u8bfb\u5199\u4e3a\u4e3b&#xff0c;\u8fd9\u4e9b\u5dee\u5f02\u51b3\u5b9a\u4e86\u5b58\u50a8\u4f18\u5316\u7684\u65b9\u5411\u3002<\/li>\n<h4 id=\"1.2%20%E6%A0%B8%E5%BF%83%E6%95%B0%E6%8D%AE%E6%B5%81%E8%BD%AC%E6%9C%BA%E5%88%B6\">1.2 \u6838\u5fc3\u6570\u636e\u6d41\u8f6c\u673a\u5236<\/h4>\n<p>\u5e94\u7528\u8bfb\u53d6\u6587\u4ef6\u7684\u5b8c\u6574\u6d41\u7a0b\u53ef\u6e05\u6670\u4f53\u73b0\u5404\u5c42\u7ea7\u7684\u534f\u540c\u5de5\u4f5c&#xff1a;\u5f53\u5e94\u7528\u8c03\u7528read()\u7cfb\u7edf\u8c03\u7528\u8bfb\u53d6\u67d0\u6587\u4ef6\u65f6&#xff0c;\u9996\u5148\u901a\u8fc7\u6587\u4ef6\u7cfb\u7edf\u5c42\u67e5\u627e\u8be5\u6587\u4ef6\u7684inode&#xff08;\u7d22\u5f15\u8282\u70b9&#xff09;&#xff0c;\u83b7\u53d6\u6570\u636e\u6240\u5728\u7684\u78c1\u76d8\u5757\u5730\u5740&#xff1b;\u968f\u540e\u6587\u4ef6\u7cfb\u7edf\u5c42\u5c06\u8bfb\u53d6\u8bf7\u6c42\u8f6c\u6362\u4e3a\u5757\u8bbe\u5907\u7684IO\u8bf7\u6c42&#xff0c;\u63d0\u4ea4\u7ed9\u5185\u6838\u5b58\u50a8\u5b50\u7cfb\u7edf\u5c42&#xff1b;IO\u8c03\u5ea6\u5668\u5bf9\u8be5\u8bf7\u6c42\u8fdb\u884c\u6392\u5e8f&#xff08;\u5982\u5408\u5e76\u76f8\u90bb\u7684\u8bfb\u53d6\u8bf7\u6c42&#xff09;\u540e&#xff0c;\u901a\u8fc7\u8bbe\u5907\u9a71\u52a8\u4e0b\u53d1\u7ed9\u786c\u4ef6\u5c42&#xff1b;\u786c\u4ef6\u5c42\u5b8c\u6210\u6570\u636e\u8bfb\u53d6\u540e&#xff0c;\u901a\u8fc7\u53cd\u5411\u6d41\u7a0b\u5c06\u6570\u636e\u8fd4\u56de\u7ed9\u5e94\u7528\u3002<\/p>\n<p>\u5728\u8fd9\u4e2a\u8fc7\u7a0b\u4e2d&#xff0c;\u5185\u6838\u4f1a\u901a\u8fc7\u201c\u9875\u7f13\u5b58&#xff08;Page Cache&#xff09;\u201d\u4f18\u5316\u6027\u80fd&#xff1a;\u5c06\u8bfb\u53d6\u8fc7\u7684\u6587\u4ef6\u6570\u636e\u7f13\u5b58\u5230\u5185\u5b58\u4e2d&#xff0c;\u5f53\u5e94\u7528\u518d\u6b21\u8bfb\u53d6\u76f8\u540c\u6570\u636e\u65f6&#xff0c;\u76f4\u63a5\u4ece\u9875\u7f13\u5b58\u8fd4\u56de&#xff0c;\u65e0\u9700\u8bbf\u95ee\u78c1\u76d8&#xff0c;\u5927\u5e45\u63d0\u5347\u8bfb\u53d6\u901f\u5ea6\u3002\u800c\u5199\u5165\u64cd\u4f5c\u5219\u91c7\u7528\u201c\u5199\u7f13\u5b58&#043;\u5f02\u6b65\u5237\u76d8\u201d\u673a\u5236&#xff0c;\u5e94\u7528\u5199\u5165\u7684\u6570\u636e\u5148\u5b58\u5165\u9875\u7f13\u5b58\u5e76\u6807\u8bb0\u4e3a\u201c\u810f\u9875\u201d&#xff0c;\u968f\u540e\u7acb\u5373\u8fd4\u56de&#xff0c;\u5185\u6838\u540e\u53f0\u7ebf\u7a0b&#xff08;\u5982flusher&#xff09;\u518d\u5c06\u810f\u9875\u5f02\u6b65\u5237\u5199\u5230\u78c1\u76d8&#xff0c;\u5e73\u8861\u5199\u5165\u6027\u80fd\u4e0e\u6570\u636e\u5b89\u5168\u6027\u3002<\/p>\n<h3 id=\"2.%20%E4%B8%BB%E6%B5%81%E6%96%87%E4%BB%B6%E7%B3%BB%E7%BB%9F%E5%8E%9F%E7%90%86%E4%B8%8E%E5%AF%B9%E6%AF%94\">2. \u4e3b\u6d41\u6587\u4ef6\u7cfb\u7edf\u539f\u7406\u4e0e\u5bf9\u6bd4<\/h3>\n<p>\u6587\u4ef6\u7cfb\u7edf\u662f\u5b58\u50a8\u7cfb\u7edf\u7684\u201c\u7075\u9b42\u201d&#xff0c;\u5176\u6838\u5fc3\u529f\u80fd\u5305\u62ec\u7a7a\u95f4\u7ba1\u7406\u3001\u5143\u6570\u636e\u7ba1\u7406\u3001\u6570\u636e\u5bb9\u9519\u7b49\u3002Linux\u4e3b\u6d41\u6587\u4ef6\u7cfb\u7edf\u5305\u62ecext4&#xff08;\u5e94\u7528\u6700\u5e7f\u6cdb&#xff09;\u3001XFS&#xff08;\u9ad8\u6027\u80fd\u5927\u5bb9\u91cf&#xff09;\u3001Btrfs&#xff08;\u529f\u80fd\u4e30\u5bcc&#xff09;&#xff0c;\u4e09\u8005\u5728\u5e95\u5c42\u8bbe\u8ba1\u4e0a\u5b58\u5728\u663e\u8457\u5dee\u5f02&#xff0c;\u9002\u7528\u573a\u666f\u4e5f\u5404\u4e0d\u76f8\u540c\u3002<\/p>\n<h4 id=\"2.1%20%E6%A0%B8%E5%BF%83%E8%AE%BE%E8%AE%A1%E5%8E%9F%E7%90%86%E5%B7%AE%E5%BC%82\">2.1 \u6838\u5fc3\u8bbe\u8ba1\u539f\u7406\u5dee\u5f02<\/h4>\n<h5 id=\"2.1.1%20ext4%E6%96%87%E4%BB%B6%E7%B3%BB%E7%BB%9F\">2.1.1 ext4\u6587\u4ef6\u7cfb\u7edf<\/h5>\n<p>ext4\u662fext\u7cfb\u5217\u6587\u4ef6\u7cfb\u7edf\u7684\u8fed\u4ee3\u7248\u672c&#xff0c;\u57fa\u4e8e\u201c\u7d22\u5f15\u8282\u70b9&#043;\u6570\u636e\u5757\u201d\u7684\u7ecf\u5178\u8bbe\u8ba1&#xff0c;\u517c\u5bb9ext2\/ext3&#xff0c;\u662f\u591a\u6570Linux\u53d1\u884c\u7248\u7684\u9ed8\u8ba4\u6587\u4ef6\u7cfb\u7edf\u3002\u5176\u6838\u5fc3\u8bbe\u8ba1\u5305\u62ec&#xff1a;<\/p>\n<ul>\n<li>\u7a7a\u95f4\u7ba1\u7406&#xff1a;\u91c7\u7528\u201c\u5757\u7ec4\u201d\u673a\u5236&#xff0c;\u5c06\u78c1\u76d8\u5212\u5206\u4e3a\u591a\u4e2a\u5757\u7ec4&#xff0c;\u6bcf\u4e2a\u5757\u7ec4\u5305\u542b\u8d85\u7ea7\u5757\u3001inode\u8868\u3001\u6570\u636e\u5757&#xff0c;\u51cf\u5c11\u78c1\u76d8\u5bfb\u9053\u65f6\u95f4&#xff1b;\u652f\u6301\u201cextent&#xff08;\u8fde\u7eed\u6570\u636e\u5757&#xff09;\u201d\u673a\u5236&#xff0c;\u5bf9\u5927\u6587\u4ef6\u91c7\u7528\u8fde\u7eed\u5757\u5b58\u50a8&#xff0c;\u63d0\u5347\u8bfb\u5199\u6027\u80fd\u3002<\/li>\n<li>\u5143\u6570\u636e\u7ba1\u7406&#xff1a;inode\u9759\u6001\u5206\u914d&#xff08;\u683c\u5f0f\u5316\u65f6\u6307\u5b9ainode\u6570\u91cf\u548c\u5927\u5c0f&#xff09;&#xff0c;\u6bcf\u4e2ainode\u5bf9\u5e94\u4e00\u4e2a\u6587\u4ef6&#xff0c;\u5b58\u50a8\u6587\u4ef6\u5143\u6570\u636e\u548c\u6570\u636e\u5757\u6307\u9488&#xff08;\u76f4\u63a5\u6307\u9488\u3001\u4e00\u7ea7\u95f4\u63a5\u6307\u9488\u3001\u4e8c\u7ea7\u95f4\u63a5\u6307\u9488\u3001\u4e09\u7ea7\u95f4\u63a5\u6307\u9488&#xff09;&#xff0c;\u6700\u5927\u652f\u630116TB\u5355\u4e2a\u6587\u4ef6\u3002<\/li>\n<li>\u5bb9\u9519\u673a\u5236&#xff1a;\u652f\u6301\u65e5\u5fd7&#xff08;Journal&#xff09;\u529f\u80fd&#xff0c;\u5c06\u6587\u4ef6\u7cfb\u7edf\u7684\u53d8\u66f4\u64cd\u4f5c\u5148\u5199\u5165\u65e5\u5fd7&#xff0c;\u518d\u5e94\u7528\u5230\u6587\u4ef6\u7cfb\u7edf&#xff0c;\u907f\u514d\u610f\u5916\u65ad\u7535\u5bfc\u81f4\u7684\u6587\u4ef6\u7cfb\u7edf\u635f\u574f\u3002<\/li>\n<\/ul>\n<h5 id=\"2.1.2%20XFS%E6%96%87%E4%BB%B6%E7%B3%BB%E7%BB%9F\">2.1.2 XFS\u6587\u4ef6\u7cfb\u7edf<\/h5>\n<p>XFS\u662f\u7531SGI\u5f00\u53d1\u7684\u9ad8\u6027\u80fd\u6587\u4ef6\u7cfb\u7edf&#xff0c;\u4e13\u4e3a\u5927\u5bb9\u91cf\u5b58\u50a8\u548c\u9ad8\u5e76\u53d1IO\u8bbe\u8ba1&#xff0c;\u5728\u4f01\u4e1a\u7ea7\u5b58\u50a8\u573a\u666f&#xff08;\u5982\u5927\u6570\u636e\u3001\u89c6\u9891\u5b58\u50a8&#xff09;\u4e2d\u5e94\u7528\u5e7f\u6cdb\u3002\u5176\u6838\u5fc3\u4f18\u52bf\u5728\u4e8e&#xff1a;<\/p>\n<ul>\n<li>\u7a7a\u95f4\u7ba1\u7406&#xff1a;\u91c7\u7528B&#043;\u6811\u7ba1\u7406extent&#xff0c;\u652f\u6301PB\u7ea7\u78c1\u76d8\u5bb9\u91cf\u548c\u767eGB\u7ea7\u5355\u4e2a\u6587\u4ef6&#xff0c;extent\u7684\u52a8\u6001\u5206\u914d\u673a\u5236\u907f\u514d\u4e86\u7a7a\u95f4\u788e\u7247&#xff1b;\u652f\u6301\u5728\u7ebf\u6269\u5bb9&#xff08;xfs_growfs\u547d\u4ee4&#xff09;&#xff0c;\u4e14\u6269\u5bb9\u8fc7\u7a0b\u4e0d\u5f71\u54cd\u4e1a\u52a1\u8fd0\u884c\u3002<\/li>\n<li>\u5143\u6570\u636e\u7ba1\u7406&#xff1a;inode\u52a8\u6001\u5206\u914d&#xff0c;\u968f\u6587\u4ef6\u521b\u5efa\u800c\u751f\u6210&#xff0c;\u65e0inode\u8017\u5c3d\u98ce\u9669&#xff1b;\u5143\u6570\u636e\u4e0e\u6570\u636e\u5206\u5f00\u5b58\u50a8&#xff0c;\u91c7\u7528\u72ec\u7acb\u7684\u65e5\u5fd7\u5206\u533a&#xff0c;\u65e5\u5fd7\u6821\u9a8c\u673a\u5236\u63d0\u5347\u4e86\u6545\u969c\u6062\u590d\u901f\u5ea6\u3002<\/li>\n<li>\u5e76\u53d1\u6027\u80fd&#xff1a;\u652f\u6301\u7ec6\u7c92\u5ea6\u9501\u673a\u5236&#xff0c;\u591a\u4e2a\u8fdb\u7a0b\u53ef\u540c\u65f6\u8bfb\u5199\u4e0d\u540c\u6587\u4ef6\u6216\u540c\u4e00\u6587\u4ef6\u7684\u4e0d\u540c\u90e8\u5206&#xff0c;\u9ad8\u5e76\u53d1\u573a\u666f\u4e0b\u6027\u80fd\u4f18\u4e8eext4\u3002<\/li>\n<\/ul>\n<h5 id=\"2.1.3%20Btrfs%E6%96%87%E4%BB%B6%E7%B3%BB%E7%BB%9F\">2.1.3 Btrfs\u6587\u4ef6\u7cfb\u7edf<\/h5>\n<p>Btrfs&#xff08;B-tree File System&#xff09;\u662f\u9762\u5411\u4e0b\u4e00\u4ee3\u7684\u6587\u4ef6\u7cfb\u7edf&#xff0c;\u4ee5\u201c\u529f\u80fd\u4e30\u5bcc\u201d\u4e3a\u6838\u5fc3\u7279\u70b9&#xff0c;\u652f\u6301\u5feb\u7167\u3001\u514b\u9686\u3001RAID\u3001\u900f\u660e\u538b\u7f29\u7b49\u9ad8\u7ea7\u529f\u80fd&#xff0c;\u9002\u7528\u4e8e\u5bf9\u6570\u636e\u53ef\u9760\u6027\u548c\u7ba1\u7406\u7075\u6d3b\u6027\u8981\u6c42\u9ad8\u7684\u573a\u666f\u3002\u5176\u6838\u5fc3\u8bbe\u8ba1\u5305\u62ec&#xff1a;<\/p>\n<ul>\n<li>\u6570\u636e\u7ed3\u6784&#xff1a;\u91c7\u7528B&#043;\u6811\u7684\u53d8\u79cd\u201cB-tree\u201d\u7edf\u4e00\u7ba1\u7406\u5143\u6570\u636e\u548c\u6570\u636e&#xff0c;\u6240\u6709\u6570\u636e&#xff08;\u5305\u62ecinode\u3001\u76ee\u5f55\u9879\u3001\u6570\u636e\u5757&#xff09;\u90fd\u5b58\u50a8\u5728B-tree\u4e2d&#xff0c;\u63d0\u5347\u67e5\u8be2\u6548\u7387\u3002<\/li>\n<li>\u9ad8\u7ea7\u529f\u80fd&#xff1a;\u652f\u6301\u201c\u5199\u65f6\u590d\u5236&#xff08;COW&#xff09;\u201d\u673a\u5236&#xff0c;\u521b\u5efa\u5feb\u7167\u548c\u514b\u9686\u65f6\u4ec5\u590d\u5236\u5143\u6570\u636e&#xff0c;\u4e0d\u590d\u5236\u5b9e\u9645\u6570\u636e&#xff0c;\u8282\u7701\u7a7a\u95f4&#xff1b;\u652f\u6301RAID 0\/1\/5\/6&#xff0c;\u65e0\u9700\u4f9d\u8d56\u786c\u4ef6RAID\u5361&#xff1b;\u652f\u6301\u900f\u660e\u538b\u7f29&#xff08;zlib\u3001lzo\u7b97\u6cd5&#xff09;\u548c\u6570\u636e\u6821\u9a8c&#xff0c;\u63d0\u5347\u6570\u636e\u5b89\u5168\u6027\u3002<\/li>\n<\/ul>\n<h4 id=\"2.2%20%E9%80%82%E7%94%A8%E5%9C%BA%E6%99%AF%E5%AF%B9%E6%AF%94\">2.2 \u9002\u7528\u573a\u666f\u5bf9\u6bd4<\/h4>\n<table>\n<tbody>\n<tr>\n<td>\n<p>\u5bf9\u6bd4\u7ef4\u5ea6<\/p>\n<\/td>\n<td>\n<p>ext4<\/p>\n<\/td>\n<td>\n<p>XFS<\/p>\n<\/td>\n<td>\n<p>Btrfs<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p>\u5355\u76d8\u6700\u5927\u5bb9\u91cf<\/p>\n<\/td>\n<td>\n<p>1EB<\/p>\n<\/td>\n<td>\n<p>8EB<\/p>\n<\/td>\n<td>\n<p>16EB<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p>\u5355\u4e2a\u6587\u4ef6\u6700\u5927<\/p>\n<\/td>\n<td>\n<p>16TB<\/p>\n<\/td>\n<td>\n<p>8EB<\/p>\n<\/td>\n<td>\n<p>16EB<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p>\u5c0f\u6587\u4ef6\u6027\u80fd<\/p>\n<\/td>\n<td>\n<p>\u4f18\u79c0<\/p>\n<\/td>\n<td>\n<p>\u826f\u597d<\/p>\n<\/td>\n<td>\n<p>\u826f\u597d&#xff08;\u538b\u7f29\u540e\u66f4\u4f18&#xff09;<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p>\u5927\u6587\u4ef6\/\u5e76\u53d1IO<\/p>\n<\/td>\n<td>\n<p>\u826f\u597d<\/p>\n<\/td>\n<td>\n<p>\u4f18\u79c0<\/p>\n<\/td>\n<td>\n<p>\u826f\u597d<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p>\u5feb\u7167\/\u514b\u9686\u529f\u80fd<\/p>\n<\/td>\n<td>\n<p>\u4e0d\u652f\u6301<\/p>\n<\/td>\n<td>\n<p>\u652f\u6301&#xff08;\u9700\u7b2c\u4e09\u65b9\u5de5\u5177&#xff09;<\/p>\n<\/td>\n<td>\n<p>\u539f\u751f\u652f\u6301&#xff08;\u9ad8\u6548&#xff09;<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p>\u63a8\u8350\u573a\u666f<\/p>\n<\/td>\n<td>\n<p>\u7cfb\u7edf\u76d8\u3001\u5c0f\u6587\u4ef6\u5bc6\u96c6&#xff08;\u4ee3\u7801\u4ed3\u3001\u7f13\u5b58&#xff09;<\/p>\n<\/td>\n<td>\n<p>\u5927\u5bb9\u91cf\u5b58\u50a8\u3001\u9ad8\u5e76\u53d1IO&#xff08;\u5927\u6570\u636e\u3001\u89c6\u9891&#xff09;<\/p>\n<\/td>\n<td>\n<p>\u6570\u636e\u5907\u4efd\u3001\u9700\u8981\u5feb\u7167\/\u538b\u7f29&#xff08;\u6570\u636e\u5e93\u5907\u4efd&#xff09;<\/p>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h3 id=\"3.%20%E5%AD%98%E5%82%A8%E5%B8%B8%E8%A7%81%E9%97%AE%E9%A2%98%E5%88%86%E6%9E%90%E4%B8%8E%E6%A0%B9%E5%9B%A0%E5%AE%9A%E4%BD%8D\">3. \u5b58\u50a8\u5e38\u89c1\u95ee\u9898\u5206\u6790\u4e0e\u6839\u56e0\u5b9a\u4f4d<\/h3>\n<p>\u751f\u4ea7\u73af\u5883\u4e2d\u7684\u5b58\u50a8\u95ee\u9898\u591a\u8868\u73b0\u4e3aIO\u5361\u987f\u3001\u6587\u4ef6\u65e0\u6cd5\u8bbf\u95ee\u3001\u78c1\u76d8\u6545\u969c\u3001\u6570\u636e\u4e22\u5931\u7b49&#xff0c;\u5176\u6839\u6e90\u6d89\u53ca\u786c\u4ef6\u3001\u6587\u4ef6\u7cfb\u7edf\u3001\u5185\u6838\u53c2\u6570\u7b49\u591a\u4e2a\u5c42\u9762&#xff0c;\u9700\u7ed3\u5408\u5206\u5c42\u67b6\u6784\u539f\u7406\u9010\u5c42\u6392\u67e5\u3002<\/p>\n<h4 id=\"3.1%20%E7%A3%81%E7%9B%98%E6%95%85%E9%9A%9C%E9%97%AE%E9%A2%98\">3.1 \u78c1\u76d8\u6545\u969c\u95ee\u9898<\/h4>\n<p>\u73b0\u8c61\u8868\u73b0&#xff1a;\u7cfb\u7edf\u65e5\u5fd7&#xff08;\/var\/log\/messages&#xff09;\u4e2d\u9891\u7e41\u51fa\u73b0\u201chard error\u201d\u201cIO error\u201d\u7b49\u5173\u952e\u8bcd&#xff0c;\u78c1\u76d8\u8bfb\u5199\u901f\u5ea6\u9aa4\u964d&#xff0c;\u90e8\u5206\u6587\u4ef6\u65e0\u6cd5\u8bbf\u95ee&#xff0c;smartctl\u5de5\u5177\u68c0\u6d4b\u663e\u793a\u78c1\u76d8\u5065\u5eb7\u72b6\u6001\u5f02\u5e38\u3002<\/p>\n<p>\u6839\u6e90\u5206\u7c7b&#xff1a;<\/p>\n<ul>\n<li>\u7269\u7406\u6545\u969c&#xff1a;HDD\u673a\u68b0\u81c2\u635f\u574f\u3001\u78c1\u5934\u8001\u5316&#xff0c;SSD\u95ea\u5b58\u82af\u7247\u635f\u574f&#xff0c;NVMe\u63a5\u53e3\u63a5\u89e6\u4e0d\u826f&#xff1b;<\/li>\n<li>\u903b\u8f91\u6545\u969c&#xff1a;\u78c1\u76d8\u574f\u9053&#xff08;\u5206\u4e3a\u7269\u7406\u574f\u9053\u548c\u903b\u8f91\u574f\u9053&#xff0c;\u7269\u7406\u574f\u9053\u65e0\u6cd5\u4fee\u590d&#xff0c;\u903b\u8f91\u574f\u9053\u53ef\u901a\u8fc7\u683c\u5f0f\u5316\u4fee\u590d&#xff09;&#xff0c;RAID\u5361\u7f13\u5b58\u6545\u969c\u5bfc\u81f4\u7684\u6570\u636e\u540c\u6b65\u5f02\u5e38\u3002<\/li>\n<\/ul>\n<p>\u6392\u67e5\u6d41\u7a0b&#xff1a;<\/p>\n<li>\u901a\u8fc7dmesg | grep -i error\u67e5\u770b\u5185\u6838\u8f93\u51fa\u7684\u78c1\u76d8\u9519\u8bef\u4fe1\u606f&#xff0c;\u786e\u8ba4\u6545\u969c\u78c1\u76d8\u8bbe\u5907\u540d&#xff08;\u5982\/dev\/sda&#xff09;&#xff1b;<\/li>\n<li>\u4f7f\u7528smartctl -a \/dev\/sda\u68c0\u6d4b\u78c1\u76d8\u5065\u5eb7\u72b6\u6001&#xff0c;\u91cd\u70b9\u5173\u6ce8\u201cSMART Health Status\u201d&#xff08;\u662f\u5426\u4e3aOK&#xff09;\u3001\u201cReallocated_Sector_Ct\u201d&#xff08;\u91cd\u6620\u5c04\u6247\u533a\u6570&#xff0c;\u6570\u503c\u975e0\u8bf4\u660e\u6709\u574f\u9053&#xff09;\u3001\u201cPower_On_Hours\u201d&#xff08;\u901a\u7535\u65f6\u95f4&#xff0c;\u8fc7\u957f\u53ef\u80fd\u5bfc\u81f4\u8001\u5316&#xff09;&#xff1b;<\/li>\n<li>\u82e5\u4e3a\u903b\u8f91\u574f\u9053&#xff0c;\u6267\u884cbadblocks -v \/dev\/sda\u68c0\u6d4b\u574f\u9053\u4f4d\u7f6e&#xff0c;\u518d\u901a\u8fc7e2fsck -c \/dev\/sda1&#xff08;ext4&#xff09;\u6216xfs_repair \/dev\/sda1&#xff08;XFS&#xff09;\u6807\u8bb0\u574f\u9053&#xff0c;\u907f\u514d\u4f7f\u7528&#xff1b;\u82e5\u4e3a\u7269\u7406\u574f\u9053&#xff0c;\u9700\u7acb\u5373\u66f4\u6362\u78c1\u76d8&#xff0c;\u901a\u8fc7RAID\u6216\u5907\u4efd\u6062\u590d\u6570\u636e\u3002<\/li>\n<h4 id=\"3.2%20inode%E8%80%97%E5%B0%BD%E9%97%AE%E9%A2%98\">3.2 inode\u8017\u5c3d\u95ee\u9898<\/h4>\n<p>\u73b0\u8c61\u8868\u73b0&#xff1a;df -h\u663e\u793a\u78c1\u76d8\u6709\u5269\u4f59\u7a7a\u95f4&#xff0c;\u4f46\u521b\u5efa\u6587\u4ef6\u65f6\u63d0\u793a\u201cno space left on device\u201d&#xff0c;df -i\u663e\u793ainode\u4f7f\u7528\u7387\u4e3a100%\u3002<\/p>\n<p>\u6839\u6e90\u5206\u6790&#xff1a;\u8be5\u95ee\u9898\u4ec5\u53d1\u751f\u5728ext2\/ext3\/ext4\u6587\u4ef6\u7cfb\u7edf&#xff0c;\u56e0\u8fd9\u7c7b\u6587\u4ef6\u7cfb\u7edf\u7684inode\u662f\u9759\u6001\u5206\u914d\u7684&#xff0c;\u5f53\u7cfb\u7edf\u4e2d\u5b58\u5728\u5927\u91cf\u5c0f\u6587\u4ef6&#xff08;\u6bcf\u4e2a\u5c0f\u6587\u4ef6\u5360\u7528\u4e00\u4e2ainode&#xff09;\u65f6&#xff0c;\u5373\u4f7f\u78c1\u76d8\u7a7a\u95f4\u672a\u7528\u5b8c&#xff0c;inode\u4e5f\u4f1a\u88ab\u8017\u5c3d\u3002\u5178\u578b\u573a\u666f\u4e3aWeb\u670d\u52a1\u5668\u65e5\u5fd7\u76ee\u5f55&#xff08;\u6bcf\u65e5\u751f\u6210\u5927\u91cf\u5c0f\u65e5\u5fd7\u6587\u4ef6&#xff09;\u3001\u5bb9\u5668\u955c\u50cf\u5b58\u50a8\u76ee\u5f55\u3002<\/p>\n<p>\u6392\u67e5\u4e0e\u89e3\u51b3&#xff1a;<\/p>\n<li>\u5b9a\u4f4dinode\u5360\u7528\u8fc7\u9ad8\u7684\u76ee\u5f55&#xff1a;\u901a\u8fc7for dir in \/*; do echo &#034;$dir: $(find $dir -maxdepth 1 -type d | wc -l)&#034;; done\u9010\u5c42\u6392\u67e5&#xff0c;\u627e\u5230\u5c0f\u6587\u4ef6\u5bc6\u96c6\u7684\u76ee\u5f55&#xff1b;<\/li>\n<li>\u4e34\u65f6\u89e3\u51b3&#xff1a;\u6e05\u7406\u65e0\u7528\u5c0f\u6587\u4ef6&#xff08;\u5982\u8fc7\u671f\u65e5\u5fd7\u3001\u4e34\u65f6\u6587\u4ef6&#xff09;&#xff0c;\u6216\u901a\u8fc7find \/data\/logs -name &#034;*.log&#034; -mtime &#043;7 -delete\u5220\u96647\u5929\u524d\u7684\u65e5\u5fd7\u6587\u4ef6&#xff1b;<\/li>\n<li>\u957f\u671f\u89e3\u51b3&#xff1a;1. \u91cd\u65b0\u683c\u5f0f\u5316ext4\u5206\u533a\u65f6\u589e\u52a0inode\u6570\u91cf&#xff0c;\u901a\u8fc7mkfs.ext4 -i 8192 \/dev\/sda1&#xff08;\u6bcf8KB\u7a7a\u95f4\u5206\u914d\u4e00\u4e2ainode&#xff0c;\u9ed8\u8ba4\u6bcf16KB\u5206\u914d\u4e00\u4e2a&#xff09;&#xff1b;2. \u8fc1\u79fb\u81f3XFS\u6216Btrfs\u6587\u4ef6\u7cfb\u7edf&#xff08;\u52a8\u6001inode\u5206\u914d&#xff0c;\u65e0\u6b64\u95ee\u9898&#xff09;\u3002<\/li>\n<h4 id=\"3.3%20IO%E6%80%A7%E8%83%BD%E5%8D%A1%E9%A1%BF%E9%97%AE%E9%A2%98\">3.3 IO\u6027\u80fd\u5361\u987f\u95ee\u9898<\/h4>\n<p>\u73b0\u8c61\u8868\u73b0&#xff1a;\u5e94\u7528\u54cd\u5e94\u5ef6\u8fdf\u663e\u8457\u589e\u52a0&#xff0c;iostat -x 1\u663e\u793a\u78c1\u76d8%util&#xff08;\u7e41\u5fd9\u5ea6&#xff09;\u6301\u7eed\u63a5\u8fd1100%&#xff0c;await&#xff08;\u5e73\u5747IO\u7b49\u5f85\u65f6\u95f4&#xff09;\u8d85\u8fc750ms&#xff08;\u6b63\u5e38\u5e94\u4f4e\u4e8e20ms&#xff09;&#xff0c;svctm&#xff08;\u5e73\u5747\u670d\u52a1\u65f6\u95f4&#xff09;\u63a5\u8fd1await&#xff08;\u8bf4\u660eIO\u8bf7\u6c42\u6392\u961f\u4e25\u91cd&#xff09;\u3002<\/p>\n<p>\u6839\u6e90\u5206\u6790&#xff1a;<\/p>\n<ul>\n<li>\u786c\u4ef6\u74f6\u9888&#xff1a;HDD\u7528\u4e8e\u9ad8\u968f\u673aIO\u573a\u666f&#xff08;\u5982\u6570\u636e\u5e93&#xff09;&#xff0c;IOPS\u4e0d\u8db3&#xff1b;\u78c1\u76d8\u9635\u5217\u7f13\u5b58\u672a\u542f\u7528\u6216\u7f13\u5b58\u5927\u5c0f\u4e0d\u8db3&#xff1b;<\/li>\n<li>IO\u8c03\u5ea6\u5668\u4e0d\u5339\u914d&#xff1a;\u5982SSD\u4f7f\u7528\u4e86\u4e3aHDD\u8bbe\u8ba1\u7684CFQ\u8c03\u5ea6\u5668&#xff0c;\u672a\u53d1\u6325SSD\u7684\u968f\u673aIO\u4f18\u52bf&#xff1b;<\/li>\n<li>\u5e94\u7528IO\u6a21\u5f0f\u4e0d\u5408\u7406&#xff1a;\u5982\u6570\u636e\u5e93\u672a\u5f00\u542f\u7f13\u5b58&#xff0c;\u5bfc\u81f4\u5927\u91cf\u91cd\u590d\u78c1\u76d8\u8bfb\u5199&#xff1b;\u5e94\u7528\u9891\u7e41\u8fdb\u884c\u5c0f\u6587\u4ef6\u968f\u673a\u5199\u5165&#xff0c;\u672a\u505aIO\u5408\u5e76\u3002<\/li>\n<\/ul>\n<p>\u6392\u67e5\u4e0e\u89e3\u51b3&#xff1a;<\/p>\n<li>\u5206\u6790IO\u7279\u5f81&#xff1a;\u901a\u8fc7pidstat -d 1 -p \u8fdb\u7a0bPID\u67e5\u770b\u5355\u4e2a\u8fdb\u7a0b\u7684IO\u60c5\u51b5&#xff0c;\u786e\u8ba4\u662f\u968f\u673aIO\u8fd8\u662f\u987a\u5e8fIO\u3001\u8bfb\u591a\u8fd8\u662f\u5199\u591a&#xff1b;\u901a\u8fc7iotop\u5b9a\u4f4dIO\u5360\u7528\u6700\u9ad8\u7684\u8fdb\u7a0b&#xff1b;<\/li>\n<li>\u4f18\u5316IO\u8c03\u5ea6\u5668&#xff1a;SSD\/NVMe\u78c1\u76d8\u63a8\u8350\u4f7f\u7528mq-deadline\u6216none\u8c03\u5ea6\u5668&#xff0c;\u6267\u884cecho mq-deadline &gt; \/sys\/block\/sda\/queue\/scheduler\u4e34\u65f6\u751f\u6548&#xff0c;\u6c38\u4e45\u751f\u6548\u9700\u4fee\u6539 grub \u914d\u7f6e\u6587\u4ef6&#xff1b;HDD\u63a8\u8350\u4f7f\u7528cfq\u6216noop\u8c03\u5ea6\u5668&#xff1b;<\/li>\n<li>\u786c\u4ef6\u5347\u7ea7\u4e0e\u4f18\u5316&#xff1a;\u9ad8\u968f\u673aIO\u573a\u666f\u5c06HDD\u66f4\u6362\u4e3aSSD\/NVMe&#xff1b;\u542f\u7528\u78c1\u76d8\u9635\u5217\u7f13\u5b58\u5e76\u914d\u7f6e\u4e3a\u201c\u5199\u56de\u6a21\u5f0f\u201d&#xff1b;<\/li>\n<li>\u5e94\u7528\u4f18\u5316&#xff1a;\u6570\u636e\u5e93\u5f00\u542f\u67e5\u8be2\u7f13\u5b58\u548c\u6570\u636e\u7f13\u5b58&#xff08;\u5982MySQL InnoDB Buffer Pool&#xff09;&#xff1b;\u5e94\u7528\u5c42\u5b9e\u73b0\u5c0f\u6587\u4ef6\u5408\u5e76\u5199\u5165&#xff08;\u5982\u65e5\u5fd7\u805a\u5408\u5de5\u5177Flume&#xff09;\u3002<\/li>\n<h3 id=\"4.%20%E5%AD%98%E5%82%A8%E7%B3%BB%E7%BB%9F%E4%BC%98%E5%8C%96%E5%AE%9E%E8%B7%B5%E4%B8%8E%E5%BF%83%E5%BE%97\">4. \u5b58\u50a8\u7cfb\u7edf\u4f18\u5316\u5b9e\u8df5\u4e0e\u5fc3\u5f97<\/h3>\n<p>\u5b58\u50a8\u7cfb\u7edf\u4f18\u5316\u662f\u201c\u786c\u4ef6\u9009\u578b-\u5185\u6838\u8c03\u4f18-\u6587\u4ef6\u7cfb\u7edf\u914d\u7f6e-\u5e94\u7528\u9002\u914d\u201d\u7684\u5168\u94fe\u8def\u5de5\u7a0b&#xff0c;\u9700\u7ed3\u5408\u4e1a\u52a1IO\u7279\u5f81\u9488\u5bf9\u6027\u8bbe\u8ba1&#xff0c;\u907f\u514d\u201c\u4e00\u5200\u5207\u201d\u5f0f\u4f18\u5316\u3002\u4ee5\u4e0b\u662f\u57fa\u4e8e\u591a\u5e74\u8fd0\u7ef4\u5b9e\u8df5\u7684\u4f18\u5316\u7b56\u7565\u4e0e\u5fc3\u5f97\u603b\u7ed3\u3002<\/p>\n<h4 id=\"4.1%20%E7%A1%AC%E4%BB%B6%E9%80%89%E5%9E%8B%E6%A0%B8%E5%BF%83%E5%8E%9F%E5%88%99\">4.1 \u786c\u4ef6\u9009\u578b\u6838\u5fc3\u539f\u5219<\/h4>\n<p>\u786c\u4ef6\u662f\u5b58\u50a8\u6027\u80fd\u7684\u57fa\u7840&#xff0c;\u9009\u578b\u9519\u8bef\u4f1a\u5bfc\u81f4\u540e\u7eed\u4f18\u5316\u6548\u679c\u53d7\u9650&#xff0c;\u6838\u5fc3\u9009\u578b\u539f\u5219\u662f\u201c\u5339\u914dIO\u7279\u5f81\u201d&#xff1a;<\/p>\n<ul>\n<li>\u5c0f\u6587\u4ef6\u968f\u673a\u8bfb\u5199\u573a\u666f&#xff08;\u5982MySQL\u3001Redis&#xff09;&#xff1a;\u4f18\u5148\u9009\u62e9NVMe SSD&#xff0c;\u5176\u968f\u673aIOPS\u6027\u80fd\u662fHDD\u76841000\u500d\u4ee5\u4e0a&#xff1b;\u82e5\u9884\u7b97\u6709\u9650&#xff0c;\u53ef\u9009\u62e9SATA SSD&#xff0c;\u907f\u514d\u4f7f\u7528HDD&#xff08;\u5bfb\u9053\u65f6\u95f4\u8fc7\u957f&#xff09;&#xff1b;\u914d\u7f6e\u8db3\u591f\u7684\u5185\u5b58\u4f5c\u4e3a\u9875\u7f13\u5b58&#xff0c;\u51cf\u5c11\u78c1\u76d8IO\u6b21\u6570\u3002<\/li>\n<li>\u5927\u6587\u4ef6\u987a\u5e8f\u8bfb\u5199\u573a\u666f&#xff08;\u5982\u89c6\u9891\u5b58\u50a8\u3001\u5927\u6570\u636eHDFS&#xff09;&#xff1a;\u53ef\u9009\u62e9\u5927\u5bb9\u91cfHDD&#xff08;\u598210TB\u4ee5\u4e0a&#xff09;&#xff0c;\u6210\u672c\u8f83\u4f4e&#xff1b;\u82e5\u9700\u63d0\u5347\u6027\u80fd&#xff0c;\u53ef\u91c7\u7528HDD\u7ec4\u6210RAID 0\u9635\u5217&#xff0c;\u6216\u6df7\u5408\u90e8\u7f72&#xff08;\u5143\u6570\u636e\u5b58\u50a8\u5728SSD&#xff0c;\u5b9e\u9645\u6570\u636e\u5b58\u50a8\u5728HDD&#xff09;\u3002<\/li>\n<li>\u9ad8\u53ef\u9760\u6027\u573a\u666f&#xff08;\u5982\u6570\u636e\u5e93\u4e3b\u5e93\u3001\u6838\u5fc3\u4e1a\u52a1\u5b58\u50a8&#xff09;&#xff1a;\u5fc5\u987b\u914d\u7f6eRAID\u9635\u5217&#xff08;RAID 10\u9002\u5408\u8bfb\u591a\u5199\u591a&#xff0c;RAID 5\u9002\u5408\u8bfb\u591a\u5199\u5c11&#xff09;&#xff0c;\u5e76\u542f\u7528\u7535\u6c60\u5907\u4efd\u5355\u5143&#xff08;BBU&#xff09;&#xff0c;\u9632\u6b62\u65ad\u7535\u5bfc\u81f4\u7684\u7f13\u5b58\u6570\u636e\u4e22\u5931&#xff1b;\u91c7\u7528\u53cc\u76d8\u70ed\u5907&#xff0c;\u63d0\u5347\u6545\u969c\u6062\u590d\u901f\u5ea6\u3002<\/li>\n<\/ul>\n<h4 id=\"4.2%20%E5%86%85%E6%A0%B8%E4%B8%8E%E6%96%87%E4%BB%B6%E7%B3%BB%E7%BB%9F%E8%B0%83%E4%BC%98%E5%AE%9E%E6%88%98\">4.2 \u5185\u6838\u4e0e\u6587\u4ef6\u7cfb\u7edf\u8c03\u4f18\u5b9e\u6218<\/h4>\n<p>4.2.1 \u5185\u6838\u53c2\u6570\u8c03\u4f18<\/p>\n<p>\u901a\u8fc7\u4fee\u6539\/etc\/sysctl.conf\u914d\u7f6e\u5185\u6838\u53c2\u6570&#xff0c;\u6267\u884csysctl -p\u751f\u6548&#xff0c;\u6838\u5fc3\u4f18\u5316\u53c2\u6570\u5982\u4e0b&#xff1a;<\/p>\n<table>\n<tbody>\n<tr>\n<td>\n<p>\u53c2\u6570\u540d\u79f0<\/p>\n<\/td>\n<td>\n<p>\u4f5c\u7528\u8bf4\u660e<\/p>\n<\/td>\n<td>\n<p>\u4f18\u5316\u914d\u7f6e<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p>vm.dirty_ratio<\/p>\n<\/td>\n<td>\n<p>\u810f\u9875\u5360\u6bd4\u9608\u503c&#xff0c;\u89e6\u53d1\u540c\u6b65\u56de\u5199<\/p>\n<\/td>\n<td>\n<p>20&#xff08;\u5199\u5bc6\u96c6\u573a\u666f\u8bbe\u4e3a15&#xff09;<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p>vm.dirty_background_ratio<\/p>\n<\/td>\n<td>\n<p>\u810f\u9875\u5360\u6bd4\u9608\u503c&#xff0c;\u89e6\u53d1\u540e\u53f0\u5f02\u6b65\u56de\u5199<\/p>\n<\/td>\n<td>\n<p>5&#xff08;\u5199\u5bc6\u96c6\u573a\u666f\u8bbe\u4e3a3&#xff09;<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p>vm.dirty_expire_centisecs<\/p>\n<\/td>\n<td>\n<p>\u810f\u9875\u8d85\u65f6\u65f6\u95f4&#xff0c;\u5f3a\u5236\u56de\u5199<\/p>\n<\/td>\n<td>\n<p>3000&#xff08;30\u79d2&#xff0c;\u6570\u636e\u5b89\u5168\u4f18\u5148\u8bbe\u4e3a1500&#xff09;<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p>blockdev &#8211;setra<\/p>\n<\/td>\n<td>\n<p>\u78c1\u76d8\u9884\u8bfb\u5927\u5c0f&#xff08;\u5355\u4f4d&#xff1a;512\u5b57\u8282\u6247\u533a&#xff09;<\/p>\n<\/td>\n<td>\n<p>HDD\u8bbe\u4e3a256&#xff08;128KB&#xff09;&#xff0c;SSD\u8bbe\u4e3a1024&#xff08;512KB&#xff09;<\/p>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h5 id=\"4.2.2%20%E6%96%87%E4%BB%B6%E7%B3%BB%E7%BB%9F%E9%85%8D%E7%BD%AE%E4%BC%98%E5%8C%96\">4.2.2 \u6587\u4ef6\u7cfb\u7edf\u914d\u7f6e\u4f18\u5316<\/h5>\n<ul>\n<li>ext4\u4f18\u5316&#xff1a;\u683c\u5f0f\u5316\u65f6\u542f\u7528extent\u548c\u65e5\u5fd7\u6821\u9a8c&#xff0c;mkfs.ext4 -O extent,has_journal -m 1 \/dev\/sda1&#xff08;-m 1\u8868\u793a\u9884\u75591%\u7a7a\u95f4\u7ed9\u5185\u6838&#xff0c;\u9ed8\u8ba45%&#xff09;&#xff1b;\u6302\u8f7d\u65f6\u6dfb\u52a0noatime\u9009\u9879&#xff08;\u4e0d\u66f4\u65b0\u6587\u4ef6\u8bbf\u95ee\u65f6\u95f4&#xff0c;\u51cf\u5c11\u5143\u6570\u636e\u5199\u5165&#xff09;&#xff0c;mount -t ext4 -o noatime \/dev\/sda1 \/data\u3002<\/li>\n<li>XFS\u4f18\u5316&#xff1a;\u683c\u5f0f\u5316\u65f6\u6307\u5b9a\u65e5\u5fd7\u5927\u5c0f\u548c\u6570\u636e\u5757\u5927\u5c0f&#xff0c;mkfs.xfs -l size&#061;16g -b size&#061;64k \/dev\/sda1&#xff08;\u5927\u6587\u4ef6\u573a\u666f\u6570\u636e\u5757\u8bbe\u4e3a64KB&#xff09;&#xff1b;\u6302\u8f7d\u65f6\u6dfb\u52a0logbufs&#061;8,logbsize&#061;256k&#xff08;\u589e\u5927\u65e5\u5fd7\u7f13\u5b58&#xff0c;\u63d0\u5347\u5199\u6027\u80fd&#xff09;&#xff0c;mount -t xfs -o noatime,logbufs&#061;8,logbsize&#061;256k \/dev\/sda1 \/data\u3002<\/li>\n<li>Btrfs\u4f18\u5316&#xff1a;\u542f\u7528\u900f\u660e\u538b\u7f29\u548c\u6821\u9a8c&#xff0c;mkfs.btrfs -m single -d raid1 \/dev\/sda \/dev\/sdb&#xff08;RAID 1\u6a21\u5f0f&#xff09;&#xff1b;\u6302\u8f7d\u65f6\u6dfb\u52a0compress&#061;zstd,checksum&#061;sha256\u9009\u9879&#xff0c;mount -t btrfs -o compress&#061;zstd,checksum&#061;sha256 \/dev\/mapper\/btrfs \/data\u3002<\/li>\n<\/ul>\n<h4 id=\"4.3%20%E8%BF%90%E7%BB%B4%E5%AE%9E%E8%B7%B5%E5%BF%83%E5%BE%97\">4.3 \u8fd0\u7ef4\u5b9e\u8df5\u5fc3\u5f97<\/h4>\n<li>\u6570\u636e\u5907\u4efd\u662f\u5e95\u7ebf&#xff1a;\u65e0\u8bba\u5b58\u50a8\u7cfb\u7edf\u5982\u4f55\u4f18\u5316&#xff0c;\u786c\u4ef6\u6545\u969c\u90fd\u65e0\u6cd5\u5b8c\u5168\u907f\u514d&#xff0c;\u5fc5\u987b\u5efa\u7acb\u201c3-2-1\u201d\u5907\u4efd\u7b56\u7565&#xff08;3\u4efd\u6570\u636e\u526f\u672c\u30012\u79cd\u5b58\u50a8\u4ecb\u8d28\u30011\u4efd\u5f02\u5730\u5907\u4efd&#xff09;&#xff0c;\u5b9a\u671f\u6f14\u7ec3\u6062\u590d\u6d41\u7a0b&#xff0c;\u907f\u514d\u6570\u636e\u4e22\u5931\u3002<\/li>\n<li>\u76d1\u63a7\u5148\u884c&#xff0c;\u9884\u9632\u4e3a\u4e3b&#xff1a;\u5efa\u7acb\u5b58\u50a8\u5168\u94fe\u8def\u76d1\u63a7&#xff0c;\u6838\u5fc3\u76d1\u63a7\u6307\u6807\u5305\u62ec\u78c1\u76d8\u5065\u5eb7\u72b6\u6001&#xff08;smart\u4fe1\u606f&#xff09;\u3001IO\u6027\u80fd&#xff08;%util\u3001await\u3001svctm&#xff09;\u3001\u6587\u4ef6\u7cfb\u7edf\u4f7f\u7528\u7387&#xff08;\u7a7a\u95f4\u548cinode&#xff09;\u3001\u9875\u7f13\u5b58\u547d\u4e2d\u7387&#xff1b;\u901a\u8fc7Prometheus&#043;Grafana\u53ef\u89c6\u5316\u76d1\u63a7&#xff0c;\u8bbe\u7f6e\u544a\u8b66\u9608\u503c&#xff08;\u5982\u78c1\u76d8%util&gt;90%\u3001inode\u4f7f\u7528\u7387&gt;85%\u544a\u8b66&#xff09;\u3002<\/li>\n<li>\u907f\u514d\u8fc7\u5ea6\u4f18\u5316&#xff1a;\u4f18\u5316\u9700\u5efa\u7acb\u5728\u95ee\u9898\u5b9a\u4f4d\u7684\u57fa\u7840\u4e0a&#xff0c;\u4e0d\u53ef\u76f2\u76ee\u8c03\u6574\u5185\u6838\u53c2\u6570\u548c\u6587\u4ef6\u7cfb\u7edf\u914d\u7f6e\u3002\u4f8b\u5982&#xff0c;\u968f\u610f\u589e\u5927\u810f\u9875\u9608\u503c\u53ef\u80fd\u5bfc\u81f4\u65ad\u7535\u65f6\u6570\u636e\u4e22\u5931\u98ce\u9669\u589e\u52a0&#xff1b;\u542f\u7528Btrfs\u7684\u538b\u7f29\u529f\u80fd\u867d\u80fd\u8282\u7701\u7a7a\u95f4&#xff0c;\u4f46\u4f1a\u589e\u52a0CPU\u5f00\u9500&#xff0c;\u9700\u5728\u7a7a\u95f4\u548c\u6027\u80fd\u95f4\u5e73\u8861\u3002<\/li>\n<li>\u5b9a\u671f\u7ef4\u62a4\u4e0d\u53ef\u5c11&#xff1a;\u5b9a\u671f\u68c0\u67e5\u78c1\u76d8\u5065\u5eb7\u72b6\u6001&#xff08;\u6bcf\u6708\u4e00\u6b21smart\u68c0\u6d4b&#xff09;\u3001\u6e05\u7406\u65e0\u7528\u6587\u4ef6&#xff08;\u907f\u514dinode\u8017\u5c3d&#xff09;\u3001\u6267\u884c\u6587\u4ef6\u7cfb\u7edf\u6821\u9a8c&#xff08;ext4\u6267\u884ce2fsck&#xff0c;XFS\u6267\u884cxfs_repair&#xff0c;\u9700\u79bb\u7ebf\u6267\u884c&#xff09;\u3001\u66f4\u65b0\u78c1\u76d8\u56fa\u4ef6&#xff08;\u4fee\u590d\u786c\u4ef6\u6f0f\u6d1e&#xff09;\u3002<\/li>\n<h2 id=\"%E4%B8%89%E3%80%81%20%E9%99%84%E5%BD%95\">\u4e09\u3001 \u9644\u5f55<\/h2>\n<p>\u9644\u5f55A&#xff1a;\u5e38\u7528\u5b58\u50a8\u6392\u67e5\u5de5\u5177\u6e05\u5355<\/p>\n<table>\n<tbody>\n<tr>\n<td>\n<p>\u5de5\u5177\u540d\u79f0<\/p>\n<\/td>\n<td>\n<p>\u6838\u5fc3\u529f\u80fd<\/p>\n<\/td>\n<td>\n<p>\u5e38\u7528\u547d\u4ee4\u793a\u4f8b<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p>smartctl<\/p>\n<\/td>\n<td>\n<p>\u78c1\u76d8\u5065\u5eb7\u72b6\u6001\u68c0\u6d4b<\/p>\n<\/td>\n<td>\n<p>smartctl -a \/dev\/sda&#xff08;\u67e5\u770b\u8be6\u7ec6\u4fe1\u606f&#xff09;<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p>iostat<\/p>\n<\/td>\n<td>\n<p>\u78c1\u76d8IO\u6027\u80fd\u76d1\u63a7<\/p>\n<\/td>\n<td>\n<p>iostat -x 1 10&#xff08;\u6bcf\u79d21\u6b21&#xff0c;\u517110\u6b21&#xff09;<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p>iotop<\/p>\n<\/td>\n<td>\n<p>\u5b9e\u65f6\u67e5\u770b\u8fdb\u7a0bIO\u5360\u7528<\/p>\n<\/td>\n<td>\n<p>iotop -o&#xff08;\u4ec5\u663e\u793a\u6709IO\u6d3b\u52a8\u7684\u8fdb\u7a0b&#xff09;<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p>df\/du<\/p>\n<\/td>\n<td>\n<p>\u78c1\u76d8\u7a7a\u95f4\u548cinode\u4f7f\u7528\u67e5\u8be2<\/p>\n<\/td>\n<td>\n<p>df -h&#xff08;\u7a7a\u95f4&#xff09;\u3001df -i&#xff08;inode&#xff09;\u3001du -sh \/*&#xff08;\u76ee\u5f55\u5927\u5c0f&#xff09;<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p>badblocks<\/p>\n<\/td>\n<td>\n<p>\u78c1\u76d8\u574f\u9053\u68c0\u6d4b<\/p>\n<\/td>\n<td>\n<p>badblocks -v \/dev\/sda1&#xff08;\u53ea\u8bfb\u68c0\u6d4b&#xff09;<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p>filefrag<\/p>\n<\/td>\n<td>\n<p>\u67e5\u770b\u6587\u4ef6\u788e\u7247\u60c5\u51b5<\/p>\n<\/td>\n<td>\n<p>filefrag -v \/data\/large_file&#xff08;\u8be6\u7ec6\u788e\u7247\u4fe1\u606f&#xff09;<\/p>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>\u9644\u5f55B&#xff1a;\u5b58\u50a8\u6545\u969c\u6392\u67e5\u6d41\u7a0b\u56fe<\/p>\n<p>1. \u78c1\u76d8\u6545\u969c\u6392\u67e5\u6d41\u7a0b&#xff1a; \u6536\u5230\u78c1\u76d8\u544a\u8b66 \u2192 dmesg\u67e5\u770b\u5185\u6838\u9519\u8bef\u65e5\u5fd7 \u2192 \u786e\u8ba4\u6545\u969c\u78c1\u76d8 \u2192 smartctl\u68c0\u6d4b\u5065\u5eb7\u72b6\u6001 \u2192 \u5224\u5b9a\u7269\u7406\/\u903b\u8f91\u6545\u969c \u2192 \u903b\u8f91\u6545\u969c&#xff1a;\u6807\u8bb0\u574f\u9053&#043;\u4fee\u590d&#xff1b;\u7269\u7406\u6545\u969c&#xff1a;\u66f4\u6362\u78c1\u76d8&#043;\u6062\u590d\u6570\u636e \u2192 \u9a8c\u8bc1\u78c1\u76d8\u53ef\u7528\u6027\u3002<\/p>\n<p>2. IO\u5361\u987f\u6392\u67e5\u6d41\u7a0b&#xff1a; \u5e94\u7528\u53cd\u9988\u5ef6\u8fdf \u2192 iostat -x\u67e5\u770b\u78c1\u76d8IO\u6307\u6807 \u2192 \u786e\u8ba4%util\u9ad8 \u2192 iotop\u5b9a\u4f4d\u9ad8IO\u8fdb\u7a0b \u2192 pidstat\u5206\u6790\u8fdb\u7a0bIO\u7279\u5f81&#xff08;\u968f\u673a\/\u987a\u5e8f&#xff09; \u2192 \u786c\u4ef6\u74f6\u9888&#xff1a;\u5347\u7ea7\u78c1\u76d8\/\u542f\u7528RAID\u7f13\u5b58&#xff1b;\u8c03\u5ea6\u5668\u95ee\u9898&#xff1a;\u66f4\u6362\u8c03\u5ea6\u5668&#xff1b;\u5e94\u7528\u95ee\u9898&#xff1a;\u4f18\u5316\u5e94\u7528IO\u6a21\u5f0f \u2192 \u9a8c\u8bc1IO\u6027\u80fd\u3002<\/p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u4e86\u89e3\u66f4\u591a\u94f6\u6cb3\u9e92\u9e9f\u64cd\u4f5c\u7cfb\u7edf\u5168\u65b0\u4ea7\u54c1&#xff0c;\u8bf7\u70b9\u51fb\u8bbf\u95ee&#xff1a;<br \/>\n\u9e92\u9e9f\u8f6f\u4ef6\u4ea7\u54c1\u4e13\u533a&#xff1a;https:\/\/www.kylinos.cn\/productPc\/<br \/>\n\u5f00\u53d1\u8005\u4e13\u533a&#xff1a;https:\/\/developer.kylinos.cn\/<br \/>\n\u6587\u6863\u4e2d\u5fc3&#xff1a;https:\/\/document.kylinos.cn\/document\/center \u76ee\u5f55<br \/>\n\u4e00\u3001 \u6587\u6863\u6982\u8ff0<br \/>\n\u4e8c\u3001 \u4e3b\u8981\u5185\u5bb9<br \/>\n1. Linux\u5b58\u50a8\u7cfb\u7edf\u6838\u5fc3\u67b6\u6784\u539f\u7406<br \/>\n1.1 \u5206\u5c42\u67b6\u6784<\/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,188,44],"topic":[],"class_list":["post-108557","post","type-post","status-publish","format-standard","hentry","category-server","tag-43","tag-188","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\u5b58\u50a8\u7cfb\u7edf\u539f\u7406\u4e0e\u8fd0\u7ef4\u5b9e\u8df5\u89e3\u6790 - \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\/108557.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\u5b58\u50a8\u7cfb\u7edf\u539f\u7406\u4e0e\u8fd0\u7ef4\u5b9e\u8df5\u89e3\u6790 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\" \/>\n<meta property=\"og:description\" content=\"\u4e86\u89e3\u66f4\u591a\u94f6\u6cb3\u9e92\u9e9f\u64cd\u4f5c\u7cfb\u7edf\u5168\u65b0\u4ea7\u54c1&#xff0c;\u8bf7\u70b9\u51fb\u8bbf\u95ee&#xff1a; \u9e92\u9e9f\u8f6f\u4ef6\u4ea7\u54c1\u4e13\u533a&#xff1a;https:\/\/www.kylinos.cn\/productPc\/ \u5f00\u53d1\u8005\u4e13\u533a&#xff1a;https:\/\/developer.kylinos.cn\/ \u6587\u6863\u4e2d\u5fc3&#xff1a;https:\/\/document.kylinos.cn\/document\/center \u76ee\u5f55 \u4e00\u3001 \u6587\u6863\u6982\u8ff0 \u4e8c\u3001 \u4e3b\u8981\u5185\u5bb9 1. Linux\u5b58\u50a8\u7cfb\u7edf\u6838\u5fc3\u67b6\u6784\u539f\u7406 1.1 \u5206\u5c42\u67b6\u6784\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.wsisp.com\/helps\/108557.html\" \/>\n<meta property=\"og:site_name\" content=\"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\" \/>\n<meta property=\"article:published_time\" content=\"2026-09-21T21:24:41+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=\"6 \u5206\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/108557.html\",\"url\":\"https:\/\/www.wsisp.com\/helps\/108557.html\",\"name\":\"\u670d\u52a1\u5668\u5b58\u50a8\u7cfb\u7edf\u539f\u7406\u4e0e\u8fd0\u7ef4\u5b9e\u8df5\u89e3\u6790 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\",\"isPartOf\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/#website\"},\"datePublished\":\"2026-09-21T21:24:41+00:00\",\"dateModified\":\"2026-09-21T21:24:41+00:00\",\"author\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41\"},\"breadcrumb\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/108557.html#breadcrumb\"},\"inLanguage\":\"zh-Hans\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.wsisp.com\/helps\/108557.html\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/108557.html#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"\u9996\u9875\",\"item\":\"https:\/\/www.wsisp.com\/helps\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"\u670d\u52a1\u5668\u5b58\u50a8\u7cfb\u7edf\u539f\u7406\u4e0e\u8fd0\u7ef4\u5b9e\u8df5\u89e3\u6790\"}]},{\"@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\u5b58\u50a8\u7cfb\u7edf\u539f\u7406\u4e0e\u8fd0\u7ef4\u5b9e\u8df5\u89e3\u6790 - \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\/108557.html","og_locale":"zh_CN","og_type":"article","og_title":"\u670d\u52a1\u5668\u5b58\u50a8\u7cfb\u7edf\u539f\u7406\u4e0e\u8fd0\u7ef4\u5b9e\u8df5\u89e3\u6790 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","og_description":"\u4e86\u89e3\u66f4\u591a\u94f6\u6cb3\u9e92\u9e9f\u64cd\u4f5c\u7cfb\u7edf\u5168\u65b0\u4ea7\u54c1&#xff0c;\u8bf7\u70b9\u51fb\u8bbf\u95ee&#xff1a; \u9e92\u9e9f\u8f6f\u4ef6\u4ea7\u54c1\u4e13\u533a&#xff1a;https:\/\/www.kylinos.cn\/productPc\/ \u5f00\u53d1\u8005\u4e13\u533a&#xff1a;https:\/\/developer.kylinos.cn\/ \u6587\u6863\u4e2d\u5fc3&#xff1a;https:\/\/document.kylinos.cn\/document\/center \u76ee\u5f55 \u4e00\u3001 \u6587\u6863\u6982\u8ff0 \u4e8c\u3001 \u4e3b\u8981\u5185\u5bb9 1. Linux\u5b58\u50a8\u7cfb\u7edf\u6838\u5fc3\u67b6\u6784\u539f\u7406 1.1 \u5206\u5c42\u67b6\u6784","og_url":"https:\/\/www.wsisp.com\/helps\/108557.html","og_site_name":"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","article_published_time":"2026-09-21T21:24:41+00:00","author":"admin","twitter_card":"summary_large_image","twitter_misc":{"\u4f5c\u8005":"admin","\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4":"6 \u5206"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/www.wsisp.com\/helps\/108557.html","url":"https:\/\/www.wsisp.com\/helps\/108557.html","name":"\u670d\u52a1\u5668\u5b58\u50a8\u7cfb\u7edf\u539f\u7406\u4e0e\u8fd0\u7ef4\u5b9e\u8df5\u89e3\u6790 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","isPartOf":{"@id":"https:\/\/www.wsisp.com\/helps\/#website"},"datePublished":"2026-09-21T21:24:41+00:00","dateModified":"2026-09-21T21:24:41+00:00","author":{"@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41"},"breadcrumb":{"@id":"https:\/\/www.wsisp.com\/helps\/108557.html#breadcrumb"},"inLanguage":"zh-Hans","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.wsisp.com\/helps\/108557.html"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.wsisp.com\/helps\/108557.html#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"\u9996\u9875","item":"https:\/\/www.wsisp.com\/helps"},{"@type":"ListItem","position":2,"name":"\u670d\u52a1\u5668\u5b58\u50a8\u7cfb\u7edf\u539f\u7406\u4e0e\u8fd0\u7ef4\u5b9e\u8df5\u89e3\u6790"}]},{"@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\/108557","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=108557"}],"version-history":[{"count":0,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts\/108557\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/media?parent=108557"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/categories?post=108557"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/tags?post=108557"},{"taxonomy":"topic","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/topic?post=108557"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}