Developer Guide

Contents

Setting Environment Variables on a Cluster

By default, when you call the MPI launch command
mpiexec
, the entire launching node environment is passed to the MPI processes. However, if there are undefined variables or variables that are different from what is stored in your environment, you can use
-env
or
-genv
options with
mpiexec
. Each of these options take two arguments- the name and the value of the environment variable to be passed.
-genv NAME1 VALUE1 -genv NAME2 VALUE2
-env NAME VALUE -genv
See these MPICH2 examples on how to set the value of
OMP_NUM_THREADS
explicitly:
mpiexec -genv OMP_NUM_THREADS 2 ....
mpiexec -n 1 -host first -env OMP_NUM_THREADS 2 test.exe : -n 2 -host second -env OMP_NUM_THREADS 3 test.exe ....
See these Intel MPI examples on how to set the value of
MKL_BLACS_MPI
explicitly:
mpiexec -genv MKL_BLACS_MPI INTELMPI ....
mpiexec -n 1 -host first -env MKL_BLACS_MPI INTELMPI test.exe : -n 1 -host second -env MKL_BLACS_MPI INTELMPI test.exe.
If you want to pass all environment variables by default and avoid passing these values explicitly, modify the user or system environment variables on each Windows node. From the
Start
menu, select
Settings
>
Control Panel
>
System
>
Advanced
>
Environment Variables
.
If you are using Microsoft MPI, the ways of setting environment variables described above are also applicable if the Microsoft Single Program Multiple Data (SPMD) process managers are running in a debug mode on all nodes of the cluster. However, the best way to set environment variables is by using the Job Scheduler with the Microsoft Management Console (MMC) and/or the Command Line Interface (CLI) to submit a job and pass environment variables. For more information about MMC and CLI, see the Microsoft Help and Support page at the Microsoft Web site (http://www.microsoft.com/).

Product and Performance Information

1

Intel's compilers may or may not optimize to the same degree for non-Intel microprocessors for optimizations that are not unique to Intel microprocessors. These optimizations include SSE2, SSE3, and SSSE3 instruction sets and other optimizations. Intel does not guarantee the availability, functionality, or effectiveness of any optimization on microprocessors not manufactured by Intel. Microprocessor-dependent optimizations in this product are intended for use with Intel microprocessors. Certain optimizations not specific to Intel microarchitecture are reserved for Intel microprocessors. Please refer to the applicable product User and Reference Guides for more information regarding the specific instruction sets covered by this notice.

Notice revision #20110804