【发布时间】:2013-11-04 20:41:24
【问题描述】:
我的应用程序在我的 Mac 上通过 nginx 在 localhost 端口 80 上运行了很长一段时间。最近我做了一些软件更新,并试图在不同的端口上运行其他应用程序,现在我无法在 localhost:80 上运行我的第一个应用程序。
我对从哪里开始感到非常困惑,但根据以下情况认为这是防火墙问题:
Tims-MacBook-Pro-2:html TimPeterson$ telnet localhost 80
Trying ::1...
telnet: connect to address ::1: Connection refused
Trying fe80::1...
telnet: connect to address fe80::1: Connection refused
Trying 127.0.0.1...
telnet: connect to address 127.0.0.1: Connection refused
telnet: Unable to connect to remote host
将浏览器指向http://localhost 会得到Oops! Google Chrome could not connect to localhost
想法?
【问题讨论】:
-
这个SO线程stackoverflow.com/questions/19607457/…提供了答案
-
我无法在该链接上看到您所指的答案。安装 ngnix 后,我也遇到了这个错误(以及 MySql 错误),但我认为是通过与您不同的方法。
-
我猜@timpeterson 指的是你应该使用
127.0.0.1而不是localhost。
标签: macos nginx localhost firewall