0

別のユーザーによって提供およびコンパイルされた OpenMPI をテストしています (すべての bin、include などのすべての必須ディレクトリに対して彼のディレクトリへのソフトリンクを使用しています) が、この奇妙なことに遭遇しました:

まず、mpirun を -n 設定 <= 10 で実行した場合、以下で実行できます。testrunmpi.py は単に「run」を出力します。各コアから。

# I am in serverA.
bash-3.2$ /home/karl/bin/mpirun -n 10 ./testrunmpi.py
run. 
run. 
run. 
run. 
run. 
run. 
run. 
run. 
run. 
run. 

ただし、-n を 10 以上実行しようとすると、次のようになります。

bash-3.2$ /home/karl/bin/mpirun -n 24 ./testrunmpi.py
karl@serverB's password: Could not chdir to home directory /home/karl: No such file or directory
bash: /home/karl/bin/orted: No such file or directory
--------------------------------------------------------------------------
A daemon (pid 19203) died unexpectedly with status 127 while attempting
to launch so we are aborting.

There may be more information reported by the environment (see above).

This may be because the daemon was unable to find all the needed shared
libraries on the remote node. You may set your LD_LIBRARY_PATH to have the
location of the shared libraries on the remote nodes and this will
automatically be forwarded to the remote nodes.
--------------------------------------------------------------------------
--------------------------------------------------------------------------
mpirun noticed that the job aborted, but has no info as to the process
that caused that situation.
--------------------------------------------------------------------------
bash-3.2$
bash-3.2$
Permission denied, please try again.
karl@serverB's password:
Permission denied, please try again.
karl@serverB's password:

サーバーAにいる間に、作業がサーバーBにディスパッチされていることがわかります。serverB にはアカウントがありません。しかし、mpirun -n <= 10 を呼び出すと、作業は serverA で行われます。

これはおかしいので、/home/karl/etc/openmpi-default-hostfile を調べて、次のように設定してみました。

serverA slots=24 max_slots=24
serverB slots=0 max_slots=32

しかし、問題は解決せず、上記と同じエラー メッセージが表示されます。プログラムを serverA のみで実行するにはどうすればよいですか?

4

1 に答える 1

1

Open MPI のデフォルトのホストファイルはシステム全体です。つまり、その場所はライブラリのビルドおよびインストール中に決定され、ユーザー固有のバージョンはありません。ompi_info実際の場所は、次のようなコマンドを実行して取得できます。

$ ompi_info --param orte orte | grep orte_default_hostfile
MCA orte: parameter "orte_default_hostfile" (current value: <LOOK HERE>, data source: default value)

ホストのリストは、いくつかの異なる方法でオーバーライドできます。-hostfileまず、 へのオプションを介して独自のホストファイルを提供できますmpirun。その場合、スロットがゼロのホストを内部に配置する必要はありません。アクセス権のないマシンは省略してください。例えば:

localhost slots=10 max_slots=10
serverA slots=24 max_slots=24

orte_default_hostfileMCA パラメータを設定して、デフォルトのホストファイルへのパスを変更することもできます。

$ mpirun --mca orte_default_hostfile /path/to/your/hostfile -n 10 executable

オプションを毎回渡す代わりに--mca、エクスポートされた環境変数 に値を設定できますOMPI_MCA_orte_default_hostfile.bashrcこれは、たとえばBash を使用している場合など、シェルの dot-rc ファイルで設定できます。

-H(または-host) オプションを使用してノードのリストを直接指定することもできます。

于 2013-01-23T10:11:24.430 に答える