आज का प्रश्न और उत्तर सत्र हमारे पास सुपरयूसर की सौजन्य है - स्टैक एक्सचेंज का एक उपविभाग, क्यू एंड ए वेब साइट्स का एक समुदाय संचालित समूह।
Cristianzambrano (विकिमीडिया कॉमन्स) की स्क्रीनशॉट सौजन्य।
प्रश्न
सुपर यूज़र रीडर सरंष सिंह जानना चाहते हैं कि https:// के साथ और बिना पिंग करने के बीच क्या अंतर है:
I am trying to ping my website https://www.example.com/ and it resolves to an unknown IP address, then it times out.
But when I ping example.com, it works. What am I missing or not understanding here?
Note: example.com was substituted for the actual website at SuperUser.
Http: // के साथ और बिना पिंग करने के बीच क्या अंतर है?
उत्तर
SuperUser योगदानकर्ता डेविडपोस्टिल का जवाब हमारे लिए है:
The argument to ping is a host name (or an IP address). So the following will all work:
On the other hand, this will not work as https://www.example.com/ is an HTTP Uniform Resource Locator (URL), not a valid host name (although part of it is a host name).
- Scheme - Always present
- Host Name - Always present
- Path or Stem - Always present but sometimes is null
- Parameters - Optional
A ping will not normally recognize URLs as a valid destination host name.
Note
Not all URLs have the format mentioned above. A complete URL consists of a naming scheme specifier followed by a string whose format is a function of the naming scheme. The format of URLs is defined in the IETF specification Uniform Resource Locators (URLs). *This is a different website address from the one shown for URL above.
DNS Hijacking
An exception to the above can happen if the DNS server (which resolves host names to IP addresses) is configured to return a valid IP address even if an invalid host name is supplied. This can happen if an ISP is hijacking your DNS queries.
From the answer Why is ping resolving to an IP 198.105.254.228 for any random host name that i type? by Michael Hampton:
They are trying to be “helpful” by redirecting requests for nonexistent domains to a white label service that provides search results and advertising, from which everyone but you gets a cut of the revenue. Fortunately, they do have a preferences page where you can supposedly turn it off.
नीचे साझा किए गए थ्रेड लिंक के माध्यम से अन्य सहायक उत्तरों के माध्यम से पढ़ना सुनिश्चित करें!
स्पष्टीकरण में जोड़ने के लिए कुछ है? टिप्पणियों में विचार व्यक्त करो। अन्य तकनीक-समझदार स्टैक एक्सचेंज उपयोगकर्ताओं से अधिक उत्तरों पढ़ना चाहते हैं? यहां पूर्ण चर्चा धागा देखें।