从 XAMPP 运行 apache 服务时出错 [英] Error in running apache services from XAMPP

查看:25
本文介绍了从 XAMPP 运行 apache 服务时出错的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我几个月前安装了 XAMPP,它一直运行良好.但是最近打开的时候提示端口被占用.

I installed XAMPP a few months ago and it has been working fine. But recently when I open it I get an error of a port being occupied.

现在每当我启动 XAMPP 并运行 apache 服务时,我都会收到以下错误:

Now whenever I start my XAMPP and run apache services I get these errors:

Apache Service detected with wrong path
Change XAMPP Apache settings or
Uninstall/disable the other service manually first
Found Path: ERROR: Not Able To Open Service Manager
Expected Path: "d:\my local server\xampp\apache\bin\httpd.exe" -k runservice
Problem detected!
Port 80 in use by "system"!
Apache WILL NOT start without the configured ports free!
You need to uninstall/disable/reconfigure the blocking application
or reconfigure Apache to listen on a different port

也许某个系统进程正在使用端口 80?

Perhaps Port 80 is being used by some system process?

这些错误是什么意思,我该如何处理?

What do these errors mean and how do I deal with them?

推荐答案

重新配置 Apache 以使用不同的端口非常容易.

Reconfiguring Apache to use a different port is pretty easy.

  1. 找到 Apache 的配置文件(它可能在 d:\my local server\xampp\apache\conf 中,但我从未使用过 XAMPP,所以我不肯定).该文件可能会被命名为 httpd.conf.
  2. 查找以 Port 开头的行.它可能是 Port 80Port 127.0.0.1:80.
  3. 将末尾的 80 更改为其他内容.
  4. 重新启动您的服务.
  1. Find the configuration file for Apache (it's probably in d:\my local server\xampp\apache\conf, but I've never used XAMPP so I'm not positive). The file will probably be named httpd.conf.
  2. Look for a line that starts with Port. It will probably be Port 80 or Port 127.0.0.1:80.
  3. Change the 80 on the end to something else.
  4. Restart your service.

至于停止其他服务,首先要弄清楚它是什么.由于这是端口 80,您很可能正在运行另一个 Web 服务器.首先要查看的是您的服务面板(Start > Run > services.msc).查找标题中包含 ApacheWebInternet 的任何内容.您可能安装了其他捆绑了 Apache 版本的软件,或者您可能安装了 Internet Information Server.

As for stopping the other service, you first need to find out what it is. Since this is port 80 you most likely have another web server running. The first place to look is your Services panel (Start > Run > services.msc). Look for anything with Apache, Web or Internet in the title. You might have installed other software that bundled a version of Apache, or you might have Internet Information Server installed.

如果您在服务中找不到任何明显的东西,您可以查找使用该端口的进程.您可以下载一些工具来简化此操作,但请使用 Windows 附带的常用工具:

If you can't find anything obvious in Services you can look for the process that's using that port. There are tools you can download to make this easier, but using the stock tools that ship with Windows:

  1. 打开命令提示符(开始 > 运行 > cmd)
  2. 运行 netstat -ao
  3. Local Address 列中查找以 :80:http
  4. 结尾的内容
  5. 查找该连接的 PID(最后一列)
  6. 运行任务管理器,转到<代码>查看>选择 Columns... 并启用 PID 列
  7. 查找该 PID 的可执行文件名称
  8. 使用 Google 找出该进程是什么、用于什么以及如何将其关闭(通常只需在服务"面板中找到它使用的名称即可)
  1. Open a command prompt (Start > Run > cmd)
  2. Run netstat -ao
  3. Look in the Local Address column for something ending with :80 or :http
  4. Find the PID for that connection (last column)
  5. Run Task Manager, go to View > Select Columns... and enable the PID column
  6. Find the executable name for that PID
  7. Use Google to figure out what that process is, what it's used for, and how to turn it off (usually just a matter of finding the name it uses in the Services panel)

这篇关于从 XAMPP 运行 apache 服务时出错的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