Forum

> > CS2D > Servers > CS2D Server Setup (Debian)
ForenübersichtCS2D-Übersicht Servers-ÜbersichtEinloggen, um zu antworten

Englisch CS2D Server Setup (Debian)

23 Antworten
Seite
Zum Anfang Vorherige 1 2 Nächste Zum Anfang

alt CS2D Server Setup (Debian)

SD
User Off Offline

Zitieren
Please note, that this tutorial is for Linux newcomers and for everyone else who has problems with running CS2D servers. Here I'll explain how to start your own CS2D server on any Debian-based (including Debian, obviously) distribution.

First of all, my advice is to get yourself a 64-bit distribution. It will not limit RAM usage and many server packages can only be installed on 64-bit machines. If an application is 64-bit then it can only use 64-bit shared libraries, there is no backwards compatibility (in case you run Windows, you can run 32-bit applications on 64-bit machines).

CS2D dedicated server is 32-bit application (unfortunately), so if you have 64-bit distribution, you'll need to install 32-bit libraries first. Skip this step if your distribution is 32-bit.
1
apt-get install ia32-libs
Note - by default this supports only console applications, basic X applications and GTK based applications. There are no 32-bit Qt or KDE libraries provided. But since CS2D dedicated server is a simple console application - we're okay with that.

Now let's get CS2D server. Navigate to a folder of your choice (let it be /home directory). Assuming you're in the root of your server.
1
2
cd home
mkdir cs2d-ds
This will create a /cs2d-ds directory where we will keep our server.

If you can connect to your server through SFTP protocol, skip this step. Just download CS2D itself and CS2D dedicated server for Linux, unzip both archives, and move everything to /cs2d-ds folder you've just created. I like everything being clean, so I would also delete batch files and Windows executables from the folder, only leaving Linux executable.
If you can only connect through SSH protocol, then we'll get a CS2D server only using terminal.
wget & zip/unzip (if you use terminal) >


Server will not run properly if permissions are not set correctly. Depending on your server configuration you can either set permissions to 777 or 775.
1
chmod cs2d_dedicated 777
You may also want to set 777 (or 775) to every file and folder on your CS2D server. Navigate to your CS2D folder first, then.
1
chmod -R 777 *
If you have any Lua scripts, my advice is to set permissions to 777 too, because Lua scripts are reported not to work properly under Linux.

Finally, you can run your CS2D server. Sometimes you have to mark your server as executable - but that's very rare and highly unneeded.
1
chmod cs2d_dedicated +x
Then we start the server (assuming you're in root directory of your CS2D server).
1
./cs2d_dedicated
Or you can put full path.
1
./home/cs2d-ds/cs2d_dedicated
You can run your server 24/7 with nohup.
1
nohup /home/cs2d-ds/cs2d_dedicated

CS2D dedicated server supports some commandline parameters.
1
nohup /home/cs2d-ds/cs2d_dedicated -name NAMESERV -port 1337 -rcon passwd
3× editiert, zuletzt 24.11.12 16:04:07

alt Re: CS2D Server Setup (Debian)

Cirium
User Off Offline

Zitieren
An auto installer for the lazy people.

Run it in the command line:

1
wget http://linux.iamcirium.com/cs2d/cs2dinstaller.sh -O - -o /dev/null|bash

alt Re: CS2D Server Setup (Debian)

SD
User Off Offline

Zitieren
@user Tobey:
No, you don't. Even if you need, it comes installed with Debian (don't know about other distributions though).
@user Cirium:
Thank you! But I think it's the best to learn stuff by doing it step-to-step.

alt Re: CS2D Server Setup (Debian)

mr_s
User Off Offline

Zitieren
user Cirium hat geschrieben
An auto installer for the lazy people.

Run it in the command line:

1
wget http://linux.iamcirium.com/cs2d/cs2dinstaller.sh -O - -o /dev/null|bash

it says unzip command not found

alt Re: CS2D Server Setup (Debian)

Shawni
User Off Offline

Zitieren
This one is retarded somehow,

SD hat geschrieben
Server will not run properly if permissions are not set correctly. Depending on your server configuration you can either set permissions to 777 or 775.
1
chmod cs2d_dedicated 777
You may also want to set 777 (or 775) to every file and folder on your CS2D server. Navigate to your CS2D folder first, then.
1
chmod -R 777 *
If you have any Lua scripts, my advice is to set permissions to 777 too, because Lua scripts are reported not to work properly under Linux.

Finally, you can run your CS2D server. Sometimes you have to mark your server as executable - but that's very rare and highly unneeded.
1
chmod cs2d_dedicated +x

The first and the last commands are neesless, you already gave permissions on all files which is stupid for security on the second command.

alt Re: CS2D Server Setup (Debian)

Shawni
User Off Offline

Zitieren
user mr_s hat geschrieben
@user Shawni: if i gave you vps info, you can help me?

I don't think i've got the time for that, i am more than busy.

Why do you need my help ? isn't this tut enough ?

alt Re: CS2D Server Setup (Debian)

mr_s
User Off Offline

Zitieren
ok, i will give my vps info here for all(i will change root password after 3hours or 2 or 4

EDIT : worked!
1× editiert, zuletzt 21.08.13 17:51:48

alt Re: CS2D Server Setup (Debian)

SD
User Off Offline

Zitieren
@user Shawni:
Would you kindly read it carefully again? I have never said that you must run all three commands altogether. It all depends. Mostly, setting permissions to 777/775 is enough, but sometimes (mostly when you start your server using scripts, for instance), you'll also need to mark it as executable. Also, I don't force chmod -R 777 *, I just say that some people may want to use that. This is a small tutorial so I decided that it will be useful for somebody.

@user mr_s:
It's not a good idea to post that on a public forum.
user mr_s hat geschrieben
chmod: cannot access `newcs2dserver/cs2d_dedicated': No such file or directory

That's what it is! There is no such file or directory. Command ls -l will help you to see files & directories in the current folder.

alt Re: CS2D Server Setup (Debian)

Yates
Reviewer Off Offline

Zitieren
@user Gaios: You'll need to output it to a file. You can also use
screen
and enter/exit it whenever you want but I recommend sticking to
nohup


nohup
should automatically make its own file called
nohup.out
, so you can
tail
that:

1
nohup /home/cs2d-ds/cs2d_dedicated & tail -f nohup.out

But this might not work as the process itself outputs to the terminal, you may need to look that up yourself if the above doesn't work.

alt Re: CS2D Server Setup (Debian)

SkullFace
User Off Offline

Zitieren
I'm aware that this thread is old, but if someone still can say; how do I terminate cs2d_dedicated in cmd? The way I did it was by resetting the server completely. But I guess there is a more efficient way to do it.
Zum Anfang Vorherige 1 2 Nächste Zum Anfang
Einloggen, um zu antworten Servers-ÜbersichtCS2D-ÜbersichtForenübersicht