无法启动Apache?

时间:2013-12-23 13:40:22

标签: apache

我已经尝试了几个关于如何解决这个问题的不同建议的链接。起初看起来端口80被阻止了。但是,当我以两种不同的方式运行apache时,我遇到了两个不同的问题:

第一种方式:

/etc/init.d/apache2 restart

给我错误:

 * Restarting web server apache2                                                                                                                                  /usr/sbin/apache2ctl: 87: ulimit: error setting limit (Operation not permitted)
/usr/sbin/apache2ctl: 87: ulimit: error setting limit (Operation not permitted)
(13)Permission denied: make_sock: could not bind to address 127.0.0.1:80
no listening sockets available, shutting down

第二种方式:

 sudo /etc/init.d/apache2 restart

给我错误:

 * Restarting web server apache2                                                                                                                      (98)Address already in use: make_sock: could not bind to address 0.0.0.0:80
no listening sockets available, shutting down

请注意,在一个示例中,它指的是0.0.0.0,而另一个示例指的是127.0.0.1。

有关为何发生这种情况的任何想法?

1 个答案:

答案 0 :(得分:1)

答案是,其他东西已经链接到您机器上的端口80,防止其他任何东西绑定到该端口。

了解httpd.conf中的所有Include指令并删除所有Listen重复项。

相关问题