[英]localhost on MacOSX connection refused
I've had my app running on localhost port 80 via nginx on my mac for quite awhile.我的应用程序在我的 Mac 上通过 nginx 在 localhost 端口 80 上运行了很长一段时间。 Recently I did some software updates and was trying to run other apps on different ports and now I can't run my first app on localhost:80.
最近我做了一些软件更新,并试图在不同的端口上运行其他应用程序,现在我无法在 localhost:80 上运行我的第一个应用程序。
I've very confused on where to start but think this is a firewall issue based on the following:我对从哪里开始感到非常困惑,但认为这是基于以下内容的防火墙问题:
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
pointing the browser to http://localhost
gives this Oops! Google Chrome could not connect to localhost
将浏览器指向
http://localhost
给出了这个Oops! Google Chrome could not connect to localhost
Oops! Google Chrome could not connect to localhost
thoughts?想法?
you may want to run 你可能想跑
apachectl configtest
first. 第一。
My problem was specific, but might help another user.我的问题很具体,但可能会帮助其他用户。 On Mac OS go to system preferences/sharing and check your computer name/localhost name (click edit to see the localhost name).
在 Mac OS 上,转到系统首选项/共享并检查您的计算机名称/本地主机名称(单击编辑以查看本地主机名称)。 My computer was reset by Apple in a non-English speaking country.
我的电脑在非英语国家被 Apple 重置。 They stuck some of their language in my computer name (great idea!) and it broke the Cisco login to localhost
他们在我的计算机名中加入了一些他们的语言(好主意!),它破坏了 Cisco 登录到 localhost
对我有用的是在/ etc / hosts文件中取消注释以下行:
::1 localhost
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.