Everything for the server on Debian 5 (Lenny)

Added by molator almost 5 years ago

Thank you to Kervala and Kerozcak (and the others)

Everything here is not new but i decided to write down my own Debian 5 (Lenny) Howto.

Remote access

Install SSH to remote access to your server :

apt-get install ssh

You will need administration rights for the first steps.

Get the source

Install mercurial :

apt-get install mercurial

You should create a specific user for the server.

We will use the following directory for this Howto :

/home/ryzom

Get the source :

hg clone http://ryzom.hg.sourceforge.net:8000/hgroot/ryzom/ryzom

Build NeL and the server using "make_all"

Install required packages

You can't build NeL with CMake on Debian 5 (Lenny).
CMake version is outdated.

It should be possible with unstable Debian 6 (Sid).

Install various packages :

apt-get install libxml2-dev g++ libtool automake autoconf libpng12-dev libjpeg62-dev rrdtool libmysqlclient15-dev flex libxmu-dev bison libexpat1-dev

Install non Debian 5 (Lenny) packages for intel processor :

wget http://fr.archive.ubuntu.com/ubuntu/pool/universe/w/w3c-libwww/libwww-ssl0_5.4.0-11build2_i386.deb

wget http://fr.archive.ubuntu.com/ubuntu/pool/universe/w/w3c-libwww/libwww-dev_5.4.0-11build2_i386.deb

dpkg -i libwww-ssl0_5.4.0-11build2_i386.deb

dpkg -i libwww-dev_5.4.0-11build2_i386.deb

or amd processor :

wget http://fr.archive.ubuntu.com/ubuntu/pool/universe/w/w3c-libwww/libwww-ssl0_5.4.0-11build2_amd64.deb

wget http://fr.archive.ubuntu.com/ubuntu/pool/universe/w/w3c-libwww/libwww-dev_5.4.0-11build2_amd64.deb

dpkg -i libwww-ssl0_5.4.0-11build2_amd64.deb

dpkg -i libwww-dev_5.4.0-11build2_amd64.deb

Install luabind

Install required packages :

apt-get install liblua5.1-0-dev boost-build libboost-dev

Get luabind source

wget http://sunet.dl.sourceforge.net/project/luabind/luabind/0.9/luabind-0.9.tar.gz

Extract the source

tar xvfz luabind-0.9.tar.gz

Build luabind

bjam --prefix=/usr/local install

Set up your shell (Bash)

Add the paths in your .bashrc :

export RYHOME="/home/ryzom/code"

export RYZOM_PATH="/home/ryzom/code/ryzom"

export PATH=$PATH:$RYZOM_PATH/tools/scripts/linux

Reload the configuration :

. .bashrc

or reconnect.

Build NeL and the server

Set static linking :

buildmode static

You should see :

Compilation modes :

Debug mode : OFF

Static linking : ON

Dynamic linking : OFF

Silent compilation : OFF

Build :

make_all

To follow the progress, type in different terminals :

tail -f $RYZOM_PATH/log/make_all_info.log

tail -f $RYZOM_PATH/log/make_all_error.log

Set up ryzom server

Edit $RYZOM_PATH/server/frontend_service.cfg and replace FSListenHost with your server domain name or ip :

FSListenHost = "open.ryzom.com";

That domain name or ip must be reachable by the client.

Edit $RYZOM_PATH/tools/server/admin/config.php and replace the path with your own :

define('NELTOOL_SYSTEMBASE','/home/ryzom/code/ryzom/tools/server/admin/');

Create rrd_graphs directory :

mkdir $RYZOM_PATH/server/save_shard/rrd_graphs/

Create log directory for client login and add write permission :

mkdir $RYZOM_PATH/tools/server/www/login/logs/

chmod o+w $RYZOM_PATH/tools/server/www/login/logs/

Edit $RYZOM_PATH/tools/server/www/login/config.php :

$LogRelativePath = './logs';

Duplicate templates and add write permission :

cp -r $RYZOM_PATH/tools/server/admin/templates/default $RYZOM_PATH/tools/server/admin/templates/default_c

chmod o+w $RYZOM_PATH/tools/server/admin/templates/default_c

Set up the webserver and database server

Install Apache, MySQL and phpMyAdmin :

apt-get install apache2 mysql-server phpmyadmin

Get Apache config here :
http://docs.google.com/leaf?id=0B3LX3q7MsUEGMWUzNTliYTgtOTI1Mi00ODAzLTg0MGEtYTNhNzM0NDYxNzIw&hl=en

Replace the paths with your own and add the content to :

/etc/apache2/httpd.conf

Restart Apache :

/etc/init.d/apache2 restart

Get database content and privileges :
http://docs.google.com/leaf?id=0B3LX3q7MsUEGOGRkZDUyMDEtY2UyZS00NjFjLWJmNTItYmZlNzhlYmE4MjVl&hl=en

Replace the paths with your own and import in phpMyAdmin:

/home/ryzom/code/ryzom/server/save_shard/rrd_graphs

Run the shard

Install screen :

apt-get install screen

Run :

shard start

Each service use a "screen" (virtual terminal).
You can switch to the next "screen" using :

CTRL + A + N

You might be obliged to hit "enter" to run some of the services.

Monitor your shard

You can monitor your shard with the shard administration website.
Enter your server domain name or ip in your browser to use it.

That's all folks!

French version :
https://docs.google.com/leaf?id=0B3LX3q7MsUEGNGExOGRmYjktODk3Yi00ZWMxLWE4YTAtNmM3YmI2ZmYwYWQ3&hl=en