[英]Apache/xampp not working on ubuntu port 80
Xampp/apache have been working fine until today. Xampp/apache 一直工作到今天。 Basically, if I configure xampp to start apache on any other port, it seems to work fine, but not on port 80. If I navigate to localhost (or 127.0.0.1) it says site can't be reached/connection refused.
基本上,如果我将 xampp 配置为在任何其他端口上启动 apache,它似乎可以正常工作,但不能在端口 80 上运行。如果我导航到 localhost(或 127.0.0.1),它会说无法访问站点/连接被拒绝。
I verified netstat while xampp has started apache:我在 xampp 启动 apache 时验证了 netstat:
sudo netstat -tulpn |
须藤 netstat -tulpn | grep ':80\\|:443'
grep ':80\\|:443'
tcp6 0 0 :::80 :::* LISTEN 7351/httpd
tcp6 0 0 :::443 :::* LISTEN 7351/httpd
If I shut down apache with xampp the netstat shows 0 results.如果我用 xampp 关闭 apache,netstat 会显示 0 结果。 I also tried running apache with
sudo /etc/init.d/apache2 start
.我还尝试使用
sudo /etc/init.d/apache2 start
运行 apache。 That doesn't work either and in that case netstat shows这也不起作用,在这种情况下 netstat 显示
tcp6 0 0 :::80 :::* LISTEN 8271/apache2
I have no idea what has happened, it has been working fine until today.我不知道发生了什么,直到今天它一直运行良好。 I also tried uninstalling and reinstalling xampp again (with the provided uninstaller).
我还尝试再次卸载并重新安装 xampp(使用提供的卸载程序)。 Only thing I remember having changed to my system since last time is installing ruby and prax.
我记得自上次以来我的系统唯一改变的是安装 ruby 和 prax。 (I also ran prax stop already).
(我也已经跑了 prax stop )。 Any ideas what could be causing this?
任何想法可能导致这种情况?
尝试更改端口 80 和 SSL 端口 443 或者如果您想尝试xampp是一个带有图形界面的服务器 php 就像 windows 上的 wamp
Perhaps your problem is some NAT rules.也许你的问题是一些 NAT 规则。 You have to disable them as stated here:
您必须按照此处的说明禁用它们:
https://serverfault.com/questions/670575/failed-to-connect-to-127-0-0-1-port-80 https://serverfault.com/questions/670575/failed-to-connect-to-127-0-0-1-port-80
I hope it helps.我希望它有帮助。
Not Found The requested URL was not found on this server. Not Found 在此服务器上找不到请求的 URL。
Apache/2.4.41 (Ubuntu) Server at localhost Port 80 in Ubuntu======== Apache/2.4.41 (Ubuntu) 服务器在 Ubuntu 中的 localhost 端口 80 ========
That's a type of problem that has been solved via the below code.这是一种已通过以下代码解决的问题。
Just open your terminal只需打开您的终端
►Commands ►命令
sudo nano /etc/apache2/apache2.conf
after that just add this line at the end and save.之后只需在最后添加这一行并保存。
Include /etc/phpmyadmin/apache.conf
then return and restart然后返回并重新启动
►Commands ►命令
sudo /etc/init.d/apache2 restart
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.