[proc=<min>[,<max>]] | Number of processors to use |
[file=<command file>] | File containing list of programs to run |
[test] | This will test all of the listed processors |
runpar test
runpar file=script proc=6,12
This program is for coarse grained parallelization on virtually any platform. It permits parallel execution on a network of workstations or a single multiprocessor machine. This was specifically done in a way to ensure maximum portability, without requiring the installation of a large parallel processing package (like MPI). For this to work, the user must have his account(s) set up so rsh can execute programs on all of the referenced machines. Each machine must also have remote access to the run directory, although this may be a different location on each machine.
The machine parameters are specified in a file called .mparm located in the directory runpar is run from. If this file does not exist, dynamic load usage (min and max processors) will not function, and only 'min' procssors will be used.
The .mparm file is 5 tab separated columns, with one machine specified per line. This is a sample entry for one machine:
rsh 2 1 localhost /homes/stevel/tst
The first column is always 'rsh'. Column 2 specifies the total number of procssors on the machine. Column 3 is a relative speed factor (currently unused). Column 4 is the machine name. 'localhost' is a special machine name, and should always be present. The final column is the path to the run directory on that machine.
For example, when running on a single 8 processor machine, the file would contain one line:
rsh 8 1 localhost /homes/stevel/tst
If there are 4 workstations named alpha, beta, gamma and delta, each with one processor, with the job being submitted on alpha, the file might contain:
rsh 1 1 localhost /homes/stevel/test
rsh 1 1 beta /hosts/alpha/disk1/stevel/test
rsh 1 1 gamma /hosts/alpha/disk1/stevel/test
rsh 1 1 delta /hosts/alpha/disk1/stevel/test
When the job is submitted, the least loaded machines will be chosen to run the specified jobs. The 'min' number of processors will be used at all times, regardless of load. If enough unloaded processors are available, runpar will slowly begin to use more processors until 'max' are used. Periodically, the usage is reduced back to 'min', to allow other users jobs to take precedence. If the machine becomes loaded during this time, the load will shift to another processor if available.
'runpar test' can be used to test the .mparm file, and the configuration of the individual machines. This will also give an indication of the current load levels on each machine as determined by runpar.
Note that this program can be used for parallel submission of any jobs, but it supports only simple coarse grained parallelization with no inter-process communication.