mampac

mampac — Sequentially execute multiple input files.

Description

The mampac utility is useful for executing a group of AMPAC input files or even an entire testsuite of input files. Mampac runs in the background and AMPAC jobs are executed sequentially. A simple summary of the each AMPAC job is written to the file MAMPAC.LOG. To monitor the progress of mampac while it is running, use tail -f MAMPAC.LOG in the same directory in which mampac is running.

By default, mampac avoids overwriting old AMPAC result files by appending a version number to each of the result files. For example, mampac temp.dat will produce temp.out, temp.arc, temp.vis, and perhaps other files. If temp.out already exists, then mampac temp.dat will instead produce temp.out~1, temp.arc~1, temp.vis~1, etc. The version number is increased incrementally to avoid overwriting any previous versions. This feature may be turned off using the -nv flag. Without version control, result files may be silently overwritten.

Mampac can be run in three different modes.

  1. Run all AMPAC input files (*.dat) in the current directory (mampac [-nv]).

  2. Recursively run all input files (*.dat) in the current directory and all sub-directories (mampac -r [-nv]).

  3. Run a select group of files. Wildcards are expanded allowing easy specification of groups of files. For example, to run all jobs in the current directory starting with "test", use mampac [-nv] test*.dat.

Usage:

		mampac [-r] [-nv] {filename(s)}

options

-r

Recursively search directories and run AMPAC jobs [default current directory only].

-nv

Turn off version control [default on].

filename(s)

Run each of the specified AMPAC jobs in the background. When filename(s) are specified, the -r option is ignored. Multiple filenames can be entered separated by spaces. UNIX file globbing (for example, using * as a wildcard) is also supported.

Output:

When mampac is launched a small amount of text is written to the screen:

Process: 25381
Running AMPAC 8.13 for *.dat in directory:
/home/semo

To check the status of your job, type "cat MAMPAC.LOG".

The text file named MAMPAC.LOG is written to the current working directory:

Running AMPAC 8.13 for *.dat in directory:
/home/semo

Thu Feb 19 11:23:22 CST 2004


Submitting AMPAC 8.13 Data file:  Ammonia.dat
Running in Temporary Directory:  amp25386
AMPAC: /home/semo/Ampac/program/ampac.exe

Thu Feb 19 11:23:23 CST 2004

Submitting AMPAC 8.13 Data file:  Ammonium.dat
Running in Temporary Directory:  amp25386
AMPAC: /home/semo/Ampac/program/ampac.exe

Thu Feb 19 11:23:23 CST 2004

... additional output ...

Thu Feb 19 11:23:29 CST 2004

Submitting AMPAC 8.13 Data file:  Water.dat
Running in Temporary Directory:  amp25386
AMPAC: /home/semo/Ampac/program/ampac.exe

Thu Feb 19 11:23:30 CST 2004
1.7u 3.1s 0:08 60%
THAT'S ALL FOLKS...

See also:

Chapter 5, Presenting Input to the Program