DNS issue: Could not resolve host:


I am using NextCloudPI for the first time and I am really happy with it. But unfortunately I have an issue.

My Pi with this image can only resolve addresses in form of IP’s and not names. That means I can do this:


PING ( 56(84) bytes of data.

64 bytes from icmp_seq=1 ttl=54 time=22.8 ms

64 bytes from icmp_seq=2 ttl=54 time=23.2 ms

But not this:

ping google.de

ping: google.de: Temporary failure in name resolution

It is not an issue with my DNS of my router, because all my other devices (another PI, MacBook Pro, MacPro etc.) are working fine in the same environment.

I also compared the /etc/dhcpcd.conf file with my other PI and they are identical with one difference:

NextCloudPi autogenerated

don’t modify! better use ncp-config

interface eth0

static ip_address=

static routers=

static domain_name_servers=

Here it is routing to the localhost.

sudo ncp-config did not helped me in that case, because I was not able to find where to set the “correct” dns.

NextCloud itself works totally fine, thats not my problem, but I can not install any other apps, script etc. because my PI does not understand the links.

Thanks in advance for any help, it is much appreciated!

Nevermind, I was able to resolve it, with a clean installation.

The issue was, that when I tried in the setup assistant to activate a ddns server, which failed, something in the backend got screwed up. I was able to reproduce the issue 3 times after a clean install with these steps:

Clean install with Raspbian full.

Using the bash script.

Within the setup assistant over the website click on yes for getting access from outside of the network, give permission to automatically add the portforwarding and then click again on no, to not add a ddns server, Eventhough you have all green checkmarks, it will not work.

It even goes that far, that if I want to use in my network, the ddns link from my synology router instead of the IP address to change some network settings it redirected me to the nextcloud panel.

So I don’t know if this is a bug, or expected behavior, but at least I can now use the PI normally with no dns issues.


I resolved it by doing this:

sudo nano /etc/resolv.conf

edit it so it was:

nameserver (it was incorrectly

then it worked.

I then re-ran DuckDNS, then ran Let’sEncrypt, then it worked got my cert.