Page 1 of 1

Route delete error on win7 64bit

Posted: Thu Feb 03, 2011 9:47 am
by giov
I 've installad on my laptop with windows7 64bit the last release openvpn-2.2.beta5 and I connect to internet with a vodafone internet key.
I've installed openvpn with vista sp2 compability and run as administrator.
also change ../openvpn/bin/openvpn-gui.1.0.3.exe compability and run as admin privileges.

this is my client configuration

Code: Select all

-------------------------------------
# Specify that we are a client and that we
# will be pulling certain config file directives
# from the server.
################################
client
dev tap
proto udp
remote xxx.xxx.xxx.xxx 5000
nobind
persist-key
persist-tun
ca keyspr\\ca.crt
cert keyspr\\xxx.crt
key keyspr\\xxx.key
route-method exe
route-delay 2
comp-lzo
verb 6
mute 20
this is the server config

Code: Select all

######################################
# Sample OpenVPN 2.0 config file for #
# multi-client server.               #
######################################

dev tap
tls-server
mode server
lport 5000

###############
# CERTIFICATI # 
###############
ca keys\\ca.crt
cert keys\\server.crt
key keys\\server.key 
dh keys\\dh1024.pem

#############
# IP SERVER #
#############
ifconfig 192.168.10.49 255.255.255.0
ifconfig-pool 192.168.10.70 192.168.10.90 255.255.255.0 
push "route-gateway 192.168.10.1" 
push "redirect-gateway" 
push "dhcp-option DNS 192.168.10.23"
push "dhcp-option WINS 192.168.10.23"
push "route 192.168.9.0 255.255.255.0"
push "route 192.168.11.0 255.255.255.0"
push "route 192.168.12.0 255.255.255.0"
push "route 192.168.14.0 255.255.255.0"
management 127.0.0.1 7505
comp-lzo
max-clients 20
persist-key
keepalive 10 60
##########
# LOGGIN #
##########
status ..\\log\\openvpn-status.log
log ..\\log\\openvpn.log
verb 3 
the connection to server is ok, but I have the route delete problem in the client log and
my laptop ip is the same that internet key vodafone and not that of my server public internet ip

Code: Select all

###############################
......
Wed Feb 02 16:48:57 2011 us=8000 C:\WINDOWS\system32\route.exe ADD xxx.xxx.xxx.xxx MASK 255.255.255.255 109.113.101.164
 OK
-----------------------------------------------
Wed Feb 02 16:48:57 2011 us=39000 C:\WINDOWS\system32\route.exe DELETE 0.0.0.0 MASK 0.0.0.0 109.113.101.164
Impossibile eliminare la route: Impossibile trovare elemento.
-----------------------------------------------
Wed Feb 02 16:48:57 2011 us=55000 C:\WINDOWS\system32\route.exe ADD 0.0.0.0 MASK 0.0.0.0 192.168.10.1
 OK
Wed Feb 02 16:48:57 2011 us=86000 C:\WINDOWS\system32\route.exe ADD 192.168.9.0 MASK 255.255.255.0 192.168.10.1
 OK
Wed Feb 02 16:48:57 2011 us=102000 C:\WINDOWS\system32\route.exe ADD 192.168.11.0 MASK 255.255.255.0 192.168.10.1
 OK
Wed Feb 02 16:48:57 2011 us=117000 C:\WINDOWS\system32\route.exe ADD 192.168.12.0 MASK 255.255.255.0 192.168.10.1
 OK
Wed Feb 02 16:48:57 2011 us=149000 C:\WINDOWS\system32\route.exe ADD 192.168.14.0 MASK 255.255.255.0 192.168.10.1
 OK
Wed Feb 02 16:48:57 2011 us=164000 Initialization Sequence Completed
Wed Feb 02 16:48:57 2011 us=164000 TUN WRITE [92]
Wed Feb 02 16:48:57 2011 us=164000 UDPv4 READ [101] from xxx.xxx.xxx.xxx :5000: P_DATA_V1 kid=0 DATA len=100
Wed Feb 02 16:48:57 2011 us=164000 TUN WRITE [60]
Wed Feb 02 16:48:57 2011 us=164000 UDPv4 READ [133] from xxx.xxx.xxx.xxx :5000: P_DATA_V1 kid=0 DATA len=132
Wed Feb 02 16:48:57 2011 us=164000 TUN WRITE [104]
Wed Feb 02 16:48:57 2011 us=164000 UDPv4 READ [141] from xxx.xxx.xxx.xxx :5000: P_DATA_V1 kid=0 DATA len=140
Wed Feb 02 16:48:57 2011 us=164000 TUN WRITE [104]
Wed Feb 02 16:48:57 2011 us=164000 UDPv4 READ [141] from xxx.xxx.xxx.xxx :5000: P_DATA_V1 kid=0 DATA len=140
Wed Feb 02 16:48:57 2011 us=164000 TUN WRITE [104]
Wed Feb 02 16:48:57 2011 us=164000 UDPv4 READ [101] from xxx.xxx.xxx.xxx :5000: P_DATA_V1 kid=0 DATA len=100
Wed Feb 02 16:48:57 2011 us=164000 TUN WRITE [66]
Wed Feb 02 16:48:57 2011 us=164000 UDPv4 READ [101] from xxx.xxx.xxx.xxx :5000: P_DATA_V1 kid=0 DATA len=100
Wed Feb 02 16:48:57 2011 us=164000 TUN WRITE [66]
......
A suggestion to resolve this problem?
On win 7 32bit and win xp client is all ok!

