jweigelt / swbf2admin

Star Wars Battlefront II (2005) server management application
GNU General Public License v3.0
51 stars 18 forks source link

Failed to connect to RCON Server #23

Closed RaTix closed 4 years ago

RaTix commented 4 years ago

I can't seem to get the rcon setup at all. When I launch the server I get the following error.

Failed to connect to rcon server at '192.168.1.210:5509' (System.Net.Sockets.SocketException (0x80004005): No connection could be made because the target machine actively refused it 192.168.1.210:5509 at System.Net.Sockets.Socket.DoConnect(EndPoint endPointSnapshot, SocketAddress socketAddress) at System.Net.Sockets.Socket.Connect(EndPoint remoteEP) at System.Net.Sockets.TcpClient.Connect(IPEndPoint remoteEP) at SWBF2Admin.Runtime.Rcon.RconClient.Start())

The game runs and I can connect and all that, but none of the dashboard stuff shows up, like players, chat, server info, etc..

jweigelt commented 4 years ago

If the port is bound properly and it still fails to connect, increase RuntimeStartDelay in core.xml to something like 3000 (this also only applies for the gog version).

RaTix commented 4 years ago

Same port and the delay got it further along. Now I'm getting "Server refused login" errors.

[8/29/2019 10:47:54 AM] INFO | Launching server with args '/win /norender /nosound /autonet dedicated /resolution 640 480' [8/29/2019 10:47:54 AM] DEBUG | Starting runtime management... [8/29/2019 10:47:55 AM] DEBUG | [WEB] Got request 'http://192.168.1.210:5500/' [8/29/2019 10:47:56 AM] DEBUG | [WEB] Got request 'http://192.168.1.210:5500/live/dashboard' [8/29/2019 10:47:57 AM] INFO | Connected to rcon server at '192.168.1.210:5510'. Sending login... [8/29/2019 10:47:57 AM] ERROR | Server refused login. [8/29/2019 10:47:57 AM] ERROR | Failed to start runtime management (Exception of type 'SWBF2Admin.Runtime.Rcon.RconNotAuthorizedException' was thrown.) [8/29/2019 10:47:58 AM] WARN | Server has crashed. [8/29/2019 10:47:58 AM] DEBUG | Stopping runtime management... [8/29/2019 10:47:58 AM] INFO | Automatic restart is enabled. Restarting server... [8/29/2019 10:47:58 AM] INFO | Launching server with args '/win /norender /nosound /autonet dedicated /resolution 640 480' [8/29/2019 10:47:58 AM] DEBUG | Starting runtime management... [8/29/2019 10:47:58 AM] DEBUG | [WEB] Got request 'http://192.168.1.210:5500/' [8/29/2019 10:47:59 AM] DEBUG | [WEB] Got request 'http://192.168.1.210:5500/live/dashboard' [8/29/2019 10:48:01 AM] INFO | Connected to rcon server at '192.168.1.210:5510'. Sending login... [8/29/2019 10:48:01 AM] ERROR | Server refused login. [8/29/2019 10:48:01 AM] ERROR | Failed to start runtime management (Exception of type 'SWBF2Admin.Runtime.Rcon.RconNotAuthorizedException' was thrown.) [8/29/2019 10:48:01 AM] DEBUG | [WEB] Got request 'http://192.168.1.210:5500/' [8/29/2019 10:48:01 AM] WARN | Server has crashed. [8/29/2019 10:48:01 AM] DEBUG | Stopping runtime management...

jweigelt commented 4 years ago

Make sure that an admin password is set and that it does not contain non-ASCII characters.

Please also check ./server/settings/ServerSettings.cfg and post the contents. Are you running the GOG Galaxy BattlefrontII.exe?

RaTix commented 4 years ago

That pointed me in the right direction, Thanks. I got it working.

The password I had set in the ServerSettings.cfg was 25 chars long. Once I shortened it to 8, it worked no problem. Not sure what the limit is, but definitely shorter than 25, lol.

And yes, using GOG version.