linux \u67e5\u627e\u6587\u4ef6\u547d\u4ee4<\/strong>\uff0c\u53ef\u4ee5\u4f9d\u7167\u6587\u4ef6\u540d\u3001\u6587\u4ef6\u7c7b\u578b\u3001\u6587\u4ef6\u5927\u5c0f\u7b49\u6761\u4ef6\u8fdb\u884c\u67e5\u627e\u30022.locate\uff1a\u5728\u7cfb\u7edf\u6570\u636e\u5e93\u4e2d\u67e5\u627e\u6587\u4ef6\uff0c\u901f\u7387\u6bd4find\u5feb\uff0c\u800c\u4e14\u53ef\u80fd\u4e0d\u591f\u786e\u5207\u30023.grep\uff1a\u5728\u6587\u4ef6\u4e2d\u67e5\u627e\u6307\u5b9a\u7684\u5b57\u7b26\u4e32\u6216\u5219\u6b63\u5219\u8868\u8fbe\u5f0f\u30024.whereis\uff1a\u67e5\u627e\u53ef\u6267\u884c\u6587\u4ef6\u3001\u6e90\u4ee3\u7801\u6587\u4ef6\u548c\u5e2e\u52a9\u6587\u6863\u7b49\u30025.which\uff1a\u67e5\u627e\u53ef\u6267\u884c\u6587\u4ef6\u7684\u8def\u5f84\u30026.type\uff1a\u67e5\u627e\u547d\u4ee4\u7684\u7c7b\u578b\uff0c\u662f\u5916\u7f6e\u547d\u4ee4\u8fd8\u662f\u5916\u90e8\u547d\u4ee4\u30027.ls\uff1a\u5217\u4e3e\u6307\u5b9a\u76ee\u5f55\u4e0b\u7684\u6587\u4ef6\u548c\u76ee\u5f55\uff0c\u53ef\u4ee5\u4f9d\u7167\u6587\u4ef6\u540d\u3001\u6587\u4ef6\u7c7b\u578b\u3001\u6587\u4ef6\u5927\u5c0f\u7b49\u6761\u4ef6\u8fdb\u884c\u8fc7\u6ee4\u3002<\/p>\nlinux\u4e2d\u5982\u4f55\u67e5\u627e\u6587\u4ef6<\/p>\n
\u5728Linux\u4e2d\uff0c\u53ef\u4ee5\u4f7f\u7528\u4ee5\u4e0b\u547d\u4ee4\u6765\u67e5\u627e\u6587\u4ef6\uff1a1.find\u547d\u4ee4\uff1a\u53ef\u4ee5\u6309\u7167\u6587\u4ef6\u540d\u3001\u6587\u4ef6\u7c7b\u578b\u3001\u6587\u4ef6\u5927\u5c0f\u7b49\u6761\u4ef6\u6765\u67e5\u627e\u6587\u4ef6\u3002\u8bf8\u5982\uff0c\u67e5\u627e\u5f53\u524d\u76ee\u5f55\u4e0b\u6240\u6709\u4ee5.txt\u7ed3\u5c3e\u7684\u6587\u4ef6\uff0c\u53ef\u4ee5\u4f7f\u7528\u4ee5\u4e0b\u547d\u4ee4\uff1afind.-name\"*.txt\"2.locate\u547d\u4ee4\uff1a\u53ef\u4ee5\u5feb\u901f\u67e5\u627e\u7cfb\u7edf\u4e2d\u65e9\u5df2\u6784\u5efa\u7d22\u5f15\u7684\u6587\u4ef6\u3002\u8bf8\u5982\uff0c\u67e5\u627e\u6240\u6709\u4ee5.txt\u7ed3\u5c3e\u7684\u6587\u4ef6\uff0c\u53ef\u4ee5\u4f7f\u7528\u4ee5\u4e0b\u547d\u4ee4\uff1alocate\"*.txt\"3.grep\u547d\u4ee4\uff1a\u53ef\u4ee5\u5728\u6587\u4ef6\u4e2d\u67e5\u627e\u6307\u5b9a\u7684\u5b57\u7b26\u4e32\u3002\u8bf8\u5982\uff0c\u67e5\u627e\u6240\u6709\u5305\u542b\u201chello\u201d\u7684\u6587\u4ef6\uff0c\u53ef\u4ee5\u4f7f\u7528\u4ee5\u4e0b\u547d\u4ee4\uff1agrep-r\"hello\".\u4ee5\u4e0a\u662fLinux\u4e2d\u5e38\u7528\u7684\u67e5\u627e\u6587\u4ef6\u7684\u547d\u4ee4\uff0c\u53ef\u4ee5\u4f9d\u7167\u5177\u4f53\u9700\u6c42\u9009\u62e9\u4f7f\u7528\u3002<\/p>\n
linux\u67e5\u627e\u5927\u6587\u4ef6\u547d\u4ee4<\/p>\n
\u5728Linux\u4e2d\u67e5\u627e\u5927\u6587\u4ef6\u7684\u547d\u4ee4\u662f\u201cfind\u201d\uff0c\u53ef\u4ee5\u4f7f\u7528\u4ee5\u4e0b\u547d\u4ee4\uff1a1.\u67e5\u627e\u5c0f\u4e8e100MB\u7684\u6587\u4ef6\uff1afind\/-typef-size+100M2.\u67e5\u627e\u5c0f\u4e8e1GB\u7684\u6587\u4ef6\uff1afind\/-typef-size+1G3.\u67e5\u627e\u6307\u5b9a\u76ee\u5f55\u4e0b\u5c0f\u4e8e500MB\u7684\u6587\u4ef6\uff1afind\/path\/to\/directory-typef-size+500M4.\u67e5\u627e\u5c0f\u4e8e100MB\u800c\u4e14\u5728\u8fd1\u67657\u5929\u5185\u66f4\u6539\u8fc7\u7684\u6587\u4ef6\uff1afind\/-typef-size+100M-mtime-75.\u67e5\u627e\u5c0f\u4e8e1GB\u800c\u4e14\u5728\u8fd1\u676530\u5929\u5185\u66f4\u6539\u8fc7\u7684\u6587\u4ef6\uff1afind\/-typef-size+1G-mtime-30\u6ce8\u610f\uff1a\u4ee5\u4e0a\u547d\u4ee4\u987b\u8981\u4f7f\u7528root\u6743\u9650\u624d\u4f1a\u6267\u884c\u3002<\/p>\n
<\/p>\n
linux\u4e2d\u600e\u6837\u67e5\u627e\u6587\u4ef6<\/p>\n
\u5728Linux\u4e2d\uff0c\u53ef\u4ee5\u4f7f\u7528\u4ee5\u4e0b\u547d\u4ee4\u6765\u67e5\u627e\u6587\u4ef6\uff1a1.find\u547d\u4ee4\uff1a\u53ef\u4ee5\u5728\u6307\u5b9a\u76ee\u5f55\u4e0b\u67e5\u627e\u6587\u4ef6\u7ea2\u65d7linux\u4e0b\u8f7d\uff0c\u652f\u6301\u6839\u636e\u6587\u4ef6\u540d\u3001\u6587\u4ef6\u7c7b\u578b\u3001\u6587\u4ef6\u5927\u5c0f\u3001\u4fee\u6539\u65f6\u95f4\u7b49\u6761\u4ef6\u8fdb\u884c\u67e5\u627e\u30022.locate\u547d\u4ee4\uff1a\u53ef\u4ee5\u5728\u7cfb\u7edf\u4e2d\u5feb\u901f\u67e5\u627e\u6587\u4ef6\uff0c\u800c\u4e14\u987b\u8981\u5148\u66f4\u65b0\u6587\u4ef6\u7d22\u5f15\u5e93\u30023.grep\u547d\u4ee4\uff1a\u53ef\u4ee5\u5728\u6587\u4ef6\u4e2d\u67e5\u627e\u6307\u5b9a\u7684\u5b57\u7b26\u4e32\u6216\u5219\u6b63\u5219\u8868\u8fbe\u5f0f\u30024.whereis\u547d\u4ee4\uff1a\u53ef\u4ee5\u67e5\u627e\u7cfb\u7edf\u4e2d\u5b89\u88c5\u7684\u6307\u5b9a\u547d\u4ee4\u7684\u4f4d\u7f6e\u30025.which\u547d\u4ee4\uff1a\u53ef\u4ee5\u67e5\u627e\u7cfb\u7edf\u624b\u6307\u5b9a\u547d\u4ee4\u7684\u4f4d\u7f6e\u3002\u4ee5\u4e0a\u662fLinux\u4e2d\u5e38\u7528\u7684\u6587\u4ef6\u67e5\u627e\u547d\u4ee4\uff0c\u53ef\u4ee5\u4f9d\u636e\u5177\u4f53\u7684\u9700\u6c42\u9009\u62e9\u5408\u9002\u7684\u547d\u4ee4\u6765\u8fdb\u884c\u67e5\u627e\u3002<\/p>\n
Linux\u7cfb\u7edf\u4e2d\u67e5\u627e\u6587\u4ef6<\/p>\n
\u5728Linux\u7cfb\u7edf\u4e2d\uff0c\u6709\u51e0\u79cd\u5e38\u7528\u7684\u65b9\u5f0f\u6765\u67e5\u627e\u6587\u4ef6\uff1a1.`find`\u547d\u4ee4\uff1a\u8be5\u547d\u4ee4\u53ef\u4ee5\u5728\u6307\u5b9a\u76ee\u5f55\u53ca\u5176\u5b50\u76ee\u5f55\u4e2d\u67e5\u627e\u6587\u4ef6\u3002\u8bf8\u5982\uff1a`find\/path\/to\/dir-namefilename`\u5c06\u5728`\/path\/to\/dir`\u76ee\u5f55\u4e2d\u67e5\u627e\u540d\u4e3a`filename`\u7684\u6587\u4ef6\u30022.`locate`\u547d\u4ee4\uff1a\u8be5\u547d\u4ee4\u4f7f\u7528\u6587\u4ef6\u540d\u6570\u636e\u5e93\uff0c\u53ef\u4ee5\u5feb\u901f\u67e5\u627e\u6587\u4ef6\u3002\u8bf8\u5982\uff1a`locatefilename`\u5c06\u67e5\u627e\u6240\u6709\u540d\u4e3a`filename`\u7684\u6587\u4ef6\u30023.`which`\u547d\u4ee4\uff1a\u8be5\u547d\u4ee4\u53ef\u4ee5\u67e5\u627e\u7cfb\u7edf\u4e2d\u7279\u5b9a\u547d\u4ee4\u7684\u5b8c\u6574\u8def\u5f84\u3002\u8bf8\u5982\uff1a`whichfilename`\u5c06\u67e5\u627e\u540d\u4e3a`filename`\u7684\u547d\u4ee4\u7684\u5b8c\u6574\u8def\u5f84\u30024.`whereis`\u547d\u4ee4\uff1a\u8be5\u547d\u4ee4\u53ef\u4ee5\u67e5\u627e\u7cfb\u7edf\u4e2d\u547d\u4ee4\u7684\u4f4d\u7f6e\uff0c\u4ee5\u53ca\u5173\u4e8e\u547d\u4ee4\u7684\u76f8\u5173\u6587\u4ef6\u3002\u8bf8\u5982\uff1a`whereisfilename`\u5c06\u67e5\u627e\u540d\u4e3a`filename`\u7684\u547d\u4ee4\u7684\u4f4d\u7f6e\u3002<\/p>\n
linux\u67e5\u627e\u6307\u5b9a\u6587\u4ef6\u547d\u4ee4<\/p>\n
\u5728Linux\u4e2d\uff0c\u67e5\u627e\u6307\u5b9a\u6587\u4ef6\u7684\u547d\u4ee4\u662f\u201cfind\u201d\u3002\u53ef\u4ee5\u4f7f\u7528\u201cfind\u201d\u547d\u4ee4\u6765\u67e5\u627e\u6307\u5b9a\u76ee\u5f55\u4e0b\u7684\u6587\u4ef6\uff0c\u4e5f\u53ef\u4ee5\u4f7f\u7528\u4e0d\u540c\u7684\u9009\u9879\u6765\u8fc7\u6ee4\u7ed3\u679c\u3002\u6bd4\u5982\uff0c\u53ef\u4ee5\u4f7f\u7528\u201c-name\u201d\u9009\u9879\u6765\u6307\u5b9a\u6587\u4ef6\u540d\uff0c\u4f7f\u7528\u201c-type\u201d\u9009\u9879\u6765\u6307\u5b9a\u6587\u4ef6\u7c7b\u578b\uff0c\u4f7f\u7528\u201c-mtime\u201d\u9009\u9879\u6765\u6307\u5b9a\u6587\u4ef6\u66f4\u6539\u65f6\u95f4\u7b49\u3002\u4f7f\u7528\u201cfind\u201d\u547d\u4ee4\u53ef\u4ee5\u5feb\u901f\u786e\u5207\u5730\u627e\u5230\u987b\u8981\u7684\u6587\u4ef6\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"
linux\u547d\u4ee4\u67e5\u627e\u6587\u4ef6linux\u4e0b\u7684find\u6587\u4ef6\u67e5\u627e\u547d\u4ee4\u4e0egrep\u6587\u4ef6\u5185\u5bb9\u67e5\u627e\u547d\u4ee4linux\u4e2d\u7684find\u547d\u4ee4linux\u6a21\u7cca\u67e5\u627e\u6587\u4ef6\u547d\u4ee4linux\u67e5\u627e\u6587\u4ef6\u8def\u5f84\u547d\u4ee4linux\u67e5\u627e\u6587\u4ef6\u5185\u5bb9\u547d\u4ee4linux\u67e5\u627e\u6587\u4ef6\u7684\u547d\u4ee4linux\u4e2d\u600e\u4e48\u67e5\u627e\u6587\u4ef6linux\u67e5\u627e\u5927\u6587\u4ef6\u547d\u4ee4linux\u4e2d\u5982\u4f55\u67e5\u627e\u6587\u4ef6linux\u67e5\u627e\u6307\u5b9a\u6587\u4ef6\u547d\u4ee4\u5728Linux\u4e2d\uff0c\u67e5\u627e\u6307\u5b9a\u6587\u4ef6\u7684\u547d\u4ee4\u662f\u201cfind\u201d\u3002<\/p>\n","protected":false},"author":1,"featured_media":270749,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[988],"tags":[999],"class_list":["post-270748","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-tougao","tag-999"],"acf":[],"_links":{"self":[{"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/posts\/270748","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/comments?post=270748"}],"version-history":[{"count":0,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/posts\/270748\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/media\/270749"}],"wp:attachment":[{"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/media?parent=270748"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/categories?post=270748"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/tags?post=270748"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}