node pm2 启动 Error: getaddrinfo ENOTFOUND 解决方法
2014-08-11 22:06
483 查看
在新的服务器上部署node以后,使用pm2 作为进程管理工具,
安装完成以后,pm2 无论执行
pm2 list 还是pm2 的其它命令,全部报
Error: getaddrinfo ENOTFOUND
的错误。
仔细检查安装都没问题,上git pm2的issue搜索发现,居然是hosts的原因导致的。
默认centos的 hosts 会把本地 127.0.0.1 localhost 注释掉,去掉再试下就可以了。
参见git pm2 issue:
https://github.com/Unitech/pm2/issues/324
原解答:
My fault! My deployment scripts
were accidentally deleting the
the
making it impossible to nodejs find the local machine.
安装完成以后,pm2 无论执行
pm2 list 还是pm2 的其它命令,全部报
Error: getaddrinfo ENOTFOUND
的错误。
仔细检查安装都没问题,上git pm2的issue搜索发现,居然是hosts的原因导致的。
默认centos的 hosts 会把本地 127.0.0.1 localhost 注释掉,去掉再试下就可以了。
参见git pm2 issue:
https://github.com/Unitech/pm2/issues/324
原解答:
My fault! My deployment scripts
were accidentally deleting the
localhostfrom
the
/etc/hostsfile,
making it impossible to nodejs find the local machine.
相关文章推荐
- Silverlight + WCF错误“The remote server returned an error: NotFound.”的解决方法
- 创建Tooltip的时候,GetLastError是1309的解决方法
- yum VNC后,启动时出错/usr/bin/Xvnc: symbol lookup error解决方法
- DotNet中编译出现Error spawning cl.exe(启动cl.exe失败)之解决方法
- yum VNC后,启动时出错/usr/bin/Xvnc: symbol lookup error解决方法
- Tomcat启动时Error Listenerstart的解决方法
- 启动 Microsoft Windows Media Player 时,收到“An internal application error has occurred”错误信息的解决方法
- MyEclipse中启动Tomcat,报OutOfMemoryError: PermGen space的解决方法
- 安卓模拟器不能启动:The connection to adb is down, and a severe error has occurred解决方法
- yum VNC后,启动时出错/usr/bin/Xvnc: symbol lookup error解决方法
- 无法在web服务器上启动调试, Server Application Error......错误解决方法
- 启动模拟器:ERROR: unknown virtual device name解决方法
- Tomcat启动时Error Listenerstart的解决方法
- 启动JBoss时出现“Error occurred during initialization of VM”错误的解决方法
- Linux启动时 Error 15: File not found 问题解决方法
- Access里的Case效果 “IErrorInfo.GetDescription 因 E_FAIL(0x80004005) 而失败!”的解决方法!
- Linux启动时 Error 15: File not found 问题解决方法
- citrix licensing服务启动失败解决方法Error:1067
- MyEclipse+Tomcat 启动时出现A configuration error occured during startup错误的解决方法
- Silverlight + WCF错误“The remote server returned an error: NotFound.”的解决方法