{"id":280,"date":"2025-11-29T09:08:16","date_gmt":"2025-11-29T01:08:16","guid":{"rendered":"https:\/\/www.52runoob.com\/?p=280"},"modified":"2025-11-29T09:08:16","modified_gmt":"2025-11-29T01:08:16","slug":"%e5%a6%82%e4%bd%95ping%e6%8c%87%e5%ae%9aip%e7%9a%84%e7%ab%af%e5%8f%a3%e5%8f%b7_ping-%e7%ab%af%e5%8f%a3","status":"publish","type":"post","link":"https:\/\/www.52runoob.com\/index.php\/2025\/11\/29\/%e5%a6%82%e4%bd%95ping%e6%8c%87%e5%ae%9aip%e7%9a%84%e7%ab%af%e5%8f%a3%e5%8f%b7_ping-%e7%ab%af%e5%8f%a3\/","title":{"rendered":"\u5982\u4f55ping\u6307\u5b9aIP\u7684\u7aef\u53e3\u53f7_ping \u7aef\u53e3"},"content":{"rendered":"\n<p>\u4e0b\u9762\u662f <strong>\u5982\u4f55 Ping \u6307\u5b9a IP \u7684\u7aef\u53e3\u53f7<\/strong> \u7684\u5b8c\u6574\u603b\u7ed3 \u2014\u2014 \u5305\u542b <strong>Windows \/ Linux \/ Mac<\/strong> \u6240\u6709\u5e38\u7528\u65b9\u6cd5\uff0c\u5e76\u89e3\u91ca\u4e3a\u4ec0\u4e48 \u201cping \u7aef\u53e3\u201d \u672c\u8eab\u5728\u6280\u672f\u4e0a\u662f\u4e0d\u5b58\u5728\u7684\u3002<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h1 class=\"wp-block-heading\">\u2705 <strong>\u9996\u5148\uff1aPing \u65e0\u6cd5\u68c0\u6d4b\u7aef\u53e3\uff08\u539f\u56e0\uff09<\/strong><\/h1>\n\n\n\n<p><code>ping<\/code> \u4f7f\u7528 <strong>ICMP \u534f\u8bae<\/strong>\uff0c\u800c\u7aef\u53e3\uff08Port\uff09\u5c5e\u4e8e <strong>TCP\/UDP \u534f\u8bae<\/strong>\u3002<\/p>\n\n\n\n<p>\u6240\u4ee5\uff1a<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>ping \u53ea\u80fd\u6d4b\u5bf9\u65b9\u4e3b\u673a\u662f\u5426\u53ef\u8fbe<\/strong><\/li>\n\n\n\n<li><strong>\u65e0\u6cd5\u6d4b\u8bd5\u7aef\u53e3\u662f\u5426\u5f00\u653e<\/strong><\/li>\n<\/ul>\n\n\n\n<p>\u8981\u6d4b\u8bd5\u67d0\u4e2a\u7aef\u53e3\u662f\u5426\u80fd\u8fde\u901a\uff0c\u9700\u8981\u4f7f\u7528\u5176\u4ed6\u5de5\u5177\u3002<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h1 class=\"wp-block-heading\">#\ufe0f\u20e3 \u65b9\u6cd5 1\uff1a\u4f7f\u7528 <code>telnet<\/code>\uff08\u6700\u7b80\u5355\uff09<\/h1>\n\n\n\n<h3 class=\"wp-block-heading\">\u2714 \u6d4b\u8bd5\u67d0\u4e2a\u7aef\u53e3\u662f\u5426\u5f00\u653e\uff1a<\/h3>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\ntelnet 192.168.1.10 3306\n\n<\/pre><\/div>\n\n\n<p>\u7ed3\u679c\uff1a<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Connected<\/strong> \u2192 \u7aef\u53e3\u5f00\u653e<\/li>\n\n\n\n<li><strong>Unable to connect \/ Connection refused<\/strong> \u2192 \u7aef\u53e3\u5173\u95ed<\/li>\n<\/ul>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h1 class=\"wp-block-heading\">#\ufe0f\u20e3 \u65b9\u6cd5 2\uff1a\u4f7f\u7528 <code>nc<\/code>\uff08nc = netcat\uff0c\u5f3a\u70c8\u63a8\u8350\uff09<\/h1>\n\n\n\n<p>Linux \/ Mac \u9ed8\u8ba4\u81ea\u5e26\u3002<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">\u2714 \u68c0\u67e5\u7aef\u53e3\uff1a<\/h3>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\nnc -zv 192.168.1.10 80\n\n<\/pre><\/div>\n\n\n<ul class=\"wp-block-list\">\n<li><code>-z<\/code> \u626b\u63cf\u6a21\u5f0f<\/li>\n\n\n\n<li><code>-v<\/code> \u8f93\u51fa\u8be6\u60c5<\/li>\n<\/ul>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h3 class=\"wp-block-heading\">\u2714 \u626b\u63cf\u591a\u4e2a\u7aef\u53e3<\/h3>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\nnc -zv 192.168.1.10 1-1024\n\n<\/pre><\/div>\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h1 class=\"wp-block-heading\">#\ufe0f\u20e3 \u65b9\u6cd5 3\uff1a\u4f7f\u7528 PowerShell\uff08Windows \u6700\u63a8\u8350\uff09<\/h1>\n\n\n\n<p>Windows \u81ea\u5e26 <strong>Test-NetConnection<\/strong><\/p>\n\n\n\n<h3 class=\"wp-block-heading\">\u2714 \u6d4b\u8bd5\u5355\u4e2a\u7aef\u53e3\uff1a<\/h3>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\nTest-NetConnection -ComputerName 192.168.1.10 -Port 22\n\n<\/pre><\/div>\n\n\n<p>\u7ed3\u679c\u793a\u4f8b\uff1a<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\nTcpTestSucceeded : True   \u2192 \u7aef\u53e3\u5f00\u653e\nTcpTestSucceeded : False  \u2192 \u7aef\u53e3\u5173\u95ed\n\n<\/pre><\/div>\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h1 class=\"wp-block-heading\">#\ufe0f\u20e3 \u65b9\u6cd5 4\uff1a\u4f7f\u7528 <code>nmap<\/code>\uff08\u4e13\u4e1a\u7aef\u53e3\u626b\u63cf\uff09<\/h1>\n\n\n\n<p>\u5982\u679c\u4f60\u9700\u8981\u626b\u63cf\u5927\u91cf\u7aef\u53e3\uff0c\u7528 nmap \u6700\u4e13\u4e1a\u3002<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">\u2714 \u68c0\u6d4b 80 \u7aef\u53e3\uff1a<\/h3>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\nnmap -p 80 192.168.1.10\n\n<\/pre><\/div>\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h3 class=\"wp-block-heading\">\u2714 \u626b\u63cf\u5e38\u89c1\u7aef\u53e3\uff1a<\/h3>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\nnmap 192.168.1.10\n\n<\/pre><\/div>\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h3 class=\"wp-block-heading\">\u2714 \u626b\u63cf\u5168\u90e8\u7aef\u53e3\uff1a<\/h3>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\nnmap -p- 192.168.1.10\n\n<\/pre><\/div>\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h1 class=\"wp-block-heading\">#\ufe0f\u20e3 \u65b9\u6cd5 5\uff1a\u6d4f\u89c8\u5668\uff08\u4ec5\u7528\u4e8e Web \u7aef\u53e3\uff09<\/h1>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\nhttp:\/\/IP:\u7aef\u53e3\n\n<\/pre><\/div>\n\n\n<p>\u4f8b\uff1a<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\nhttp:\/\/192.168.1.10:8080\n\n<\/pre><\/div>\n\n\n<p>\u5982\u679c\u80fd\u6253\u5f00\u7f51\u9875\uff0c\u5219\u7aef\u53e3\u5f00\u653e\u3002<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h1 class=\"wp-block-heading\">#\ufe0f\u20e3 \u5e38\u89c1\u9519\u8bef\u7406\u89e3\uff1a<code>ping<\/code> \u7aef\u53e3\u4e0d\u5b58\u5728<\/h1>\n\n\n\n<p>\u5f88\u591a\u4eba\u4ee5\u4e3a\u53ef\u4ee5\uff1a<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\nping 192.168.1.10:8080\n\n<\/pre><\/div>\n\n\n<p>\u8fd9\u79cd\u5199\u6cd5\u5728\u6240\u6709\u7cfb\u7edf\u4e2d\u90fd\u662f <strong>\u65e0\u6548<\/strong> \u7684\u3002<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h1 class=\"wp-block-heading\">\u2714 \u63a8\u8350\u603b\u7ed3\uff08\u6309\u7cfb\u7edf\uff09<\/h1>\n\n\n\n<figure class=\"wp-block-table\"><table class=\"has-fixed-layout\"><thead><tr><th>\u7cfb\u7edf<\/th><th>\u6700\u63a8\u8350\u547d\u4ee4<\/th><\/tr><\/thead><tbody><tr><td>Windows<\/td><td><code>Test-NetConnection<\/code><\/td><\/tr><tr><td>Mac<\/td><td><code>nc -zv<\/code><\/td><\/tr><tr><td>Linux<\/td><td><code>nc -zv<\/code><\/td><\/tr><tr><td>\u4e13\u4e1a\u626b\u63cf<\/td><td><code>nmap<\/code><\/td><\/tr><\/tbody><\/table><\/figure>\n","protected":false},"excerpt":{"rendered":"<p>\u4e0b\u9762\u662f \u5982\u4f55 Ping \u6307\u5b9a IP \u7684\u7aef\u53e3\u53f7 \u7684\u5b8c\u6574\u603b\u7ed3 \u2014\u2014 \u5305\u542b Windo&#8230; <a class=\"more-link\" href=\"https:\/\/www.52runoob.com\/index.php\/2025\/11\/29\/%e5%a6%82%e4%bd%95ping%e6%8c%87%e5%ae%9aip%e7%9a%84%e7%ab%af%e5%8f%a3%e5%8f%b7_ping-%e7%ab%af%e5%8f%a3\/\">Continue Reading &rarr;<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[12],"tags":[],"class_list":["post-280","post","type-post","status-publish","format-standard","hentry","category-12"],"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/www.52runoob.com\/index.php\/wp-json\/wp\/v2\/posts\/280","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.52runoob.com\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.52runoob.com\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.52runoob.com\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.52runoob.com\/index.php\/wp-json\/wp\/v2\/comments?post=280"}],"version-history":[{"count":1,"href":"https:\/\/www.52runoob.com\/index.php\/wp-json\/wp\/v2\/posts\/280\/revisions"}],"predecessor-version":[{"id":281,"href":"https:\/\/www.52runoob.com\/index.php\/wp-json\/wp\/v2\/posts\/280\/revisions\/281"}],"wp:attachment":[{"href":"https:\/\/www.52runoob.com\/index.php\/wp-json\/wp\/v2\/media?parent=280"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.52runoob.com\/index.php\/wp-json\/wp\/v2\/categories?post=280"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.52runoob.com\/index.php\/wp-json\/wp\/v2\/tags?post=280"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}