u/graysfox

Android phone not using wireguard DNS

I am trying to get my phone to use the DNS server I have on my local network (using pihole). The DNS server works fine when I am home, and it works fine connecting with wireguard from a laptop, but my phone stubbornly seems to only want to use 8.8.8.8 as it's DNS server.

Wireguard Client Config

[Interface]
Address = 10.8.0.2/24, fdcc:ad94:bacf:61a4::cafe:2/112
DNS = 192.168.0.10
MTU = 1420
PrivateKey = <redacted>

[Peer]
AllowedIPs = 0.0.0.0/0, ::/0
Endpoint = <redacted>:51820
PreSharedKey = <redacted>
PublicKey = <redacted>

My I don't see anything wrong with my wireguard config. My phone is running e/os, so I used another phone to test and make sure it wasn't just an e/os issue, but I ran into the same thing.

I have already turned off the 'Private DNS' option in my android settings and the similar setting for my Firefox web browser.

When I am connected to the VPN - here is what I see running a few console commands (from Termux):

$ nslookup <my-domain>
server:       8.8.8.8
address:      8.8.8.8#53

Non-authorative answer:
Name:    <my-domain>
Address:   <my-public-ip>

$ nslookup <my-domain> 192.168.0.10
server:       192.168.0.10
address:      192.168.0.10#53

Name:    <my-domain>
Address:   192.168.0.10
Name:    <my-domain>
Address:   ::

So my phone can access my dns server over the vpn when I specify it with termux, but by default it is still using 8.8.8.8. Anyone have an idea what might be going on here?

reddit.com
u/graysfox — 7 days ago