The FutureGateway Science Gateway (FGSG) is an environment capable to host multiple containerised nodes provided by Docker virtualisation engine. Using this environment it has been developed for the Department of phisics of Catania, a job submission system based on Dropbox file sharing system. In order to execute a set of NetLogo simulations it is simply requested to create a file named nlexe containing a specific set of parameters. To get more information about the FGFS, please visit its own presentation page.
This is an environment to execute NetLogo scritps in parallel and seamlessly. The system uses two different components each implemented as a dedicated container:
- volmanager - It has the responsabiltiy to keep updated a particular shared folder (DropBox) triggering slave nodes once an execution request has been identified.
- slave - The slave node is the final container that phisically execute a single NetLogo script.
Each component will be described in detail by below sections.
The whole execution workflow is managed by a single bash script; this because the use of a single script helps the creation of a dedicated application inside a ScienceGateway (FutureGateway). The script can initiate, stop and manage the service activity; in particular:
INIT; A volmanager container, together with a dedicated user docker volume will be instantiated. During container startup, the DropBox configuration requires to acknowledge the sharing request prompting the user to click a link. The loop will continue until a timeout or user acknlowledgement occurs. After this operation, the volmanager will keep updated the DropBox volume content and it will trigger NetLogo executions instantiating parallel instances of slave containers once an execution request will be found. Triggering of NetLogo execution is possible just creating a file named:
_nlexe. Inside that file several parameters may be specified and used by the master container. ALL nodes will share the same docker volume so that all nodes may access to the same files and directories of the DropBox shared folder.
DELETE; This operation will remove all allocated resources done by the INIT command.
DBXRESET; Reset th Dropbox synchronizaton daemon causing its restart
CHKSTOP; Stop the main execution check daemon
CHKSTART; Start the execution check daemon if not already running
Volume management node. It keeps the responsibility to keep updated the user shared volume (DropBox) and trigger an execution, as soon as the user places a
_nlexe file inside a directory holding the NetLogo sccript to execute. The
_nlexe file will be renamed to
.nlrun, when the execution starts. During the execution, the volmanager wil start several instances of slave nodes, each executing a single NetLogo run. Output files will be generated accordinlgy to the parameter values specified in file
_nlexe and placed inside a directory having as name the timestamp of the execution start.
_nlexe contains several values that must be specified to run the NetLogo simulations. Below the list and the meaning of each parameter:
COUNT- Specify the number of instance to run
FILE- The name of the NetLogo file
EXPERIMENT- The name of the experiment
OUTPUTFILE- The name of the output file generated by the script. This name will be replaced by
X_OUTPUTFILEwhere X is the execution counting number.
Execution parameter file may contain variables that will change the standard/default submission behavior. These variables are a subset of the
netlogo_exec.sh configuration variables.
Below a list of these variables:
SUBMIT_WAIT_DELAY- Delay used to wait for new available slots
SUBMIT_DELAY- Delay used to wait after each submission, this allows docker to update its internal status avoiding overloading requests; use this parameter carefully
RUN_PATTERN- Pattern used to notify execution
ERR_PATTERN- Pattern used to notify execution errors
DONE_PATTERN- Pattern used to notify done execution
DUSER- Remote shell user to start NetLogo slave containers
DHOST- Remote shell host name to start NetLogo slave containers
SLAVE_IMAGE- Docker image used for NetLogo slave executions
One of the most important aspect of the volmanager node is the file syncrhonization with a given Dropbox account. The association to the Dropbox user account is accomplished with a special link provided by the dropbox client during volmanager startup. Onche the execution control loop starts the synchronization, only specific paths will be synchronized. The paths to be enabled for synchronization can be specified in the file:
netlogo_sync.txt, that can be also modified during volmanager lifetime. The synchronization process is handled by a dedicated script named: netlogo_sync.sh
Slave instance is the responsible of a single headless NetLogo execution and fired by the volmanager node, during its loop.
Leave your comments
Back to the main news page.