What I am trying to do: Use ip/connection of my openvpn server (Debian) when I connect to it via gui over win 8 desktop
The problem : I followed
http://openvpn.net/index.php/open-source/documentation/howto.html#redirect this guide, and made proper changes, right after openvpn is connected I started to get DNS error (Server's DNS not resolved) and can't visit any site from my browser. I also tried pushing DNS settings from conf. Plus for some reason I have blank default gateway settings when I check it from windows.
server conf
port 3131
proto udp
dev tun
ca ca.crt
cert open.crt
key open.key # This file should be kept secret
dh dh1024.pem
server 10.8.0.0 255.255.255.0
ifconfig-pool-persist ipp.txt
push "redirect-gateway def1"
push "dhcp-option DNS 10.8.0.1"
keepalive 10 120
comp-lzo
persist-key
persist-tun
status openvpn-status.log
log-append openvpn.log
verb 6
client conf
client
dev tun
proto udp
remote 1** 3131
resolv-retry infinite
nobind
persist-key
persist-tun
ca ca.crt
cert client.crt
key client.key
ns-cert-type server
comp-lzo
verb 6
ipconfig /all part from windows (client) - notice the empty default gateway-
Connection-specific DNS Suffix . :
Description . . . . . . . . . . . : TAP-Windows Adapter V9
Physical Address. . . . . . . . . : 00-FF-D9-1F-84-6A
DHCP Enabled. . . . . . . . . . . : Yes
Autoconfiguration Enabled . . . . : Yes
Link-local IPv6 Address . . . . . : fe80::2cbb:b7ec:3194:62ae%32(Preferred)
IPv4 Address. . . . . . . . . . . : 10.8.0.6(Preferred)
Subnet Mask . . . . . . . . . . . : 255.255.255.252
Lease Obtained. . . . . . . . . . : 30 Mayıs 2013 Perşembe 01:52:42
Lease Expires . . . . . . . . . . : 30 Mayıs 2014 Cuma 01:52:41
Default Gateway . . . . . . . . . :
DHCP Server . . . . . . . . . . . : 10.8.0.5
DHCPv6 IAID . . . . . . . . . . . : 536936409
DHCPv6 Client DUID. . . . . . . . : 00-01-00-01-19-22-FF-7B-14-FE-B5-AB-01-2D
DNS Servers . . . . . . . . . . . : 10.8.0.1
NetBIOS over Tcpip. . . . . . . . : Enabled
verb6 logs from client while connecting
I don't have well knowledge about openvpn so please let me know if there is any missing or required logs, and I can share it gladly. By the way I also did iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -o eth0 -j MASQUERADE . And I am sure that eth0 is the main interface on server