Posts Tagged ‘debian’

Counter Strike Debian linux server setup

Counter Strike server setup procedure on Debian linux – January 7th, 2008
Based upon – http://www.cstrike-planet.com/tutorial/1/5 – Props to whoever wrote it!
IT IS ADVISABLE TO RUN THE VARIOUS INSTALL PROCESSES AS ROOT! Edit: You can actually run all of these from a regular system user account.

handy tip – to measure current directory size: du -h

This setup procedure assumes that you (the installer) currently possess:

  1. knowledge of how to use a command line text editor in linux (vi, nano, etc.)
  2. knowledge of how to use apt-get or yum to install dependencies
  3. a preexisting linux installation, and root access on said box (you are able to login as “root”)

I’m doing this installation on a Debian Etch (4.0) minimal installation within a VPS. You do not necessarily have to install a separate Counter Strike dedicated server on a separate VPS. All you have to do is setup the Counter Strike dedicated server to run on different port/IP addresses. So let’s get going!

  1. Create an install directory and dl the installer
    • mkdir srcds (the directory for Counter Strike: Source dedicated server)
    • cd srcds
    • wget http://www.cstrike-planet.com/dls/hldsupdatetool.bin
  2. Make the installer executable and execute it
    • chmod +x hldsupdatetool.bin
    • ./hldsupdatetool.bin
  3. Agree to the terms and conditions by typing “yes” and “steam” will be created in the same directory
  4. Now run the steam installer that will dowload a new version of HLDSUpdateTool
    • just to be on the same side, why not make it executable (if it isn’t already) – chmod +x steam
    • run steam: ./steam – it took about 10 minutes for it to update. all depends upon the steam server loads.
  5. We are now ready to download and install Counter Strike Source. be sure the trailing dot stays in the command! It is there so that the install goes into the current directory.
    • ./steam -command update -game “Counter-Strike Source” -dir .
    • the install size is ~ 1.1GB uncompressed
  6. The server is now ready for various customizations. I’ll be writing more on that later …

Your Ad Here

This next installation method is for the Counter Strike 1.6 linux dedicated server
Based upon – http://www.cstrike-planet.com/tutorial/1-Linux-Install-CS-16/6

  1. Repeat steps 1-5 in previous installation but in different root directory. so instead of “srcds” let’s put the installation in “hlds”. Step 2 of the previous method should this time be:
    • mkdir hlds
    • cd hlds
  2. Run the various steps outlined above, and now to install the cstrike1.6 linux dedicated server.
    • ./steam -command update -game cstrike -dir .
    • the install is ~ 360MB

Q and A time
Q: How can I keep hlds running while I am not logged into the server with SSH?
A: Start your dedicated server with screen: screen -S hlds ./hlds_run . And then when you want to access the running server process once logged back in: screen -r hlds.

Q: How many CS virtual servers can I get on one machine?
A: see – http://www.webhostingtalk.com/showthread.php?t=743585

Q: What does the “tickrate” have anything to do with anything? What is it?
A: see – http://www.counter-strike.com/tickrate.php

Q: Where can I get cheap vps/dedicated server hosting to try this out on?
A: You could pick up a VPS from webkeepers.com or check out ThePlanet’s bargain bin: https://www.theplanet.com/servers/outlet.aspx.

OpenVZ on Debian Etch

OpenVZ setup procedure followed – January 5th, 2009
host machine – 1.5ghz, 1GB ram, 40GB hard disk drive
host os – Debian 4.0
kernel image – etchnhalf
for more detailed information see: http://download.openvz.org/doc/OpenVZ-Users-Guide.pdf
for more information on symbolic linking see: http://www.ss64.com/bash/ln.html

These instructions are for setting up an OpenVZ system on Debian 4.0 (Etch) with browser-based administration via Webmin. I couldn’t get the OpenVZ plugin for Webmin working, but maybe you can. This cookbook assumes running knowledge of how to edit configuration files via “vi”, using apt-get to install dependencies/software, and how to install via tarballs (.tar.gz).

  1. Install latest Debian distro (Etch at the time of authoring) on your physical server. You can get the netinstall (what I used) here: http://www.debian.org/distrib/netinst. Partition setup note: 5-7GB for root filesystem, 1.25X-2X size of RAM for swap, rest of space for /var/lib/vz (for OpenVZ VPS nodes).
  2. Once installed, configure static ipv4/ipv6 address(es) on interfaces (/etc/network/interfaces) and nameservers in the /etc/resolv.conf file.
  3. Modify apt-get sources if incorrect and add line “deb http://download.openvz.org/debian-systs etch openvz”
  4. Run command to update apt-get with new openvz repository: wget -q http://download.openvz.org/debian-systs/dso_archiv_signing_key.asc -O- | apt-key add – && apt-get update
  5. apt-get install ssh (so we don’t have to sit in front of the server rack anymore)
  6. apt-get upgrade (update to the newest software versions)
  7. You might need to execute “shutdown -r now” if debian installed a new kernel and/or other critical operating system feature.
  8. Now we can get to the good stuff. It’s time to install the OpenVZ kernel: http://wiki.openvz.org/Installation_on_Debian#Kernel_installation
  9. After installing the OpenVZ kernel and rebooting into your new OpenVZ kernel based system (and making sure you have all the OpenVZ shiz running properly), we can now install some webmin dependancies: apt-get install perl libnet-ssleay-perl openssl libauthen-pam-perl libpam-runtime libio-pty-perl libmd5-perl
  10. I suggest running the webmin minimal install – http://webmin.com/tgz.html
  11. install openvz webmin module – http://www.provider4u.de/openvz.tar.gz
  12. install various openvz os templates to /var/lib/vz/template/cache from: http://download.openvz.org/contrib/template/precreated/

Return top