SRCDS Steam group

[Advanced]: Set up sv_downloadurl for faster downloads
Original old thread by DarkZealot89 can be found here:

sv_downloadurl, what is it actually? Do I need it?
No you don't need sv_downloadurl, however if you have a lot of custom files on your server like maps and models it is real handy to have a blazing download. Downloads directly from the actual gameserver can lag and be a pain in the butt due to being so slow, you can lose a lot of clients.

sv_downloadurl acts as an image of the server located on a website somewhere else, which contains all the custom files you have. Setting sv_downloadurl will speed up the downloading process, when on a good webhost downloads can be next to instant and will reach speeds never seen before.

How to set it up:
First of all you need webspace somewhere, in this tutorial I will use "" as my webspace.

Second thing you have to do is create a folder on your webspace named exactly like the mod is called in the SRCDS folder, I will use "cstrike".
Now It will look like this: ""

Good, now I have 2 new maps and a sound that can be played within the server:
Quote:fy_pwnage.bsp (Location: cstrike\maps)
surf_leet_beta.bsp (Location: cstrike\maps)
mysupersound.mp3 (Location: cstrike\sound\admin_plugin)

To allow these to download real fast we have to copy them to the webspace, be sure to match the exact file folders and names on the webserver, else it won't work. Here's how my webspace looks like now:

Make sure all your files permissions are set correctly, people have to be able to read and download them!

Now it's ready, open up your server.cfg, on my machine it's located in C:\SRCDS\cstrike\cfg. If you run a different mod, hl2 deathmatch for example, it will be in "hl2mp" instead of "cstrike"
When opened add a line to the server.cfg containing your download url. Also be sure to have sv_allowdownload and sv_allowupload set to "1" for me it will look like this:
Quote:sv_downloadurl ""
sv_allowdownload 1
sv_allowupload 1

Well that's really all there is to it! Restart your server and have fun.
Note: Some websites, mostly free of charge, block the file extensions used or even the request URL sent by the game/server. So not all webhosts are compatible!

Still too slow? Slurping bandwidth?! How to, Bzip2!

Yeah, that's right, what you've seen above isn't as fast as it can get!
What is Bzip2? Bzip is a compression method/program just like winzip and winrar etc., however the source engine client has this decompress tool built in.
What does that mean? It means you can save a lot of download time, space on your webserver and bandwith while keeping the download process just as easy as it was before, all automatic.

(Windows Only) Bzipping is actually made easy by sKeletor, he made a nice batch script to automatically bzip all your files dropped in a folder.
Here's the file:

.zip (Size: 30.5 KB / Downloads: 2,985)

Extract it somewhere you like, I put it on my desktop.
I will use the files I've used above to Bzip and upload to my webspace.
I copy fy_pwnage.bsp, surf_leet_beta.bsp and mysupersong.mp3 to the "compress" folder and double click "bzip", when it's done the black window will dissapear.
When it's done go take a look inside the "compress" folder, there they are! (End of Windows Only)

Now I have fy_pwnage.bsp.bz2, surf_leet_beta.bsp.bz2 and mysupersong.mp3.bz2. I upload them so i have the following on my webspace (same as above):

You can delete the big, normal .bsp files from your webspace, you don't need those anymore. Do NOT delete them from your gameserver directory!

Good now that's all set, all we have to do now is also copy them to the gameserver directory. This is how it looks like now:
Quote:... cstrike/maps/fy_pwnage.bsp
... cstrike/maps/fy_pwnage.bsp.bz2
... cstrike/maps/surf_leet_beta.bsp
... cstrike/maps/surf_leet_beta.bsp.bz2
... cstrike/sound/admin_plugin/mysupersound.mp3
... cstrike/sound/admin_plugin/mysupersound.mp3.bz2

As you can see I have both the normal file and the bz2.
The gameserverserver always needs at least the BSP!

That's it, you're all set to run your server with lightning fast bzipped downloads!

Discussion, questions and suggestions can be posted here:

Forum Jump:

Users browsing this thread: 1 Guest(s)