Go Back   EQEmulator Home > EQEmulator Forums > Support > Support::Linux Servers

Support::Linux Servers Support forum for Linux EQEMu users.

Reply
 
Thread Tools Display Modes
  #1  
Old 03-01-2013, 08:58 AM
LordAdakos
Sarnak
 
Join Date: Dec 2007
Posts: 60
Default Linux Server Rebuild (3/1/13)

To compile and run a linux server (assuming 32 bit debian/ubuntu) (please let me know if I'm wrong about anything - a lot of this info was ripped from other guides, and X's and Proskeptics scripts)

Are these the proper steps?


1.Update host kernel info
Code:
cp /etc/sysctl.conf /etc/sysctl.conf_original
grep -v "kernel.shm" /etc/sysctl.conf | grep -v "TJL" > /etc/new_sysctl.conf
mv /etc/new_sysctl.conf /etc/sysctl.conf
echo "# added by TJL - 2012-02-27 for eqemu" >> /etc/sysctl.conf
echo "kernel.shmmax = 134217728" >> /etc/sysctl.conf
echo "kernel.shmall=65536" >> /etc/sysctl.conf
2.apt-get updates/installs
Code:
apt-get clean
apt-get update
pt-get -y install git git-core gcc g++ cpp libmysqlclient-dev libio-stringy-perl
apt-get -y install zlib-bin zlibc unzip make cmake subversion
apt-get -y install libmysqlclient-dev libperl-dev mysql-client-5.1
apt-get -y install mysql-server
3.make dirs start git
Code:
mkdir -p /home/eqemu/server/logs
mkdir -p /home/eqemu/source
mkdir -p /home/eqemu/server/Maps
mkdir -p /home/eqemu/server/quests
mkdir -p /home/eqemu/server/plugins
mkdir -p /home/eqemu/server/shared

cd /home/eqemu/source

git clone git://github.com/EQEmu/Server.git
svn co http://projecteqdb.googlecode.com/svn/trunk/peqdatabase
svn co http://projecteqquests.googlecode.com/svn/trunk/quests
svn co http://eqemumaps.googlecode.com/svn/trunk/Maps

