如何解决MPICH的执行问题:错误代码(10049)

时间:2020-07-07 07:01:58

标签: mpi mpich

我是MPICH2的新手,我试图执行一个小程序。该程序的构建没有错误,但是当我尝试运行该程序时,它显示了我所附的错误。您能帮我解决这个问题吗?

> [01:17268]..ERROR:Error while connecting to host, The requested address is not valid in its context. (10049)
[01:17268]..ERROR:Connect on sock (host=localhost, port=0) failed, exhaused all end points
SMPDU_Sock_post_connect failed.
[2] PMI_ConnectToHost failed: unable to post a connect to localhost:0, error: Undefined dynamic error code
uPMI_ConnectToHost returning PMI_FAIL
[2] PMI_Init failed.
Fatal error in MPI_Init: Other MPI error, error stack:
MPIR_Init_thread(377): Initialization failed
MPID_Init(90)........: channel initialization failed
MPID_Init(357).......: PMI_Init returned -1
[01:10548]..ERROR:Error while connecting to host, The requested address is not valid in its context. (10049)
[01:10548]..ERROR:Connect on sock (host=localhost, port=0) failed, exhaused all end points
SMPDU_Sock_post_connect failed.
[1] PMI_ConnectToHost failed: unable to post a connect to localhost:0, error: Undefined dynamic error code
uPMI_ConnectToHost returning PMI_FAIL
[1] PMI_Init failed.
Fatal error in MPI_Init: Other MPI error, error stack:
MPIR_Init_thread(377): Initialization failed
MPID_Init(90)........: channel initialization failed
MPID_Init(357).......: PMI_Init returned -1
[01:11576]..ERROR:Error while connecting to host, The requested address is not valid in its context. (10049)
[01:11576]..ERROR:Connect on sock (host=localhost, port=0) failed, exhaused all end points
SMPDU_Sock_post_connect failed.
[0] PMI_ConnectToHost failed: unable to post a connect to localhost:0, error: Undefined dynamic error code
uPMI_ConnectToHost returning PMI_FAIL
[0] PMI_Init failed.
Fatal error in MPI_Init: Other MPI error, error stack:
MPIR_Init_thread(377): Initialization failed
MPID_Init(90)........: channel initialization failed
MPID_Init(357).......: PMI_Init returned -1
#include <mpi.h>
#include <stdio.h>
int main() {
int np;
int pid;
MPI_Init(NULL,NULL);
MPI_Comm_size(MPI_COMM_WORLD,&np);
MPI_Comm_rank(MPI_COMM_WORLD, &pid);
printf("Hi parallel...\n");
MPI_Finalize();
return 0;
}

0 个答案:

没有答案
相关问题