I'm a newbie so, my bad if my question is a non sense to you.

I'm currently renting a server where I installed PiHole and PiVPN. PiHole is a DNS sinkhole that I use for blocking add, and the PiVPN allows all my devices thanks to OpenVPN to get all my traffic through a personal VPN to reach my PiHole. On PC it's great, even for laptop, because battery life is enough to support the "keepalive packets" that's allow OpenVPN to stay connected to my server even if I'm not using internet directly.

However, on Android, it's the main problem, since I'm using a VPN 24/7, and my battery is melting like snow in the sun. So the question is the following : How can I setup an internal VPN that's redirect DNS queries to my PiHole (my server got an IP adress that's correspond to my personal DNS-PiHole) ?

I know some applications can work like "that", like AdAway (for non-root smartphone) or NetGuard.

I'm by the way rooted, and already using AdAway which is making the job, but it's more for technical challenge battery management.

Thank you for your time and your help !

Have a nice week,

  • Is your PiHole server reachable without VPN? Because if not one "internal VPN" wouldn't be enough, you would need a second VPN to just reach your PiHole server (e.g. just for DNS traffic to the PiHole server). Finally the main question remains: what do you gain by using your PiHole server instead of AdAway or similar apps like Blokada?
    – Robert
    Mar 15 '21 at 10:25
  • Hello, thanks for your rapid answer. I finally find what I need, "DNS Change" or "DNS Override" are making the job ! My problem is solved I guess, even if I don't like using app which aren't opensource :s
    – user344991
    Mar 15 '21 at 14:01
  • If root is available, I prefer running dnscrypt on the device than relying on VPN. Mar 15 '21 at 14:10
  • Hi there, I don't even know how to do that (I mean, running a script on Android), I guess it's with adb command ? I read as well that each time you reboot your device, you will have to re-over-write DNS again, I'm wrong ?
    – user344991
    Mar 15 '21 at 14:12

Your Answer

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