我刚刚重新安装XAMPP,当我试图在XAMPP控制面板中启动我的Apache服务器时,我现在得到以下错误:

16:50:25  [Apache]     Status change detected: running
16:50:26  [Apache]     Status change detected: stopped
16:50:26  [Apache]     Error: Apache shutdown unexpectedly.
16:50:26  [Apache]     This may be due to a blocked port, missing dependencies,
16:50:26  [Apache]     improper privileges, a crash, or a shutdown by another method.
16:50:26  [Apache]     Press the Logs button to view error logs and check
16:50:26  [Apache]     the Windows Event Viewer for more clues
16:50:26  [Apache]     If you need more help, copy and post this
16:50:26  [Apache]     entire log window on the forums

我怎么解决这个问题?


当前回答

我刚刚在我的xampp v3.2.2 [win 10 pro x64]上遇到了这个错误,

我首先尝试在管理cmd中运行“net stop http”命令,但它没有解决问题,所以我继续尝试“netstat -abno”命令,我发现ssl端口(443)正在被vmware使用。

因此,我的建议是,不要只寻找阻塞端口80的原因,还要寻找使用端口443的潜在程序。因为我真的不喜欢把我的默认端口号改为8081和4433。

这就是你解决这个问题的方法…

首先输入以下命令

停止HTTP

然后尝试启动apache,如果它仍然不工作。输入以下命令

Netstat -ABNO

你肯定会遇到麻烦的应用,它会占用你宝贵的移植端口。

复制pid,然后使用以下命令

taskkill /f /pid pid

这里的PID是你复制的PID。

希望这能帮助到一些人。

其他回答

这对我很管用……

如果你正在使用windows…

在windows搜索栏中搜索'cmd'。

输入:C: \ xampp \ apache \ bin \ httpd.exe

查找发生错误的文件和行。

例如,我的在下面的文件中 第37行。

httpd-multilang-errordoc.conf

打开代码并通过删除该行或修复该行来修复错误。

完成了!我现在该工作了。

:)

我有一个类似的错误,改变端口或运行为管理员不工作。 我用的是Windows 10。 我从xampp目录运行apache_start.bat,我得到了一个更具体的反馈,说我的https-vhosts.conf文件上有一个错误,特别是在文档根目录的末尾有一个额外的\。把它拿开,它又工作了。

我通过停止“Web部署代理服务”解决了这个问题。打开:System -> Computer Management -> Services -> Web部署代理服务。停止此服务并启动XAMPP工作。 我想这是MS Webmatrix提供的一项服务。

>系统和保安>管理>服务>网络调送服务

你可以在XAMPP目录下运行apache_start.bat文件查看你的错误细节。

我收到了上面相同的错误,导致我的原因是在文件'httpd-vhosts.conf'中,我在<Directory>标签中放了一个注释,就像这样…

<Directory "*PATH TO MY FOLDER*...">
        AllowOverride All
        Require all Granted    ## This directive could/should be set to denied.
</Directory>

一旦我删除了注释,Apache就启动了。我想我应该把注释放在它自己的行里。我只是想,像其他网络代码一样,它可以在那里。