deploying_snowballs_ubuntu7 - ryzom/ryzomcore GitHub Wiki


title: Deploying NeL+NeLNS+Snowballs on Ubuntu 7.10 description: published: true date: 2023-03-01T05:22:29.135Z tags: editor: markdown dateCreated: 2022-03-16T10:34:30.427Z

Roughly based on the guide from here: http://www.opennel.org/confluence/display/~tao/Debian+4.0r1+Quick+Guide

Installation of NeL, NeLNS and Snowballs with CMake under Ubuntu 7.10 (made using a default installation on a VPS at Gandi)

Update your software.

aptitude update
aptitude upgrade

Install the prerequisite packages.

Keep selecting this text to the right until it stops moving, and then copy it, cause you won't see all of it immediately.

aptitude install subversion make cmake gcc glibc-doc manpages-dev autoconf automake autotools-dev libtool flex bison libc6-dev zlib1g-dev linux-kernel-headers libxml2-dev libfreetype6-dev libopenal0a libopenal-dev libjpeg62-dev xorg-dev libalut-dev g++ libgtk2.0-dev libogg-dev libvorbis-dev libcegui-mk2-0c2a libcegui-mk2-dev libgl1-mesa-dev libglu1-mesa-dev mesa-utils libmysqlclient15-dev

Here's some useful tools that might come in handy too on a server.

aptitude install nano postfix screen

Get the NeL source.

First go to some directory with about 2GB space (for compiling), where you'll keep the nel source files.

cd .
mkdir opennel
svn co https://nel.svn.sourceforge.net/svnroot/nel/trunk opennel

Build and install.

NeL

cd opennel
cd nel
mkdir cmake
cd cmake
cmake -G "Unix Makefiles" ..
make install

NeLNS

cd ..
cd ..
cd nelns
mkdir cmake
cd cmake
cmake -G "Unix Makefiles" ..
make install

Snowballs2

cd ..
cd ..
cd snowballs2
mkdir cmake
cd cmake
cmake -G "Unix Makefiles" ..
make install

Setting up the NeLNS Login Service

Launching the NeLNS Login Service

Setting up a Shard

Set the NSHost in the common NeLNS service configuration to the NS of the shard, set the WindowStyle to NONE and configure the error report mail addresses and smtp server. Make a backup of your config after it's ok.

cd /usr/local/share/nel/nelns/
nano common.cfg
// By default, use WIN displayer.
// When running inside a console, you should change this to NONE.
WindowStyle = "NONE";

// By default, use the naming service at localhost.
// The naming service is used to link services together into one single shard.
NSHost = "127.0.0.1";

DontUseAES = 1;

NegFiltersDebug    += { "NETL", "NET" };
NegFiltersInfo     += { "NETL" };
NegFiltersWarning  += { };

// Where to send error reports.
DefaultEmailSMTP = "127.0.0.1";
DefaultEmailFrom = "[email protected]";
DefaultEmailTo = "[email protected]";
cp common.cfg bkp.common.cfg

Configure the NeLNS Welcome Service to use the correct ShardId as known by the Login Service, there can only be one WS running per ShardId. Set the LSHost to point to your Login Service. Make another backup.

nano welcome_service.cfg
// Link the common configuration file.
RootConfigFilename = "common.cfg";

DisplayedVariables += { "", "@OnlineFS|frontends", "@OnlineUsers|users", "NbOnlineUsers|OnlineUsersNumber" };

// Address of the Login Service.
LSHost = "ls.shards.kaetemi.be";

// Short name of the Frontend Service.
FrontendServiceName = "FS";

// Value that identifies the shard in the database. Must be unique for each different shard.
ShardId = 309;

ExpectedServices = { };

PlayerLimit = 1000;

// Access level to shard:
// 0: only dev
// 1: dev + privileged users (see also OpenGroups variable)
// 2: open for all
ShardOpen = 2;

// File that contains the ShardOpen value (used to override ShardOpen value through AES' command createFile)
// For instance, ShardOpen default value is 0, then AES creates a file to set ShardOpen to 2. If WS crashes,
// ShardOpen is still set to 2 when it relaunches...
ShardOpenStateFile = "";

// Privileged Groups
OpenGroups = "";

DontUseAES = 1;

// Set what the game is.
ClientApplication = "snowballs2";
cp welcome_service.cfg bkp.welcome_service.cfg

Set the UniqueOnShardServices for the NeLNS Naming Service, and make a backup again.

nano naming_service.cfg
// Link the common configuration file.
RootConfigFilename = "common.cfg";

DisplayedVariables += { "", "@Services|nsServices" };

SId = 1;

DontUseNS = 1;
DontUseAES = 1;

NegFiltersDebug = { "NETL" };
NegFiltersInfo = { "NETL" };

UniqueOnShardServices = { "WS", "POS", "CHAT" };
UniqueByMachineServices = { };
cp naming_service.cfg bkp.naming_service.cfg

Set the NSHost in the common Snowballs service configuration to the NS of the shard, set the WindowStyle to NONE and configure the error report mail addresses and smtp server, and make a backup as usual.

cd /usr/local/share/nel/snowballs/
nano common.cfg
// By default, use WIN displayer.
// When running inside a console, you should change this to NONE.
WindowStyle = "NONE";

// By default, use the naming service at localhost.
// The naming service is used to link services together into one single shard.
NSHost = "127.0.0.1";

DontUseAES = 1;

NegFiltersDebug    += { "NETL", "NET" };
NegFiltersInfo     += { "NETL" };
NegFiltersWarning  += { };

// Where to send error reports.
DefaultEmailSMTP = "127.0.0.1";
DefaultEmailFrom = "[email protected]";
DefaultEmailTo = "[email protected]";
cp common.cfg bkp.common.cfg

Snowballs2 Position Service
Snowballs2 Chat Service
Snowballs2 Frontend Services

Launching a Shard

Go to a dir where it's safe to have random log.log files dropped, launch 'screen', make new sessions for every service, and launch every one of them.

cd ~
screen

Hit Enter

welcome_service

Hit Ctrl-A, Ctrl-C (hold down Ctrl and type A then C) to create a new session.

naming_service

Ctrl-A, Ctrl-C

sno_position

Ctrl-A, Ctrl-C

sno_chat

Ctrl-A, Ctrl-C

sno_frontend

You can then use Ctrl-A, Ctrl-N to switch between the sessions in screen.
To get out of your terminal without killing the sessions, you can detach the screen sessions by pressing Ctrl-A, Ctrl-D, and you'll be back in your normal console, after which you can safely kill your remote connection without losing the services.
To regain control of the screens, type:

screen -r

If your terminal is killed while screen is open, screen is automatically detached, and you can regain control of the sessions again in the same way.
To kill a session, you can either use Ctrl-A, Ctrl-K, or Ctrl-C out of the service and type exit to close the session.

⚠️ **GitHub.com Fallback** ⚠️