Web Hosting Talk







View Full Version : How-To: Install Half-Life Dedicated Server and its mods


CArmstrong
11-15-2004, 10:34 PM
I know there are older guides, but this one is updated for CS:Source and the like. Enjoy



*************
HLDS Installation Walkthrough
by Chris 'CArmstrong' Armstrong
Operator, #hlds, GameSurge IRC
Location: http://hlds.amchrisarmstrong.com/wt.txt
Last Update: 10/17/2004
*************

INSTALLATION - LINUX

1) adduser hlds && passwd hlds
2) su hlds
3) cd ~
4) wget http://www.steampowered.com/download/hldsupdatetool.bin
5) chmod +x hldsupdatetool.bin && ./hldsupdatetool.bin
5a) If you see an error about not finding /bin/uncompress type ln -s /bin/gunzip /bin/uncompress && ./hldsupdatetool.bin
6) ./steam -command update -game gamename -dir ~/hlds -username yoursteamaccountgoeshere -password yourrealpasswordgoeshere
6a) Replace gamename above with cstrike for CS, tfc for TFC, dod for Day of Defeat, "counter-strike source" for CS:S (yes, you need the quotations)
7) The tool will probably update itself, and then begin downloading the files. Eat a snack or get off your behind for a bit, and take a walk. This can take awhile.

INSTALLATION - WINDOWS

1) Download and install http://www.steampowered.com/download/hlds_updatetool.exe
2) Start -> Run -> cmd <Enter> (or any other way of getting a command prompt)
3) cd C:\HLServer (or whatever path you installed to)
4) hldsupdatetool.exe -command update -game gamename -dir C:\HLServer -username yoursteamaccountgoeshere -password yourrealpasswordgoeshere
4a) Replace gamename above with cstrike for CS, tfc for TFC, dod for Day of Defeat, "counter-strike source" for CS:S (yes, you need the quotations)
4b) Also, if you installed to a different location than C:\HLServer, replace that above too
5) The tool will probably update itself, and then begin downloading the files. Take a break. This can take awhile.

----------

CONFIGURATION - LINUX (Half-Life 1 or its mods)

In Linux, text files are usually edited using pico or nano in the following manner:
pico filename
nano filename

For any file you need to edit here, use nano or pico followed by the entire path I give you to the file's location.

1) Edit ~/hlds/gamename/server.cfg (replace gamename with whatever you used before)
***This is where your server variables are stored. Reference the http://server.counter-strike.net config editor for easy coverage of the common ones.

2) Edit (nano or pico) ~/hlds/gamename/motd.txt (replace gamename with whatever you used before)
***This file contains the message people see when they first connect. HTML is acceptable and used by default.

3) Edit (nano or pico) ~/hlds/gamename/mapcycle.txt (replace gamename, as usual)
***This is a file containing the maps your server will play, one on each line.

CONFIGURATION - LINUX (Counter-Strike Source)

Same files as HL1, different locations:

1) Edit ~/hlds/cstrike/cfg/server.cfg
2) Edit ~/hlds/cstrike/motd.txt
3) Edit ~/hlds/cstrike/mapcycle.txt


CONFIGURATION - WINDOWS

Edit the files from the Linux section with Notepad. The files are in the same locations, just the main directory will be different (C:\HLServer instead of ~/hlds)

----------

STARTING THE SERVER - LINUX (Half-Life 1 or its mods)

1) cd ~/hlds
2) ./hlds_run -game gamename +maxplayers number +map ******* &
EXAMPLE: ./hlds_run -game cstrike +maxplayers 20 +map de_dust +ip 1.1.1.1 +port 27015 &
***Many more things can be specified here. See the http://server.counter-strike.net config editor for all possible options. Anything here takes precedence over settings in server.cfg

STARTING THE SERVER - LINUX (Counter-Strike Source)

1) cd ~/hlds
2) ./srcds_run -game cstrike +maxplayers 20 +map de_dust &
EXAMPLE: ./srcds_run -game cstrike +maxplayers 20 +map de_dust +ip 1.1.1.1 +port 27015 &
***Many more things can be specified here. See the http://server.counter-strike.net config editor for all possible options. Anything here takes precedence over settings in server.cfg

----------

FAQ

Q: How do I install AdminMod or MetaMod?
A: http://www.adminmod.org/help/online/ will walk you through this better than we can, including installing and configuring MetaMod. Also visit #adminmod

Q: How do I install AMXmod or AMXmodX?
A: AMXmod is no longer being developed. For AMXmodX, see http://www.amxmodx.org/doc/ and #amxmodx

Mouse_103
12-15-2004, 03:04 PM
Thanks for tutorial :D

I plan to sell game servers :)

Peruvianfinest
01-14-2005, 03:16 AM
thanks , this is much shorter than i have found in other site ..i plan on getting a dedicated server for gaming (cs/dod/source) etc. This was very helpful.

Peruvianfinest
01-14-2005, 03:23 AM
for windows

-command update -game gamename -dir C:\HLServer -username yoursteamaccountgoeshere -password yourrealpasswordgoeshere


can you put an example of what to put
i get -command is not recognized as an internal or external command.

Kris0r321
06-24-2005, 10:44 AM
you havent put the HldsUpdateTool.exe in front of it, so its tryin to run the command on windows and not the update tool :)

marketingmb
06-24-2005, 01:41 PM
grea tutorial man! really helped!

marketingmb
06-24-2005, 01:43 PM
But i need help with an issue can anyone help via pm?

Kris0r321
06-24-2005, 06:25 PM
you can pm me if you want, ive installed hlds on both platforms

Dafoe
06-26-2005, 06:53 PM
Originally posted by Chris Armstrong

5a) If you see an error about not finding /bin/uncompress type ln -s /bin/gunzip /bin/uncompress && ./hldsupdatetool.bin


Hi everyone,

Im having trouble with step 5a)

I get the error:
hlds@serv:~$ ./hldsupdatetool.bin
bash: ./hldsupdatetool.bin: No such file or directory

although I´ve followed the step ln -s /bin/gunzip /bin/uncompress

gunzip seems to be installed:
hlds@serv:~$ whereis gunzip
gunzip: /bin/gunzip /usr/share/man/man1/gunzip.1.gz

Can anyone help me out PLZ!

CArmstrong
07-18-2005, 01:04 AM
Dafoe, your error isn't due to uncompress. Either you never downloaded hldsupdatetool.bin or it isn't in the present directory when you're typing ./hldsupdatetool.bin

AcuNett
07-20-2005, 06:29 PM
Is it possible to have more than one cs server on a machine use the default 27015 port?

There's no point in using different IPs if they can't use the default port.

AcuNett
07-20-2005, 09:23 PM
I got it. Had to put +ip in front of all of them.

Ogeres
07-22-2005, 03:05 AM
thank you very much

gadji
08-01-2005, 09:15 AM
Does this only work on a local machine?

How would you do it if you wanted to install it on a webhosting package that you bought?

KenThomp
08-15-2005, 01:42 PM
gadji, You can install with the above steps if you have a dedicated / VPS server that gave you SSH access.

gadji
08-16-2005, 03:45 AM
Thanks levidjkt.