Install Guides

From BlueFur.com Support Wiki

Jump to: navigation, search

Setup a Counter-Strike Server

SSH to your server. Below I'm assuming you have logged into a user other than root.

su to root (If you initially logged into root when you ssh'ed to the server, this command can be disregarded).

su -

I recommend that you run HLDS on a specific user. While you can run it under whatever user you like, even root, it makes it easier to manage and keep organized running it as its own user:


useradd hlds passwd hlds


exit (Only if you su'ed to root, and didn't initially log in as root)

Now download the files either using wget from your server or downloading them yourself and uploading them to the hlds user.

http://www.3dgamers.com/dl/games/ha...1_full.bin.html http://www.counter-strike.net/linux_full.html

Once the servers are in your /home/hlds directory (and you are there too) do the following:

chmod +x hlds_l_3111_full.bin ./hlds_l_3111_full.bin


Answer 'Yes' at the prompt.

tar -xvzf hlds_l_3111_full.tar.gz

This should have created a directory named "hlds_l" containing all the HLDS files. I personally hate the _l part of the directory name and like to do the following:

mv hlds_l hlds

That should have renamed the directory to just "hlds".

Now put the CS server file you downloaded in the "hlds" directory:

mv cs*.tar.gz hlds

Go into the HLDS directory:

cd hlds

Untar the file:

tar -xvzf cs*.tar.gz

This should have created a directory named "cstrike".

Go into the "cstrike" directory:

cd cstrike

Edit the server.cfg file and if you like, the optional motd.txt and mapcycle.txt files:

You can find CS server commands at http://server.counter-strike.net

You also probably want to add an rcon password for the server. To do so, do the following:

pico -w server.cfg

Put the rcon password on its own line, anywhere in the file:

rcon_password yourpassword

[ctrl + x]

[y]

[enter]

Next we go back to the "hlds" directory and make a script to start he server:

cd .. pico -w startcs

./hlds_run -game cstrike +maxplayers 16 +map de_dust&


The above line can be customized to fit your needs, as well you can add extra options. Also, the & makes the server launch into the background. Without it, as soon as you exit the ssh session, your CS server will die.

HLDS has a ping booster built in.

Just add...

-pingboost #

...to your start line.

For example:

./hlds_run -game cstrike -pingboost 1 +maxplayers 16 +map de_dust&

The number (1 in the example) tells how much you want to boost pings.

1 Gives a small boost without using very much extra CPU.

2 Gives a pretty good boost but uses a bit more CPU.

3 Is a CPU hog and not recommended unless you think your CPU can handle it.


[ctrl + x]

[y]

[enter]

chmod +x startcs

Now the script is created, all you have to do is run it to start your CS server.

./startcs

Thats it. Your CS server should be running now.

Setup Shoutcast Server

Generally you dont want to run shoutcast as root as that can be really bad. so we create a shoutcast user:

1.) Login to root 2.) adduser shoutcast 3.) passwd shoutcast

Now it will ask for a new password set this and remember it.

Now login as the new shoutcast user.


Installing shoutcast:

Lets grab shoutcast from nullsoft:


quote:


wget http://www.shoutcast.com/downloads/sc1-9-2/shoutcast-1-9-2-linux-glibc6.tar.gz



Lets extract shoutcast:


quote:


tar -zxvf shoutcast-1-9-2-linux-glibc6.tar.gz



Lets tidy up the directory:


quote:


rm -rf shoutcast-1-9-2-linux-glibc6.tar.gz mv shoutcast-1-9-2-linux-glibc6 shoutcast cd shoutcast




How to configure shoutcast?

your going to want to edit the shoutcast configuration.


quote:


pico sc_serv.conf or nano sc_serv.conf

depending on what you have.



Ok lets set some important configureation options. Change these settings in the file:

MaxUser Password PortBase

uncomment AdminPassword and set an admin password.

Now at this point you can go threw the settings and change them to what you want or you can save and start shoutcast and it will work perfectly.

to save crtl+x

How do i start shoutcast?

./sc_serv sc_serv.conf

Personal tools