Step-by-step Dedicated Server on CentOS

User avatar
WarStalkeR
Corporal
Posts: 22
Joined: Thu 12 Sep 2013 03:27
Contact:

Step-by-step Dedicated Server on CentOS

Postby WarStalkeR » Fri 11 Apr 2014 18:33

Image

So, some of us - private server owners are dedicated CentOS fans, or just users who found way in their life after using CentOS for a while. But since WarGame: AirLand Battle Dedicated Server software was native only to Debian, many other OS Linux users, including us CentOS users had problems making it run.

Current guide will explain what to do, to make WarGame: AirLand Battle Dedicated Server run on CentOS 6 (x86). There are two ways: for people who fine downloading already prepared files by me and for paranoid people, who prefer to do everything by themselves.

Very Easy Step-by-step Installation:
Spoiler : :

Code: Select all

yum install wget p7zip nano

1) Getting libraries in place:

Code: Select all

cd /
mkdir libhelp
cd libhelp
wget http://soon-tm.info/t_stuff/libhelp.7z
7za x libhelp.7z
rm -f libhelp.7z
chmod 755 lib*

2) Preparing dedicated server:

Code: Select all

useradd wargame
cd /opt
mkdir wargame_dserver
cd wargame_dserver
wget --no-check-certificate https://link_to_ip_from_eugen/software_name.tar.gz
tar -xvzf wargame2_server.tar.gz
rm -f wargame2_server.tar.gz
ln -sf /libhelp/libssl.so.1.0.0 libssl.so.1.0.0
ln -sf /libhelp/libcrypto.so.1.0.0 libcrypto.so.1.0.0
ln -sf /libhelp/libstdc++.so.6 libstdc++.so.6
touch wargame2_server_launcher.sh
chmod 755 wargame2_server_launcher.sh
nano wargame2_server_launcher.sh
and put there this script (where XXXX is port what you want to use for games and YY.YY.YY.YY is static IP of your server):

Code: Select all

#!/bin/sh

cd "$(dirname "$0")"

LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:./ ./wargame2-server +port XXXX +port_mms 10804 +ip YY.YY.YY.YY
after creating script wargame2_server_launcher.sh:

Code: Select all

cd ..
chown wargame:wargame -R wargame_dserver
cd wargame_dserver
su wargame
now via nano edit everything you need in the server configuration files and then:

Code: Select all

./wargame2_server_launcher.sh

3) Enjoy!
Hardcore Step-by-step Installation:
Spoiler : :

Code: Select all

yum install wget p7zip nano gcc gcc-c++ make zip tar glibc procps vi initscripts openssl

1) Getting right version libssl.so.1.0.0 and libcrypto.so.1.0.0:
There are two ways to get them. One is go to https://www.openssl.org/ and grab latest version of 1.0.0 lib (which openssl-1.0.0l.tar.gz is currently) compile it and then manually patch it, so it will show version WarGame needs - I suggest to forget about this way even to most advanced CentOS users, it will take hell of the time. Second way is go and download, and install VirtualBox Software on your home PC, download Debian Wheezy minimum installation CD. Install it, install there OpenSSH, start sshd, via WinSCP grab required files from /usr/lib/i386-linux-gnu/libssl.so.1.0.0 and from /usr/lib/i386-linux-gnu/libcrypto.so.1.0.0 and then upload it somewhere on to your server, I suggest /libhelp/deb_openssl folder for it.

2) Getting suitable version of libstdc++.so.6:

Code: Select all

mkdir -p /libhelp/installers_to_delete/
cd /libhelp/installers_to_delete/
wget http://ftp.gnu.org/gnu/gcc/gcc-4.8.2/gcc-4.8.2.tar.gz
tar -xzvf gcc-4.8.2.tar.gz
cd gcc-4.8.2
./contrib/download_prerequisites
cd ..
mkdir gcc-4.8.2-obj
cd gcc-4.8.2-obj/
$PWD/../gcc-4.8.2/configure --prefix=/libhelp/gcc-4.8.2 --enable-languages=c++ --disable-nls --disable-multilib --disable-libgcj --without-headers --disable-static
make -j6
make -j6 install

3) Preparing dedicated server:

Code: Select all

useradd wargame
cd /opt
mkdir wargame_dserver
cd wargame_dserver
wget --no-check-certificate https://link_to_ip_from_eugen/software_name.tar.gz
tar -xvzf wargame2_server.tar.gz
rm -f wargame2_server.tar.gz
ln -sf /libhelp/deb_openssl/libssl.so.1.0.0 libssl.so.1.0.0
ln -sf /libhelp/deb_openssl/libcrypto.so.1.0.0 libcrypto.so.1.0.0
ln -sf /libhelp/gcc-4.8.2/lib/libstdc++.so.6 libstdc++.so.6
touch wargame2_server_launcher.sh
chmod 755 wargame2_server_launcher.sh
nano wargame2_server_launcher.sh
and put there this script (where XXXX is port what you want to use for games and YY.YY.YY.YY is static IP of your server):

Code: Select all

#!/bin/sh

cd "$(dirname "$0")"

LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:./ ./wargame2-server +port XXXX +port_mms 10804 +ip YY.YY.YY.YY
after creating script wargame2_server_launcher.sh:

Code: Select all

cd ..
chown wargame:wargame -R wargame_dserver
cd wargame_dserver
su wargame
now via nano edit everything you need in the server configuration files and then:

Code: Select all

./wargame2_server_launcher.sh

4) Enjoy!
P. S. If somebody of you has right iptables settings, which allow Wargame Dedicated Server software to run correctly, please post it here, I will be really thankful!
"Happiness for everybody, freely, and let no one to leave unhappy!" (c) Strugatsky Brothers

Who is online

Users browsing this forum: No registered users and 1 guest