macos - MPID_nem_tcp_init(384).............: gethostbyname 失败,Mac (errno 1)
问题描述
我在我的 macbook 上本地安装了 mpich3.3,但是我得到了这个运行时错误:
MPI_Init 中的致命错误:其他 MPI 错误,错误堆栈:
MPIR_Init_thread(565).......
MPID_Init(224) .....................:通道初始化失败
MPIDI_CH3_Init(105).......
MPID_nem_init(324).......
MPID_nem_tcp_init(178).............:
MPID_nem_tcp_get_business_card(425):
MPID_nem_tcp_init(384).............: gethostbyname 失败,Mac (errno 1)
谁能帮我指出问题并告诉我如何解决?
解决方案
通过在文件中添加新行已解决此问题/etc/hosts
。
1 ##
2 # Host Database
3 #
4 # localhost is used to configure the loopback interface
5 # when the system is booting. Do not change this entry.
6 ##
7 127.0.0.1| localhost
8 255.255.255.255|broadcasthost
只需添加一个新行127.0.0.1 Mac
,您需要在其中替换Mac
为您当前的机器名称。
我相信这个问题是由系统偏好中的机器名称修改引起的。
推荐阅读
- azure - 调用 APIM 管理器 API 失败
- php - 如果 user_id 和 post_id 相同,如何从我的数据库中删除一个赞?
- sonarqube - 无法将 SonarQube 与 SQL 服务器连接
- spring - 为什么我的 Spring 导入语句不起作用?
- ios - SCNLevelOfDetails 委托/通知
- oracle - Oracle DB Developer 导入 .dmp 时出错
- sql - 了解引用触发操作的工作原理
- unity3d - 如何从中间点开始 Vector3.Lerp?
- php - 在编辑器上更新 header.php 时,Wordpress 主题崩溃
- angularjs - 不能在 angular.js 中工作 ng-click,为什么我不明白