How to fix your DNS resolution issues on Linux

  VPS Hosting

This is fairly simple process and this can be done on any version of Linux that uses Systemd as an Initiator. This will include pretty much all Debian based releases. Redhat based releases and Arch based releases. (Sorry for those Gentoo users who don’t use Systemd). To make this happen all you have to do is run a few commands in the terminal (or console). Here you can view the family of Linux Distros.

In the video it’s a little bit different to this article, the reason for this is the video is designed for new users to get an explanation of what’s going on. Though for those power users who are looking for that quick fix, just run the following commands. If you are new to Linux as well, you can just run the following commands in your terminal and that should fix your issue.

sudo su

rm /etc/resolv.conf

touch /etc/resolv.conf

echo nameserver 1.1.1.1 >> /etc/resolv.conf

echo nameserver 8.8.8.8 >> /etc/resolv.conf

chattr +i /etc/resolv.conf

reboot

Was this article helpful?
YesNo

Sign up to be alerted of new articles!

We will let you know of any new articles that we publish so that you may benefit from the many upcoming tutorials we have planned for you.