Networking 101: Temporary failure in name resolution


This time we are going to analyze two common issues that we can face on our Linux machines, concerning networking. 

Issue: Temporary failure in name resolution 

Inside the configuration file /etc/resolv.conf is an augmented generated file that contains the IP address of the DNS name server. 

cat /etc/resolv.conf

First, we can test if the ping command is working, I will test with our website.

ping ithands-on.com

Then we switch to root user, and we use vi to go inside the file /etc/resolv.conf

vi /etc/resolv.conf




In, the end as you can see, as soon we save as a comment the nameserver the ping command gives us the error "Temporary failure in name resolution". Now it will be enough to go back to the file, remove the # and save it, and to be sure that you did it right you can test the ping command again. 


Comments

Leave as a comment:

Archive