I've been trying to setup a VPN using OpenVPN 2.1_rc22 on my windows VPS to route all my traffic (including internet) and so far everything I've tried has failed.
My windows VPS is running under vmware (not virtuozzo or hyperVM) and I've tried different openVPN client/server config files and setups, I followed different "how-to's" , my IPEnableRouter is set to 1 on my windows and windows VPS registry but so far no luck. Im starting to wonder if anyone has been able to setup a VPN on a windows VPS that is under vmware and route all the traffic through the VPN, I can figure out what could be wrong with my setup/config files so Im looking for some guidance in this matter.
this is where I am so far :
I can stablish a VPN connection and ping from client to server
Code: Select all
C:\Documents and Settings\client>ping 10.8.0.1
Pinging 10.8.0.1 with 32 bytes of data:
Reply from 10.8.0.1: bytes=32 time=55ms TTL=128
Reply from 10.8.0.1: bytes=32 time=55ms TTL=128
Reply from 10.8.0.1: bytes=32 time=54ms TTL=128
Reply from 10.8.0.1: bytes=32 time=55ms TTL=128
Code: Select all
C:\Documents and Settings\Administrator>ping 10.8.0.6
Pinging 10.8.0.6 with 32 bytes of data:
Request timed out.
Request timed out.
Request timed out.
Request timed out.
Code: Select all
port 1194
proto udp
dev tun
ca ca.crt
cert server.crt
key server.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 bypass-dhcp"
;route add gateway my.VPS.public.IP #test gw
client-to-client
keepalive 10 120
comp-lzo
max-clients 5
persist-key
persist-tun
status openvpn-status.log
verb 6
Code: Select all
client
dev tun
dev-node MyTap
proto udp
remote my.VPS.public.IP 1194
resolv-retry infinite
nobind
persist-key
persist-tun
ca ca.crt
cert slipsam.crt
key slipsam.key
ns-cert-type server
comp-lzo
verb 6
Code: Select all
http://paste2.org/p/549052
Code: Select all
http://paste2.org/p/549053
Code: Select all
C:\>route print
===========================================================================
Interface List
0x1 ........................... MS TCP Loopback interface
0x2 ...00 1f d0 d1 37 3c ...... Realtek RTL8168C(P)/8111C(P) PCI-E Gigabit Etnet NIC - Packet Scheduler Miniport
0x3 ...00 ff 23 5b 95 f0 ...... TAP-Win32 Adapter V9 - Packet Scheduler Miniport
0x4 ...08 00 27 00 94 43 ...... VirtualBox Host-Only Ethernet Adapter - Packecheduler Miniport
===========================================================================
Active Routes:
Network Destination Netmask Gateway Interface Metric
0.0.0.0 128.0.0.0 10.8.0.5 10.8.0.6 1
0.0.0.0 0.0.0.0 192.168.1.254 192.168.1.67 20
10.8.0.0 255.255.255.0 10.8.0.5 10.8.0.6 1
10.8.0.4 255.255.255.252 10.8.0.6 10.8.0.6 30
10.8.0.6 255.255.255.255 127.0.0.1 127.0.0.1 30
10.255.255.255 255.255.255.255 10.8.0.6 10.8.0.6 30
65.54.49.168 255.255.255.255 192.168.1.254 192.168.1.67 20
69.64.250.20 255.255.255.255 192.168.1.254 192.168.1.67 20
72.21.91.20 255.255.255.255 192.168.1.254 192.168.1.67 20
91.121.209.36 255.255.255.255 192.168.1.254 192.168.1.67 20
my.VPS.Public.IP 255.255.255.255 192.168.1.254 192.168.1.67 1
127.0.0.0 255.0.0.0 127.0.0.1 127.0.0.1 1
128.0.0.0 128.0.0.0 10.8.0.5 10.8.0.6 1
169.254.0.0 255.255.0.0 192.168.1.67 192.168.1.67 30
192.168.1.0 255.255.255.0 192.168.1.67 192.168.1.67 20
192.168.1.67 255.255.255.255 127.0.0.1 127.0.0.1 20
192.168.1.255 255.255.255.255 192.168.1.67 192.168.1.67 20
192.168.56.0 255.255.255.0 192.168.56.1 192.168.56.1 20
192.168.56.1 255.255.255.255 127.0.0.1 127.0.0.1 20
192.168.56.255 255.255.255.255 192.168.56.1 192.168.56.1 20
207.46.113.85 255.255.255.255 192.168.1.254 192.168.1.67 20
224.0.0.0 240.0.0.0 10.8.0.6 10.8.0.6 30
224.0.0.0 240.0.0.0 192.168.1.67 192.168.1.67 20
224.0.0.0 240.0.0.0 192.168.56.1 192.168.56.1 20
255.255.255.255 255.255.255.255 10.8.0.6 10.8.0.6 1
255.255.255.255 255.255.255.255 192.168.1.67 192.168.1.67 1
255.255.255.255 255.255.255.255 192.168.56.1 192.168.56.1 1
Default Gateway: 10.8.0.5
===========================================================================
Persistent Routes:
None
Code: Select all
C:\Program Files\OpenVPN\config>route print
IPv4 Route Table
===========================================================================
Interface List
0x1 ........................... MS TCP Loopback interface
0x10004 ...00 50 56 a2 08 ad ...... VMware Accelerated AMD PCNet Adapter
0x20002 ...00 ff 76 c0 2b 85 ...... TAP-Win32 Adapter V9
===========================================================================
===========================================================================
Active Routes:
Network Destination Netmask Gateway Interface Metric
0.0.0.0 0.0.0.0 98.126.myVPS.GW 98.126.myVPS.IP 10
98.126.unknown.IP 255.255.255.248 98.126.myVPS.IP 98.126.myVPS.IP 10
98.126.myVPS.IP 255.255.255.255 127.0.0.1 127.0.0.1 10
98.255.255.255 255.255.255.255 98.126.myVPS.IP 98.126.myVPS.IP 10
127.0.0.0 255.0.0.0 127.0.0.1 127.0.0.1 1
224.0.0.0 240.0.0.0 98.126.myVPS.IP 98.126.myVPS.IP 10
255.255.255.255 255.255.255.255 98.126.myVPS.IP 20002 1
255.255.255.255 255.255.255.255 98.126.myVPS.IP 98.126.myVPS.IP 1
Default Gateway: 98.126.myVPS.GW
===========================================================================
Persistent Routes:
None
C:\Program Files\OpenVPN\config>
I noticed on my log file after testing different config files is that somehow OpenVPN makes 192.168.1.254 as my default gateway no matter what I try when it should be something like 10.8.0.1 right? that could explain why the clients internet is being cut but I still havent figured out how to tell OpenVPN to use a different gateway I've tried the push route command but then I cant connect to my VPN.
What could be wrong with my server config file? , is there something like a very specific technical thing I have to request to my provider in order to make my VPN work? all I want is route my internet traffic through my VPN, thanks for reading my wall of text and any help provided is greatly appreciated