v2ray-plugin icon indicating copy to clipboard operation
v2ray-plugin copied to clipboard

Connection stays ESTABLISHED forever

Open liujunhui2 opened this issue 6 years ago • 4 comments

At server side, there are TCP connections that stay in ESTABLISHED state and they will never change unless the service is restarted. It seems that when the client switches networks (e.g. LTE <-> WIFI), the current established connection will be forgotten and left untouched at the server side.

A potential solution may be enabling the socket keepalive option.

liujunhui2 avatar Mar 22 '19 01:03 liujunhui2

@VictoriaRaymond Is it possible that it's a socket leak? I think this kind of connection will be closed after a timeout?

madeye avatar Mar 22 '19 03:03 madeye

BTW I set mux=2 at the client side, though I don't know what's the significance.

liujunhui2 avatar Mar 22 '19 05:03 liujunhui2

Does this cause any real problems tho?

Mygod avatar Jun 20 '19 14:06 Mygod

The number of connections keep increasing. I usually restart ss before the connection number exceeds 200. Now I have added nginx as the front end, this problem does not bother me for the time being.

liujunhui2 avatar Jun 21 '19 06:06 liujunhui2