{"id":110687,"date":"2026-09-29T08:16:51","date_gmt":"2026-09-29T00:16:51","guid":{"rendered":"https:\/\/www.wsisp.com\/helps\/110687.html"},"modified":"2026-09-29T08:16:51","modified_gmt":"2026-09-29T00:16:51","slug":"linux-%e6%9c%8d%e5%8a%a1%e5%99%a8%e5%b8%b8%e7%94%a8%e5%ae%9e%e7%94%a8%e5%91%bd%e4%bb%a4%e5%a4%a7%e5%85%a8","status":"publish","type":"post","link":"https:\/\/www.wsisp.com\/helps\/110687.html","title":{"rendered":"Linux \u670d\u52a1\u5668\u5e38\u7528\u5b9e\u7528\u547d\u4ee4\u5927\u5168"},"content":{"rendered":"<h3>1. \u5f15\u8a00<\/h3>\n<p>Linux \u670d\u52a1\u5668\u5728\u65e5\u5e38\u8fd0\u7ef4\u548c\u5f00\u53d1\u90e8\u7f72\u4e2d\u626e\u6f14\u7740\u6838\u5fc3\u89d2\u8272\u3002\u638c\u63e1\u5e38\u7528\u4e14\u5b9e\u7528\u7684\u547d\u4ee4&#xff0c;\u80fd\u591f\u663e\u8457\u63d0\u5347\u5de5\u4f5c\u6548\u7387&#xff0c;\u5e2e\u52a9\u5feb\u901f\u5b9a\u4f4d\u95ee\u9898\u3001\u7ba1\u7406\u7cfb\u7edf\u8d44\u6e90\u5e76\u5b8c\u6210\u81ea\u52a8\u5316\u4efb\u52a1\u3002\u672c\u6587\u6574\u7406\u4e86\u4e00\u4efd\u9ad8\u9891\u4f7f\u7528\u7684 Linux \u547d\u4ee4\u6e05\u5355&#xff0c;\u8986\u76d6\u6587\u4ef6\u64cd\u4f5c\u3001\u7cfb\u7edf\u76d1\u63a7\u3001\u7f51\u7edc\u6392\u67e5\u3001\u6743\u9650\u7ba1\u7406\u3001\u8fdb\u7a0b\u63a7\u5236\u7b49\u5e38\u89c1\u573a\u666f\u3002<\/p>\n<h3>2. \u6587\u4ef6\u4e0e\u76ee\u5f55\u64cd\u4f5c<\/h3>\n<p>\u6587\u4ef6\u64cd\u4f5c\u662f\u4f7f\u7528 Linux \u670d\u52a1\u5668\u6700\u57fa\u7840\u4e5f\u6700\u9891\u7e41\u7684\u5de5\u4f5c&#xff0c;\u4ee5\u4e0b\u547d\u4ee4\u8986\u76d6\u4e86\u67e5\u770b\u3001\u590d\u5236\u3001\u79fb\u52a8\u3001\u67e5\u627e\u548c\u538b\u7f29\u7b49\u6838\u5fc3\u9700\u6c42\u3002<\/p>\n<ul>\n<li>ls&#xff1a;\u5217\u51fa\u76ee\u5f55\u5185\u5bb9&#xff0c;\u5e38\u7528\u53c2\u6570 -l \u663e\u793a\u8be6\u7ec6\u4fe1\u606f&#xff0c;-a \u663e\u793a\u9690\u85cf\u6587\u4ef6&#xff0c;-h \u4ee5\u4eba\u7c7b\u53ef\u8bfb\u65b9\u5f0f\u663e\u793a\u6587\u4ef6\u5927\u5c0f\u3002<\/li>\n<li>cd&#xff1a;\u5207\u6362\u5de5\u4f5c\u76ee\u5f55&#xff0c;\u4f8b\u5982 cd \/var\/log \u8fdb\u5165\u65e5\u5fd7\u76ee\u5f55&#xff0c;cd .. \u8fd4\u56de\u4e0a\u7ea7\u76ee\u5f55\u3002<\/li>\n<li>pwd&#xff1a;\u663e\u793a\u5f53\u524d\u6240\u5728\u76ee\u5f55\u7684\u5b8c\u6574\u8def\u5f84\u3002<\/li>\n<li>cp&#xff1a;\u590d\u5236\u6587\u4ef6\u6216\u76ee\u5f55&#xff0c;cp -r \u9012\u5f52\u590d\u5236\u76ee\u5f55&#xff0c;cp -p \u4fdd\u7559\u6587\u4ef6\u5c5e\u6027\u3002<\/li>\n<li>mv&#xff1a;\u79fb\u52a8\u6587\u4ef6\u6216\u91cd\u547d\u540d&#xff0c;\u4f8b\u5982 mv old.txt new.txt \u5b9e\u73b0\u91cd\u547d\u540d\u3002<\/li>\n<li>rm&#xff1a;\u5220\u9664\u6587\u4ef6\u6216\u76ee\u5f55&#xff0c;rm -rf \u5f3a\u5236\u9012\u5f52\u5220\u9664&#xff0c;\u4f7f\u7528\u65f6\u9700\u683c\u5916\u8c28\u614e\u3002<\/li>\n<li>find&#xff1a;\u6309\u540d\u79f0\u3001\u7c7b\u578b\u3001\u5927\u5c0f\u7b49\u6761\u4ef6\u67e5\u627e\u6587\u4ef6&#xff0c;\u4f8b\u5982 find \/etc -name &#034;*.conf&#034; \u67e5\u627e\u6240\u6709\u914d\u7f6e\u6587\u4ef6\u3002<\/li>\n<li>tar&#xff1a;\u6253\u5305\u548c\u89e3\u538b\u6587\u4ef6&#xff0c;tar -czvf archive.tar.gz \/path \u538b\u7f29&#xff0c;tar -xzvf archive.tar.gz \u89e3\u538b\u3002<\/li>\n<li>du&#xff1a;\u7edf\u8ba1\u76ee\u5f55\u6216\u6587\u4ef6\u5360\u7528\u7684\u78c1\u76d8\u7a7a\u95f4&#xff0c;du -sh \/var \u67e5\u770b\u76ee\u5f55\u603b\u5927\u5c0f\u3002<\/li>\n<\/ul>\n<h3>3. \u7cfb\u7edf\u4fe1\u606f\u4e0e\u8d44\u6e90\u76d1\u63a7<\/h3>\n<p>\u670d\u52a1\u5668\u8fd0\u884c\u72b6\u6001\u548c\u8d44\u6e90\u4f7f\u7528\u60c5\u51b5\u662f\u8fd0\u7ef4\u6392\u67e5\u7684\u91cd\u8981\u4f9d\u636e&#xff0c;\u4ee5\u4e0b\u547d\u4ee4\u5e2e\u52a9\u5feb\u901f\u638c\u63e1\u7cfb\u7edf\u5065\u5eb7\u5ea6\u3002<\/p>\n<ul>\n<li>top&#xff1a;\u5b9e\u65f6\u663e\u793a\u8fdb\u7a0b\u548c\u7cfb\u7edf\u8d44\u6e90\u5360\u7528&#xff0c;\u6309 P \u6309 CPU \u6392\u5e8f&#xff0c;\u6309 M \u6309\u5185\u5b58\u6392\u5e8f\u3002<\/li>\n<li>free -h&#xff1a;\u4ee5\u4eba\u7c7b\u53ef\u8bfb\u683c\u5f0f\u67e5\u770b\u5185\u5b58\u548c\u4ea4\u6362\u5206\u533a\u4f7f\u7528\u60c5\u51b5\u3002<\/li>\n<li>df -h&#xff1a;\u67e5\u770b\u78c1\u76d8\u5206\u533a\u4f7f\u7528\u7387&#xff0c;\u53ca\u65f6\u53d1\u73b0\u78c1\u76d8\u7a7a\u95f4\u4e0d\u8db3\u3002<\/li>\n<li>uptime&#xff1a;\u663e\u793a\u7cfb\u7edf\u8fd0\u884c\u65f6\u95f4\u3001\u767b\u5f55\u7528\u6237\u6570\u548c\u8d1f\u8f7d\u5e73\u5747\u503c\u3002<\/li>\n<li>uname -a&#xff1a;\u67e5\u770b\u5185\u6838\u7248\u672c\u548c\u7cfb\u7edf\u67b6\u6784\u4fe1\u606f\u3002<\/li>\n<li>cat \/proc\/cpuinfo&#xff1a;\u67e5\u770b CPU \u8be6\u7ec6\u4fe1\u606f&#xff0c;\u5305\u62ec\u6838\u5fc3\u6570\u548c\u578b\u53f7\u3002<\/li>\n<li>iostat&#xff1a;\u76d1\u63a7\u78c1\u76d8 I\/O \u8bfb\u5199\u8d1f\u8f7d&#xff0c;\u9002\u5408\u6392\u67e5\u78c1\u76d8\u6027\u80fd\u74f6\u9888\u3002<\/li>\n<li>vmstat&#xff1a;\u6c47\u603b\u8fdb\u7a0b\u3001\u5185\u5b58\u3001\u5206\u9875\u548c CPU \u6d3b\u52a8\u60c5\u51b5\u3002<\/li>\n<\/ul>\n<p>\u68c0\u67e5\u6574\u4e2a\u673a\u5668\u78c1\u76d8\u6839\u76ee\u5f55\u4e0b\u9762\u6587\u4ef6\u5939\u5360\u7528\u7a7a\u95f4&#xff1a;<\/p>\n<p>sudo du -xhd1 \/ 2&gt;\/dev\/null | sort -hr<\/p>\n<p>\u5982\u679c\u53d1\u73b0 \/var \u5f88\u5927<\/p>\n<p>\u8fd9\u662f Linux \u670d\u52a1\u5668\u78c1\u76d8\u7206\u6ee1\u6700\u5e38\u89c1\u7684\u60c5\u51b5\u4e4b\u4e00\u3002<\/p>\n<p>sudo du -xhd1 \/var 2&gt;\/dev\/null | sort -hr<\/p>\n<p>\u91cd\u70b9\u68c0\u67e5 Docker<\/p>\n<p>\u5982\u679c\u8fd9\u662f\u5f00\u53d1\/\u751f\u4ea7\u670d\u52a1\u5668&#xff0c;\u6211\u5efa\u8bae\u4f60\u4f18\u5148\u68c0\u67e5 Docker\u3002<\/p>\n<p>\u6267\u884c&#xff1a;<\/p>\n<p>docker system df<\/p>\n<p>\u4ee5\u53ca&#xff1a;<\/p>\n<p>docker system df -v<\/p>\n<p>\u518d\u770b Docker \u5b9e\u9645\u76ee\u5f55&#xff1a;<\/p>\n<p>sudo du -sh \/var\/lib\/docker<\/p>\n<p>\u5982\u679c\u8fd9\u91cc\u8fbe\u5230\u51e0\u5341 GB\u3001\u51e0\u767e GB&#xff0c;\u5c31\u9700\u8981\u8fdb\u4e00\u6b65\u68c0\u67e5\u3002<\/p>\n<p>1. \u67e5\u770b Docker \u5bb9\u5668<\/p>\n<p>docker ps -a<\/p>\n<p>2. \u67e5\u770b\u5bb9\u5668\u65e5\u5fd7\u5927\u5c0f<\/p>\n<p>\u8fd9\u662f\u975e\u5e38\u5e38\u89c1\u7684\u201c\u9690\u5f62\u6740\u624b\u201d\u3002<\/p>\n<p>\u6267\u884c&#xff1a;<\/p>\n<p>sudo du -h \/var\/lib\/docker\/containers\/*\/*-json.log 2&gt;\/dev\/null | sort -hr | head -20<\/p>\n<p>\u5982\u679c\u51fa\u73b0&#xff1a;<\/p>\n<p>100G \/var\/lib\/docker\/containers\/xxx\/xxx-json.log<br \/>\n80G  \/var\/lib\/docker\/containers\/xxx\/xxx-json.log<br \/>\n30G  \/var\/lib\/docker\/containers\/xxx\/xxx-json.log<\/p>\n<p>\u57fa\u672c\u53ef\u4ee5\u786e\u5b9a\u662f Docker \u5bb9\u5668\u65e5\u5fd7\u6ca1\u6709\u9650\u5236\u5927\u5c0f\u3002<\/p>\n<p>\u53ef\u4ee5\u5148\u5b89\u5168\u5730\u6e05\u7a7a\u67d0\u4e2a\u8d85\u5927\u65e5\u5fd7&#xff1a;<\/p>\n<p>sudo truncate -s 0 \/var\/lib\/docker\/containers\/\u5bb9\u5668ID\/\u5bb9\u5668ID-json.log<\/p>\n<p>\u4f8b\u5982&#xff1a;<\/p>\n<p>sudo truncate -s 0 \/var\/lib\/docker\/containers\/abc123\/abc123-json.log<\/p>\n<p>\u4e0d\u5efa\u8bae\u76f4\u63a5 rm Docker \u6b63\u5728\u4f7f\u7528\u7684\u65e5\u5fd7\u6587\u4ef6\u3002<\/p>\n<hr \/>\n<p>\u68c0\u67e5 \/var\/log<\/p>\n<p>\u5982\u679c \/var\/log \u5f88\u5927&#xff1a;<\/p>\n<p>sudo du -xhd1 \/var\/log 2&gt;\/dev\/null | sort -hr<\/p>\n<p>\u8fdb\u4e00\u6b65&#xff1a;<\/p>\n<p>sudo du -ah \/var\/log 2&gt;\/dev\/null | sort -hr | head -30<\/p>\n<p>\u91cd\u70b9\u5173\u6ce8&#xff1a;<\/p>\n<p>\/var\/log\/syslog<br \/>\n\/var\/log\/messages<br \/>\n\/var\/log\/auth.log<br \/>\n\/var\/log\/kern.log<br \/>\n\/var\/log\/journal<\/p>\n<p>\u5982\u679c\u662f systemd journal&#xff1a;<\/p>\n<p>journalctl &#8211;disk-usage<\/p>\n<p>\u4f8b\u5982&#xff1a;<\/p>\n<p>Archived and active journals take up 120.0G in the file system.<\/p>\n<p>\u53ef\u4ee5\u6309\u7167\u65f6\u95f4\u6e05\u7406&#xff0c;\u4f8b\u5982\u53ea\u4fdd\u7559\u6700\u8fd1 7 \u5929&#xff1a;<\/p>\n<p>sudo journalctl &#8211;vacuum-time&#061;7d<\/p>\n<p>\u6216\u8005\u9650\u5236\u5230 2G&#xff1a;<\/p>\n<p>sudo journalctl &#8211;vacuum-size&#061;2G<\/p>\n<hr \/>\n<p>\u68c0\u67e5 \/home<\/p>\n<p>\u5982\u679c \/home \u5f88\u5927&#xff1a;<\/p>\n<p>sudo du -xhd1 \/home 2&gt;\/dev\/null | sort -hr<\/p>\n<p>\u4f8b\u5982&#xff1a;<\/p>\n<p>300G \/home\/user<\/p>\n<p>\u7ee7\u7eed&#xff1a;<\/p>\n<p>sudo du -xhd1 \/home\/user 2&gt;\/dev\/null | sort -hr<\/p>\n<p>\u91cd\u70b9\u5173\u6ce8&#xff1a;<\/p>\n<p>~\/.cache<br \/>\n~\/.local<br \/>\n~\/.npm<br \/>\n~\/.m2<br \/>\n~\/.gradle<br \/>\n~\/.conda<br \/>\n~\/.cache\/pip<\/p>\n<p>\u4f8b\u5982 Python&#xff1a;<\/p>\n<p>du -sh ~\/.cache\/pip<\/p>\n<p>\u53ef\u4ee5\u6e05\u7406&#xff1a;<\/p>\n<p>pip cache purge<\/p>\n<p>Node&#xff1a;<\/p>\n<p>du -sh ~\/.npm<\/p>\n<p>Maven&#xff1a;<\/p>\n<p>du -sh ~\/.m2<\/p>\n<p>Gradle&#xff1a;<\/p>\n<p>du -sh ~\/.gradle<\/p>\n<hr \/>\n<p>\u68c0\u67e5 \/opt<\/p>\n<p>\u5f88\u591a\u90e8\u7f72\u73af\u5883\u4f1a\u628a\u5e94\u7528\u653e\u5728&#xff1a;<\/p>\n<p>\/opt<\/p>\n<p>\u68c0\u67e5&#xff1a;<\/p>\n<p>sudo du -xhd1 \/opt 2&gt;\/dev\/null | sort -hr<\/p>\n<p>\u5982\u679c\u4f60\u7684 Java\u3001GIS\u3001AI\u3001Docker \u90e8\u7f72\u9879\u76ee\u6bd4\u8f83\u591a&#xff0c;\u8fd9\u91cc\u5c24\u5176\u503c\u5f97\u68c0\u67e5\u3002<\/p>\n<p>\u4f8b\u5982&#xff1a;<\/p>\n<p>350G \/opt\/app<\/p>\n<p>\u7ee7\u7eed&#xff1a;<\/p>\n<p>sudo du -xhd1 \/opt\/app 2&gt;\/dev\/null | sort -hr<\/p>\n<p>\u4e00\u4e2a\u67e5\u770b\u811a\u672c<\/p>\n<p>echo &#034;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061; \u78c1\u76d8 &#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#034;<br \/>\ndf -h<\/p>\n<p>echo<br \/>\necho &#034;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061; inode &#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#034;<br \/>\ndf -ih<\/p>\n<p>echo<br \/>\necho &#034;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061; \u6839\u76ee\u5f55 &#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#034;<br \/>\nsudo du -xhd1 \/ 2&gt;\/dev\/null | sort -hr<\/p>\n<p>echo<br \/>\necho &#034;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061; \/var &#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#034;<br \/>\nsudo du -xhd1 \/var 2&gt;\/dev\/null | sort -hr<\/p>\n<p>echo<br \/>\necho &#034;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061; \/home &#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#034;<br \/>\nsudo du -xhd1 \/home 2&gt;\/dev\/null | sort -hr<\/p>\n<p>echo<br \/>\necho &#034;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061; \/opt &#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#034;<br \/>\nsudo du -xhd1 \/opt 2&gt;\/dev\/null | sort -hr<\/p>\n<p>echo<br \/>\necho &#034;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061; \u5927\u6587\u4ef6 &#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#034;<br \/>\nsudo find \/ -xdev -type f -size &#043;5G -exec ls -lh {} \\\\; 2&gt;\/dev\/null | sort -k5 -hr | head -30<\/p>\n<p>echo<br \/>\necho &#034;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061; Deleted\u4f46\u4ecd\u88ab\u5360\u7528 &#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#034;<br \/>\nsudo lsof &#043;L1 2&gt;\/dev\/null | head -50<\/p>\n<p>echo<br \/>\necho &#034;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061; Docker &#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#034;<br \/>\ndocker system df 2&gt;\/dev\/null<\/p>\n<p>echo<br \/>\necho &#034;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061; Docker\u65e5\u5fd7 &#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#034;<br \/>\nsudo du -h \/var\/lib\/docker\/containers\/*\/*-json.log 2&gt;\/dev\/null | sort -hr | head -20<\/p>\n<p>echo<br \/>\necho &#034;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061; Journal &#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#061;&#034;<br \/>\nsudo journalctl &#8211;disk-usage 2&gt;\/dev\/null<\/p>\n<h3>4. \u8fdb\u7a0b\u7ba1\u7406<\/h3>\n<p>\u8fdb\u7a0b\u7ba1\u7406\u662f\u670d\u52a1\u5668\u7ef4\u62a4\u7684\u6838\u5fc3\u6280\u80fd&#xff0c;\u6d89\u53ca\u67e5\u770b\u3001\u7ec8\u6b62\u548c\u540e\u53f0\u8fd0\u884c\u7b49\u64cd\u4f5c\u3002<\/p>\n<ul>\n<li>ps&#xff1a;\u67e5\u770b\u5f53\u524d\u8fdb\u7a0b\u5feb\u7167&#xff0c;ps -ef \u663e\u793a\u6240\u6709\u8fdb\u7a0b&#xff0c;ps aux \u663e\u793a\u8be6\u7ec6\u8d44\u6e90\u5360\u7528\u3002<\/li>\n<li>kill&#xff1a;\u7ec8\u6b62\u6307\u5b9a\u8fdb\u7a0b&#xff0c;kill -9 PID \u5f3a\u5236\u7ed3\u675f&#xff0c;kill -15 PID \u4f18\u96c5\u9000\u51fa\u3002<\/li>\n<li>pkill&#xff1a;\u6309\u540d\u79f0\u6279\u91cf\u7ec8\u6b62\u8fdb\u7a0b&#xff0c;\u4f8b\u5982 pkill -f nginx \u7ed3\u675f\u6240\u6709 nginx \u76f8\u5173\u8fdb\u7a0b\u3002<\/li>\n<li>jobs&#xff1a;\u67e5\u770b\u5f53\u524d\u7ec8\u7aef\u540e\u53f0\u8fd0\u884c\u7684\u4efb\u52a1\u5217\u8868\u3002<\/li>\n<li>nohup&#xff1a;\u8ba9\u547d\u4ee4\u5728\u540e\u53f0\u6301\u7eed\u8fd0\u884c&#xff0c;\u5373\u4f7f\u7ec8\u7aef\u5173\u95ed\u4e5f\u4e0d\u4e2d\u65ad&#xff0c;\u4f8b\u5982 nohup java -jar app.jar &amp;\u3002<\/li>\n<li>systemctl&#xff1a;\u7ba1\u7406\u7cfb\u7edf\u670d\u52a1&#xff0c;systemctl start nginx \u542f\u52a8\u670d\u52a1&#xff0c;systemctl enable nginx \u8bbe\u7f6e\u5f00\u673a\u81ea\u542f\u3002<\/li>\n<\/ul>\n<h3>5. \u7f51\u7edc\u6392\u67e5\u4e0e\u8fde\u63a5<\/h3>\n<p>\u7f51\u7edc\u95ee\u9898\u662f\u670d\u52a1\u5668\u8fd0\u7ef4\u7684\u9ad8\u9891\u573a\u666f&#xff0c;\u638c\u63e1\u5e38\u7528\u7f51\u7edc\u547d\u4ee4\u53ef\u4ee5\u5feb\u901f\u5b9a\u4f4d\u8fde\u901a\u6027\u3001\u7aef\u53e3\u548c\u8fde\u63a5\u72b6\u6001\u3002<\/p>\n<ul>\n<li>ping&#xff1a;\u6d4b\u8bd5\u76ee\u6807\u4e3b\u673a\u8fde\u901a\u6027&#xff0c;\u4f8b\u5982 ping -c 4 baidu.com \u53d1\u9001 4 \u4e2a\u63a2\u6d4b\u5305\u3002<\/li>\n<li>curl&#xff1a;\u53d1\u9001 HTTP \u8bf7\u6c42\u6d4b\u8bd5\u63a5\u53e3&#xff0c;curl -I https:\/\/example.com \u67e5\u770b\u54cd\u5e94\u5934&#xff0c;curl -X POST -d &#034;key&#061;value&#034; URL \u53d1\u9001 POST \u8bf7\u6c42\u3002<\/li>\n<li>wget&#xff1a;\u4e0b\u8f7d\u8fdc\u7a0b\u6587\u4ef6&#xff0c;wget -c URL \u652f\u6301\u65ad\u70b9\u7eed\u4f20\u3002<\/li>\n<li>ss&#xff1a;\u67e5\u770b\u7f51\u7edc\u8fde\u63a5\u548c\u76d1\u542c\u7aef\u53e3&#xff0c;ss -tlnp \u5217\u51fa\u6240\u6709\u76d1\u542c\u7aef\u53e3\u53ca\u5bf9\u5e94\u8fdb\u7a0b\u3002<\/li>\n<li>netstat&#xff1a;\u4f20\u7edf\u7f51\u7edc\u7edf\u8ba1\u5de5\u5177&#xff0c;netstat -tulnp \u67e5\u770b\u7aef\u53e3\u5360\u7528\u60c5\u51b5\u3002<\/li>\n<li>traceroute&#xff1a;\u8ffd\u8e2a\u6570\u636e\u5305\u5230\u8fbe\u76ee\u6807\u4e3b\u673a\u7684\u8def\u7531\u8def\u5f84&#xff0c;\u7528\u4e8e\u5b9a\u4f4d\u7f51\u7edc\u5ef6\u8fdf\u8282\u70b9\u3002<\/li>\n<li>ip addr&#xff1a;\u67e5\u770b\u7f51\u5361 IP \u5730\u5740\u548c\u7f51\u7edc\u914d\u7f6e\u4fe1\u606f\u3002<\/li>\n<\/ul>\n<h3>6. \u6743\u9650\u4e0e\u7528\u6237\u7ba1\u7406<\/h3>\n<p>\u591a\u7528\u6237\u73af\u5883\u4e0b\u7684\u6743\u9650\u63a7\u5236\u662f Linux \u5b89\u5168\u7684\u57fa\u7840&#xff0c;\u4ee5\u4e0b\u547d\u4ee4\u7528\u4e8e\u7ba1\u7406\u7528\u6237\u3001\u7ec4\u548c\u6587\u4ef6\u6743\u9650\u3002<\/p>\n<ul>\n<li>chmod&#xff1a;\u4fee\u6539\u6587\u4ef6\u6743\u9650&#xff0c;\u4f8b\u5982 chmod 755 script.sh \u8bbe\u7f6e\u6240\u6709\u8005\u53ef\u8bfb\u5199\u6267\u884c&#xff0c;\u5176\u4ed6\u7528\u6237\u53ef\u8bfb\u6267\u884c\u3002<\/li>\n<li>chown&#xff1a;\u4fee\u6539\u6587\u4ef6\u6240\u6709\u8005\u548c\u6240\u5c5e\u7ec4&#xff0c;\u4f8b\u5982 chown root:root file.txt\u3002<\/li>\n<li>useradd&#xff1a;\u521b\u5efa\u65b0\u7528\u6237&#xff0c;useradd -m username \u540c\u65f6\u521b\u5efa\u7528\u6237\u4e3b\u76ee\u5f55\u3002<\/li>\n<li>passwd&#xff1a;\u8bbe\u7f6e\u6216\u4fee\u6539\u7528\u6237\u5bc6\u7801\u3002<\/li>\n<li>usermod&#xff1a;\u4fee\u6539\u7528\u6237\u5c5e\u6027&#xff0c;\u4f8b\u5982 usermod -aG sudo username \u5c06\u7528\u6237\u52a0\u5165 sudo \u7ec4\u3002<\/li>\n<li>groupadd&#xff1a;\u521b\u5efa\u65b0\u7528\u6237\u7ec4\u3002<\/li>\n<li>sudo&#xff1a;\u4ee5\u7ba1\u7406\u5458\u6743\u9650\u6267\u884c\u547d\u4ee4&#xff0c;\u4f8b\u5982 sudo apt update\u3002<\/li>\n<\/ul>\n<h3>7. \u65e5\u5fd7\u67e5\u770b\u4e0e\u6587\u672c\u5904\u7406<\/h3>\n<p>\u65e5\u5fd7\u5206\u6790\u548c\u6587\u672c\u5904\u7406\u662f\u6392\u67e5\u95ee\u9898\u7684\u91cd\u8981\u624b\u6bb5&#xff0c;\u7ed3\u5408\u7ba1\u9053\u548c\u8fc7\u6ee4\u547d\u4ee4\u53ef\u4ee5\u9ad8\u6548\u63d0\u53d6\u5173\u952e\u4fe1\u606f\u3002<\/p>\n<ul>\n<li>tail&#xff1a;\u67e5\u770b\u6587\u4ef6\u672b\u5c3e\u5185\u5bb9&#xff0c;tail -f \/var\/log\/syslog \u5b9e\u65f6\u8ddf\u8e2a\u65e5\u5fd7\u8f93\u51fa\u3002<\/li>\n<li>head&#xff1a;\u67e5\u770b\u6587\u4ef6\u5f00\u5934\u5185\u5bb9&#xff0c;head -n 20 file.log \u663e\u793a\u524d 20 \u884c\u3002<\/li>\n<li>grep&#xff1a;\u6309\u5173\u952e\u5b57\u8fc7\u6ee4\u6587\u672c&#xff0c;grep &#034;ERROR&#034; app.log \u67e5\u627e\u9519\u8bef\u65e5\u5fd7&#xff0c;grep -r &#034;keyword&#034; \/etc \u9012\u5f52\u641c\u7d22\u76ee\u5f55\u3002<\/li>\n<li>awk&#xff1a;\u6309\u5217\u5904\u7406\u6587\u672c&#xff0c;\u4f8b\u5982 awk &#039;{print $1}&#039; file.txt \u8f93\u51fa\u7b2c\u4e00\u5217\u3002<\/li>\n<li>sed&#xff1a;\u6d41\u5f0f\u6587\u672c\u7f16\u8f91&#xff0c;sed -i &#039;s\/old\/new\/g&#039; file.txt \u5168\u5c40\u66ff\u6362\u5e76\u5199\u56de\u6587\u4ef6\u3002<\/li>\n<li>less&#xff1a;\u5206\u9875\u67e5\u770b\u5927\u6587\u4ef6&#xff0c;\u652f\u6301\u4e0a\u4e0b\u7ffb\u9875\u548c\u5173\u952e\u5b57\u641c\u7d22\u3002<\/li>\n<li>wc -l&#xff1a;\u7edf\u8ba1\u6587\u4ef6\u884c\u6570&#xff0c;\u5e38\u7528\u4e8e\u5feb\u901f\u8bc4\u4f30\u65e5\u5fd7\u89c4\u6a21\u3002<\/li>\n<\/ul>\n<h3>8. \u8f6f\u4ef6\u5305\u7ba1\u7406<\/h3>\n<p>\u4e0d\u540c\u53d1\u884c\u7248\u4f7f\u7528\u4e0d\u540c\u7684\u5305\u7ba1\u7406\u5de5\u5177&#xff0c;\u638c\u63e1\u5e38\u7528\u64cd\u4f5c\u53ef\u4ee5\u5feb\u901f\u5b89\u88c5\u3001\u66f4\u65b0\u548c\u5378\u8f7d\u8f6f\u4ef6\u3002<\/p>\n<ul>\n<li>apt&#xff1a;Debian \u548c Ubuntu \u7cfb\u5217&#xff0c;apt update \u66f4\u65b0\u8f6f\u4ef6\u6e90&#xff0c;apt install nginx \u5b89\u88c5\u8f6f\u4ef6&#xff0c;apt upgrade \u5347\u7ea7\u6240\u6709\u8f6f\u4ef6\u5305\u3002<\/li>\n<li>yum&#xff1a;CentOS 7 \u53ca\u4ee5\u4e0b\u7248\u672c&#xff0c;yum install -y httpd \u5b89\u88c5\u8f6f\u4ef6&#xff0c;yum remove httpd \u5378\u8f7d\u8f6f\u4ef6\u3002<\/li>\n<li>dnf&#xff1a;CentOS 8 \u53ca\u4ee5\u4e0a\u7248\u672c&#xff0c;\u7528\u6cd5\u4e0e yum \u7c7b\u4f3c&#xff0c;dnf install nginx\u3002<\/li>\n<li>rpm&#xff1a;\u76f4\u63a5\u64cd\u4f5c RPM \u5305&#xff0c;rpm -ivh package.rpm \u5b89\u88c5\u672c\u5730\u5305&#xff0c;rpm -qa \u5217\u51fa\u5df2\u5b89\u88c5\u5305\u3002<\/li>\n<li>dpkg&#xff1a;Debian \u7cfb\u5e95\u5c42\u5305\u5de5\u5177&#xff0c;dpkg -i package.deb \u5b89\u88c5\u672c\u5730\u5305\u3002<\/li>\n<\/ul>\n<h3>9. \u5b9e\u7528\u7ec4\u5408\u6280\u5de7<\/h3>\n<p>\u5c06\u591a\u4e2a\u547d\u4ee4\u901a\u8fc7\u7ba1\u9053\u7ec4\u5408&#xff0c;\u53ef\u4ee5\u5b8c\u6210\u66f4\u590d\u6742\u7684\u8fd0\u7ef4\u4efb\u52a1&#xff0c;\u4ee5\u4e0b\u662f\u4e00\u4e9b\u9ad8\u9891\u5b9e\u7528\u7ec4\u5408\u3002<\/p>\n<p># \u67e5\u770b\u5360\u7528 CPU \u6700\u9ad8\u7684\u524d 5 \u4e2a\u8fdb\u7a0b<br \/>\nps aux &#8211;sort&#061;-%cpu | head -6<br \/>\n\u7edf\u8ba1\u65e5\u5fd7\u4e2d ERROR \u51fa\u73b0\u7684\u6b21\u6570<br \/>\ngrep -c &#034;ERROR&#034; \/var\/log\/app.log<br \/>\n\u67e5\u627e\u5e76\u5220\u9664 30 \u5929\u524d\u7684\u65e5\u5fd7\u6587\u4ef6<br \/>\nfind \/var\/log -name &#034;*.log&#034; -mtime &#043;30 -exec rm {} ;<br \/>\n\u5b9e\u65f6\u76d1\u63a7\u65e5\u5fd7\u5e76\u8fc7\u6ee4\u5173\u952e\u5b57<br \/>\ntail -f \/var\/log\/syslog | grep &#034;nginx&#034;<br \/>\n\u67e5\u770b\u67d0\u4e2a\u7aef\u53e3\u88ab\u54ea\u4e2a\u8fdb\u7a0b\u5360\u7528<br \/>\nss -tlnp | grep :8080<br \/>\n\u6279\u91cf\u66ff\u6362\u914d\u7f6e\u6587\u4ef6\u4e2d\u7684 IP \u5730\u5740<br \/>\nsed -i &#039;s\/192.168.1.1\/10.0.0.1\/g&#039; \/etc\/app\/config.conf<br \/>\n\u67e5\u770b\u5185\u5b58\u5360\u7528\u6700\u9ad8\u7684\u524d 10 \u4e2a\u8fdb\u7a0b<br \/>\nps aux &#8211;sort&#061;-%mem | head -11<br \/>\n\u7edf\u8ba1\u5f53\u524d\u76ee\u5f55\u4e0b\u5404\u5b50\u76ee\u5f55\u7684\u78c1\u76d8\u5360\u7528\u5e76\u6392\u5e8f<br \/>\ndu -sh *\/ | sort -hr<br \/>\n\u67e5\u770b\u5f53\u524d\u7cfb\u7edf\u8d1f\u8f7d\u548c\u8fd0\u884c\u65f6\u95f4<br \/>\nuptime &amp;&amp; cat \/proc\/loadavg<br \/>\n\u67e5\u627e\u6700\u8fd1 24 \u5c0f\u65f6\u5185\u4fee\u6539\u8fc7\u7684\u6587\u4ef6<br \/>\nfind \/var\/log -type f -mtime -1 -ls<br \/>\n\u7edf\u8ba1\u8bbf\u95ee\u91cf\u6700\u9ad8\u7684\u524d 10 \u4e2a IP&#xff08;Nginx \u65e5\u5fd7&#xff09;<br \/>\nawk &#039;{print $1}&#039; \/var\/log\/nginx\/access.log | sort | uniq -c | sort -rn | head -10<br \/>\n\u67e5\u770b\u5f53\u524d TCP \u8fde\u63a5\u72b6\u6001\u7edf\u8ba1<br \/>\nss -s<br \/>\n\u6279\u91cf\u6740\u6389\u5305\u542b\u67d0\u4e2a\u5173\u952e\u5b57\u7684\u8fdb\u7a0b<br \/>\nps aux | grep &#034;java&#034; | grep -v grep | awk &#039;{print $2}&#039; | xargs kill -9<br \/>\n\u67e5\u770b\u78c1\u76d8\u7a7a\u95f4\u6700\u5927\u7684\u524d 10 \u4e2a\u6587\u4ef6<br \/>\nfind \/ -type f -size &#043;100M -exec ls -lh {} ; 2&gt;\/dev\/null | awk &#039;{print $5, $9}&#039; | sort -rh | head -10<br \/>\n\u5b9e\u65f6\u67e5\u770b\u7cfb\u7edf\u8d44\u6e90\u5360\u7528\u6700\u9ad8\u7684\u8fdb\u7a0b&#xff08;\u6bcf 2 \u79d2\u5237\u65b0&#xff09;<br \/>\ntop -b -n 1 | head -20<br \/>\n\u7edf\u8ba1\u65e5\u5fd7\u4e2d 5xx \u9519\u8bef\u7801\u51fa\u73b0\u7684\u6b21\u6570<br \/>\ngrep -E &#034;HTTP\/1.1&#034; 5[0-9][0-9]&#034; \/var\/log\/nginx\/access.log | wc -l<br \/>\n\u67e5\u770b\u5f53\u524d\u767b\u5f55\u7528\u6237\u53ca\u5176\u64cd\u4f5c<br \/>\nwho &amp;&amp; w<br \/>\n\u6279\u91cf\u538b\u7f29\u5e76\u5907\u4efd\u6307\u5b9a\u76ee\u5f55&#xff08;\u5e26\u65f6\u95f4\u6233&#xff09;<br \/>\ntar -czvf \/backup\/etc_$(date &#043;%Y%m%d).tar.gz \/etc<br \/>\n\u67e5\u770b\u7cfb\u7edf\u6240\u6709\u76d1\u542c\u7aef\u53e3\u53ca\u5bf9\u5e94\u8fdb\u7a0b<br \/>\nnetstat -tulnp | grep LISTEN<br \/>\n\u7edf\u8ba1\u5f53\u524d\u76ee\u5f55\u4e0b\u6587\u4ef6\u6570\u91cf<br \/>\nls -l | grep &#034;^-&#034; | wc -l<\/p>\n<p>\u9664\u4e86\u4e0a\u8ff0\u57fa\u7840\u7ec4\u5408&#xff0c;\u4e0b\u9762\u518d\u8865\u5145\u4e00\u6279\u66f4\u8d34\u8fd1\u771f\u5b9e\u8fd0\u7ef4\u573a\u666f\u7684\u9ad8\u9891\u7528\u6cd5&#xff0c;\u8986\u76d6\u78c1\u76d8\u6e05\u7406\u3001\u670d\u52a1\u6392\u67e5\u3001\u6279\u91cf\u64cd\u4f5c\u548c\u6027\u80fd\u5206\u6790\u7b49\u65b9\u5411\u3002<\/p>\n<p># \u627e\u51fa\u5e76\u6e05\u7406\u8d85\u8fc7 1G \u7684\u65e5\u5fd7\u6587\u4ef6&#xff08;\u5148\u5217\u51fa\u518d\u786e\u8ba4\u5220\u9664&#xff09;<br \/>\nfind \/var\/log -type f -size &#043;1G -exec ls -lh {} \\\\;<br \/>\n# \u67e5\u770b\u7cfb\u7edf\u542f\u52a8\u8017\u65f6\u6700\u957f\u7684\u670d\u52a1&#xff08;systemd \u5206\u6790&#xff09;<br \/>\nsystemd-analyze blame | head -10<br \/>\n# \u67e5\u770b\u67d0\u4e2a\u670d\u52a1\u7684\u8be6\u7ec6\u72b6\u6001\u548c\u6700\u8fd1\u65e5\u5fd7<br \/>\nsystemctl status nginx &amp;&amp; journalctl -u nginx &#8211;no-pager -n 50<br \/>\n# \u6279\u91cf\u5c06\u5f53\u524d\u76ee\u5f55\u4e0b\u6240\u6709 .log \u6587\u4ef6\u538b\u7f29\u5f52\u6863<br \/>\nfind . -name &#034;*.log&#034; -exec gzip {} \\\\;<br \/>\n# \u7edf\u8ba1\u6bcf\u4e2a\u7528\u6237\u5360\u7528\u7684\u78c1\u76d8\u7a7a\u95f4\u5e76\u6392\u5e8f<br \/>\nsudo du -sh \/home\/* 2&gt;\/dev\/null | sort -hr<br \/>\n# \u67e5\u770b\u7f51\u7edc\u8fde\u63a5\u4e2d\u5904\u4e8e TIME_WAIT \u72b6\u6001\u7684\u8fde\u63a5\u6570<br \/>\nss -s | grep -i timewait<br \/>\n# \u5b9e\u65f6\u67e5\u770b\u67d0\u4e2a\u8fdb\u7a0b\u7684 CPU \u548c\u5185\u5b58\u5360\u7528<br \/>\ntop -p $(pgrep -d, -f java)<br \/>\n# \u7edf\u8ba1\u65e5\u5fd7\u4e2d\u8bbf\u95ee\u91cf\u6700\u9ad8\u7684\u524d 10 \u4e2a URL&#xff08;Nginx \u65e5\u5fd7&#xff09;<br \/>\nawk &#039;{print $7}&#039; \/var\/log\/nginx\/access.log | sort | uniq -c | sort -rn | head -10<br \/>\n# \u6279\u91cf\u4fee\u6539\u6587\u4ef6\u6743\u9650&#xff08;\u5c06\u5f53\u524d\u76ee\u5f55\u4e0b\u6240\u6709 .sh \u8bbe\u4e3a\u53ef\u6267\u884c&#xff09;<br \/>\nfind . -name &#034;*.sh&#034; -exec chmod &#043;x {} \\\\;<br \/>\n# \u67e5\u770b\u7cfb\u7edf\u6700\u8fd1\u4e00\u6b21\u91cd\u542f\u7684\u539f\u56e0\u548c\u65f6\u95f4<br \/>\nlast reboot | head -3<br \/>\n# \u7edf\u8ba1\u5f53\u524d\u76ee\u5f55\u4e0b\u5404\u6587\u4ef6\u7c7b\u578b\u6570\u91cf<br \/>\nfind . -type f | awk -F. &#039;{print $NF}&#039; | sort | uniq -c | sort -rn | head -10<br \/>\n# \u67e5\u770b\u5185\u5b58\u548c\u4ea4\u6362\u5206\u533a\u4f7f\u7528\u60c5\u51b5&#xff08;\u6bcf\u79d2\u5237\u65b0\u4e00\u6b21&#xff0c;\u5171 5 \u6b21&#xff09;<br \/>\nfree -h -s 1 -c 5<br \/>\n# \u6279\u91cf\u5220\u9664 7 \u5929\u524d\u7684\u4e34\u65f6\u6587\u4ef6<br \/>\nfind \/tmp -type f -mtime &#043;7 -delete<br \/>\n# \u67e5\u770b\u67d0\u4e2a IP \u7684\u8bbf\u95ee\u6b21\u6570&#xff08;Nginx \u65e5\u5fd7&#xff09;<br \/>\ngrep &#034;192.168.1.100&#034; \/var\/log\/nginx\/access.log | wc -l<br \/>\n# \u67e5\u770b\u5f53\u524d\u7cfb\u7edf\u6253\u5f00\u7684\u6587\u4ef6\u6570<br \/>\nlsof | wc -l<br \/>\n# \u67e5\u770b\u78c1\u76d8 I\/O \u6700\u9ad8\u7684\u8fdb\u7a0b<br \/>\niotop -o -n 1 -b | head -15<br \/>\n# \u6279\u91cf\u91cd\u547d\u540d\u6587\u4ef6&#xff08;\u5c06 .txt \u6539\u4e3a .md&#xff09;<br \/>\nfor f in *.txt; do mv &#034;$f&#034; &#034;${f%.txt}.md&#034;; done<br \/>\n# \u67e5\u770b\u7cfb\u7edf\u6240\u6709\u5b9a\u65f6\u4efb\u52a1<br \/>\ncrontab -l &amp;&amp; ls \/etc\/cron.d\/<br \/>\n# \u7edf\u8ba1\u65e5\u5fd7\u4e2d ERROR \u548c WARN \u7684\u6570\u91cf\u5bf9\u6bd4<br \/>\ngrep -c &#034;ERROR&#034; \/var\/log\/app.log &amp;&amp; grep -c &#034;WARN&#034; \/var\/log\/app.log<br \/>\n# \u67e5\u770b\u5f53\u524d\u7cfb\u7edf\u67b6\u6784\u548c\u5185\u6838\u4fe1\u606f<br \/>\nuname -a &amp;&amp; cat \/etc\/os-release | head -2<\/p>\n<p>\u8fd9\u4e9b\u7ec4\u5408\u547d\u4ee4\u8986\u76d6\u4e86\u78c1\u76d8\u6e05\u7406\u3001\u670d\u52a1\u6392\u67e5\u3001\u65e5\u5fd7\u5206\u6790\u3001\u6279\u91cf\u64cd\u4f5c\u548c\u6027\u80fd\u76d1\u63a7\u7b49\u9ad8\u9891\u573a\u666f\u3002\u5efa\u8bae\u5728\u5b9e\u9645\u4f7f\u7528\u524d\u5148\u7528 man \u67e5\u770b\u5404\u547d\u4ee4\u7684\u53c2\u6570\u8bf4\u660e&#xff0c;\u5e76\u6839\u636e\u81ea\u8eab\u73af\u5883\u8c03\u6574\u8def\u5f84\u548c\u5173\u952e\u5b57&#xff0c;\u907f\u514d\u8bef\u64cd\u4f5c\u3002<\/p>\n<h3>10. \u603b\u7ed3<\/h3>\n<p>\u672c\u6587\u6574\u7406\u4e86 Linux \u670d\u52a1\u5668\u8fd0\u7ef4\u4e2d\u9ad8\u9891\u4f7f\u7528\u7684\u547d\u4ee4&#xff0c;\u6db5\u76d6\u6587\u4ef6\u64cd\u4f5c\u3001\u7cfb\u7edf\u76d1\u63a7\u3001\u8fdb\u7a0b\u7ba1\u7406\u3001\u7f51\u7edc\u6392\u67e5\u3001\u6743\u9650\u63a7\u5236\u3001\u65e5\u5fd7\u5206\u6790\u548c\u8f6f\u4ef6\u5305\u7ba1\u7406\u7b49\u65b9\u9762\u3002\u5b9e\u9645\u5de5\u4f5c\u4e2d\u5efa\u8bae\u7ed3\u5408 man \u547d\u4ee4\u67e5\u770b\u6bcf\u4e2a\u5de5\u5177\u7684\u8be6\u7ec6\u53c2\u6570\u8bf4\u660e&#xff0c;\u5e76\u6839\u636e\u5177\u4f53\u573a\u666f\u7075\u6d3b\u7ec4\u5408\u4f7f\u7528\u3002\u719f\u7ec3\u638c\u63e1\u8fd9\u4e9b\u547d\u4ee4&#xff0c;\u80fd\u591f\u663e\u8457\u63d0\u5347\u670d\u52a1\u5668\u7ba1\u7406\u548c\u95ee\u9898\u6392\u67e5\u7684\u6548\u7387\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>1. \u5f15\u8a00Linux \u670d\u52a1\u5668\u5728\u65e5\u5e38\u8fd0\u7ef4\u548c\u5f00\u53d1\u90e8\u7f72\u4e2d\u626e\u6f14\u7740\u6838\u5fc3\u89d2\u8272\u3002\u638c\u63e1\u5e38\u7528\u4e14\u5b9e\u7528\u7684\u547d\u4ee4&#xff0c;\u80fd\u591f\u663e\u8457\u63d0\u5347\u5de5\u4f5c\u6548\u7387&#xff0c;\u5e2e\u52a9\u5feb\u901f\u5b9a\u4f4d\u95ee\u9898\u3001\u7ba1\u7406\u7cfb\u7edf\u8d44\u6e90\u5e76\u5b8c\u6210\u81ea\u52a8\u5316\u4efb\u52a1\u3002\u672c\u6587\u6574\u7406\u4e86\u4e00\u4efd\u9ad8\u9891\u4f7f\u7528\u7684 Linux \u547d\u4ee4\u6e05\u5355&#xff0c;\u8986\u76d6\u6587\u4ef6\u64cd\u4f5c\u3001\u7cfb\u7edf\u76d1\u63a7\u3001\u7f51\u7edc\u6392\u67e5\u3001\u6743\u9650\u7ba1\u7406\u3001\u8fdb\u7a0b\u63a7\u5236\u7b49\u5e38\u89c1\u573a\u666f\u30022. \u6587\u4ef6\u4e0e\u76ee\u5f55\u64cd\u4f5c\u6587\u4ef6\u64cd\u4f5c\u662f\u4f7f\u7528 Linux \u670d\u52a1\u5668\u6700\u57fa\u7840\u4e5f\u6700\u9891\u7e41\u7684\u5de5\u4f5c&#xff0c;\u4ee5\u4e0b\u547d\u4ee4\u8986\u76d6\u4e86\u67e5\u770b\u3001\u590d\u5236\u3001\u79fb\u52a8\u3001\u67e5\u627e\u548c\u538b\u7f29\u7b49\u6838\u5fc3\u9700\u6c42\u3002ls&#xff1a;\u5217\u51fa<\/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-110687","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>Linux \u670d\u52a1\u5668\u5e38\u7528\u5b9e\u7528\u547d\u4ee4\u5927\u5168 - \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\/110687.html\" \/>\n<meta property=\"og:locale\" content=\"zh_CN\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Linux \u670d\u52a1\u5668\u5e38\u7528\u5b9e\u7528\u547d\u4ee4\u5927\u5168 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\" \/>\n<meta property=\"og:description\" content=\"1. \u5f15\u8a00Linux \u670d\u52a1\u5668\u5728\u65e5\u5e38\u8fd0\u7ef4\u548c\u5f00\u53d1\u90e8\u7f72\u4e2d\u626e\u6f14\u7740\u6838\u5fc3\u89d2\u8272\u3002\u638c\u63e1\u5e38\u7528\u4e14\u5b9e\u7528\u7684\u547d\u4ee4&#xff0c;\u80fd\u591f\u663e\u8457\u63d0\u5347\u5de5\u4f5c\u6548\u7387&#xff0c;\u5e2e\u52a9\u5feb\u901f\u5b9a\u4f4d\u95ee\u9898\u3001\u7ba1\u7406\u7cfb\u7edf\u8d44\u6e90\u5e76\u5b8c\u6210\u81ea\u52a8\u5316\u4efb\u52a1\u3002\u672c\u6587\u6574\u7406\u4e86\u4e00\u4efd\u9ad8\u9891\u4f7f\u7528\u7684 Linux \u547d\u4ee4\u6e05\u5355&#xff0c;\u8986\u76d6\u6587\u4ef6\u64cd\u4f5c\u3001\u7cfb\u7edf\u76d1\u63a7\u3001\u7f51\u7edc\u6392\u67e5\u3001\u6743\u9650\u7ba1\u7406\u3001\u8fdb\u7a0b\u63a7\u5236\u7b49\u5e38\u89c1\u573a\u666f\u30022. \u6587\u4ef6\u4e0e\u76ee\u5f55\u64cd\u4f5c\u6587\u4ef6\u64cd\u4f5c\u662f\u4f7f\u7528 Linux \u670d\u52a1\u5668\u6700\u57fa\u7840\u4e5f\u6700\u9891\u7e41\u7684\u5de5\u4f5c&#xff0c;\u4ee5\u4e0b\u547d\u4ee4\u8986\u76d6\u4e86\u67e5\u770b\u3001\u590d\u5236\u3001\u79fb\u52a8\u3001\u67e5\u627e\u548c\u538b\u7f29\u7b49\u6838\u5fc3\u9700\u6c42\u3002ls&#xff1a;\u5217\u51fa\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.wsisp.com\/helps\/110687.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-29T00:16:51+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\/110687.html\",\"url\":\"https:\/\/www.wsisp.com\/helps\/110687.html\",\"name\":\"Linux \u670d\u52a1\u5668\u5e38\u7528\u5b9e\u7528\u547d\u4ee4\u5927\u5168 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\",\"isPartOf\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/#website\"},\"datePublished\":\"2026-09-29T00:16:51+00:00\",\"dateModified\":\"2026-09-29T00:16:51+00:00\",\"author\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41\"},\"breadcrumb\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/110687.html#breadcrumb\"},\"inLanguage\":\"zh-Hans\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.wsisp.com\/helps\/110687.html\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/110687.html#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"\u9996\u9875\",\"item\":\"https:\/\/www.wsisp.com\/helps\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Linux \u670d\u52a1\u5668\u5e38\u7528\u5b9e\u7528\u547d\u4ee4\u5927\u5168\"}]},{\"@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":"Linux \u670d\u52a1\u5668\u5e38\u7528\u5b9e\u7528\u547d\u4ee4\u5927\u5168 - \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\/110687.html","og_locale":"zh_CN","og_type":"article","og_title":"Linux \u670d\u52a1\u5668\u5e38\u7528\u5b9e\u7528\u547d\u4ee4\u5927\u5168 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","og_description":"1. \u5f15\u8a00Linux \u670d\u52a1\u5668\u5728\u65e5\u5e38\u8fd0\u7ef4\u548c\u5f00\u53d1\u90e8\u7f72\u4e2d\u626e\u6f14\u7740\u6838\u5fc3\u89d2\u8272\u3002\u638c\u63e1\u5e38\u7528\u4e14\u5b9e\u7528\u7684\u547d\u4ee4&#xff0c;\u80fd\u591f\u663e\u8457\u63d0\u5347\u5de5\u4f5c\u6548\u7387&#xff0c;\u5e2e\u52a9\u5feb\u901f\u5b9a\u4f4d\u95ee\u9898\u3001\u7ba1\u7406\u7cfb\u7edf\u8d44\u6e90\u5e76\u5b8c\u6210\u81ea\u52a8\u5316\u4efb\u52a1\u3002\u672c\u6587\u6574\u7406\u4e86\u4e00\u4efd\u9ad8\u9891\u4f7f\u7528\u7684 Linux \u547d\u4ee4\u6e05\u5355&#xff0c;\u8986\u76d6\u6587\u4ef6\u64cd\u4f5c\u3001\u7cfb\u7edf\u76d1\u63a7\u3001\u7f51\u7edc\u6392\u67e5\u3001\u6743\u9650\u7ba1\u7406\u3001\u8fdb\u7a0b\u63a7\u5236\u7b49\u5e38\u89c1\u573a\u666f\u30022. \u6587\u4ef6\u4e0e\u76ee\u5f55\u64cd\u4f5c\u6587\u4ef6\u64cd\u4f5c\u662f\u4f7f\u7528 Linux \u670d\u52a1\u5668\u6700\u57fa\u7840\u4e5f\u6700\u9891\u7e41\u7684\u5de5\u4f5c&#xff0c;\u4ee5\u4e0b\u547d\u4ee4\u8986\u76d6\u4e86\u67e5\u770b\u3001\u590d\u5236\u3001\u79fb\u52a8\u3001\u67e5\u627e\u548c\u538b\u7f29\u7b49\u6838\u5fc3\u9700\u6c42\u3002ls&#xff1a;\u5217\u51fa","og_url":"https:\/\/www.wsisp.com\/helps\/110687.html","og_site_name":"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","article_published_time":"2026-09-29T00:16:51+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\/110687.html","url":"https:\/\/www.wsisp.com\/helps\/110687.html","name":"Linux \u670d\u52a1\u5668\u5e38\u7528\u5b9e\u7528\u547d\u4ee4\u5927\u5168 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","isPartOf":{"@id":"https:\/\/www.wsisp.com\/helps\/#website"},"datePublished":"2026-09-29T00:16:51+00:00","dateModified":"2026-09-29T00:16:51+00:00","author":{"@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41"},"breadcrumb":{"@id":"https:\/\/www.wsisp.com\/helps\/110687.html#breadcrumb"},"inLanguage":"zh-Hans","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.wsisp.com\/helps\/110687.html"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.wsisp.com\/helps\/110687.html#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"\u9996\u9875","item":"https:\/\/www.wsisp.com\/helps"},{"@type":"ListItem","position":2,"name":"Linux \u670d\u52a1\u5668\u5e38\u7528\u5b9e\u7528\u547d\u4ee4\u5927\u5168"}]},{"@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\/110687","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=110687"}],"version-history":[{"count":0,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts\/110687\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/media?parent=110687"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/categories?post=110687"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/tags?post=110687"},{"taxonomy":"topic","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/topic?post=110687"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}