Tue Sep 22 10:56:45 2015 TAP-Win32 Driver Version 9.8
Tue Sep 22 10:56:45 2015 TAP-Win32 MTU=1500
Tue Sep 22 10:56:45 2015 Notified TAP-Win32 driver to set a DHCP IP/netmask of 193.168.100.6/255.255.255.0 on interface {FC0EF599-16D1-4496-96FE-4B5E38804B80} [DHCP-serv: 193.168.100.0, lease-time: 31536000]
Tue Sep 22 10:56:45 2015 Successful ARP Flush on interface [23] {FC0EF599-16D1-4496-96FE-4B5E38804B80}
Tue Sep 22 10:56:50 2015 TEST ROUTES: 1/1 succeeded len=0 ret=1 a=0 u/d=up
Tue Sep 22 10:56:50 2015 C:\WINDOWS\system32\route.exe ADD 139.129.128.133 MASK 255.255.255.255 100.64.22.146
Tue Sep 22 10:56:50 2015 ROUTE: CreateIpForwardEntry succeeded with dwForwardMetric1=20 and dwForwardType=4
Tue Sep 22 10:56:50 2015 Route addition via IPAPI succeeded [adaptive]
Tue Sep 22 10:56:50 2015 C:\WINDOWS\system32\route.exe ADD 0.0.0.0 MASK 128.0.0.0 193.168.100.1
Tue Sep 22 10:56:50 2015 ROUTE: route addition failed using CreateIpForwardEntry: 至少有一个参数不正确。 [status=160 if_index=23]
Tue Sep 22 10:56:50 2015 Route addition via IPAPI failed [adaptive]
Tue Sep 22 10:56:50 2015 Route addition fallback to route.exe
操作完成!
Tue Sep 22 10:56:50 2015 C:\WINDOWS\system32\route.exe ADD 128.0.0.0 MASK 128.0.0.0 193.168.100.1
Tue Sep 22 10:56:50 2015 ROUTE: route addition failed using CreateIpForwardEntry: 至少有一个参数不正确。 [status=160 if_index=23]
Tue Sep 22 10:56:50 2015 Route addition via IPAPI failed [adaptive]
Tue Sep 22 10:56:50 2015 Route addition fallback to route.exe
操作完成!
Tue Sep 22 10:56:50 2015 Initialization Sequence Completed
Tue Sep 22 10:56:59 2015 Replay-window backtrack occurred [1] 很多程序现在都没有Windows 7的版本,很多都要用兼容Windows XP的模式安装和使用,OpenVPN的Windows客户端就是这样的。安装文件要在属性选择中的兼容性选择Windows XP和以管理员的身份运行,安装好的运行文件也同样选择这两个选项。如果还是不能连接到VPN的网络,需要在配置文件中加入(client.ovpn文件末尾添加这两行就可以了):
route-method exe
route-delay 2
这样才能正确的在机器中添加路由,否则会在Log文件中看到类似的信息:
ROUTE: route addition failed using CreateIpForwardEntry: 至少有一个参数不正确。 Route addition via IPAPI failed 这两个openvpn命令的参数解释如下: --route-method m
Which method m to use for adding routes on Windows? ipapi (default) -- Use IP helper API.
exe -- Call the route.exe shell command.
--route-delay [n] [w]
Delay n seconds (default=0) after connection establishment, before adding routes. If n is 0, routes will be added immediately upon
connection establishment. If --route-delay is omitted, routes will be added immediately after TUN/TAP device open and --up scrip{过滤}t execution, before any --user or --group privilege downgrade (or --chroot execution.)
This option is designed to be useful in scenarios where DHCP is used to set tap adapter addresses. The delay will give the DHCP handshake time to complete before routes are added.
On Windows, --route-delay tries to be more intelligent by waiting w seconds (w=30 by default) for the TAP-Win32 adapter to come up before adding routes.
|