Cant resolve hostname using OpenVPN

  • I have domain xxx.yyy

    I have hostnames like pfsense and NAS

    Using OpenVPN I cant resolve eg NAS - I have to use full name

    I am sure I had this working before the update. But now I cant find the correct setting again…


  • post your server1.conf.

  • dev ovpns1
    dev-type tun
    dev-node /dev/tun1
    writepid /var/run/
    #user nobody
    #group nobody
    script-security 3
    keepalive 10 60
    proto udp
    cipher AES-128-CBC
    up /usr/local/sbin/ovpn-linkup
    down /usr/local/sbin/ovpn-linkdown
    client-connect /usr/local/sbin/
    client-disconnect /usr/local/sbin/
    client-config-dir /var/etc/openvpn-csc
    auth-user-pass-verify /var/etc/openvpn/server1.php via-env
    tls-verify /var/etc/openvpn/server1.tls-verify.php
    lport 1194
    management /var/etc/openvpn/server1.sock unix
    max-clients 3
    push "route"
    push "dhcp-option DOMAIN holte.home"
    push "dhcp-option DNS"
    push "dhcp-option DNS"
    ca /var/etc/openvpn/ 
    cert /var/etc/openvpn/server1.cert 
    key /var/etc/openvpn/server1.key 
    dh /etc/dh-parameters.1024
    tls-auth /var/etc/openvpn/server1.tls-auth 0
    push "route"

  • What kind of client machine are you coming from?

    If it's Windows, can you post the output of "ifconfig /allcompartments /all" ?

    I'm wondering if your local machine is seeing the domain suffix of your remote network properly.

    On my Windows machines, connecting to an OVPN server that pushes an internal DNS server to me (for internal office machine naming) I have to ensure that I get the domain suffix of the office applied to my machines.

    Sometimes (using OVPNGUI on my Windows 7 Machine) this does not happen unless I start OVPNGUI "as administrator" so that the push commands can be executed as admin, and make the appropriate changes on my local machine.

  • Hi pfbits,

    I found out myself after you pointed me in the right direction.

    I had a faulty DNS suffinx setting on the VPN adapter. This was due to misconfiguration of OpenVPN (I changed my domain name at one time).

    So now everything is working as it should.

    Thank you very much for helping me out.

Log in to reply