Page 1 of 1

Windows Client Keeps Disconnecting

Posted: Mon Aug 21, 2023 3:39 pm
by lpd7
I am running OPV on a PFSense box using IOS and Windows clients, this issue is isolated to Windows Only.

The client is continually connecting/disconnecting and as I am new to OPV just having finally got it running on my PFS box.

From what I can glean it seems that ping may be an issue but again this is a newbies view.

Below is the log from my last connection any input to resolve would be appreciated.


Initial Connection Log Info:
2023-08-21 10:58:14 OpenVPN 2.6.5 [git:v2.6.5/cbc9e0ce41] Windows-MSVC [SSL (OpenSSL)] [LZO] [LZ4] [PKCS11] [AEAD] [DCO] built on Jun 13 2023
2023-08-21 10:58:14 Windows version 10.0 (Windows 10 or greater), amd64 executable
2023-08-21 10:58:14 library versions: OpenSSL 3.1.1 30 May 2023, LZO 2.10
2023-08-21 10:58:14 DCO version: v0
2023-08-21 10:58:19 TCP/UDP: Preserving recently used remote address: [AF_INET]xxx.xxx.114.11:1194
2023-08-21 10:58:19 UDPv4 link local: (not bound)
2023-08-21 10:58:19 UDPv4 link remote: [AF_INET]xxx.xxx.114.11:1194
2023-08-21 10:58:19 WARNING: this configuration may cache passwords in memory -- use the auth-nocache option to prevent this
2023-08-21 10:58:19 [My Open VPN Server CA] Peer Connection Initiated with [AF_INET]xxx.xxx.114.11:1194
2023-08-21 10:58:21 open_tun
2023-08-21 10:58:21 tap-windows6 device [OpenVPN TAP-Windows6] opened
2023-08-21 10:58:21 Set TAP-Windows TUN subnet mode network/local/netmask = xxx.xxx.200.0/xxx.xxx.200.2/255.255.248.0 [SUCCEEDED]
2023-08-21 10:58:21 Notified TAP-Windows driver to set a DHCP IP/netmask of xxx.xxx.200.2/255.255.248.0 on interface {76F2C53E-0B07-4178-A847-694E} [DHCP-serv: xxx.xxx.200.0, lease-time: 31536000]
2023-08-21 10:58:21 Successful ARP Flush on interface [12] {76F2C53E-0B07-4178-A847-694E}
2023-08-21 10:58:21 IPv4 MTU set to 1500 on interface 12 using service
2023-08-21 10:58:26 Initialization Sequence Complete

Log After Reset:
2023-08-21 11:00:39 [My Open VPN Server CA] Inactivity timeout (--ping-restart), restarting
2023-08-21 11:00:39 SIGUSR1[soft,ping-restart] received, process restarting
2023-08-21 11:00:40 TCP/UDP: Preserving recently used remote address: [AF_INET]xxx.xxx.114.11:1194
2023-08-21 11:00:40 UDPv4 link local: (not bound)
2023-08-21 11:00:40 UDPv4 link remote: [AF_INET]xxx.xxx.114.11:1194
2023-08-21 11:00:40 [My Open VPN Server CA] Peer Connection Initiated with [AF_INET]xxx.xxx.114.11:1194
2023-08-21 11:00:42 Preserving previous TUN/TAP instance: OpenVPN TAP-Windows6
2023-08-21 11:00:42 Initialization Sequence Completed
2023-08-21 11:02:41 [My Open VPN Server CA] Inactivity timeout (--ping-restart), restarting
2023-08-21 11:02:41 SIGUSR1[soft,ping-restart] received, process restarting
2023-08-21 11:02:42 TCP/UDP: Preserving recently used remote address: [AF_INET]xxx.xxx.114.11:1194
2023-08-21 11:02:42 UDPv4 link local: (not bound)
2023-08-21 11:02:42 UDPv4 link remote: [AF_INET]xxx.xxx.114.11:1194
2023-08-21 11:02:43 [My Open VPN Server CA] Peer Connection Initiated with [AF_INET]xxx.xxx.114.11:1194
2023-08-21 11:02:43 Preserving previous TUN/TAP instance: OpenVPN TAP-Windows6
2023-08-21 11:02:43 Initialization Sequence Completed

Additional Log Info:
2023-08-21 11:04:04 SIGTERM received, sending exit notification to peer
2023-08-21 11:04:05 SIGTERM[soft,exit-with-notification] received, process exiting

Re: Windows Client Keeps Disconnecting

Posted: Tue Aug 22, 2023 2:38 am
by openvpn_inc
Hello,

In order to ensure that the connection is continuing to work properly you can tell OpenVPN to do a type of internal ping to check if the connection is actually really working. In your case it seems to not be.

2023-08-21 11:02:41 SIGUSR1[soft,ping-restart] received, process restarting

ping-restart is the directive that tells OpenVPN to do this internal pinging, and, if it fails repeatedly, trigger a reconnect to try to get the failed connection working again.

So it looks like some firewall or bad connection that is preventing the connection from working correctly.

I am not sure what to advise you other than trying to find out what's blocking this and fixing that.

Kind regards,
Johan

Re: Windows Client Keeps Disconnecting

Posted: Wed Aug 23, 2023 6:10 pm
by lpd7
openvpn_inc wrote:
Tue Aug 22, 2023 2:38 am
Hello,

In order to ensure that the connection is continuing to work properly you can tell OpenVPN to do a type of internal ping to check if the connection is actually really working. In your case it seems to not be.

2023-08-21 11:02:41 SIGUSR1[soft,ping-restart] received, process restarting

ping-restart is the directive that tells OpenVPN to do this internal pinging, and, if it fails repeatedly, trigger a reconnect to try to get the failed connection working again.

So it looks like some firewall or bad connection that is preventing the connection from working correctly.

I am not sure what to advise you other than trying to find out what's blocking this and fixing that.

Kind regards,
Johan
Thank you for the insight. As I am new to this can you recommend where to start and what I would be looking for? Also why would this not be an issue for the iOS device assuming the ping is also a part of that operation/functionality as well?

Re: Windows Client Keeps Disconnecting

Posted: Thu Aug 24, 2023 12:44 pm
by imjebran
Hello,

Is your windows VPN client and iOS client behind the same network? if so, there could be a directive as a reason. Did you try listening to your OpenVPN server on a different port?

Regards,
Jebran.