Version 8 (modified by jorisborgdorff, 12 years ago) (diff) |
---|
Using MTO
The MUSCLE Transfer Overlay (MTO) is a daemon for forwarding traffic from MUSCLE 2. This service is often required when MUSCLE 2 is run on several sites with firewall restrictions. On each site, a MTO should be placed on a node that is less strict in its firewall policies, but that can be accessed from other MTO nodes. Often, clusters have an interactive node that is suitable for this purpose.
If it is already installed, set up, and connected between all needed sites, all that is needed is that the --intercluster flag is added to the command-line, the rest stays the same.
muscle2 -mc model.cxa.rb --intercluster sub1
The address of the simulation manager (suppose its 10.0.0.200:5002) can then directly be used on another site:
muscle2 -c model.cxa.rb --intercluster -M 10.0.0.200:5002 sub2
For convenience, the --intercluster flag also has the shorthand -i.
Configuration files
If the MTO is not yet set up for the sites that are needed, first the configuration files have to be set and then the MTO can be executed.
MTO's configuration is stored in two files:
- global topology file (MUSCLE_HOME/etc/mto-topology.cfg)
// Comment # Comment # host definiton # <name> <address> [<port>] # if port is ommited, this MTO will not listen for incomming connections A localhost B localhost 5100 C localhost D localhost 5300
- local mto config file ( MUSCLE_HOME/etc/mto-config.cfg)
# Name of this MTO as in mto-copology.cfg myName = A # Port range for clients of this MTO # Clients may register listening ports only from this range. # This range must not overlap any other MTO's range. localPortLow = 5002 localPortHigh = 5099 # Port and address where this MTO will listen for client requests. # Port and address for other MTO's is located in the topology file. internalPort = 5001 internalAddress = private-address
For MUSCLE 2 commands, the second file is of importance: it implies that it can only use a limited port range on a given cluster, and how it should contact the MTO. To make this information available to MUSCLE 2, create the file MUSCLE_HOME/etc/muscle.defaults matching the mto-config.cfg file, containing
export MUSCLE_MTO=private-address:5001 export MUSCLE_PORT_MIN=5002 export MUSCLE_PORT_MAX=5099
When MUSCLE_HOME/etc/muscle.profile is sourced, these variables are then also set.
starting MTO
- debug mode
mto --debug
- deamon mode
mto
Example setup
Suppose we are using two domains, Amsterdam.nl (IP: 50.50.50.50) and Poznan.pl (IP: 100.100.100.100). For the former, we use port range 5000-5999, and it does not have any open ports but it can contact the latter, with port range 6000-6999 and an open port 20300. Then the global topology becomes
# <name> <address> [<port>] Ams amsterdam.nl Poz poznan.pl 20300
In Ams, we have the local configuration
myName = Ams localPortLow = 5002 localPortHigh = 5999 internalPort = 5001 internalAddress = 50.50.50.50
And in Poz, the configuration becomes:
myName = Poz localPortLow = 6002 localPortHigh = 6999 internalPort = 6001 internalAddress = 100.100.100.100
For this configuration to work, on Ams port 5001 must be available and on Poz port 6001 and port 20300 must be available.