Re: Route delete error on win7 64bit

Posted: Thu Feb 03, 2011 11:02 am
by maikcat
hi there,

first i would suggest to use tun instead of tap..

second

can you try to remove these:

>push "route-gateway 192.168.10.1"
>push "redirect-gateway"


what do you want to do exactly..?

cheers,

michael.

Re: Route delete error on win7 64bit

Posted: Thu Feb 03, 2011 2:14 pm
by giov
I want to connect to my office and get the ip as if I was physically in my office.
But Now I keep the ip of my internet key.
When I connect by win7 32bit or xp client I obtain my office's ip.
(many 32bit clients connect to the server without problems)

I think this is the error:
Wed Feb 02 16:48:57 2011 us=39000 C:\WINDOWS\system32\route.exe DELETE 0.0.0.0 MASK 0.0.0.0 109.113.101.164
Impossibile eliminare la route: Impossibile trovare elemento.

thanks!

Re: Route delete error on win7 64bit

Posted: Fri Feb 04, 2011 3:54 pm
by giov
I've installed openvpn-2.1.4 on two clients with Windows7, one 32bit and another 64bit.
I've set the compatibility (right click > Properties > Compatibility tab) to Windows Vista sp2 and set it to run as an administrator.
The install went fine for me, and the TAP driver is now signed in this RC.
As mentioned in the brief note, I set OpenVPN GUI Compatibility to Windows Vista sp2 and set it to run as an administrator,
otherwise any of the network level stuff (such as routing of networks) won’t work.
I put the same config.opvn in the config dir and I use a vodafone internet key.

