简体   繁体   English

MPI - 在多台计算机上执行程序

[英]MPI - execute program on more than one computer

I'm trying to execute a mpi program on two computers.我正在尝试在两台计算机上执行一个 mpi 程序。

First computer: 192.168.0.101第一台电脑:192.168.0.101

Second computer: 192.168.0.100第二台电脑:192.168.0.100

I can execute more processes on a single computer, but when I try to do something like this (I'm using command prompt on 192.168.0.101):我可以在一台计算机上执行更多进程,但是当我尝试执行这样的操作时(我在 192.168.0.101 上使用命令提示符):

mpiexec -hosts -2 192.168.0.100 192.168.0.101 "\\192.168.0.101\temp\mpi.exe"

I get some errors like: No connection could be made because the target machine actively refused it.我收到一些错误,例如:无法建立连接,因为目标机器主动拒绝了它。

However, this execute fine:但是,这执行得很好:

mpiexec -hosts -2 192.168.0.100 192.168.0.100 "\\192.168.0.101\temp\mpi.exe"

How can I execute it on both machines?如何在两台机器上执行它?

It fails not because of the MPI command, but because the node with address 192.168.0.101 is not configured as it should, so that your program can access it.它失败不是因为 MPI 命令,而是因为地址为 192.168.0.101 的节点没有按应有的方式配置,因此您的程序可以访问它。

First try to ping the node, and then try to solve that issue;首先尝试ping该节点,然后尝试解决该问题; to make that node reachable.使该节点可达。 Your MPI command is fine, that's why it runs fine with the same node twice.您的 MPI 命令很好,这就是为什么它可以在同一个节点上正常运行两次。

Have you configured how MPI is supposed to run the process on the remote node ?您是否配置了 MPI 应该如何在远程节点上运行该进程?

typically you have to configure a remote agent ( could be ssh, rsh, or other ),通常,您必须配置远程代理(可以是 ssh、rsh 或其他),

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM