Pfsense, OpenVPN and DNS

Hey people!

I have a Pfsense, OpenVPN/Radius setup. I was trying to get hostnames working when connected and when I set “Force all DNS over OpenVPN” on the OVPN server it works fine (not sure if that’s there’s a way around that). Now I can ping hosts on the network I’m connected to using “hostname.localdomain”.

Unfortunately I have one app that connects to a server using only the hostname without the domain and it refuses to connect when I’m using OpenVPN. Is there a way to make this work by changes to the OpenVPN server or Pfsense environment? Or is this something I should fix using the hosts file on my Windows client? I’d prefer the former as it’ll be more future proof.

Thanks for any pointers!

I managed to get it working. There’s plenty of questions and possible solution floating around the net, but in the end it’s very simple and the solution came from a Netgate employee so I’m quite confident it’s the correct way to achieve this ( Derelict’s post)

You have to make sure that you push the DNS and the domain (I was missing that part) in the OpenVPN server configuration. In my case it looks like this: