OpenWrt Forum Archive

Topic: option localservice '0' -- Is this a bad idea for dnsmasq? and OpenVPN

The content of this topic has been archived on 28 Mar 2018. There are no obvious gaps in this topic, but there may still be some posts missing at the end.

config dnsmasq
        option localservice '0' #enable queries from vpn

I spent the better part of three hours trying to figure out why local DNS lookups weren't working from my Android phone, thinking it was an OpenVPN option or a strict firewall.  I was unable to resolve any addresses at all with just 192.168.1.1 in the OpenVPN config.  The Google DNS servers worked just fine.  I had actually started to write a post with all of these configs in it when the answer came to me.

Maybe this should be in the OpenVPN documentation?  Maybe not.  Is this option a bad idea?  I disabled it to make local DNS lookups work from my VPN.  If it is a bad idea, I suppose I could type in the IP addresses with my stubby fingers on my phone instead.

I will be using this to access my home network securely from elsewhere.  Separately, I have a VPN client to my provider on my phone if I want to be private.

Thanks!

Hi,
I reached the same conclusion while i was trying to find out why the names of the remote network hosts weren't resolved. Sincerely, i don't know if this is a bad idea, perhaps it is so in some specific network configurations.
Btw, seems like the vpn client does not know at all about "push dhcp-option DNS x.x.x.x" and "push dhcp-option DOMAIN domain" that are inside my /etc/config/openvpn.

At least you figured out in 3 hours, i've been banging my head for days!

arny91 wrote:

Btw, seems like the vpn client does not know at all about "push dhcp-option DNS x.x.x.x" and "push dhcp-option DOMAIN domain" that are inside my /etc/config/openvpn.

I'm seeing the DNS and DOMAIN that OpenWrt pushes in the openvpn client log in Android.  I think they are going through.  When I had 192.168.1.1 and 8.8.8.8 for DNS, and I didn't have

config dnsmasq
        option localservice '0'

set in /etc/config/dhcp, I was able to resolve outside internet addresses just fine.

I'm not certain that the "lan" domain is going across.  Things seem to be working.

arny91 wrote:

At least you figured out in 3 hours, i've been banging my head for days!

I count myself lucky that I found that dnsmasq option at all.

The discussion might have continued from here.