Serverless Grids

From OpenSimulator

(Difference between revisions)
Jump to: navigation, search
Line 2: Line 2:
  
 
This hybrid architecture can be setup independent of whether you have Hypergrid enabled or not; however, for simplicity sake, the explanation here uses the pre-packaged configuration StandaloneHypergrid, because it already has all the right connectors enabled. For configurations of non-HG standalones, please ask on the IRC.  
 
This hybrid architecture can be setup independent of whether you have Hypergrid enabled or not; however, for simplicity sake, the explanation here uses the pre-packaged configuration StandaloneHypergrid, because it already has all the right connectors enabled. For configurations of non-HG standalones, please ask on the IRC.  
 +
 +
NOTE: this works with releases r10869 and above (as of Sep.28)
  
 
== <br>Step One: Install a DB server  ==
 
== <br>Step One: Install a DB server  ==

Revision as of 10:08, 29 September 2009

This tutorial explains how to set up a grid composed of several simulators, possibly running on different machines, by stitching standalones together, and without running extra servers (URM or others). The only other server you need besides OpenSim.exe (the simulator) is either a MySQL or MSSQL server -- the DB.

This hybrid architecture can be setup independent of whether you have Hypergrid enabled or not; however, for simplicity sake, the explanation here uses the pre-packaged configuration StandaloneHypergrid, because it already has all the right connectors enabled. For configurations of non-HG standalones, please ask on the IRC.

NOTE: this works with releases r10869 and above (as of Sep.28)

Contents


Step One: Install a DB server

This tutorial does not explain how to do this, but you need a database server running in one of your machines. Please see elsewhere on this wiki, or search on the Web how to do that. You can either use MySQL or MSSQL; this tutorial assumes MySQL, but for MSQL it's in all identical.

After installing a MySQL server, create an account called "opensim", and give all permissions to that account. For a grid spawning multiple machines, you need to set up this account so that it can access the DB server from other machines. Again, search elsewhere for how to do this, if you don't know.

Before you go any further, make sure this account is properly setup by logging to the DB server from all the machines where you plan to run simulators. If you can't login with the mysql client from those machines, using the opensim account you just created, OpenSim also won't be able to. So don't even attempt at proceeding to step two if this doesn't work.


Step Two: OpenSim Configuration

For each OpenSim simulator instance do this.

As usual, copy OpenSim.ini.example to your own copy of OpenSim.ini. Make whatever changes you usually make to work in HG standalone. You can use your prior copy of OpenSim.ini. Then make the following changes:

  1. Search for "userDatabase_plugin". Set it to
    userDatabase_plugin = "OpenSim.Data.MySQL.dll"
  2. Search for "user_source". Set it to
    user_source = "Data Source=XXX;Database=opensim;User ID=opensim;Password=YYY;"
    where
    XXX = localhost or the name of the machine where you have your MySQL server, if different from the local machine
    YYY = the password of the opensim account you have created
  3. In the [Architecture] section, make sure this one is choosen:
    Include-HGStandalone = "config-include/StandaloneHypergrid.ini"

Copy config-include/StandaloneCommon.ini.example to config-include/StandaloneCommon.ini, and make the following changes/settings:

  1. In the [DatabaseService] section, choose MySql instead of the default SQLite:
    StorageProvider = "OpenSim.Data.MySQL.dll"
    ConnectionString = "Data Source=XXX;Database=opensim;User ID=opensim;Password=YYY;"
    (see XXX and YYY above)
  2. In the [GridService] section, choose the MySql option instead of the default one:
    StorageProvider = "OpenSim.Data.MySQL.dll:MySqlRegionData"
    ConnectionString = "Data Source=XXX;Database=opensim;User ID=opensim;Password=YYY;"

Step Three: Region Configuration

For each OpenSim simulator instance, set up region files as you usually do. Make sure that no two regions are on the same coordinates. If you want the differerent simulators to form a larger contiguous space, place the regions in such a way that they are neighbours.

Step Four: Start Up the Simulators

As the title says, start the simulators. You may want to let each one finish starting up before starting the next one. For different simulators with neighbouring regions, you should see console messages pertaining to "HelloNeighbour", which is an indication that the simulators are finding each other.

Step Five: Login

Your login uri is the normal uri for standalones. That is, http://<one of your simulators>:<http port>


And voila! Insta-scalability without servers.

Personal tools
General
About This Wiki