ping 网关 检查计算机是否连通代理服务器或者internet
ping ip(自己的) 检查网卡
ping ip (别人的) 检查是否连通内网或者外网
如果网络不通,可以按照以下步骤来诊断网络状况:
1.Ping本机IP
例如本机IP地址为:222.31.191.211。则执行命令Ping 222.31.191.211。如果网卡安装配置没有问题,则应有类似下列显示:
C:\>ping 222.31.191.211
Pinging 222.31.191.211 with 32 bytes of data:
Reply from 222.31.191.211: bytes=32 time<1ms TTL=128
Reply from 222.31.191.211: bytes=32 time<1ms TTL=128
Reply from 222.31.191.211: bytes=32 time<1ms TTL=128
Reply from 222.31.191.211: bytes=32 time<1ms TTL=128
Ping statistics for 222.31.191.211:
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
Minimum = 0ms, Maximum = 0ms, Average = 0ms
如果在MS-DOS方式下执行此命令显示内容为:Request timed out,则表明网卡安装或配置有问题。将网线断开再次执行此命令,如果显示正常,则说明本机使用的IP地址可能与另一台正在使用的机器IP地址重复了。如果仍然不正常,则表明本机网卡安装或配置有问题,需继续检查相关网络配置。
2.Ping网关IP
假定网关IP为:222.31.191.110,则执行命令“Ping 222.31.191.110”。在MS-DOS方式下执行此命令,如果显示类似以下信息:
Pinging 222.31.191.110 with 32 bytes of data:
Reply from 222.31.191.110: bytes=32 time<1ms TTL=255
Reply from 222.31.191.110: bytes=32 time<1ms TTL=255
Reply from 222.31.191.110: bytes=32 time<1ms TTL=255
Reply from 222.31.191.110: bytes=32 time<1ms TTL=255
Ping statistics for 222.31.191.110:
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
Minimum = 0ms, Maximum = 0ms, Average = 0ms
则表明局域网中的网关路由器正在正常运行。反之,则说明网关设置有问题,请检查IP,网关等信息是否设置正确。
3.Ping远程IP
这一命令可以检测本机能否正常访问Internet。比如林大主页的IP地址为:202.204.112.68。在MS-DOS方式下执行命令:“Ping 202.204.112.68”,如果屏幕显示:
Pinging 202.204.112.68 with 32 bytes of data:
Reply from 202.204.112.68: bytes=32 time<1ms TTL=63
Reply from 202.204.112.68: bytes=32 time<1ms TTL=63
Reply from 202.204.112.68: bytes=32 time<1ms TTL=63
Reply from 202.204.112.68: bytes=32 time<1ms TTL=63
Ping statistics for 202.204.112.68:
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
Minimum = 0ms, Maximum = 0ms, Average = 0ms
则表明运行正常,能够正常接入内部网。反之,则表明网络设置存在问题或IP绑定不正确。
4.Ping DNS IP
这一命令用于检查内部网的DNS是否工作正常,如果您可以正常联网,但是输入域名却无法解析时请尝试该命令“ping 202.204.112.66”,如果显示
Pinging 202.204.112.66 with 32 bytes of data:
Reply from 202.204.112.66: bytes=32 time<1ms TTL=63
Reply from 202.204.112.66: bytes=32 time<1ms TTL=63
Reply from 202.204.112.66: bytes=32 time<1ms TTL=63
Reply from 202.204.112.66: bytes=32 time<1ms TTL=63
Ping statistics for 202.204.112.66:
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
Minimum = 0ms, Maximum = 0ms, Average = 0ms
则表明DNS服务器工作正常,如果显示“Request timed out.”请马上联系信息中心。
ping 192.168.0.1 就是ping 自己
比如说ping www.163.com
就是ping的163网站
就会从你这里发4个数据包到163,然后163会回4个数据包给你,通常是用来测试网路通不通
有显示send 就是发送数据,lost 就是丢失数据
ping 221.125.23.21 就是测试一下这个IP地址与自己的网路是否相同
ping 221.125.23.21 -l 65535
就是发一个65535这么大的数据包给这个IP地址,(一般这么大的是发不成功的)
有一种木马程序就是使中毒的机器在相同时间同时PING 一个IP地址,导致该IP地址不断反馈信息,致使网络繁忙,好象以前腾讯公司收到的攻击就是类似的