xampp 启动apache 提示:Error: Apache shutdown unexpectedly.

本文详细介绍了当XAMPP的Apache服务无法启动时,如何排查并解决配置文件错误和端口冲突的问题,包括移动XAMPP安装位置、检查目录名、验证SSL端口443占用情况及修改httpd-ssl.conf配置。

无法启动xampp的apache提示错误:

下午 8:32:21  [Apache]       Error: Apache shutdown unexpectedly.

下午 8:32:21  [Apache]       This may be due to a blocked port, missing dependencies,

下午 8:32:21  [Apache]       improper privileges, a crash, or a shutdown by another method.

下午 8:32:21  [Apache]       Press the Logs button to view error logs and check

下午 8:32:21  [Apache]       the Windows Event Viewer for more clues

下午 8:32:21  [Apache]       If you need more help, copy and post this

下午 8:32:21  [Apache]       entire log window on the forums

进入dos下启动,D:\share tools\xampp\apache\bin>httpd.exe,发现提示配置文件的错误如下:

 

可能是是因为存放的目录名(share  tools)中间有空格,导致无法有效访问配置文件。

解决方法:

将xampp移动到D盘目录下,再次启动。依然报错同样的错误,再次进入dos下启动,提示信息如下:

 

提示内容,很明显ssl端口443被暂用。

验证443端口是否真的被占用:

netstat –ano | findstr 443

查询结果如下:

 

可以看到443端口果然被占用,接下来就好办了,只要修改httpd-ssl.conf中的Listen 443端口号,保存重新启动即可。

httpd-ssl.conf配置文件的存放路径:

D:\xampp\apache\conf\extra

重启启动apache,就可以启动成功,如下:

 

 

转载于:https://www.cnblogs.com/JcHome/p/10201452.html

19:23:03 [main] Checking for prerequisites 19:23:04 [main] All prerequisites found 19:23:04 [main] Initializing Modules 19:23:04 [mysql] MySQL Service detected with wrong path 19:23:04 [mysql] Change XAMPP MySQL and Control Panel settings or 19:23:04 [mysql] Uninstall/disable the other service manually first 19:23:04 [mysql] Found Path: D:\lenovo\mysql\mysql-8.0.42-winx64\bin\mysqld MySQL 19:23:04 [mysql] Expected Path: d:\lenovo\xampp\mysql\bin\mysqld.exe --defaults-file=d:\lenovo\xampp\mysql\bin\my.ini mysql 19:23:04 [mysql] Problem detected! 19:23:04 [mysql] Port 3306 in use by "Unable to open process"! 19:23:04 [mysql] MySQL WILL NOT start without the configured ports free! 19:23:04 [mysql] You need to uninstall/disable/reconfigure the blocking application 19:23:04 [mysql] or reconfigure MySQL and the Control Panel to listen on a different port 19:23:04 [main] Starting Check-Timer 19:23:04 [main] Control Panel Ready 19:23:10 [Apache] Attempting to start Apache app... 19:23:11 [Apache] Status change detected: running 19:23:12 [Apache] Status change detected: stopped 19:23:12 [Apache] Error: Apache shutdown unexpectedly. 19:23:12 [Apache] This may be due to a blocked port, missing dependencies, 19:23:12 [Apache] improper privileges, a crash, or a shutdown by another method. 19:23:12 [Apache] Press the Logs button to view error logs and check 19:23:12 [Apache] the Windows Event Viewer for more clues 19:23:12 [Apache] If you need more help, copy and post this 19:23:12 [Apache] entire log window on the forums
最新发布
05-10
评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符  | 博主筛选后可见
 
红包 添加红包
表情包 插入表情
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值