Junior — Middle
What methods can be used to verify the correctness of DNS name resolution?
sobes.tech AI
Answer from AI
To verify the correctness of DNS name resolution, you can use the following methods:
-
nslookupcommand — shows the IP address corresponding to the domain name.nslookup example.com -
digcommand — a more detailed DNS query, allows viewing A, CNAME, MX records, and others.dig example.com -
pingcommand — checks if the name resolves and if the host is reachable.ping example.com -
Checking via browser or curl — if the name resolves and the server responds, DNS is working correctly.
curl -I http://example.com -
Checking the local hosts file — ensure that the name is not overridden locally.
These methods will help verify that the DNS name resolves correctly to the desired IP address.