In case you have problems with DNS servers.
The error looks like this:
We will show two ways to solve the problem, through SSH-access and through sFTP-access.
Use SSH
Use the Nano utility to browse and edit the resolv.conf file where you configure our server’s DNS. Enter the command
The file editor opened before us resolv.conf
File will be empty, or it will contain text as a description, depending on the selected distribution Linux.
This file must specify nameserver for your OS.
Which nameserver to choose? You can read more about this at the very end of the article. In this case, we will use DNS 8.8.8.8 as the primary.
Enter this text in the file:
Press Ctrl + X to exit the file. Then press Y to save the changes.
Then press Enter to keep the file name as it is.
Use sFTP
Connect to our server via sFTP. Next we need to go to the directory /etc and find there the file resolv.conf
Open it with any text editor.
The file will be empty, or it will contain text as a description, depending on the Linux distribution you choose.
We need to add the optimal nameserver here, we will point them out several, in case of problems with one of them.
Great, save the file and upload it to the server.
Last updated