Jump to content

RCON times out 88% of the time when using "rcon" pip package


TomyLobo

Recommended Posts

  • 41.65
  • Multiplayer.
  • Dedicated.
  • No.
  • Reproduction steps:
pip install rcon
rconclt <my rcon password>@127.0.0.1:27033 help

The rconclt command hangs forver in about half of the cases.
server log when it succeeds:
 

LOG  : General     , 1645268810174> 1,664,515> RCON: new connection Socket[addr=/127.0.0.1,port=54546,localport=27033]
LOG  : General     , 1645268810176> 1,664,517> RCON: ID=1393758552 Type=3 Body='<my rcon password>' Socket[addr=/127.0.0.1,port=54546,localport=27033]
LOG  : General     , 1645268810177> 1,664,518> RCON: ID=252286249 Type=2 Body='help' Socket[addr=/127.0.0.1,port=54546,localport=27033]
LOG  : General     , 1645268810229> 1,664,570> help
LOG  : General     , 1645268810278> 1,664,619> RCON: connection closed Socket[addr=/127.0.0.1,port=54546,localport=27033]

server log when it fails:
 

LOG  : General     , 1645268909960> 1,764,301> RCON: new connection Socket[addr=/127.0.0.1,port=54550,localport=27033]
LOG  : General     , 1645268909961> 1,764,302> RCON: ID=1006733196 Type=3 Body='<my rcon password>' Socket[addr=/127.0.0.1,port=54550,localport=27033]

I ran it 100 times (with a timeout of 1s) and it timed out 88 out of 100 attempts.

I ran it 1000 times (with a timeout of 300ms) and it timed out 891 out of 1000 attempts.

 

Using https://github.com/gorcon/rcon-cli, it works every single time.

So there must be some incompatibility specifically with the rcon client from the pip package.

Edited by TomyLobo
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...