Ping request time out although web browser works on same computer

核能气质少年 提交于 2019-12-23 07:55:47

问题


I'm on the World Wide Web right now, as evidenced by posting on StackOverflow. However, if I try to ping stackoverflow.com from the command line, the ping times out. What do I need to do for ping to work?

> ping stackoverflow.com

Pinging stackoverflow.com [198.252.206.140] with 32 bytes of data:
Request timed out.
Request timed out.
Request timed out.
Request timed out.

Ping statistics for 198.252.206.140:
    Packets: Sent = 4, Received = 0, Lost = 4 (100% loss),

Edit, try tracert

> tracert stackoverflow.com

Tracing route to stackoverflow.com [198.252.206.140] over a maximum of 30 hops:

  1     *        *        *     Request timed out.
  2     *        *        *     Request timed out.
  3     *        *        *     Request timed out.
  4     *        *        *     Request timed out.
  5     *        *        *     Request timed out.
  6     *        *        *     Request timed out.
  7     *        *        *     Request timed out.
  8     *        *        *     Request timed out.
  9     *        *        *     Request timed out.
 10     *        *        *     Request timed out.
 11     *        *        *     Request timed out.
 12     *        *        *     Request timed out.
 13     *        *        *     Request timed out.
 14     *        *        *     Request timed out.
 15     *        *        *     Request timed out.
 ...
 Trace complete.

It's Request timed out. all the way to 30 hops.

Edit, try ping google.com

Same result. :-)


回答1:


Some hosts have a firewall that block the ICMP (http://ca.wikipedia.org/wiki/Internet_Control_Message_Protocol) packets like ping. You can use traceroute (cmd line tool or online webs like http://ping.eu/traceroute/) or tcptraceroute (http://linux.die.net/man/1/tcptraceroute).

Some routers also have a firewall that block ICMP. You can detect this by doing ping google.com. It that fails, then it's your local router that's problematic not the remote host.

hope it can help you



来源:https://stackoverflow.com/questions/29826271/ping-request-time-out-although-web-browser-works-on-same-computer

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!