How to make OpenVPN connection unstuck from MANAGEMENT: >STATE:1668905555,TCP_CONNECT?

Official client software for OpenVPN Access Server and OpenVPN Cloud.
Post Reply
witchraider
OpenVpn Newbie
Posts: 1
Joined: Sat Nov 19, 2022 1:59 pm

How to make OpenVPN connection unstuck from MANAGEMENT: >STATE:1668905555,TCP_CONNECT?

Post by witchraider » Sat Nov 19, 2022 2:00 pm

I use OpenVPN UDP over SOCKS5 proxy.
most of the time it works, but sometimes it gets stuck in this state when I'm not using PC:

Sun Nov 20 01:22:35 2022 Socket Buffers: R=[65536->65536] S=[65536->65536]
Sun Nov 20 01:22:35 2022 Attempting to establish TCP connection with [AF_INET]127.0.0.1:10808 [nonblock]
Sun Nov 20 01:22:35 2022 MANAGEMENT: >STATE:1668905555,TCP_CONNECT,,,,,,

and stays at that state for minutes, the only way I can fix it is by manually clicking on reconnect button, but I want this to be done automatically. I want to give this state only 5 seconds and then auto reconnect after it, without my intervention.

https://i.imgur.com/09wLWBL.png

How can I achieve that?

here is my OpenVPN Config file

verb 4
client
windows-driver wintun
tls-client
script-security 2
remote-cert-tls server
dev tun
nobind
persist-key
persist-tun
comp-lzo yes
cipher AES-256-CBC
ping 10
ping-restart 30

remote [DOMAIN] 1196 udp

auth-user-pass

redirect-gateway def1 ipv6
register-dns
block-outside-dns
socks-proxy 127.0.0.1 10808
connect-retry 2 3

auth-user-pass userpass.txt

<ca>
-----BEGIN CERTIFICATE-----
Bunch of text
-----END CERTIFICATE-----
</ca>


The SOCKS5 proxy I'm using comes from a software installed on my PC, I've already set a persistent route in Windows routing table for its server's IP address to go directly through my Internet using my router's default gateway, so it won't be interrupted by VPN connection or go through VPN connection again.

User avatar
ordex
OpenVPN Inc.
Posts: 444
Joined: Wed Dec 28, 2016 2:32 am
Location: IRC #openvpn-devel @ libera.chat

Re: How to make OpenVPN connection unstuck from MANAGEMENT: >STATE:1668905555,TCP_CONNECT?

Post by ordex » Tue Nov 29, 2022 9:53 pm

Maybe --server-poll-timeout can help you. But I haven't tested how it works on windows with TCP.

Post Reply