Having network issues

I recently rebuilt my server onto Debian 9, and am having problems with URL resolution.

All I have done is changed my root password, and created an account (adduser sam) which has been added to the sudo group.

This user (sam) cannot resolve domains. The contents of /etc/resolv.conf are

nameserver: nameserver:

To be clear, I have installed no packages or made any other changes, other than generating an SSH key for sam.

I tried creating a second user to see if that worked, but it didn’t

Also found that root user cannot complete an apt-get update as the name resolution for fail - however, it can ping

I’ve tried rebooting, but no joy - is there some kind of network issue or something?


Submit an answer
You can type!ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

In my experience, all freshly created droplets have working internet connection without the need of fiddling with resolv.conf. Do you experience the same problem even with newborn droplets?

If instead you wish to change nameservers for whatever reason, your /etc/resolv.conf is wrong. Check out the Debian documentation about resolv.conf: there are no columns after “nameserver” (or after any other field you can set with resolv.conf for that matter).