Server Redirects & Download Speeds

netspeedWhy is the speed so bad when downloading maps?

 

When switching to a map that the player actually lacks, the server can offer it as a downloadable file, meaning the player can sit back and let it download into the client-side cache, then recommence play.

There are two downloadable locations:

  1. the gaming server itself
  2. a redirect server

 

The most obvious place would be the gaming server which already has the files needed, but herein lies the problem:

  • downloading from within UT (using the UChannels) is speed-limited, according to a couple of settings
  • downloading from the gaming server impacts upon bandwidth for other gamers, causing initial gameplay lag until all players have completed downloading pre-requisite files

no-redirectHence the idea of the redirect, a separate repository that can serve up these files upon demand, sitting to one side of the gaming server.  Having a redirect offers a few advantages:

  • downloads from redirect servers go through a direct TCP Link, not a UChannel, meaning faster speeds possible
  • bandwidth demands are moved away from the gaming server, meaning no adverse impact upon initial gameplay
  • the files hosted can be compressed for faster download and space-saving concerns.

redirect

So why not offer everything on a redirect? Two major concerns are:

  • the cost of running another server – traditionally this represented a serious investment for committed server owners.
  • the effort of ensuring files were duplicated and available upon the redirect

This last one represented the biggest hurdle: responsibility for providing the map is delegated out to the redirect server; when the gaming server switches to a map and required files are missing on the redirect server, the original gaming server may not offer to provide content it already had (depending upon the “AllowDownloads” server-side setting).

Setting Up Your Server To Use A Redirect

Using a redirect is a server-side setting: the UT server states the location of the redirect, for example:

[IpDrv.HTTPDownload]
RedirectToURL=http://ut.filedump.net:32000/assets/
UseCompression=False

[IpDrv.TcpNetDriver]
AllowDownloads=True

The client visits there to obtain content: for example if WetCona.utx was a required file, the client attempts to fetch http://ut.filedump.net:32000/assets/WetCona.utx and caches it locally.

Testing

To test, rename (or delete) a certain map, then connect to the server and have it switch to this map (using mapvote or some other control panel system). The missing map should then begin to download, and once complete an 200status entry shows in the webserver logs, for example:

192.168.20.82 - - "GET /assets/CTF-NuggetLove.ut2 HTTP/1.1" 200 4323627 "-" "Unreal"

A common mistake is mismatching case for the file – if the name differs from the request, a 404-status (“file not found”) error is generated:

192.168.20.82 - - "GET /assets/CTF-nuggetlove.ut2 HTTP/1.1" 404 4323627 "-" "Unreal"

This is presented to the player in-game as an alarming disconnect message about being unable to download that file. There’s not a great deal they can do about it other than sit that game out or seek out another download site, which really should be the purpose of our redirect.

Compression

This is a prickly topic: UseCompression=True requires all files to be compressed using the ucc-bin tool first, meaning that all the compressed files have a .uz additional file extension, which the server searches for. If this is enabled but the map is missing, the webserver logs will show a 404-status error:

192.168.20.82 - - "GET /assets/CTF-NuggetLove.ut2.uz HTTP/1.1" 404 242 "-" "Unreal"

Sadly, the server will not fall back to the uncompressed version if found – it simply looks for that matching filename and gives up on unmet requirements, presenting the player with the same in-game error message.

Server Fallback

This can be useful (or a curse, depending upon your viewpoint) – setting AllowDownloads=True in the [IpDrv.TcpNetDriver] section applies to server downloads, not redirect downloads. This means that if the redirect fails to provide the right file, the server will offer up the same file, albeit at a slower speed than the webserver can provide (a UChannel download, not an HTTP download). The webserver logs will still show a 404-status error but the player sees the file downloading and is able to join the game after a brief delay.

For that reason, server admins should regularly check their webserver download logs for evidence of 404 errors, which could indicate new server assets which are missing off the redirect.

Further details can be found on the Unreal Wiki

How do I speed up my downloads?

There are some articles written on various settings, both server-side and client-side, varying between recommending configuration settings being raised in client files and warning against too high a threshold for fear of adversely impacting in-game play.

However, the following have been tested and recommended.

UT99:

Find the “unrealtournament.ini” file – this is usually in your “System” directory. Win7 users may find a local copy held in:

 C:\Users\<USERNAME>\AppData\Local\VirtualStore\Program Files (x86)\UnrealTournament\System

Make a backup of this file first, and ensure that UT99 is not actually playing (configuration modifications shouldn’t be made during gameplay). Then edit this file to change the following settings:

[Engine.Player]
ConfiguredInternetSpeeds=1234567
ConfiguredLanSpeed=1234567

This should set the netspeed to around 12.3MBytes/sec. Jack it up higher if your network can handle it.

UT2004:

Similar settings but these are held in the “user.ini” file – again, usually in your “System” directory.

Stop UT2004 first (again, configuration modifications shouldn’t be made during gameplay), make a backup, then change the same settings:

[Engine.Player]
ConfiguredInternetSpeed=1234567
ConfiguredLanSpeed=1234567

Leave a Reply

Your email address will not be published. Required fields are marked *