When I connect with 32bit client is all ok.
Access to my NETWORK LAN (192.168.10.X, ecc..) is ok
Access to internet is ok and my ip is MY OFFICE IPADDRESS (http://www.whatismyip.com)

Code: Select all

----------------------------------
Wed Jan 26 11:17:06 2011 us=23000 228 variation(s) on previous 20 message(s) suppressed by --mute
Wed Jan 26 11:17:06 2011 us=23000 TEST ROUTES: 5/5 succeeded len=4 ret=1 a=0 u/d=up
Wed Jan 26 11:17:06 2011 us=23000 C:\WINDOWS\system32\route.exe ADD MY_SERVER_PUBBLIC_IP MASK 255.255.255.255 109.115.177.93
Wed Jan 26 11:17:06 2011 us=38000 ROUTE: CreateIpForwardEntry succeeded with dwForwardMetric1=25 and dwForwardType=4
Wed Jan 26 11:17:06 2011 us=38000 Route addition via IPAPI succeeded [adaptive]
Wed Jan 26 11:17:06 2011 us=38000 C:\WINDOWS\system32\route.exe DELETE 0.0.0.0 MASK 0.0.0.0 109.115.177.93
Wed Jan 26 11:17:06 2011 us=38000 Route deletion via IPAPI succeeded [adaptive]
Wed Jan 26 11:17:06 2011 us=38000 C:\WINDOWS\system32\route.exe ADD 0.0.0.0 MASK 0.0.0.0 192.168.10.1
Wed Jan 26 11:17:06 2011 us=70000 ROUTE: CreateIpForwardEntry succeeded with dwForwardMetric1=30 and dwForwardType=4
Wed Jan 26 11:17:06 2011 us=70000 Route addition via IPAPI succeeded [adaptive]
Wed Jan 26 11:17:06 2011 us=70000 C:\WINDOWS\system32\route.exe ADD 192.168.9.0 MASK 255.255.255.0 192.168.10.1
Wed Jan 26 11:17:06 2011 us=70000 ROUTE: CreateIpForwardEntry succeeded with dwForwardMetric1=30 and dwForwardType=4
Wed Jan 26 11:17:06 2011 us=70000 Route addition via IPAPI succeeded [adaptive]
Wed Jan 26 11:17:06 2011 us=70000 C:\WINDOWS\system32\route.exe ADD 192.168.11.0 MASK 255.255.255.0 192.168.10.1
Wed Jan 26 11:17:06 2011 us=85000 ROUTE: CreateIpForwardEntry succeeded with dwForwardMetric1=30 and dwForwardType=4
Wed Jan 26 11:17:06 2011 us=85000 Route addition via IPAPI succeeded [adaptive]
Wed Jan 26 11:17:06 2011 us=85000 C:\WINDOWS\system32\route.exe ADD 192.168.12.0 MASK 255.255.255.0 192.168.10.1
Wed Jan 26 11:17:06 2011 us=85000 ROUTE: CreateIpForwardEntry succeeded with dwForwardMetric1=30 and dwForwardType=4
Wed Jan 26 11:17:06 2011 us=85000 Route addition via IPAPI succeeded [adaptive]
Wed Jan 26 11:17:06 2011 us=85000 C:\WINDOWS\system32\route.exe ADD 192.168.14.0 MASK 255.255.255.0 192.168.10.1
Wed Jan 26 11:17:06 2011 us=85000 ROUTE: CreateIpForwardEntry succeeded with dwForwardMetric1=30 and dwForwardType=4
Wed Jan 26 11:17:06 2011 us=85000 Route addition via IPAPI succeeded [adaptive]
Wed Jan 26 11:17:06 2011 us=85000 Initialization Sequence Completed

When I connect with 64bit client isn't ok.
Access to my NETWORK LAN (192.168.10.X, ecc..) is ok
Access to internet isn't ok

Code: Select all

Fri Feb 04 15:52:41 2011 us=36000 248 variation(s) on previous 20 message(s) suppressed by --mute
Fri Feb 04 15:52:41 2011 us=36000 TEST ROUTES: 5/5 succeeded len=4 ret=1 a=0 u/d=up
Fri Feb 04 15:52:41 2011 us=36000 C:\WINDOWS\system32\route.exe ADD MY_SERVER_PUBBLIC_IP MASK 255.255.255.255 109.113.160.224
Fri Feb 04 15:52:41 2011 us=36000 ROUTE: CreateIpForwardEntry succeeded with dwForwardMetric1=25 and dwForwardType=4
Fri Feb 04 15:52:41 2011 us=36000 Route addition via IPAPI succeeded [adaptive]
Fri Feb 04 15:52:41 2011 us=36000 C:\WINDOWS\system32\route.exe DELETE 0.0.0.0 MASK 0.0.0.0 109.113.160.224
Fri Feb 04 15:52:41 2011 us=52000 Route deletion via IPAPI succeeded [adaptive]
Fri Feb 04 15:52:41 2011 us=52000 C:\WINDOWS\system32\route.exe ADD 0.0.0.0 MASK 0.0.0.0 192.168.10.1
Fri Feb 04 15:52:41 2011 us=83000 ROUTE: route addition failed using CreateIpForwardEntry: Uno o più argomenti non validi.   [status=160 if_index=25]
Fri Feb 04 15:52:41 2011 us=83000 Route addition via IPAPI failed [adaptive]
Fri Feb 04 15:52:41 2011 us=83000 Route addition fallback to route.exe
 OK
Fri Feb 04 15:52:41 2011 us=130000 C:\WINDOWS\system32\route.exe ADD 192.168.9.0 MASK 255.255.255.0 192.168.10.1
Fri Feb 04 15:52:41 2011 us=161000 ROUTE: route addition failed using CreateIpForwardEntry: Uno o più argomenti non validi.   [status=160 if_index=25]
Fri Feb 04 15:52:41 2011 us=161000 Route addition via IPAPI failed [adaptive]
Fri Feb 04 15:52:41 2011 us=161000 Route addition fallback to route.exe
 OK
Fri Feb 04 15:52:41 2011 us=192000 C:\WINDOWS\system32\route.exe ADD 192.168.11.0 MASK 255.255.255.0 192.168.10.1
Fri Feb 04 15:52:41 2011 us=223000 ROUTE: route addition failed using CreateIpForwardEntry: Uno o più argomenti non validi.   [status=160 if_index=25]
Fri Feb 04 15:52:41 2011 us=223000 Route addition via IPAPI failed [adaptive]
Fri Feb 04 15:52:41 2011 us=223000 Route addition fallback to route.exe
 OK
Fri Feb 04 15:52:41 2011 us=255000 C:\WINDOWS\system32\route.exe ADD 192.168.12.0 MASK 255.255.255.0 192.168.10.1
Fri Feb 04 15:52:41 2011 us=286000 ROUTE: route addition failed using CreateIpForwardEntry: Uno o più argomenti non validi.   [status=160 if_index=25]
Fri Feb 04 15:52:41 2011 us=286000 Route addition via IPAPI failed [adaptive]
Fri Feb 04 15:52:41 2011 us=286000 Route addition fallback to route.exe
 OK
Fri Feb 04 15:52:41 2011 us=301000 C:\WINDOWS\system32\route.exe ADD 192.168.14.0 MASK 255.255.255.0 192.168.10.1
Fri Feb 04 15:52:41 2011 us=333000 ROUTE: route addition failed using CreateIpForwardEntry: Uno o più argomenti non validi.   [status=160 if_index=25]
Fri Feb 04 15:52:41 2011 us=333000 Route addition via IPAPI failed [adaptive]
Fri Feb 04 15:52:41 2011 us=333000 Route addition fallback to route.exe
 OK
Fri Feb 04 15:52:41 2011 us=364000 Initialization Sequence Completed
When I connect with 64bit client after adding two parameters
(route-method exe and route-delay 2)

Access to my NETWORK LAN (192.168.10.X, ecc..) is ok
Access to internet is ok but my ip is MY VODAFONE INTERNET KEY IP ADDRESS (http://www.whatismyip.com)

Code: Select all

Fri Feb 04 16:17:16 2011 us=41000 126 variation(s) on previous 20 message(s) suppressed by --mute
Fri Feb 04 16:17:16 2011 us=41000 TEST ROUTES: 5/5 succeeded len=4 ret=1 a=0 u/d=up
Fri Feb 04 16:17:16 2011 us=41000 C:\WINDOWS\system32\route.exe ADD MY_SERVER_PUBBLIC_IP MASK 255.255.255.255 109.115.202.235
 OK
Fri Feb 04 16:17:16 2011 us=57000 C:\WINDOWS\system32\route.exe DELETE 0.0.0.0 MASK 0.0.0.0 109.115.202.235
Impossibile eliminare la route: Impossibile trovare elemento.
Fri Feb 04 16:17:16 2011 us=88000 C:\WINDOWS\system32\route.exe ADD 0.0.0.0 MASK 0.0.0.0 192.168.10.1
 OK
Fri Feb 04 16:17:16 2011 us=119000 C:\WINDOWS\system32\route.exe ADD 192.168.9.0 MASK 255.255.255.0 192.168.10.1
 OK
Fri Feb 04 16:17:16 2011 us=135000 C:\WINDOWS\system32\route.exe ADD 192.168.11.0 MASK 255.255.255.0 192.168.10.1
 OK
Fri Feb 04 16:17:16 2011 us=166000 C:\WINDOWS\system32\route.exe ADD 192.168.12.0 MASK 255.255.255.0 192.168.10.1
 OK
Fri Feb 04 16:17:16 2011 us=197000 C:\WINDOWS\system32\route.exe ADD 192.168.14.0 MASK 255.255.255.0 192.168.10.1
 OK
Fri Feb 04 16:17:16 2011 us=213000 Initialization Sequence Completed
I want obtain the same scenario of 32bit with 64bit client.
Please help me.

Re: Route delete error on win7 64bit

Posted: Mon Feb 07, 2011 3:40 pm
by giov
Nobody helps me?

Re: Route delete error on win7 64bit

Posted: Thu Feb 10, 2011 10:07 am
by maikcat
hi there,

because i currently dont have win7 x64 to try openvpn on,
can you install win7 x64 and test your setup..?

cheers,

michael.

Re: Route delete error on win7 64bit

Posted: Thu Feb 10, 2011 10:21 am
by giov
maikcat wrote:hi there,

because i currently dont have win7 x64 to try openvpn on,
can you install win7 x64 and test your setup..?

cheers,

michael.
What? I do not understand... I already install win7 x64bit and I have the problem describes obove.

Re: Route delete error on win7 64bit

Posted: Thu Feb 10, 2011 10:35 am
by janjust
try using
push "redirect-gateway def1"
instead of just
push "redirect-gateway"

also, without the "def1" OpenVPN first tries to delete the existing default route but it seems that this fails on Win7 64bit (this is where the

Code: Select all

Impossibile eliminare la route: Impossibile trovare elemento.
comes from) What is the routing table before OpenVPN starts?

Re: Route delete error on win7 64bit

Posted: Thu Feb 10, 2011 10:36 am
by maikcat
i didnt express it correctly..

i would have wrote:

can you made a fresh install of win7 x64 (no apps) and try it?

michael.

Re: Route delete error on win7 64bit

Posted: Thu Feb 10, 2011 10:37 am
by janjust
try using

Code: Select all

  push "redirect-gateway def1"
instead of just
push "redirect-gateway"
also, post the routing table before OpenVPN starts - it seems OpenVPN has trouble determining what the default GW is.

HTH,

JJK