HP-MPI User's Guide (11th Edition)

Getting started
Getting started using Windows
Chapter 2 33
> job add 4288 /numprocessors:1 ^
/stdout:\\node\path\to\a\shared\file.out ^
/stderr:\\node\path\to\a\shared\file.err ^
"%MPI_ROOT%\bin\mpirun" -ccp \\node\path ^
\to\hello_world.exe
Step 6. Submit the job. The machine resources are allocated and the job is run.
> job submit /id:4288
Building and running MPMD applications on
Windows CCS
To run Multiple-Program Multiple-Data (MPMD) applications or other
more complex configurations that require further control over the
application layout or environment, use an appfile to submit the HP-MPI
job through the CCS scheduler.
Create the appfile indicating the node for the ranks using the -h <node>
flag, and the rank count for the given node using the -n X flag. Ranks
will be laid out in the order they appear in the appfile. Submit the job
using mpirun -ccp -f <appfile>. For this example, the
hello_world.c program will be copied to simulate a server and client
program in an MPMD application. The print statement for each will be
modified to indicate server or client program so the MPMD
application can be demonstrated:
Step 1. Change to a writable directory on a mapped drive. The mapped drive
should be to a shared folder for the cluster.
Step 2. Open a Visual Studio command window. This example uses a 64-bit
version, so a Visual Studio x64 command window is opened.
Step 3. Copy the hello_world.c source to server.c and client.c. Then edit
each file to change the print statement and include 'server' and 'client' in
each:
X:\Demo> copy "%MPI_ROOT\help\hello_world.c" .\server.c
X:\Demo> copy "%MPI_ROOT\help\hello_world.c" .\server.c
Now, edit each to modify the print statement for both .c files to include
'server' or 'client' in the print so the executable being run is visible.
Step 4. Compile the server.c and client.c programs: