Page 1 of 1

OpenVPN connection sometimes failed with unknown reason

Posted: Tue Aug 08, 2017 7:25 am
by Lordtakehu
Hi all,
I have a SoftEther VPN server which run OpenVPN (softether-vpnserver-v4.22-9634-beta-2016.11.27-linux-x64-64bit.tar.gz) installed on CentOS 6. The DHCP server is the external one. VPN connection is good in generally but the connection sometimes failed because the unknown reason relate to the response info or something.
I can observe the output log from server_log/ when connection failed is:
<<
2017-08-08 13:54:52.195 OpenVPN Session 290 (***A:56840 -> ***B:1194): A new session is created. Protocol: UDP
2017-08-08 13:54:52.195 OpenVPN Session 290 (***A:56840 -> ***B:1194) Channel 0: A new channel is created.
2017-08-08 13:54:53.190 OpenVPN Session 290 (***A:56840 -> ***B:1194) Channel 0: A new channel is created.
2017-08-08 13:54:54.196 OpenVPN Session 290 (***A:56840 -> ***B:1194) Channel 0: A new channel is created.
2017-08-08 13:54:55.202 OpenVPN Session 290 (***A:56840 -> ***B:1194) Channel 0: A new channel is created.
2017-08-08 13:54:56.208 OpenVPN Session 290 (***A:56840 -> ***B:1194) Channel 0: A new channel is created.
2017-08-08 13:54:57.214 OpenVPN Session 290 (***A:56840 -> ***B:1194) Channel 0: A new channel is created.
2017-08-08 13:54:58.219 OpenVPN Session 290 (***A:56840 -> ***B:1194) Channel 0: A new channel is created.
2017-08-08 13:54:59.225 OpenVPN Session 290 (***A:56840 -> ***B:1194) Channel 0: A new channel is created.
2017-08-08 13:55:00.261 OpenVPN Session 290 (***A:56840 -> ***B:1194) Channel 0: A new channel is created.
2017-08-08 13:55:01.237 OpenVPN Session 290 (***A:56840 -> ***B:1194) Channel 0: A new channel is created.
2017-08-08 13:55:02.202 OpenVPN Session 291 (***A:64018 -> ***B:1194): A new session is created. Protocol: UDP
2017-08-08 13:55:02.202 OpenVPN Session 291 (***A:64018 -> ***B:1194) Channel 0: A new channel is created.
2017-08-08 13:55:03.198 OpenVPN Session 291 (***A:64018 -> ***B:1194) Channel 0: A new channel is created.
2017-08-08 13:55:04.204 OpenVPN Session 291 (***A:64018 -> ***B:1194) Channel 0: A new channel is created.
2017-08-08 13:55:05.209 OpenVPN Session 291 (***A:64018 -> ***B:1194) Channel 0: A new channel is created.
2017-08-08 13:55:06.205 OpenVPN Session 291 (***A:64018 -> ***B:1194) Channel 0: A new channel is created.
2017-08-08 13:55:07.211 OpenVPN Session 291 (***A:64018 -> ***B:1194) Channel 0: A new channel is created.
2017-08-08 13:55:08.206 OpenVPN Session 291 (***A:64018 -> ***B:1194) Channel 0: A new channel is created.
2017-08-08 13:55:09.212 OpenVPN Session 291 (***A:64018 -> ***B:1194) Channel 0: A new channel is created.
2017-08-08 13:55:10.228 OpenVPN Session 291 (***A:64018 -> ***B:1194) Channel 0: A new channel is created.
2017-08-08 13:55:11.234 OpenVPN Session 291 (***A:64018 -> ***B:1194) Channel 0: A new channel is created.
2017-08-08 13:55:11.335 OpenVPN Session 286 (***A:52350 -> ***B:1194): Deleting the session.
2017-08-08 13:55:11.496 The connection with the client (IP address ***A, Port number 52350) has been disconnected.
>>

where the success connection should be:
<<
2017-08-08 14:07:19.537 OpenVPN Session 11 (***A:64308 -> ***B:1194): A new session is created. Protocol: UDP
2017-08-08 14:07:19.537 OpenVPN Session 11 (***A:64308 -> ***B:1194) Channel 0: A new channel is created.
2017-08-08 14:07:19.537 OpenVPN Session 11 (***A:64308 -> ***B:1194) Channel 0: A new channel is created.
2017-08-08 14:07:19.578 OpenVPN Session 11 (***A:64308 -> ***B:1194) Channel 0: Option Strings Received: "V4,dev-type tun,link-mtu 1557,tun-mtu 1500,proto UDPv4,cipher AES-128-CBC,auth SHA1,keysize 128,key-method 2,tls-client"
2017-08-08 14:07:19.588 OpenVPN Session 11 (***A:64308 -> ***B:1194) Channel 0: Option Strings to Send: "V4,dev-type tun,link-mtu 1557,tun-mtu 1500,proto UDPv4,cipher AES-128-CBC,auth SHA1,keysize 128,key-method 2,tls-server"
2017-08-08 14:07:19.588 On the TCP Listener (Port 0), a Client (IP address ***A, Host name "***A", Port number 64308) has connected.
2017-08-08 14:07:19.588 For the client (IP address: ***A, host name: "***A", port number: 64308), connection "CID-5" has been created.
2017-08-08 14:07:19.588 SSL communication for connection "CID-5" has been started. The encryption algorithm name is "(null)".
2017-08-08 14:07:19.588 [HUB "CentOS VPN"] The connection "CID-5" (IP address: ***A, Host name: ***A, Port number: 64308, Client name: "OpenVPN Client", Version: 4.22, Build: 9634) is attempting to connect to the Virtual Hub. The auth type provided is "External server authentication" and the user name is "******".
2017-08-08 14:07:21.891 [HUB "CentOS VPN"] Connection "CID-5": Successfully authenticated as user "******".
>>

I tried to reinstall the VPN but this issue sometimes happens. Can anyone give me a clue or another VPN related log so that I can investigate more on this? Thank you.

Re: OpenVPN connection sometimes failed with unknown reason

Posted: Thu Aug 17, 2017 6:15 am
by thisjun
Could you try to use TCP connection?

Re: OpenVPN connection sometimes failed with unknown reason

Posted: Fri Aug 25, 2017 9:37 am
by Lordtakehu
Seems the SecureNAT in my system has problem, I added new static route and it works now. Thank you all.