当前位置:网站首页>Why can't you Ping the website but you can access it?

Why can't you Ping the website but you can access it?

2022-06-25 12:03:00 lxw1844912514

today , When visiting a website , I want to see its ip How much is the , It's just windows Command line down ping This website / host ;ip The address is resolved , But the request timed out , No, ping through , I was very confused at that time . then , I tracert The ip Followed up I want to see what the problem is , At last I found out , When the ip When The request was refused . All of a sudden , It should be the server Set relevant policies on the network layer icmp The echo request message is restricted ; The web page is accessed with http agreement , Therefore, this phenomenon will occur .

e4a20817665f23dbff0cde2a10c4de4b.png

ping The essence of : Send a icmp Echo the request message to the destination host , And wait for the echo icmp The reply . Then print out the echo message .

The echoed results include Number of bytes 、 reaction time 、TTL( Time to live )

ping The reason for not being able to access the website :

One 、 Network settings

The reason for this is that you need to specify it manually IP、 gateway 、DNS Server networking mode , And using proxy server to access the Internet . Check your computer's network settings carefully .

Two 、DNS Server issues

When IE When unable to browse the web , Try it first IP Address to access , If you can visit , So it should be DNS The problem of , cause DNS The problem may be getting DNS Error or DNS There is a problem with the server itself , At this time, you can manually specify DNS service ( The address can be your local ISP Provided DNS Server address , It can also be used in other places and can be used normally DNS Server address .) In the properties of the network ,( Control panel — Network and dial-up connections — Local connection — Right click Properties —TCP/IP agreement — attribute — Use the following DNS Server address ). Different ISP Different DNS Address . Sometimes it's a router or network card problem , Can't be with ISP Of DNS Service connection , In this case , Turn off the router for a while and then turn it on , Or reset the router .

There's another possibility , It's local DNS There is a problem with the cache . In order to improve the speed of website access , The system will automatically access and obtain IP The address of the website is stored locally DNS In the cache , Once you visit this website again , No longer pass DNS Server and directly from the local server DNS Cache to fetch the site's IP Address access . therefore , If the local DNS There is a problem with the cache , It will make the website inaccessible . Can be in “ function ” In the implementation of ipconfig /flushdns To rebuild the local DNS cache .

3、 ... and 、IE The problem with the browser itself

When IE When the browser itself fails , It will naturally affect browsing ; perhaps IE Being maliciously modified and damaged will also lead to inability to browse the web . You can try to use “ huangshan IE Repair experts ” To repair ( It is recommended to repair in safe mode ), Or to IE( Such as reassembly IE Encountered a problem that cannot be restarted , May refer to : Attachment 1: unable to reinstall IE)

Four 、 The problem of network firewall

If the network firewall is not set properly , If the safety level is too high 、 Don't be careful IE Put it in the blocked access list 、 Wrong firewall policy, etc , You can try to check the policy 、 Reduce the security level of the firewall or turn it off directly to see if it returns to normal .

5、 ... and 、 Network protocol and network card driver

IE Can't browse , It could be a network protocol ( especially TCP/IP agreement ) Or the network card driver is damaged , Try to reset the network card driver and network protocol .

6、 ... and 、HOSTS Problems with documents

HOSTS The document was modified , It will also lead to abnormal browsing , The solution, of course, is to empty HOSTS The contents of the document .

7、 ... and 、 Problems with system files

When and IE When relevant system files are replaced or damaged , Will affect IE Normal use , You can use SFC Command to fix ,WIN98 The system can be found in “ function ” In the implementation of SFC, Then perform the scan ;WIN2000/XP/2003 It's in “ function ” In the implementation of sfc /scannow Try to fix .

Tracert The essence of : utilize ICMP Datagram and IP In the datagram header TTL value .TTL(Time To Live) It's a IP Datagram lifetime , When each IP When the datagram passes through the router, it will be returned TTL Value minus 1 Or subtract the time spent in the router , But most datagrams stay in the router for less than 1 Seconds , So it's actually in TTL Value minus 1. such ,TTL The value is equivalent to the counter of a router .

When the router receives a TTL by 0 perhaps 1 Of IP When it comes to datagrams , The router will no longer forward this data , And throw it away , And send a ICMP“ Overtime ” Information to the source host .Tracert The key to the program is this echo ICMP The message IP The source address of the header is the address of the router IP Address .

meanwhile , If the destination host is reached , We don't know , therefore ,Tracert Also send a UDP Information to the destination host , And choose a large value as UDP The port of , Make this port not used by any application of the host . therefore , When the destination host is reached ,UDP The module generates a “ The port is not reachable ” Error of , In this way, we can judge whether we have reached the destination .

75aeb6529f6563a1c7b8345eb059fa6d.png

原网站

版权声明
本文为[lxw1844912514]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/176/202206251145314562.html