Technical help on Netspeed?  (Read 7390 times)

Piglet

  • 1337
  • *
  • Posts: 3181
  • Country: gb
Technical help on Netspeed?
« on: January 05, 2020, 22:52 »
In the past the restriction we had was that the server didn't have enough CPU power. We hit 100% cpu and the game lagged.

The issue we now have on the server is that there is so much going on that the game engine cannot fit all the information you need into the messages that are sent by it to your PC.

This is a technical issue we need some help with. Here's what we've found out today:

With:

[IpDrv.TcpNetDriver]
MaxInternetClientRate=20000


1. If you start the server with 16 player slots (MaxPlayers=16) the server allows connection at 20k.  We can then add 32 bots on a box map, and the gameplay is smooth. The client connection stays at 20k and all is well.

See the last "In" line:




2. If you start the server with 20 or 32 player slots (MaxPlayers=20 or MaxPlayers=32) the server allows connection at 10k only. We can then add 32 bots on a box map, and the gameplay is laggy - there isn't enough bandwidth to get the client machines what they need.


3. If you start the server with 16 player slots (MaxPlayers=16) the server allows connection at 20k.  We can then add 32 bots on a box map, and the gameplay is smooth. If we change the maximum number of players allowed to 32 mid-game, the client connection stays at 20k and all is well.

Any ideas?

jiRNGen

  • Full Member 
  • *
  • Posts: 71
  • Country: fr
Re: Technical help on Netspeed?
« Reply #1 on: January 06, 2020, 04:47 »

THOR`

  • Sr. Member
  • *
  • Posts: 142
  • Country: gb
    • anxious_f0x
Re: Technical help on Netspeed?
« Reply #2 on: January 06, 2020, 07:09 »
Did you manage to get hold of Flak at all Piglet?

EDIT: I DM’d Tim Sweeney over on twitter asking for a little assistance, doubt he’ll respond but don’t ask don’t get right? :D
« Last Edit: January 06, 2020, 07:40 by THOR` »

Piglet

  • 1337
  • *
  • Posts: 3181
  • Country: gb
Re: Technical help on Netspeed?
« Reply #3 on: January 06, 2020, 08:56 »
I did a buddy request but didn't hear anything back.

THOR`

  • Sr. Member
  • *
  • Posts: 142
  • Country: gb
    • anxious_f0x
Re: Technical help on Netspeed?
« Reply #4 on: January 06, 2020, 09:04 »
I’ll throw a DM her way on discord sometime today as well.

Piglet

  • 1337
  • *
  • Posts: 3181
  • Country: gb
Re: Technical help on Netspeed?
« Reply #5 on: January 06, 2020, 10:14 »
I'm not sure but maybe look here:
https://unrealadmin.org/forums/showthread.php?t=29246

Ahh - no that doesn't help. The issue is that the engine dynamically changes the maximum client rate depending on the maximum number of players configured.

We want the maximum client rate on the maximum number of players.

At the moment we can have either the player numbers or the rate but not both at the same time.

We have a 200Mbps both ways connection...so there is no bandwidth issue
« Last Edit: January 06, 2020, 10:17 by Piglet »

holyspam

  • 1337
  • *
  • Posts: 329
  • Country: gr
Re: Technical help on Netspeed?
« Reply #6 on: January 06, 2020, 15:59 »
Have you put both of these in the server ini?
Code: [Select]
[IpDrv.TcpNetDriver]
MaxClientRate=20000
MaxInternetClientRate=20000


But the players need to change theirs too, or else player netspeed doesnt go to 20000
Those two above are in ut2004.ini for players and there's also these two in user.ini:
Code: [Select]
[Engine.Player]
ConfiguredInternetSpeed=20000
ConfiguredLanSpeed=20000


IIRC MaxClientRate is the maximum you send per player
MaxClientRate is the maximum for LAN servers
Maybe it needs both? No idea.

The proper way to do this, would be to re-organise all code and choose which info is needed every tick VS every X seconds/end of round/death etc


Out of curiosity, what happens at 50-60-100 players?Is there a new limit?
Maybe epic decided that <16 players is LAN and >16 is internet, so internal checks reset the speed limit
« Last Edit: January 06, 2020, 16:16 by holyspam »

Piglet

  • 1337
  • *
  • Posts: 3181
  • Country: gb
Re: Technical help on Netspeed?
« Reply #7 on: January 06, 2020, 16:24 »
Yes, the client has to up the limit too.

What I'm seeing is the server capping to 10k at over 16 players regardless of the server settings.  I'm looking for a way round that.

hagis

  • 1337
  • *
  • Posts: 404
  • Country: gb
Re: Technical help on Netspeed?
« Reply #8 on: January 06, 2020, 19:39 »
Quote
3. If you start the server with 16 player slots (MaxPlayers=16) the server allows connection at 20k.... If we change the maximum number of players allowed to 32 mid-game, the client connection stays at 20k and all is well.

is there not some hack way round this - presume on map change the 10k limit returns?

Piglet

  • 1337
  • *
  • Posts: 3181
  • Country: gb
Re: Technical help on Netspeed?
« Reply #9 on: January 06, 2020, 20:47 »
We could write something which sets the player count to 16 at map end, and 32 at map start. I have no idea when it decides the max netspeed and how that would work for players joining.

We can't be the first people to have this issue, but I can't find anything similar on the internet

THOR`

  • Sr. Member
  • *
  • Posts: 142
  • Country: gb
    • anxious_f0x
Re: Technical help on Netspeed?
« Reply #10 on: January 09, 2020, 05:53 »
I had a little chat with Stolid (anxious_d0g) about this and this is what he had to say.

Quote
ive never heard of that before, but then i never did anything with large playercounts.
i doubt there is an easy way to set it to not do that, but since you can change it to 20k mid game you can write a simple mutator to set it like that a second after the game has started. while youre at it you can make it force any client to 20k too at the same time so that people dont have to know about the need for that and it all just works as intended.

Would a mutator like that be possible?

Piglet

  • 1337
  • *
  • Posts: 3181
  • Country: gb
Re: Technical help on Netspeed?
« Reply #11 on: January 10, 2020, 09:42 »
I've written a serveractor to fix the problem at the server end.

The first version I did I tried to update the client too - however:

1. It didn't work by either of these two methods, done from the server end. It may need some other method, or it being done from a client class rather than from the server:

var PlayerController PC;
... PC.ConsoleCommand("netspeed 20000");
or ... PC.Player.ConfiguredInternetSpeed = 20000;

2. I'm not entirely comfortable setting the client speed. The player may have bandwidth limitations. They may be paying for network usage and not wanting increased usage. They may have a lower power computer that would work less well with more information to process.

For now players have to run the command or bind it to a key as per the information I put on the front page of this site