PDA

View Full Version : Bandwidth requirements for dedicated server?



M_C
3rd March 2006, 23:39
How much BW (down/up) is needed to run a decent 7 man hidden server?

AskedRelic
5th March 2006, 18:42
Hmmm, I don't know exact numbers but I can give estimates according to my bandwidth graphs from over the last month...

When my 9 person server is full, max upload is around 0.4 MBit/s, max download is around 0.2 MBits/s, so in useful terms, that is like max upload of 50kbps and max download of 25 kbps.

Honestly, it would probably be the same kind of bandwidth usage as a CS server, it's just a hidden server can only do about 9-10 people max.

And also for my server that is barely ever fully, it looks like I'm doing about 20gb of traffic monthly.

M_C
5th March 2006, 19:54
Thanks, I thought it'd use more with hidden than tfc.

Night Raider
5th March 2006, 21:56
Hidden requires more processing speed than most Source games. Many props and ragdolls are server-side, meaning that the servers are the ones that process the ragdoll locations for all clients to see.

deadscott
5th March 2006, 23:49
The minimum amount of upload bandwidth your server must have, you multiply your sv_maxrate by the number if players on the server. Thus a sv_maxrate of 20000 with 20 players will require at least 20 * 20,000 = 400,000 Bytes per Second of Bandwidth. I say at least, because your theoretical maximum upload speed is just that, theoretical, and you will find that most connections will not sustain their theorectical maximums for long periods of time, which is exactly how GameServers must operate to provide a positive end user experience.

You are going to require at least 400,000 Bytes per Second of Bandwith to serve 20 players effectively. We now need to convert this to normal Networking conventions, so we can compare apples with apples. To do this, the calculation for this example is as follows:

400,000 Bytes * 8 bits / 1,000 = 3,200 KiloBits/Second (3,200Kbps) or 400,000 Bytes * 8 bits / 1,000,000 = 3.2 Megabits/Second (3.2Mbps)

Whatever Bytes Per Second you have, you need to convert that into a bit speed, by multiplying it by 8 (8 bits = 1 Byte) and then convert that into either kilobits or megabits, by dividing by 1,000 for kilo or 1,000,000 for mega to give you a value in Kilobits per Second (Kbps) or Megabits per Second (Mbps), whichever is easier to read.

Please realise that your X Mbps connection maybe rated very close to what you need, but it is nearly always necessary to leave an overhead of between 10%-25% to make sure the server can always cope. So an sv_maxrate 20000 server with 20 players is probably going to require a 4Mbps Upstream Connection to adequately cope with the load.

sv_maxrate * {player number} * 8 / 1,000 = Minimum Upstream Speed in Kbps your server requires.

This calculation will work for mulitple SRCDS processes on the one physical server.

If you want to turn this calculation around, and wish to calculate the maximum theoretical sv_maxrate your server can run for a given upload speed (in kbps) and player number, the calculation is as follows:

upload bandwidth in kilobits per second / 8 * 1000 / player number = the theoretical maximum sv_maxrate you can run your server at.

This Calculation only works for a single SRCDS process on a single physical server.

M_C
6th March 2006, 00:29
Ok, now I know how to calculate sv_maxrate, thanks, but how low can this setting be and still provide a decent experience? Is 20k per person what is recommended or just the number used in the example? Using those numbers (20 people/3.2M) I get roughly 10 people per T1, right? That sounds high seeing as how the servers I play on keep my up/down at 2-4k/s avg, according to net_graph, which would be about 256k-512k (up) per 10 people. Maybe I'm not doing the math right or are we getting robbed? ;)

deadscott
6th March 2006, 01:04
We use an sv_maxrate 20000. This seems to be good for the majority of clients. The client can tweak their settings to match. Clients will not sustain their maximums, but we caculate our bandwidth as if they would. Our box sits at a data center in Dallas, Texas operating on a network that is fully meshed and redundant with 10 backbone providers. So for us bandwidth is not an issue.

It really depends on how much bandwidth you have available. You then adjust your sv_maxrate using the formula above. Running a box on a home cable network you might try sv_maxrate at 12000 or lower. Changing rates and tweaking usage is something only you can figure out whats best for your box. Trial and error my man.

M_C
6th March 2006, 01:13
Yeah, askrelic said his server uses 50k max for a 9 person, that's a sv_maxrate of ~5.5k per person or about 3 people per 128k up. So a 9 man server, could be ran on a pipe with an upload of 384k/s, right? I wonder what other servers set their maxrates at?

deadscott
6th March 2006, 01:18
So a 9 man server, could be ran on a pipe with an upload of 384k/s, right?

Yes, if you can get your clients to set their rates to match your servers settings.

M_C
6th March 2006, 01:26
Doesn't the server override the client setting for this, hence sv_ not cl_ or do bad client settings mess with servers?

deadscott
6th March 2006, 01:50
No, a client cannot change a servers settings.

When you play in any server type rate in your console, or check your config.cfg to see what rate your client machine is using. The rate is how fast a client is asking for information from the server, or more correctly it tells the server how fast the client can accept information from the server. This depends on the clients download speed. If a clients rate is set to high for their connection the server will be sending information faster than the client can recieve it. This will cause packet loss and GamePlay lag.

The sv_maxrate is the highest speed a server will send information. The higher the speed the more bandwidth used.

The clients rate is how fast the client can receive that information.

If you are setting up a box on a limited bandwidth situation for a group of friends or such, find the best sv_maxrate for your amount of bandwidth leaving 20-25% spare. The have your friends/clients set their rate to match. This will optimize their settings to match your servers.

The only limiter here is the amount of bandwidth you have available.

M_C
6th March 2006, 02:14
OK, so what's the default rate and what *should* it be per 512k down? Maye it'd be easier to explain the network. I have business dsl with static IP's but due to my distance from the CO I can only get 768/128 which I run small mail/web/shell servers. I also have a residential cable modem that's 3m/256k, dynamic, but I just use that as a web proxy when I need to grab something larger. I don't think they like users running game servers on the cable either. I don't think the dsl is fast enough for more than 2-3 people and, for a hidden server, that's not enough so maybe I should just proxy my client through the cable instead of running a server at all. I should tweak my client settings but I don't know what setting to use for hidden. I could copy my settings from TFC and see if they work. :D

deadscott
6th March 2006, 02:38
Your main concern here is your upload speed. The speed at which you can send clients information. The highest for you is 256k?

In general, a good rule-of-thumb is roughly 6KB (Kilo-Bytes) upstream (upload) per player slot.

M_C
6th March 2006, 02:50
The static dsl upload is just 128kb/s and the, dynamic, cable is at 256k but I don't think the cable allows game servers. Right now I play on the dsl but I *could* proxy the client and route through the cable to play. Until I move or get other options I'm stuck with what I have. ;)