{"id":16635,"date":"2024-11-18T11:16:58","date_gmt":"2024-11-18T03:16:58","guid":{"rendered":"https:\/\/fwq.ai\/blog\/16635\/"},"modified":"2024-11-18T11:16:58","modified_gmt":"2024-11-18T03:16:58","slug":"%e9%9d%a2%e8%af%95%e5%ae%98%e5%b8%b8%e8%80%83%e7%9a%84-21-%e6%9d%a1-linux-%e5%91%bd%e4%bb%a4","status":"publish","type":"post","link":"https:\/\/fwq.ai\/blog\/16635\/","title":{"rendered":"\u9762\u8bd5\u5b98\u5e38\u8003\u7684 21 \u6761 Linux \u547d\u4ee4"},"content":{"rendered":"<p> <\/p>\n<p style=\"text-align: center\"><img decoding=\"async\" src=\"https:\/\/img.php.cn\/upload\/article\/001\/275\/013\/d19b7e27fc602b54e70e996af15895fd-0.png\" class=\"aligncenter\" title=\"\u9762\u8bd5\u5b98\u5e38\u8003\u7684 21 \u6761 Linux \u547d\u4ee4\u63d2\u56fe\" alt=\"\u9762\u8bd5\u5b98\u5e38\u8003\u7684 21 \u6761 Linux \u547d\u4ee4\u63d2\u56fe\" \/><strong>\u6b63\u6587<\/strong><\/p>\n<pre>find&nbsp;\/var\/mail\/&nbsp;-size&nbsp;+50M&nbsp;-exec&nbsp;rm&nbsp;{}&nbsp;\uff3c;<\/pre>\n<p> \u767b\u5f55\u540e\u590d\u5236 <\/p>\n<h2> <strong><span style=\"font-family: Optima-Regular, PingFangTC-light;font-size: 19px\">\u56db\u3001\u6587\u4ef6\u7684\u6743\u9650&nbsp;<\/span><\/strong> <span style=\"font-size: 15px;font-family: Optima-Regular, PingFangTC-light\">\u4f7f\u7528 &#8220;+&#8221; \u8bbe\u7f6e\u6743\u9650\uff0c\u4f7f\u7528 &#8220;-&#8221; \u7528\u4e8e\u53d6\u6d88<\/span> <\/h2>\n<h3> <strong><span style=\"font-size: 15px;font-family: Optima-Regular, PingFangTC-light\">9. chmod \u547d\u4ee4<\/span><\/strong><span style=\"font-size: 15px;font-family: Optima-Regular, PingFangTC-light\"><\/span> <\/h3>\n<ul>\n<li> ls -lh \u663e\u793a\u6743\u9650 <\/li>\n<li> chmod ugo+rwx directory1 \u8bbe\u7f6e\u76ee\u5f55\u7684\u6240\u6709\u4eba(u)\u3001\u7fa4\u7ec4(g)\u4ee5\u53ca\u5176\u4ed6\u4eba(o)\u4ee5\u8bfb\uff08r\uff0c4 \uff09\u3001\u5199(w\uff0c2)\u548c\u6267\u884c(x\uff0c1)\u7684\u6743\u9650 <\/li>\n<li> chmod go-rwx directory1 &nbsp;\u5220\u9664\u7fa4\u7ec4(g)\u4e0e\u5176\u4ed6\u4eba(o)\u5bf9\u76ee\u5f55\u7684\u8bfb\u5199\u6267\u884c\u6743\u9650 <\/li>\n<\/ul>\n<h3> <strong><span style=\"font-size: 15px;font-family: Optima-Regular, PingFangTC-light\">10. chown \u547d\u4ee4<\/span><\/strong><span style=\"font-size: 15px;font-family: Optima-Regular, PingFangTC-light\"><\/span> <\/h3>\n<p><span style=\"font-size: 15px;font-family: Optima-Regular, PingFangTC-light\">\u6539\u53d8\u6587\u4ef6\u7684\u6240\u6709\u8005\uff1a<\/span> <\/p>\n<ul>\n<li> chown user1 file1 \u6539\u53d8\u4e00\u4e2a\u6587\u4ef6\u7684\u6240\u6709\u4eba\u5c5e\u6027 <\/li>\n<li> chown -R user1 directory1 \u6539\u53d8\u4e00\u4e2a\u76ee\u5f55\u7684\u6240\u6709\u4eba\u5c5e\u6027\u5e76\u540c\u65f6\u6539\u53d8\u6539\u76ee\u5f55\u4e0b\u6240\u6709\u6587\u4ef6\u7684\u5c5e\u6027 <\/li>\n<li> chown user1:group1 file1 \u6539\u53d8\u4e00\u4e2a\u6587\u4ef6\u7684\u6240\u6709\u4eba\u548c\u7fa4\u7ec4\u5c5e\u6027 <\/li>\n<\/ul>\n<h3> <strong><span style=\"font-size: 15px;font-family: Optima-Regular, PingFangTC-light\">11. chgrp \u547d\u4ee4<\/span><\/strong><span style=\"font-size: 15px;font-family: Optima-Regular, PingFangTC-light\"><\/span> <\/h3>\n<p><span style=\"font-size: 15px;font-family: Optima-Regular, PingFangTC-light\">\u6539\u53d8\u6587\u4ef6\u6240\u5c5e\u7528\u6237\u7ec4\uff1a<\/span> <\/p>\n<ul>\n<li> chgrp group1 file1 \u6539\u53d8\u6587\u4ef6\u7684\u7fa4\u7ec4 <\/li>\n<\/ul>\n<p><strong><span style=\"font-family: Optima-Regular, PingFangTC-light;font-size: 19px\">\u4e94\u3001\u6587\u672c\u5904\u7406<\/span><\/strong> <\/p>\n<h3> <strong><span style=\"font-size: 15px;font-family: Optima-Regular, PingFangTC-light\">12. grep \u547d\u4ee4<\/span><\/strong><span style=\"font-size: 15px;font-family: Optima-Regular, PingFangTC-light\"><\/span> <\/h3>\n<p><span style=\"font-size: 15px;font-family: Optima-Regular, PingFangTC-light\">\u5206\u6790\u4e00\u884c\u7684\u4fe1\u606f\uff0c\u82e5\u5f53\u4e2d\u6709\u6211\u4eec\u6240\u9700\u8981\u7684\u4fe1\u606f\uff0c\u5c31\u5c06\u8be5\u884c\u663e\u793a\u51fa\u6765\uff0c\u8be5\u547d\u4ee4\u901a\u5e38\u4e0e\u7ba1\u9053\u547d\u4ee4\u4e00\u8d77\u4f7f\u7528\uff0c\u7528\u4e8e\u5bf9\u4e00\u4e9b\u547d\u4ee4\u7684\u8f93\u51fa\u8fdb\u884c\u7b5b\u9009\u52a0\u5de5\u7b49\u7b49\uff1a<\/span> <\/p>\n<ul>\n<li> grep Aug \/var\/log\/messages&nbsp;&nbsp;\u5728\u6587\u4ef6 &#8216;\/var\/log\/messages&#8217;\u4e2d\u67e5\u627e\u5173\u952e\u8bcd&#8221;Aug&#8221; <\/li>\n<li> grep ^Aug \/var\/log\/messages&nbsp;\u5728\u6587\u4ef6 &#8216;\/var\/log\/messages&#8217;\u4e2d\u67e5\u627e\u4ee5&#8221;Aug&#8221;\u5f00\u59cb\u7684\u8bcd\u6c47 <\/li>\n<li> grep [0-9] \/var\/log\/messages&nbsp;\u9009\u62e9 &#8216;\/var\/log\/messages&#8217; \u6587\u4ef6\u4e2d\u6240\u6709\u5305\u542b\u6570\u5b57\u7684\u884c <\/li>\n<li> grep Aug -R \/var\/log\/*&nbsp;\u5728\u76ee\u5f55 &#8216;\/var\/log&#8217; \u53ca\u968f\u540e\u7684\u76ee\u5f55\u4e2d\u641c\u7d22\u5b57\u7b26\u4e32&#8221;Aug&#8221; <\/li>\n<li> sed &#8216;s\/stringa1\/stringa2\/g&#8217; example.txt&nbsp;\u5c06example.txt\u6587\u4ef6\u4e2d\u7684 &#8220;string1&#8221; \u66ff\u6362\u6210 &#8220;string2&#8221; <\/li>\n<li> sed &#8216;\/^$\/d&#8217; example.txt&nbsp;\u4eceexample.txt\u6587\u4ef6\u4e2d\u5220\u9664\u6240\u6709\u7a7a\u767d\u884c\uff08\u641c\u7d22\u516c\u4f17\u53f7Java\u77e5\u97f3\uff0c\u56de\u590d\u201c2021\u201d\uff0c\u9001\u4f60\u4e00\u4efdJava\u9762\u8bd5\u9898\u5b9d\u5178\uff09 <\/li>\n<\/ul>\n<h3> <strong><span style=\"font-size: 15px;font-family: Optima-Regular, PingFangTC-light\">13. paste \u547d\u4ee4<\/span><\/strong><span style=\"font-size: 15px;font-family: Optima-Regular, PingFangTC-light\"><\/span> <\/h3>\n<ul>\n<li> paste file1 file2&nbsp;\u5408\u5e76\u4e24\u4e2a\u6587\u4ef6\u6216\u4e24\u680f\u7684\u5185\u5bb9 <\/li>\n<li> paste -d &#8216;+&#8217; file1 file2&nbsp;\u5408\u5e76\u4e24\u4e2a\u6587\u4ef6\u6216\u4e24\u680f\u7684\u5185\u5bb9\uff0c\u4e2d\u95f4\u7528&#8221;+&#8221;\u533a\u5206 <\/li>\n<\/ul>\n<h3> <strong><span style=\"font-size: 15px;font-family: Optima-Regular, PingFangTC-light\">14. sort \u547d\u4ee4<\/span><\/strong><span style=\"font-size: 15px;font-family: Optima-Regular, PingFangTC-light\"><\/span> <\/h3>\n<ul>\n<li> sort file1 file2&nbsp;\u6392\u5e8f\u4e24\u4e2a\u6587\u4ef6\u7684\u5185\u5bb9 <\/li>\n<li> sort file1 file2 | uniq&nbsp;\u53d6\u51fa\u4e24\u4e2a\u6587\u4ef6\u7684\u5e76\u96c6(\u91cd\u590d\u7684\u884c\u53ea\u4fdd\u7559\u4e00\u4efd) <\/li>\n<li> sort file1 file2 | uniq -u&nbsp;\u5220\u9664\u4ea4\u96c6\uff0c\u7559\u4e0b\u5176\u4ed6\u7684\u884c <\/li>\n<li> sort file1 file2 | uniq -d&nbsp;\u53d6\u51fa\u4e24\u4e2a\u6587\u4ef6\u7684\u4ea4\u96c6(\u53ea\u7559\u4e0b\u540c\u65f6\u5b58\u5728\u4e8e\u4e24\u4e2a\u6587\u4ef6\u4e2d\u7684\u6587\u4ef6) <\/li>\n<\/ul>\n<h3><span style=\"font-size: 15px;font-family: Optima-Regular, PingFangTC-light\">15. comm \u547d\u4ee4<\/span><\/h3>\n<ul>\n<li> comm -1 file1 file2&nbsp;\u6bd4\u8f83\u4e24\u4e2a\u6587\u4ef6\u7684\u5185\u5bb9\u53ea\u5220\u9664 &#8216;file1&#8217; \u6240\u5305\u542b\u7684\u5185\u5bb9 <\/li>\n<li> comm -2 file1 file2&nbsp;\u6bd4\u8f83\u4e24\u4e2a\u6587\u4ef6\u7684\u5185\u5bb9\u53ea\u5220\u9664 &#8216;file2&#8217; \u6240\u5305\u542b\u7684\u5185\u5bb9 <\/li>\n<li> comm -3 file1 file2&nbsp;\u6bd4\u8f83\u4e24\u4e2a\u6587\u4ef6\u7684\u5185\u5bb9\u53ea\u5220\u9664\u4e24\u4e2a\u6587\u4ef6\u5171\u6709\u7684\u90e8\u5206 <\/li>\n<\/ul>\n<p><strong><span style=\"font-family: Optima-Regular, PingFangTC-light;font-size: 19px\">\u516d\u3001\u6253\u5305\u548c\u538b\u7f29\u6587\u4ef6<\/span><\/strong> <\/p>\n<h3> <strong><span style=\"font-size: 15px;font-family: Optima-Regular, PingFangTC-light\">16. tar \u547d\u4ee4<\/span><\/strong><span style=\"font-size: 15px;font-family: Optima-Regular, PingFangTC-light\"><\/span> <\/h3>\n<p><span style=\"font-size: 15px;font-family: Optima-Regular, PingFangTC-light\">\u5bf9\u6587\u4ef6\u8fdb\u884c\u6253\u5305\uff0c\u9ed8\u8ba4\u60c5\u51b5\u5e76\u4e0d\u4f1a\u538b\u7f29\uff0c\u5982\u679c\u6307\u5b9a\u4e86\u76f8\u5e94\u7684\u53c2\u6570\uff0c\u5b83\u8fd8\u4f1a\u8c03\u7528\u76f8\u5e94\u7684\u538b\u7f29\u7a0b\u5e8f\uff08\u5982gzip\u548cbzip\u7b49\uff09\u8fdb\u884c\u538b\u7f29\u548c\u89e3\u538b\uff1a<\/span> <\/p>\n<ul>\n<li> -c \uff1a\u65b0\u5efa\u6253\u5305\u6587\u4ef6 <\/li>\n<li> -t \uff1a\u67e5\u770b\u6253\u5305\u6587\u4ef6\u7684\u5185\u5bb9\u542b\u6709\u54ea\u4e9b\u6587\u4ef6\u540d <\/li>\n<li> -x \uff1a\u89e3\u6253\u5305\u6216\u89e3\u538b\u7f29\u7684\u529f\u80fd\uff0c\u53ef\u4ee5\u642d\u914d-C\uff08\u5927\u5199\uff09\u6307\u5b9a\u89e3\u538b\u7684\u76ee\u5f55\uff0c\u6ce8\u610f-c,-t,-x\u4e0d\u80fd\u540c\u65f6\u51fa\u73b0\u5728\u540c\u4e00\u6761\u547d\u4ee4\u4e2d <\/li>\n<li> -j \uff1a\u901a\u8fc7bzip2\u7684\u652f\u6301\u8fdb\u884c\u538b\u7f29\/\u89e3\u538b\u7f29 <\/li>\n<li> -z \uff1a\u901a\u8fc7gzip\u7684\u652f\u6301\u8fdb\u884c\u538b\u7f29\/\u89e3\u538b\u7f29 <\/li>\n<li> -v \uff1a\u5728\u538b\u7f29\/\u89e3\u538b\u7f29\u8fc7\u7a0b\u4e2d\uff0c\u5c06\u6b63\u5728\u5904\u7406\u7684\u6587\u4ef6\u540d\u663e\u793a\u51fa\u6765 <\/li>\n<li> -f filename \uff1afilename\u4e3a\u8981\u5904\u7406\u7684\u6587\u4ef6 <\/li>\n<li> -C dir \uff1a\u6307\u5b9a\u538b\u7f29\/\u89e3\u538b\u7f29\u7684\u76ee\u5f55dir <\/li>\n<li> \u538b\u7f29\uff1atar -jcv -f filename.tar.bz2 \u8981\u88ab\u5904\u7406\u7684\u6587\u4ef6\u6216\u76ee\u5f55\u540d\u79f0 <\/li>\n<li> \u67e5\u8be2\uff1atar -jtv -f filename.tar.bz2 <\/li>\n<li> \u89e3\u538b\uff1atar -jxv -f filename.tar.bz2 -C \u6b32\u89e3\u538b\u7f29\u7684\u76ee\u5f55 <\/li>\n<li> bunzip2 file1.bz2&nbsp;\u89e3\u538b\u4e00\u4e2a\u53eb\u505a &#8216;file1.bz2&#8217;\u7684\u6587\u4ef6 <\/li>\n<li> bzip2 file1&nbsp;\u538b\u7f29\u4e00\u4e2a\u53eb\u505a &#8216;file1&#8217; \u7684\u6587\u4ef6 <\/li>\n<li> gunzip file1.gz&nbsp;\u89e3\u538b\u4e00\u4e2a\u53eb\u505a &#8216;file1.gz&#8217;\u7684\u6587\u4ef6 <\/li>\n<li> gzip file1&nbsp;\u538b\u7f29\u4e00\u4e2a\u53eb\u505a &#8216;file1&#8217;\u7684\u6587\u4ef6 <\/li>\n<li> gzip -9 file1&nbsp;\u6700\u5927\u7a0b\u5ea6\u538b\u7f29 <\/li>\n<li> rar a file1.rar test_file&nbsp;\u521b\u5efa\u4e00\u4e2a\u53eb\u505a &#8216;file1.rar&#8217; \u7684\u5305 <\/li>\n<li> rar a file1.rar file1 file2 dir1&nbsp;\u540c\u65f6\u538b\u7f29 &#8216;file1&#8217;, &#8216;file2&#8217; \u4ee5\u53ca\u76ee\u5f55 &#8216;dir1&#8217; <\/li>\n<li> rar x file1.rar&nbsp;\u89e3\u538brar\u5305 <\/li>\n<li> zip file1.zip file1&nbsp;\u521b\u5efa\u4e00\u4e2azip\u683c\u5f0f\u7684\u538b\u7f29\u5305 <\/li>\n<li> unzip file1.zip&nbsp;\u89e3\u538b\u4e00\u4e2azip\u683c\u5f0f\u538b\u7f29\u5305 <\/li>\n<li> zip -r file1.zip file1 file2 dir1&nbsp;\u5c06\u51e0\u4e2a\u6587\u4ef6\u548c\u76ee\u5f55\u540c\u65f6\u538b\u7f29\u6210\u4e00\u4e2azip\u683c\u5f0f\u7684\u538b\u7f29\u5305 <\/li>\n<\/ul>\n<p style=\"margin: 20px 8px;font-family: -apple-system, BlinkMacSystemFont,\"><strong><span style=\"font-family: Optima-Regular, PingFangTC-light;font-size: 19px\">\u4e03\u3001\u7cfb\u7edf\u548c\u5173\u673a (\u7cfb\u7edf\u7684\u5173\u673a\u3001\u91cd\u542f\u4ee5\u53ca\u767b\u51fa )<\/span><\/strong><\/p>\n<ul>\n<li> shutdown -h now \u5173\u95ed\u7cfb\u7edf(1) <\/li>\n<li> init 0 \u5173\u95ed\u7cfb\u7edf(2) <\/li>\n<li> telinit 0 \u5173\u95ed\u7cfb\u7edf(3) <\/li>\n<li> shutdown -h hours:minutes &amp; \u6309\u9884\u5b9a\u65f6\u95f4\u5173\u95ed\u7cfb\u7edf <\/li>\n<li> shutdown -c \u53d6\u6d88\u6309\u9884\u5b9a\u65f6\u95f4\u5173\u95ed\u7cfb\u7edf <\/li>\n<li> shutdown -r now \u91cd\u542f(1) <\/li>\n<li> reboot \u91cd\u542f(2) <\/li>\n<li> logout \u6ce8\u9500 <\/li>\n<li> time \u6d4b\u7b97\u4e00\u4e2a\u547d\u4ee4\uff08\u5373\u7a0b\u5e8f\uff09\u7684\u6267\u884c\u65f6\u95f4 <\/li>\n<\/ul>\n<p><span style=\"font-size: 19px\"><strong><span style=\"font-family: Optima-Regular, PingFangTC-light\">\u516b\u3001\u8fdb\u7a0b\u76f8\u5173\u7684\u547d\u4ee4<\/span><\/strong><\/span> <\/p>\n<h3> <strong><span style=\"font-size: 15px;font-family: Optima-Regular, PingFangTC-light\">17 jps\u547d\u4ee4<\/span><\/strong><span style=\"font-size: 15px;font-family: Optima-Regular, PingFangTC-light\"><\/span> <\/h3>\n<p><span style=\"font-size: 15px;font-family: Optima-Regular, PingFangTC-light\">\u663e\u793a\u5f53\u524d\u7cfb\u7edf\u7684java\u8fdb\u7a0b\u60c5\u51b5\uff0c\u53ca\u5176id\u53f7\uff1a<\/span> <\/p>\n<ul>\n<li> jps(Java Virtual Machine Process Status Tool)\u662fJDK 1.5\u63d0\u4f9b\u7684\u4e00\u4e2a\u663e\u793a\u5f53\u524d\u6240\u6709java\u8fdb\u7a0bpid\u7684\u547d\u4ee4\uff0c\u7b80\u5355\u5b9e\u7528\uff0c\u975e\u5e38\u9002\u5408\u5728 \/unix\u5e73\u53f0\u4e0a\u7b80\u5355\u5bdf\u770b\u5f53\u524djava\u8fdb\u7a0b\u7684\u4e00\u4e9b\u7b80\u5355\u60c5\u51b5\u3002 <\/li>\n<\/ul>\n<h3> <strong><span style=\"font-size: 15px;font-family: Optima-Regular, PingFangTC-light\">18 ps\u547d\u4ee4<\/span><\/strong><span style=\"font-size: 15px;font-family: Optima-Regular, PingFangTC-light\"><\/span> <\/h3>\n<p><span style=\"font-size: 15px;font-family: Optima-Regular, PingFangTC-light\">\u7528\u4e8e\u5c06\u67d0\u4e2a\u65f6\u95f4\u70b9\u7684\u8fdb\u7a0b\u8fd0\u884c\u60c5\u51b5\u9009\u53d6\u4e0b\u6765\u5e76\u8f93\u51fa\uff0cprocess\u4e4b\u610f\uff1a<\/span> <\/p>\n<ul>\n<li> -A \uff1a\u6240\u6709\u7684\u8fdb\u7a0b\u5747\u663e\u793a\u51fa\u6765 <\/li>\n<li> -a \uff1a\u4e0d\u4e0eterminal\u6709\u5173\u7684\u6240\u6709\u8fdb\u7a0b <\/li>\n<li> -u \uff1a\u6709\u6548\u7528\u6237\u7684\u76f8\u5173\u8fdb\u7a0b <\/li>\n<li> -x \uff1a\u4e00\u822c\u4e0ea\u53c2\u6570\u4e00\u8d77\u4f7f\u7528\uff0c\u53ef\u5217\u51fa\u8f83\u5b8c\u6574\u7684\u4fe1\u606f <\/li>\n<li> -l \uff1a\u8f83\u957f\uff0c\u8f83\u8be6\u7ec6\u5730\u5c06PID\u7684\u4fe1\u606f\u5217\u51fa <\/li>\n<\/ul>\n<pre>ps&nbsp;aux&nbsp;#&nbsp;\u67e5\u770b\u7cfb\u7edf\u6240\u6709\u7684\u8fdb\u7a0b\u6570\u636eps&nbsp;ax&nbsp;#&nbsp;\u67e5\u770b\u4e0d\u4e0eterminal\u6709\u5173\u7684\u6240\u6709\u8fdb\u7a0bps&nbsp;-lA&nbsp;#&nbsp;\u67e5\u770b\u7cfb\u7edf\u6240\u6709\u7684\u8fdb\u7a0b\u6570\u636eps&nbsp;axjf&nbsp;#&nbsp;\u67e5\u770b\u8fde\u540c\u4e00\u90e8\u5206\u8fdb\u7a0b\u6811\u72b6\u6001<\/pre>\n<p> \u767b\u5f55\u540e\u590d\u5236 <\/p>\n<h3> <strong><span style=\"font-size: 15px;font-family: Optima-Regular, PingFangTC-light\">19 kill\u547d\u4ee4<\/span><\/strong><span style=\"font-size: 15px;font-family: Optima-Regular, PingFangTC-light\"><\/span> <\/h3>\n<p><span style=\"font-size: 15px;font-family: Optima-Regular, PingFangTC-light\">\u7528\u4e8e\u5411\u67d0\u4e2a\u5de5\u4f5c\uff08%jobnumber\uff09\u6216\u8005\u662f\u67d0\u4e2aPID\uff08\u6570\u5b57\uff09\u4f20\u9001\u4e00\u4e2a\u4fe1\u53f7\uff0c\u5b83\u901a\u5e38\u4e0eps\u548cjobs\u547d\u4ee4\u4e00\u8d77\u4f7f\u7528\uff1a<\/span> <\/p>\n<h3> <strong><span style=\"font-size: 15px;font-family: Optima-Regular, PingFangTC-light\">20 killall\u547d\u4ee4<\/span><\/strong><span style=\"font-size: 15px;font-family: Optima-Regular, PingFangTC-light\"><\/span> <\/h3>\n<p><span style=\"font-size: 15px;font-family: Optima-Regular, PingFangTC-light\">\uff08\u5411\u4e00\u4e2a\u547d\u4ee4\u542f\u52a8\u7684\u8fdb\u7a0b\u53d1\u9001\u4e00\u4e2a\u4fe1\u53f7\uff09<\/span> <\/p>\n<h3> <strong><span style=\"font-size: 15px;font-family: Optima-Regular, PingFangTC-light\">21 top\u547d\u4ee4<\/span><\/strong><span style=\"font-size: 15px;font-family: Optima-Regular, PingFangTC-light\"><\/span> <\/h3>\n<p><span style=\"font-size: 15px;font-family: Optima-Regular, PingFangTC-light\">\u662fLinux\u4e0b\u5e38\u7528\u7684\u6027\u80fd\u5206\u6790\u5de5\u5177\uff0c\u80fd\u591f\u5b9e\u65f6\u663e\u793a\u7cfb\u7edf\u4e2d\u5404\u4e2a\u8fdb\u7a0b\u7684\u8d44\u6e90\u5360\u7528\u72b6\u51b5\uff0c\u7c7b\u4f3c\u4e8eWindows\u7684\u4efb\u52a1\u7ba1\u7406\u5668\u3002<\/span><br \/>\n<span style=\"font-size: 15px;font-family: Optima-Regular, PingFangTC-light\">\u5982\u4f55\u6740\u6b7b\u8fdb\u7a0b\uff1a<\/span> <\/p>\n<ul>\n<li> \u56fe\u5f62\u5316\u754c\u9762\u7684\u65b9\u5f0f <\/li>\n<li> kill -9 pid &nbsp;\uff08-9\u8868\u793a\u5f3a\u5236\u5173\u95ed\uff09 <\/li>\n<li> killall -9 \u7a0b\u5e8f\u7684\u540d\u5b57 <\/li>\n<li> pkill \u7a0b\u5e8f\u7684\u540d\u5b57 <\/li>\n<\/ul>\n<p><span style=\"font-size: 15px;font-family: Optima-Regular, PingFangTC-light\">\u67e5\u770b\u8fdb\u7a0b\u7aef\u53e3\u53f7\uff1a<\/span> <\/p>\n<pre>netstat&nbsp;-tunlp|grep&nbsp;\u7aef\u53e3\u53f7<\/pre>\n<p> \u767b\u5f55\u540e\u590d\u5236 <\/p>\n<p>\u4ee5\u4e0a\u5c31\u662f\u9762\u8bd5\u5b98\u5e38\u8003\u7684 21 \u6761 Linux \u547d\u4ee4\u7684\u8be6\u7ec6\u5185\u5bb9\uff0c\u66f4\u591a\u8bf7\u5173\u6ce8\u7c73\u4e91\u5176\u5b83\u76f8\u5173\u6587\u7ae0\uff01<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u6b63\u6587 find&nbsp;\/var\/mail\/&nbsp;-size&nbsp;+50M&nbsp;-exec&nbsp;rm&nbsp;{}&nbsp;\uff3c; \u767b\u5f55\u540e\u590d\u5236 \u56db\u3001\u6587\u4ef6\u7684\u6743\u9650&nbsp; \u4f7f\u7528 &#8220;+&#8221; \u8bbe\u7f6e\u6743\u9650\uff0c\u4f7f\u7528 &#8220;-&#8221; \u7528\u4e8e\u53d6\u6d88 9. chmod \u547d\u4ee4 ls -lh \u663e\u793a\u6743\u9650 chmod ugo+rwx directory1 \u8bbe\u7f6e\u76ee\u5f55\u7684\u6240\u6709\u4eba(u)\u3001\u7fa4\u7ec4(g)\u4ee5\u53ca\u5176\u4ed6\u4eba(o)\u4ee5\u8bfb\uff08r\uff0c4 \uff09\u3001\u5199(w\uff0c2)\u548c\u6267\u884c(x\uff0c1)\u7684\u6743\u9650 chmod go-rwx directory1 &nbsp;\u5220\u9664\u7fa4\u7ec4(g)\u4e0e\u5176\u4ed6\u4eba(o)\u5bf9\u76ee\u5f55\u7684\u8bfb\u5199\u6267\u884c\u6743\u9650 10. chown \u547d\u4ee4 \u6539\u53d8\u6587\u4ef6\u7684\u6240\u6709\u8005\uff1a chown user1 file1 \u6539\u53d8\u4e00\u4e2a\u6587\u4ef6\u7684\u6240\u6709\u4eba\u5c5e\u6027 chown -R user1 directory1 \u6539\u53d8\u4e00\u4e2a\u76ee\u5f55\u7684\u6240\u6709\u4eba\u5c5e\u6027\u5e76\u540c\u65f6\u6539\u53d8\u6539\u76ee\u5f55\u4e0b\u6240\u6709\u6587\u4ef6\u7684\u5c5e\u6027 chown user1:group1 file1 \u6539\u53d8\u4e00\u4e2a\u6587\u4ef6\u7684\u6240\u6709\u4eba\u548c\u7fa4\u7ec4\u5c5e\u6027 11. chgrp \u547d\u4ee4 \u6539\u53d8\u6587\u4ef6\u6240\u5c5e\u7528\u6237\u7ec4\uff1a chgrp group1 file1 \u6539\u53d8\u6587\u4ef6\u7684\u7fa4\u7ec4 \u4e94\u3001\u6587\u672c\u5904\u7406 12. grep \u547d\u4ee4 \u5206\u6790\u4e00\u884c\u7684\u4fe1\u606f\uff0c\u82e5\u5f53\u4e2d\u6709\u6211\u4eec\u6240\u9700\u8981\u7684\u4fe1\u606f\uff0c\u5c31\u5c06\u8be5\u884c\u663e\u793a\u51fa\u6765\uff0c\u8be5\u547d\u4ee4\u901a\u5e38\u4e0e\u7ba1\u9053\u547d\u4ee4\u4e00\u8d77\u4f7f\u7528\uff0c\u7528\u4e8e\u5bf9\u4e00\u4e9b\u547d\u4ee4\u7684\u8f93\u51fa\u8fdb\u884c\u7b5b\u9009\u52a0\u5de5\u7b49\u7b49\uff1a grep [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[8],"tags":[],"class_list":["post-16635","post","type-post","status-publish","format-standard","hentry","category-os"],"_links":{"self":[{"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/posts\/16635","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/comments?post=16635"}],"version-history":[{"count":0,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/posts\/16635\/revisions"}],"wp:attachment":[{"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/media?parent=16635"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/categories?post=16635"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/tags?post=16635"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}