4.copying things
Code:
cp -r /home/eqemu/source/Maps/* /home/eqemu/server/Maps/
cp -r /home/eqemu/source/quests/* /home/eqemu/server/quests/
chmod --recursive ugo+rwx /home/eqemu/server/quests/
cp -r /home/eqemu/source/quests/plugins/* /home/eqemu/server/plugins/
chmod --recursive ugo+rwx /home/eqemu/server/plugins/
cp /home/eqemu/source/Server/utils/defaults/commands.pl /home/eqemu/server/
cp /home/eqemu/source/Server/utils/defaults/plugin.pl /home/eqemu/server/
cp /home/eqemu/source/Server/utils/defaults/worldui.pl /home/eqemu/server/

5.SQLs
Code:
mysql -u root -p*PASSWORD* -e "drop database if exists peqdb; create database if not exists peqdb;"
gunzip peqdb_rev*.sql.gz
mysql -u root -p*PASSWORD* -f -D peqdb < /home/eqemu/source/peqdatabase/peqdb_*.sql
# that might take a little time -- just under two minutes on my machine...
mysql -u root -p*PASSWORD* -f -D peqdb < /home/eqemu/source/peqdatabase/load_player.sql
mysql -u root -p*PASSWORD* -f -D peqdb < /home/eqemu/source/peqdatabase/load_login.sql
mysql -u root -p*PASSWORD* -f -D peqdb < /home/eqemu/source/peqdatabase/load_bots.sql

6.Move things
Code:
cd /home/eqemu/server
cp /home/eqemu/source/Server/utils/defaults/eqemu_config.xml.full eqemu_config.xml
cp /home/eqemu/source/Server/utils/defaults/log.ini .
cp /home/eqemu/source/Server/loginserver/login_util/login.ini .
cp /home/eqemu/source/Server/loginserver/login_util/login_opcodes.conf .
cp /home/eqemu/source/Server/loginserver/login_util/login_opcodes_sod.conf .
cp /home/eqemu/source/Server/utils/patches/*.conf .
7.compiling and relocating files
Code:
# Fixed that they need the crypt files during the single make, not after. X
# These are the 32bit crypt files - 64 bits commented out inline.
# Switch comments for 64-bit OS. (Different process for GIT-based 
compile - X)
#
cd /home/eqemu/source/Server/dependencies

# 32 bits
wget -c http://projecteqemu.googlecode.com/files/ubuntu_LoginServerCrypto_x86.zip

# 64 bits
# wget -c http://projecteqemu.googlecode.com/files/ubuntu_LoginServerCrypto_x64.zip

rm -rf libEQEmuAuthCrypto.a
rm -rf libcryptopp.a
unzip ubu*.zip
#
# Added CMAKE section, to be able to use make later on. X.
#
echo
echo ' '
echo ' +--------------------------------------------------------------+'
echo ' Now CMAKE: Do not take advanced options, '
echo ' Make sure you have the Loginserver to ON, as well as'
echo ' EQEMU_ENABLE_RVALUE_MOVE to ON'
echo ' If it starts asking for unknown PATHS, something broke. Restart. '
echo ' +--------------------------------------------------------------+'
echo ' '
mkdir /home/eqemu/source/build
cd /home/eqemu/source/build
cmake -G "Unix Makefiles" -i /home/eqemu/source/Server/
make clean &> /home/eqemu/clean_eqemuserver.log
echo ' '
echo ' Compiling source-code -- please wait... '
echo ' '
make &> /home/eqemu/compile_eqemuserver.log
#
# takes 12 minutes (tested with make -j, craps out. Won't suggest it - X)
# check that log file with nano just to see that there were no errors..
# if there were errors, then they'd probably be on the screen too, so only panic
# if you see a problem on-screen
#
# or use tail /home/eqemu/compile_eqemuserver.log
# to see the last lines - if it hits 100%, you're done - X.
#
echo ' '
echo '+--------------------------------------------------------------+ '
echo '! Making links to compiled executables in the server directory.!'
echo '+--------------------------------------------------------------+ '
#read -p "[ Press [ENTER] to continue... ]"
echo ' '
#
# Fixed the links to take new build process into account - X.
#
ln -s /home/eqemu/source/build/Bin/shared_memory /home/eqemu/server/shared_memory
ln -s /home/eqemu/source/build/Bin/world /home/eqemu/server/world
ln -s /home/eqemu/source/build/Bin/zone /home/eqemu/server/zone
ln -s /home/eqemu/source/build/Bin/loginserver /home/eqemu/server/loginserver
ln -s /home/eqemu/source/build/Bin/eqlaunch /home/eqemu/server/eqlaunch
ln -s /home/eqemu/source/build/Bin/chatserver /home/eqemu/server/chatserver
ln -s /home/eqemu/source/build/Bin/mailserver /home/eqemu/server/mailserver
#
cd /home/eqemu/server

8.write a startup script
Code:
# Adapted startup script, EQEmuLoginServer is no longer used, it is now
# just loginserver, as well as some other fixes - X.
#
echo ' '
echo '+--------------------------------------------------------------+ '
echo '! Writing Startup Script... !'
echo '+--------------------------------------------------------------+ '
read -p "[ Press [ENTER] to continue... ]"
echo ' '
echo 'ulimit -c unlimited ' > /home/eqemu/server/startup.sh
echo ' ' >> /home/eqemu/server/startup.sh
echo 'cd /home/eqemu/server ' >> /home/eqemu/server/startup.sh
echo 'export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:. ' >> /home/eqemu/server/startup.sh
echo ' ' >> /home/eqemu/server/startup.sh
echo 'rm -rf /home/eqemu/server/logs/*.log ' >> /home/eqemu/server/startup.sh
echo 'chmod --recursive ugo+rwx /home/eqemu/server/quests ' >> /home/eqemu/server/startup.sh
echo ' ' >> /home/eqemu/server/startup.sh
echo 'echo Starting Login Server... ' >> /home/eqemu/server/startup.sh
echo ' ./loginserver 2>&1 >> /home/eqemu/server/logs/login.log & ' >> /home/eqemu/server/startup.sh
echo ' ' >> /home/eqemu/server/startup.sh
echo 'echo Waiting about 5 seconds before starting World Server... ' >> /home/eqemu/server/startup.sh
echo 'sleep 5 ' >> /home/eqemu/server/startup.sh
echo './shared_memory 2>&1 >> /home/eqemu/server/logs/sharedmem.log' >> /home/eqemu/server/startup.sh
echo 'sleep 3 ' >> /home/eqemu/server/startup.sh
echo ' ' >> /home/eqemu/server/startup.sh
echo './world 2>&1 > /home/eqemu/server/logs/world.log & ' >> /home/eqemu/server/startup.sh
echo ' ' >> /home/eqemu/server/startup.sh
echo 'echo Waiting 10 seconds before starting the zones via launcher ' >> /home/eqemu/server/startup.sh
echo 'sleep 10 ' >> /home/eqemu/server/startup.sh
echo './eqlaunch zone 2>&1 > /home/eqemu/server/logs/zones.log & ' >> /home/eqemu/server/startup.sh
echo ' ' >> /home/eqemu/server/startup.sh
echo 'echo The server is mostly ready... give it a couple of minutes '  >> /home/eqemu/server/startup.sh
echo 'echo to load stuff from the databases for the zones and users ' >> /home/eqemu/server/startup.sh
echo 'echo can start logging in. ' >> /home/eqemu/server/startup.sh
chmod ugo+x /home/eqemu/server/startup.sh


echo '+--------------------------------------------------------------+'
echo '! Writing db.ini !'
echo '+--------------------------------------------------------------+'
echo '[Database] ' > /home/eqemu/server/db.ini
echo "host=$EXT_IP " >> /home/eqemu/server/db.ini
echo 'user=eqemu ' >> /home/eqemu/server/db.ini
echo "password=*PASSWORD* " >> /home/eqemu/server/db.ini
echo 'database=peqdb ' >> /home/eqemu/server/db.ini
#
9.priv settings, kill script
Code:
chmod -R ugo+rw /home/eqemu

echo "killall eqlaunch world zone loginserver " >> /home/eqemu/server/killeq.sh
chmod -R ugo+x /home/eqemu/server/killeq.sh


10.Config EQEMU_CONFIG.XML
Code:
Set Shortname, longname, host, database, etc.


10.is it done?
Code:
#ON
echo '! /home/eqemu/server/startup.sh !'
#OFF
echo '! /home/eqemu/server/killeq.sh !'
99.TO DO
Code:
I need to test this, see if it works, see if I'm missing anything. I feel like I probably am.
I also need to make this more friendly to read, I threw a lot of script in there
I'd like to turn this into an actual guide at some point to help newbies (like me, admittedly)
Reply With Quote
  #2  
Old 03-01-2013, 02:33 PM
lerxst2112
Demi-God
 
Join Date: Aug 2010
Posts: 1,742
Default

One way to find out is to try it and see.
Reply With Quote
  #3  
Old 08-07-2013, 05:29 PM
Dimorge02
Fire Beetle
 
Join Date: Sep 2004
Posts: 29
Default

Step 5. gunzip peqdb_rev*.sql.gz

needs to include full path to peqdb
Reply With Quote
  #4  
Old 08-07-2013, 05:59 PM
Dimorge02
Fire Beetle
 
Join Date: Sep 2004
Posts: 29
Default

I'll post current steps for patching database if you want.
Reply With Quote
  #5  
Old 10-17-2013, 08:26 PM
cmileto
Fire Beetle
 
Join Date: Jun 2012
Posts: 10
Default

yes pls, tyvm!
__________________
Doing it for the lolz...
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

   

All times are GMT -4. The time now is 11:57 AM.


 

Everquest is a registered trademark of Daybreak Game Company LLC.
EQEmulator is not associated or affiliated in any way with Daybreak Game Company LLC.
Except where otherwise noted, this site is licensed under a Creative Commons License.
       
Powered by vBulletin®, Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Template by Bluepearl Design and vBulletin Templates - Ver3.3