I've set up pihole w/ cloudflared + pivpn on a raspberry pi 2b+

Everything seems to be working properly when connected to my internal WIFI (cable modem / router combo) on an Android client using the OpenVPN application. The client connects, and I can see activity in the vpn logs in that instance. I can't seem to connect with my Android client on cellular data or outside of my Wifi.

I've forwarded ports 1194 on my router to point to the raspberry pi internal IP (on same port), which is a reserved ip on my internal network. Externally, I'm able to ping my router's IP when forwarding port 80, either via the ip directly, or through Duck DNS which I have setup to point to my router.

Pihole is configured to listen on both tun0 or eth0, and upstream DNS is through cloudflared DNS over HTTPS, with pihole set to DNS of This was a pretty vanilla installation on Raspbian jessie following the common guides for setting up both pihole and pivpn through the 1 step install. Adblocking and pihole functionality seems to be working as intended

My questions are:

1) What configuration parameters should I be looking at to troubleshoot; and 2) I've heard ISPs with a NAT between my modem / router might interfere with this functionality; is there a way to determine if this issue is upstream of my network, or with some way I have configured the services on the raspi?

Thanks for any help / pointers.

  • In your .ovpn profile for Android what IP is it connecting to??? It could just be your profiles pointing to the internal IP as opposed to the external one. – rohtua Feb 7 '19 at 20:30
  • I tried by pointing to both the external ip (router), as well as the dynamic domain on duck dns which I had set up. – Erik Stewart Feb 8 '19 at 21:45
  • Does any error appear in the ovpn app on Android when trying to connect??? You've probably done it but with the external IP / URL in the .ovpn file the port number is included as well??? Ideally if you can get hold of the logs either from the open vpn app or server (should be an openvpn log in /var/log ) when trying to connect it should help identify where the issue might be. – rohtua Feb 8 '19 at 21:54

This has been resolved (although definitive cause of initial issue is still unclear).

I believe the issue had to do with using cloud-flared as a privacy sensitive DNS solution on top of the pihole install. I ended up getting things to work with pihole w/ unbound + OpenVPN.

| improve this answer | |
  • Please accept your answer with a click on the tick on its left side. This will finish your question and it will not pop up again months for months. – Ingo Nov 23 '19 at 19:02

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.