This article explains how to configure a server in order to be ready to communicate with the speed-gm panel, based on some very useful pre-made code to those who have not mastered completely linux systems.
More advanced users can adjust what they wish and also use our support system to reach us.
Run the following commands on the server. If the system is 64bit we should add support to 32-bit in order to support some games and steamCMD.
# Add ia32 shared libraries
apt-get -y install lib32gcc1
# Install dependencies
apt-get -y install sudo wget debconf-utils apache2 php5 php5-curl php5-sqlite expect screen dos2unix sudo unzip sysstat zip telnet
Choose one of the next two, depending on your operating system.
# Install unrar 64 bit
cd /tmp
wget http://www.rarlab.com/rar/rarlinux-x64-5.1.1.tar.gz
tar -zxvf rarlinux-x64-5.1.1.tar.gz
cd rar
cp rar unrar /bin
# Install unrar 32 bit
cd /tmp
wget http://www.rarlab.com/rar/rarlinux-5.1.1.tar.gz
tar -zxvf rarlinux-5.1.1.tar.gz
cd rar
cp rar unrar /bin
FTP Server installation.
# Download proftpd
cd /tmp
wget http://install.speed-gm.com/proftpd/debian/proftp.sh
# Run proftpd
chmod +x proftp.sh
./proftp.sh
rm proftp.sh
Choose one of the next two, depending on your operating system.
# Download ioncube 64 bit
cd /tmp
wget http://downloads3.ioncube.com/loader_downloads/ioncube_loaders_lin_x86-64.tar.gz
tar -zxvf ioncube_loaders_lin_x86-64.tar.gz
mkdir /usr/local/ioncube
cd ioncube
mv * /usr/local/ioncube
# Download ioncube 32 bit
cd /tmp
wget http://downloads3.ioncube.com/loader_downloads/ioncube_loaders_lin_x86.tar.gz
tar -zxvf ioncube_loaders_lin_x86.tar.gz
mkdir /usr/local/ioncube
cd ioncube
mv * /usr/local/ioncube
Install ioncube.
# Identify version of php to activate the correct loader. 5.2, 5.3, 5.4, etc
php -v
# Add ioncube to php
echo zend_extension = /usr/local/ioncube/ioncube_loader_lin_5.4.so >> /etc/php5/cli/php.ini
echo zend_extension = /usr/local/ioncube/ioncube_loader_lin_5.4.so >> /etc/php5/apache2/php.ini
Add shell nologin.
echo /sbin/nologin >> /etc/shells
Create SGM vhost in apache.
cd /etc/apache2/sites-enabled && wget install.speed-gm.com/vhost/ubuntu/sgm.conf
cd /etc/apache2/sites-available && wget install.speed-gm.com/vhost/ubuntu/sgm.conf
Create the SGM public folder.
mkdir /usr/share/sgm
Download the remote web files.
# IF PHP Version < 5.5
cd /usr/share && wget http://install.speed-gm.com/remote/5/sgm.zip && unzip -o sgm.zip && rm -f sgm.zip
# If PHP Version = 5.5
cd /usr/share && wget http://install.speed-gm.com/remote/55/sgm.zip && unzip -o sgm.zip && rm -f sgm.zip
Download and edit SGM config.php file.
# Download config.php
cd /usr/share/sgm && wget http://install.speed-gm.com/config/config.php# Configure config.php with your box data
# Configure config.php with your box details
nano config.php
# You will se the follwing content
<?php
$Server = 'ServerID';
$Key = 'Key';
$Remote = 'innov4web.pt';
$urlRemote = 'http://your_url.speed-gm.com';
Change the 'ServerID', 'Key' and 'your_url' for the values that are presented in the Edit box menu of your Box.
The result will be something like this.
Assign permissions.
cd /usr/share/sgm
chown -R root:root *
chmod 644 index.php
chmod 644 dn.php
Download SGM main folder .
cd /home && wget http://install.speed-gm.com/structure.tar.gz && tar -zxvf structure.tar.gz && rm structure.tar.gz
# If PHP Version < 5.5
cd /home/SGM/tools && wget http://install.speed-gm.com/remote/5/scripts.zip && unzip -o scripts.zip && rm -f scripts.zip
# If PHP Verison = 5.5
cd /home/SGM/tools && wget http://install.speed-gm.com/remote/55/scripts.zip && unzip -o scripts.zip && rm -f scripts.zip
Assign permissions to SGM folder.
cd /home
chown -R root:root SGM
cd /home/SGM/tools/scripts
chmod +x run.php
chmod +x socket.sh
chmod +x socket.php
chmod +x chpasswd
Download SteamCMD.
cd /home/SGM/tools/steamcmd
wget http://media.steampowered.com/client/steamcmd_linux.tar.gz
tar -zxvf steamcmd_linux.tar.gz
rm steamcmd_linux.tar.gz
Configure Cron.
# Open crontab edit mode
crontab -e
# Add the following
* * * * * cd /home/SGM/tools/scripts && php run.php
Restart apache.
/etc/init.d/apache2 restart
Wait a moment and you can confirm the box status on the panel as Online.
Change the status of the box to Enabled in the Edit box menu in order to support game and voice servers installation.
Enable the main IP or add a secondary Ip to install the game servers.
Save FTP settings in order to update the configuration file in the remote Box
Finally, SGM gives you the choise of which games you wish to run on a specific box.
Check this document to learn how to enable/disable games on a specific box.
Powered by WHMCompleteSolution