当前位置 主页 > 服务器问题 > Linux/apache问题 >

    Apache 解决80端口占用问题

    栏目:Linux/apache问题 时间:2019-10-09 16:18

    今天安装mongodb后发现apache无法启动

    命令行 services.msc 打开服务

    在服务里启动Apache2a服务,报错误码1

    网上查有很多情况都报的1

    可以通过命令行下  执行apache bin 下的 httpd.exe进一步了解

    AH00548: NameVirtualHost has no effect and will be removed in the next release D:/phpStudy/Apache/conf/extra/httpd-vhosts.conf:34
    (OS 10013)以一种访问权限不允许的方式做了一个访问套接字的尝试。 : AH00072: make_sock: could not bind to address [::]:80
    (OS 10013)以一种访问权限不允许的方式做了一个访问套接字的尝试。 : AH00072: make_sock: could not bind to address 0.0.0.0:80
    AH00451: no listening sockets available, shutting down
    AH00015: Unable to open logs

    看到这里估计是80端口被占用了,我之前也有一次遇到过80被System占用,后来通过修改httpd.conf里的监听端口解决

    通过命令行 netstat -ano|findstr 80 查看占用的pid  为4

    通过tasklist 显示所有进程

    System              4 Services          0    108 K

    果然还是System占用,这次必须解决,通过查看资料了解到System一般为SQL Server Reporting Services (MSSQLSERVER)这个服务

    直接去服务里禁用它,apache成功开启

    总结

    以上所述是小编给大家介绍的Apache 解决80端口占用问题 ,希望对大家有所帮助,如果大家有任何疑问欢迎给我留言,小编会及时回复大家的!