{"id":28857,"date":"2023-09-19T00:08:09","date_gmt":"2023-09-18T16:08:09","guid":{"rendered":"https:\/\/www.techphant.cn\/?p=28857"},"modified":"2023-09-19T00:08:09","modified_gmt":"2023-09-18T16:08:09","slug":"rhzkdkzyqk","status":"publish","type":"post","link":"https:\/\/www.techphant.cn\/blog\/28857.html","title":{"rendered":"\u5982\u4f55\u67e5\u770b\u7aef\u53e3\u5360\u7528\u60c5\u51b5"},"content":{"rendered":"
\u7aef\u53e3\u5360\u7528\u662f\u6307\u7f51\u7edc\u4e0a\u7684\u4e00\u53f0\u4e3b\u673a\u6b63\u5728\u4f7f\u7528\u7684\u7aef\u53e3\uff0c\u6bcf\u4e2a\u7aef\u53e3\u90fd\u6709\u4e00\u4e2a\u552f\u4e00\u7684\u53f7\u7801\uff0c\u7528\u4e8e\u6807\u8bc6\u4e00\u4e2a\u7279\u5b9a\u7684\u670d\u52a1\u6216\u5e94\u7528\u7a0b\u5e8f\u3002\u67e5\u770b\u7aef\u53e3\u5360\u7528\u60c5\u51b5\u53ef\u4ee5\u5e2e\u52a9\u6211\u4eec\u8bc6\u522b\u7f51\u7edc\u4e2d\u53ef\u80fd\u5b58\u5728\u7684\u5b89\u5168\u6f0f\u6d1e\uff0c\u5e76\u4e3a\u6211\u4eec\u63d0\u4f9b\u6709\u6548\u7684\u7f51\u7edc\u5b89\u5168\u4fdd\u62a4\u3002\u672c\u6587\u5c06\u4ecb\u7ecd\u5982\u4f55\u67e5\u770b\u7aef\u53e3\u5360\u7528\u60c5\u51b5\uff0c\u4ee5\u53ca\u5982\u4f55\u4f7f\u7528\u67e5\u770b\u7aef\u53e3\u5360\u7528\u60c5\u51b5\u7684\u5de5\u5177\u6765\u63d0\u5347\u7f51\u7edc\u5b89\u5168\u6027\u3002<\/p>\n
\u7aef\u53e3\u662f\u4e00\u79cd\u7279\u6b8a\u7684\u7f51\u7edc\u63a5\u53e3\uff0c\u7528\u6765\u6807\u8bc6\u7f51\u7edc\u4e0a\u4e0d\u540c\u7684\u670d\u52a1\u548c\u5e94\u7528\u7a0b\u5e8f\u3002\u6bcf\u4e2a\u7aef\u53e3\u90fd\u6709\u4e00\u4e2a\u552f\u4e00\u7684\u53f7\u7801\uff0c\u7528\u4e8e\u6807\u8bc6\u4e00\u4e2a\u7279\u5b9a\u7684\u670d\u52a1\u6216\u5e94\u7528\u7a0b\u5e8f\uff0c\u4ece\u800c\u4f7f\u7f51\u7edc\u4e0a\u7684\u4e0d\u540c\u8bbe\u5907\u53ef\u4ee5\u6b63\u786e\u5730\u8bc6\u522b\u5b83\u4eec\u3002\u7aef\u53e3\u53f7\u4ece0\u523065535\uff0c\u5176\u4e2d0~1023\u662f\u7cfb\u7edf\u4fdd\u7559\u7aef\u53e3\uff0c1024~49151\u662f\u7528\u6237\u7aef\u53e3\uff0c49152~65535\u662f\u4e34\u65f6\u7aef\u53e3\u3002<\/p>\n
\u5728Windows\u7cfb\u7edf\u4e2d\uff0c\u53ef\u4ee5\u4f7f\u7528netstat\u547d\u4ee4\u6765\u67e5\u770b\u7aef\u53e3\u5360\u7528\u60c5\u51b5\u3002netstat\u547d\u4ee4\u53ef\u4ee5\u663e\u793a\u6240\u6709\u5f53\u524d\u6253\u5f00\u7684\u7aef\u53e3\uff0c\u4ee5\u53ca\u5b83\u4eec\u7684\u72b6\u6001\u548c\u5360\u7528\u60c5\u51b5\u3002\u4f7f\u7528netstat\u547d\u4ee4\u65f6\uff0c\u53ef\u4ee5\u6dfb\u52a0\u4e00\u4e9b\u53c2\u6570\u6765\u67e5\u770b\u66f4\u8be6\u7ec6\u7684\u4fe1\u606f\uff0c\u4f8b\u5982\u53ef\u4ee5\u4f7f\u7528-a\u53c2\u6570\u6765\u67e5\u770b\u6240\u6709\u7aef\u53e3\u7684\u5360\u7528\u60c5\u51b5\uff0c\u4f7f\u7528-b\u53c2\u6570\u6765\u67e5\u770b\u6bcf\u4e2a\u7aef\u53e3\u5360\u7528\u7684\u8fdb\u7a0b\u7b49\u3002<\/p>\n
\u5728Linux\u7cfb\u7edf\u4e2d\uff0c\u53ef\u4ee5\u4f7f\u7528lsof\u547d\u4ee4\u6765\u67e5\u770b\u7aef\u53e3\u5360\u7528\u60c5\u51b5\u3002lsof\u547d\u4ee4\u53ef\u4ee5\u663e\u793a\u5f53\u524d\u6253\u5f00\u7684\u6240\u6709\u6587\u4ef6\uff0c\u5305\u62ec\u7aef\u53e3\uff0c\u4ee5\u53ca\u5b83\u4eec\u7684\u72b6\u6001\u548c\u5360\u7528\u60c5\u51b5\u3002\u4f7f\u7528lsof\u547d\u4ee4\u65f6\uff0c\u53ef\u4ee5\u6dfb\u52a0\u4e00\u4e9b\u53c2\u6570\u6765\u67e5\u770b\u66f4\u8be6\u7ec6\u7684\u4fe1\u606f\uff0c\u4f8b\u5982\u53ef\u4ee5\u4f7f\u7528-i\u53c2\u6570\u6765\u67e5\u770b\u6240\u6709\u7aef\u53e3\u7684\u5360\u7528\u60c5\u51b5\uff0c\u4f7f\u7528-p\u53c2\u6570\u6765\u67e5\u770b\u6bcf\u4e2a\u7aef\u53e3\u5360\u7528\u7684\u8fdb\u7a0b\u7b49\u3002<\/p>\n
\u5728Mac\u7cfb\u7edf\u4e2d\uff0c\u53ef\u4ee5\u4f7f\u7528lsof\u547d\u4ee4\u6765\u67e5\u770b\u7aef\u53e3\u5360\u7528\u60c5\u51b5\u3002lsof\u547d\u4ee4\u53ef\u4ee5\u663e\u793a\u5f53\u524d\u6253\u5f00\u7684\u6240\u6709\u6587\u4ef6\uff0c\u5305\u62ec\u7aef\u53e3\uff0c\u4ee5\u53ca\u5b83\u4eec\u7684\u72b6\u6001\u548c\u5360\u7528\u60c5\u51b5\u3002\u4f7f\u7528lsof\u547d\u4ee4\u65f6\uff0c\u53ef\u4ee5\u6dfb\u52a0\u4e00\u4e9b\u53c2\u6570\u6765\u67e5\u770b\u66f4\u8be6\u7ec6\u7684\u4fe1\u606f\uff0c\u4f8b\u5982\u53ef\u4ee5\u4f7f\u7528-i\u53c2\u6570\u6765\u67e5\u770b\u6240\u6709\u7aef\u53e3\u7684\u5360\u7528\u60c5\u51b5\uff0c\u4f7f\u7528-p\u53c2\u6570\u6765\u67e5\u770b\u6bcf\u4e2a\u7aef\u53e3\u5360\u7528\u7684\u8fdb\u7a0b\u7b49\u3002<\/p>\n
\u67e5\u770b\u7aef\u53e3\u5360\u7528\u60c5\u51b5\u662f\u7f51\u7edc\u5b89\u5168\u7ba1\u7406\u7684\u91cd\u8981\u7ec4\u6210\u90e8\u5206\uff0c\u53ef\u4ee5\u5e2e\u52a9\u6211\u4eec\u8bc6\u522b\u7f51\u7edc\u4e2d\u53ef\u80fd\u5b58\u5728\u7684\u5b89\u5168\u6f0f\u6d1e\uff0c\u5e76\u4e3a\u6211\u4eec\u63d0\u4f9b\u6709\u6548\u7684\u7f51\u7edc\u5b89\u5168\u4fdd\u62a4\u3002<\/strong>\u4e0d\u540c\u7684\u64cd\u4f5c\u7cfb\u7edf\u6709\u4e0d\u540c\u7684\u7aef\u53e3\u67e5\u770b\u5de5\u5177\uff0c\u4f8b\u5982Windows\u7cfb\u7edf\u53ef\u4ee5\u4f7f\u7528netstat\u547d\u4ee4\uff0cLinux\u7cfb\u7edf\u548cMac\u7cfb\u7edf\u53ef\u4ee5\u4f7f\u7528lsof\u547d\u4ee4\u6765\u67e5\u770b\u7aef\u53e3\u5360\u7528\u60c5\u51b5\u3002\u6b64\u5916\uff0c\u4e5f\u53ef\u4ee5\u4f7f\u7528\u4e00\u4e9b\u4e13\u4e1a\u7684\u7aef\u53e3\u67e5\u770b\u5de5\u5177\u6765\u67e5\u770b\u7aef\u53e3\u5360\u7528\u60c5\u51b5\uff0c\u4ee5\u4fbf\u66f4\u597d\u5730\u4fdd\u62a4\u7f51\u7edc\u5b89\u5168\u3002<\/p>\n","protected":false},"excerpt":{"rendered":" \u7aef\u53e3\u5360\u7528\u662f\u6307\u7f51\u7edc\u4e0a\u7684\u4e00\u53f0\u4e3b\u673a\u6b63\u5728\u4f7f\u7528\u7684\u7aef\u53e3\uff0c\u6bcf\u4e2a\u7aef\u53e3\u90fd\u6709\u4e00\u4e2a\u552f\u4e00\u7684\u53f7\u7801\uff0c\u7528\u4e8e\u6807\u8bc6\u4e00\u4e2a\u7279\u5b9a\u7684\u670d\u52a1\u6216\u5e94\u7528\u7a0b\u5e8f\u3002\u67e5\u770b\u7aef\u53e3\u5360\u7528\u60c5\u51b5\u53ef\u4ee5\u5e2e\u52a9\u6211\u4eec\u8bc6\u522b\u7f51\u7edc\u4e2d\u53ef\u80fd\u5b58\u5728\u7684\u5b89\u5168\u6f0f\u6d1e\uff0c\u5e76\u4e3a\u6211<\/p>\n","protected":false},"author":1,"featured_media":3671,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"site-sidebar-layout":"default","site-content-layout":"default","ast-global-header-display":"","ast-main-header-display":"","ast-hfb-above-header-display":"","ast-hfb-below-header-display":"","ast-hfb-mobile-header-display":"","site-post-title":"","ast-breadcrumbs-content":"","ast-featured-img":"","footer-sml-layout":"","theme-transparent-header-meta":"","adv-header-id-meta":"","stick-header-meta":"","header-above-stick-meta":"","header-main-stick-meta":"","header-below-stick-meta":"","footnotes":""},"categories":[36],"tags":[52],"class_list":["post-28857","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-blog","tag-wxtx"],"_links":{"self":[{"href":"https:\/\/www.techphant.cn\/wp-json\/wp\/v2\/posts\/28857","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.techphant.cn\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.techphant.cn\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.techphant.cn\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.techphant.cn\/wp-json\/wp\/v2\/comments?post=28857"}],"version-history":[{"count":0,"href":"https:\/\/www.techphant.cn\/wp-json\/wp\/v2\/posts\/28857\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.techphant.cn\/wp-json\/wp\/v2\/media\/3671"}],"wp:attachment":[{"href":"https:\/\/www.techphant.cn\/wp-json\/wp\/v2\/media?parent=28857"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.techphant.cn\/wp-json\/wp\/v2\/categories?post=28857"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.techphant.cn\/wp-json\/wp\/v2\/tags?post=28857"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}