DNS issue with OpenVPN
-
VPN works. I can successfully connect from work to my home pfsense via VPN. But I am experiencing different behavior when on Linux and Windows.
Network at work: 10.0.0.0/16
Domain at work: work.comNetwork at home on LAN port: 10.10.0.0/16
Network for VPN clients: 10.20.0.0/16
Domain at home: home.comWhen I connect to VPN from work from a Windows machine my server at home srv1.home.com (which is in 10.10.0.0/16) is resolvable and I can access it by its FQDN.
But from Linux this does not work. Before I connect to VPN my /etc/resolve.conf looks like this:
domain work.com search work.com nameserver 10.0.0.1
After I connect to VPN my /etc/resolve.conf looks like this:
domain work.com search work.com home.com nameserver 10.0.0.1 nameserver 10.20.0.1
The routing is also there. The only way I can access srv1.home.com by FQDN is by commenting "nameserver 10.0.0.1" in my resolve.conf. But if I do so then I cannot resolve anything in work.com. I can only resolve machines in home.com. If I don't comment out "nameserver 10.0.0.1" then nothing in home.com will get resolved, but work.com will work. How do I solve this? What am I missing here?
Thanks!