我在 上有一个工作OpenVPN
配置Windows 7
。我可以通过 GUI 以及命令行 ( openvpn --config .\openvpn.ovpn
) 连接到它。
这是配置文件:
## acme.ovpn ##
client
proto tcp
dev tun
persist-key
persist-tun
ca ca.crt
cert mycert.crt
key mykey.key
remote <REMOTE_IP> 443
route <SOME_OTHER_IP> 255.255.255.0
resolv-retry infinite
status openvpn-status.log
verb 3
我将所有配置文件复制到一个EC2
实例中RHEL 7.3
,然后安装 openvpn。但是,当我尝试运行sudo openvpn --config ./openvpn.ovpn
) 时,跟踪最终显示
Wed Feb 8 14:52:27 2017 Restart pause, 5 second(s)
Wed Feb 8 14:52:32 2017 WARNING: No server certificate verification method has been enabled. See http://openvpn.net/howto.html#mitm for more info.
Wed Feb 8 14:52:32 2017 Socket Buffers: R=[87380->87380] S=[16384->16384]
Wed Feb 8 14:52:32 2017 Attempting to establish TCP connection with [AF_INET]<OPENVPN_IP>:443 [nonblock]
Wed Feb 8 14:52:42 2017 TCP: connect to [AF_INET]<OPENVPN_IP>:443 failed, will try again in 5 seconds: Connection timed out
Wed Feb 8 14:52:57 2017 TCP: connect to [AF_INET]<OPENVPN_IP>:443 failed, will try again in 5 seconds: Connection timed out
Wed Feb 8 14:53:13 2017 TCP: connect to [AF_INET]<OPENVPN_IP>:443 failed, will try again in 5 seconds: Connection timed out
Wed Feb 8 14:53:28 2017 TCP: connect to [AF_INET]<OPENVPN_IP>:443 failed, will try again in 5 seconds: Connection timed out
Wed Feb 8 14:53:43 2017 TCP: connect to [AF_INET]<OPENVPN_IP>:443 failed, will try again in 5 seconds: Connection timed out
Wed Feb 8 14:53:58 2017 TCP: connect to [AF_INET]<OPENVPN_IP>:443 failed, will try again in 5 seconds: Connection timed out
请注意,EC2 实例只是一个 openvpn 客户端,而不是服务器,这已经被误解了。我正尝试从它建立到服务器的连接,上面的日志占位符就是该服务器的 IP。
为什么在 Windows 7 上本地成功的相同配置在云虚拟机上会失败,我应该怎么做才能修复它?
这个问题也已被问过这里。
有关的: