multiprocess

NAME
SYNOPSIS
PREPARATION
EXECUTION
EXAMPLE
COPYRIGHT
SEE ALSO

NAME

multiprocess − RWP*Load Simulator execution multi-process execution

SYNOPSIS

Execution of a single rwloadsim process may not be sufficient to run a complex workload, both due to complexity or due to the need to run a high number of threads concurrently. You can therefore run rwloadsim in multi-process mode, that consist of a preparation step followed by an actual execution with several concurrently running rwloadsim processes. In a multi-process run, statistics will be saved by each rwloadsim process as in ordinary runs, but all processes will use the same runnumber. For subsequent reporting, graphing, etc, the multi processes therefore appear as a single run.

Multi-process runs require a repository database and the first step gets the runnumber from a sequence in the repository database. Additionally, it is during the first step that the common start time is defined using the -c option to rwloadsim.

PREPARATION

To prepare a multi-process run, first execute rwloadsim only providing the input file (or files) needed to make a connection to the repository database. You are recommended not providing any other input files, except if you need to execute some code during this step; examples of such code could be code that inserts or updates certain aspect of the repository that are relevant for the whole run.

You must also provide the -P option with the name of a file where rwloadsim will write information needed by the subsequent actual simulation run. The contents will be one line of text without any white-space. In the current release, the contents is in the format NNN:SSSSSSSS.MMM, where NNN is the runnumber and the rest represents the common start time for all control loops since some epoch with ms resolution. This contents may change in a future release of rwloadsim and you are strongly advised against depending on the format of the file.

As more preparation, setup, creation of session pools, etc. would be required by a multi-process run, you should normally always provide the -c option with a value higher than the default of 5s setting the common control loop start time further into the future.

EXECUTION

Each rwloadsim process that is part of your actual execution must be started with either the -R or -M option. They have the same purpose so you can use the one that suits your scripting model best.

The -R option takes the name of the prepare file that was created in your prepare run as its option value. The -M option takes the contents of the prepare file (which is a single line) as a text string as its option value.

The input file(s) and potentially arguments provided to each rwloadsim program should implement your entire workload and you can very well start rwloadsim processes with different (but to you related) workloads and/or start multiple processes with the same.

If needed for your subsequent reporting or graphing, use the -p option to set a number that each rwloadsim process will use when it saves statistics into the repository tables. If not provided, the process number from the Operating System will be used.

If required, you can use ssh to have other systems involved in a single multi-process run; if doing so, all systems involved must have their system time coordinated e.g. via ntp.

EXAMPLE

This small example shows how you can use multi-process execution:

# prepare a run setting common start time 10s into the future
rwloadsim -P prepfile.txt -c 10 repository.rwl

# start five ordinary executions in background
for pno in 1 2 3 4 5
do
  rwloadsim -R prepfile.txt -p $pno fullrun.rwl &
done

# Use ssh to start a run with some special stuff on another host
ssh systemhost rwloadsim -p 0 -M ‘cat prepfile.txt‘ systemstuff.rwl &

# wait for all to complete
wait

COPYRIGHT

Copyright © 2023 Oracle Corporation

Licensed under the Universal Permissive License v 1.0 as shown at https://oss.oracle.com/licenses/upl

SEE ALSO

statistics(1rwl), rwloadsim(1rwl)