热门标签 | HotTags
当前位置:  开发笔记 > 编程语言 > 正文

Apache不会从wamp开始-Apachewon'tstartinwamp

IhavebeengooglingforthepastfewhoursbutIsimplycantgetmyapacheonwamptostart.Mysk

I have been googling for the past few hours but I simply can't get my apache on wamp to start. My skype isn't running, and the test port 80 shows it isn't being used by anything. Before this happened, I was trying to add a new vhost, but now I have reverted back all of the files where I made changes. Anyway to debug why apache won't start?

在过去的几个小时里,我一直在google上搜索,但是我根本无法让我的apache启动wamp。我的skype没有运行,测试端口80显示它没有被任何东西使用。在此之前,我试图添加一个新的vhost,但是现在我已经恢复了所有进行更改的文件。为了调试为什么apache不启动?

Clicking on start/resume service for apache doesn't show any errors either.

单击apache的start/resume服务也不会显示任何错误。

Also just in case, I am running Win7 64bit

同样,为了以防万一,我正在运行Win7 64位。

12 个解决方案

#1


84  

If you have an issue in the httpd.conf or any files included by it there are a couple of ways to find out what the problem is

如果您在httpd中有问题。conf或它包含的任何文件有两种方法可以找出问题所在

First look at your Windows Event Viewer. Click on the Windows link in the left and menu and then Applications. Look for messages from Apache with the red error icon.

首先查看Windows事件查看器。单击左边的Windows链接和菜单,然后单击应用程序。使用红色错误图标查找来自Apache的消息。

Secondly, open a command window, then CD into \wamp\bin\apache\apache2.x.y\bin, replace x,y with your actual version. Now you can run this command to get Apache(httpd) to vaidate the httpd.conf file.

其次,打开一个命令窗口,然后CD进入\wamp\bin\apache\apache2.x。y\bin,用你的实际版本替换x,y。现在,您可以运行这个命令来让Apache(httpd)对httpd进行vaidate。conf文件。

httpd.exe -t

This should give errors with line numbers related to the http.conf file. It stops on the first error, so you will have to keep running it and fixing the error and then run it again until it gives the all OK message.

这会产生与http相关的行号错误。conf文件。它会在第一个错误上停止,所以您必须继续运行它并修复错误,然后再运行它,直到它给出所有OK消息。

#2


17  

That is what I did and it helped me to find out what my Apache-PHP needed:

这就是我所做的,它帮助我发现我的Apache-PHP需要什么:

C:\Users\Admin>cd C:\wamp\bin\apache\apache2.4.9\bin

C:\wamp\bin\apache\apache2.4.9\bin>httpd -t
Syntax OK

C:\wamp\bin\apache\apache2.4.9\bin>httpd -k start
[Thu Apr 23 14:14:52.150189 2015] [mpm_winnt:error] [pid 3184:tid 112] 
(OS 2)The system cannot find the file specified.  : AH00436: 
No installed service named "Apache2.4".

C:\wamp\bin\apache\apache2.4.9\bin>

The most simple solution:

最简单的解决方案:

Uninstall and reinstall WAMP (do not even try to set it up on top of existing installation - it would not help)

卸载和重新安装WAMP(不要试图在现有的安装上安装它——它不会有帮助)

P.S.

注:

If you wonder how did I get to this situation, here is the answer: I was trying to install WAMP and it throws me an error in the middle of installation saying:

如果你想知道我是怎么得到这个情况的,答案是:我试着安装WAMP,它在安装过程中给我一个错误提示:

httpd.exe - System Error

The program can't start because MSVCR110.dll is missing from your computer. 
Try reinstalling the program to fix this problem.

OK

I got and installed Microsoft Visual C++ 2012 Redistributable from here http://www.microsoft.com/en-us/download/details.aspx?id=30679#

我在这里安装了Microsoft Visual c++ 2012 Redistributable http://www.microsoft.com/en-us/download/details.aspx?id=30679#

And it gave me the "dll" and the MYSQL started working, but not Apache. To make Apache to work I uninstalled and reinstalled WAMP.

它给了我“dll”,MYSQL也开始工作了,但不是Apache。为了让Apache工作,我卸载和重新安装WAMP。

#3


11  

Use apaches startup debug tool from command:

使用apaches启动调试工具:

httpd.exe -e warn

  1. press Win+R
  2. Win + R
  3. type cmd and press enter
  4. 输入cmd并按enter键
  5. goto directory which contains your apache httpd.exe file. for example if your wamp is installed in e:\wamp type cd /d e:\wamp\bin\apache\ApacheX.X.X\bin in cmd and press enter.
  6. goto目录包含您的apache httpd。exe文件。例如,如果你的wamp安装在e:\wamp型号cd /d:\wamp\bin\ \apache\ apachexe . x中。X\bin in cmd,按enter键。
  7. type httpd.exe -e warn (or httpd.exe -e debug for more details) to see error message about problem which is prohibiting apache to start.
  8. httpd类型。exe -e警告(或httpd)。exe -e调试了解更多细节),查看关于禁止apache启动的问题的错误信息。

#4


0  

Invalid Command '80HostnameLookups' , perhaps misspelled or defined by a module not included in the server configuration
I got this error when I debug the issue (wamp server was not going online) by the procedure defined by @RiggsFolly. Just comment the line 80HostnameLookups Off by changing it to #80HostnameLookups Off. This solution worked for me and apache starts running.
Note:80HostnameLookups Off can be found on line 222 of httpd.conf file located in C:\wamp\bin\apache\apache2.4.9\conf

无效的命令“80HostnameLookups”,可能是由一个没有包含在服务器配置中的模块拼写错误或定义的。只要将第80HostnameLookups改为#80HostnameLookups就行了。注意:可以在httpd的222行找到80HostnameLookups。位于C:\wamp\bin\ apache2.4.9\conf中的conf文件

#5


0  

phpmyadmin.conf opened with apacheconf.exe and contents chained so you must do the following:

phpmyadmin。conf apacheconf开张。exe和内容链表,因此您必须执行以下操作:

  1. copy contents of phpsysinfo.conf [C:\wamp\alias]
  2. 复制phpsysinfo内容。设计(C:\ wamp \别名)
  3. paste into phpmyadmin.conf [C:\wamp\alias]
  4. 粘贴到phpmyadmin。设计(C:\ wamp \别名)
  5. change Alias /phpsysinfo "c:/wamp/apps/phpsysinfo3.1.12/" to Alias /phpmyadmin "c:/wamp/apps/phpmyadmin4.1.14/"
  6. 更改别名/phpsysinfo“c:/wamp/apps/phpsysinfo3.1.12/”到Alias /phpmyadmin“c:/wamp/apps/phpmyadmin4.1.14/”
  7. change to
  8. 将 <目录c: wamp apps phpsysinfo3.1.12> 改为 <目录c: wamp apps phpmyadmin4.1.14>

its worked for me.

它为我工作。

#6


0  

My solution was that 2 .dll files(msvcp110.dll, msvcr110.dll) were missing from the directory : C:\wamp\bin\apache\apache2.4.9\bin So I copied these 2 files to all these locations just in case and restarted wamp it worked C:\wamp C:\wamp\bin\apache\apache2.4.9\bin C:\wamp\bin\apache\apache2.4.9 C:\wamp\bin\mysql\mysql5.6.17 C:\wamp\bin\php\php5.5.12

我的解决方案是2 .dll文件(msvcp110)。我把这两个文件复制到所有这些地方,以防万一,并重新启动它

I hope this helps someone out.

我希望这能帮助别人。

#7


0  

I just search this solution, but can't find. Then I solved that by check some parts on wamp in my laptop.

我只是搜索这个解,但是找不到。然后我通过检查我笔记本上wamp的一些部件来解决这个问题。

We know that apache server runs with :80 port by default. Your PC have already used this port by another services. So, first

我们知道apache服务器默认使用:80端口运行。您的PC已经被其他服务使用了这个端口。所以,首先

  1. Click on wamp icon->Apache->Service->Test Port 80
  2. 单击wamp图标->Apache->服务->测试端口80

Then u can find the service which can use :80 port.

然后你可以找到可以使用的服务:80端口。

  OR
  1. Go to "control panel-> Programs and features-> Turn Windows features on or off ". And unchecke right on "Internet Information Service". Then Restart your PC.
  2. 去“控制面板->程序和功能->打开或关闭窗口功能”。并取消“互联网信息服务”的登记。然后重新启动你的电脑。

Problem was solved.

问题已经解决了。

#8


0  

My solution on Windows 10 was just to stop IIS (Internet Information Services).

我在Windows 10上的解决方案就是停止IIS (Internet信息服务)。

#9


0  

If Apache is installed as a Windows service, any errors will show up in the Windows System event log. To view the System event log, navigate to Windows Administrative Tools->Event Viewer and open the System log in the Windows Logs folder. Or, you can see the same errors by running httpd.exe at the command line. In my case, httpd.exe is located here: C:\Bitnami\wampstack-5.6.26-2\apache2\bin.

如果Apache被安装为Windows服务,那么任何错误都将显示在Windows系统事件日志中。要查看系统事件日志,请导航到Windows管理工具——>事件查看器,并在Windows Logs文件夹中打开系统日志。或者,您可以通过运行httpd看到相同的错误。exe在命令行。在我的例子中,httpd。exe位于这里:C:\Bitnami\wampstack-5.6.26-2\apache2\bin。

If there is a problem with starting Apache, most likely the problem can be fixed by editing the httpd.conf file located in the \apache2\conf folder. As already suggested, you can check the syntax of the httpd.conf file by running httpd.exe -t at the command line.

如果在启动Apache时出现问题,那么通过编辑httpd可以解决这个问题。位于\apache2\conf文件夹中的conf文件。如前所述,您可以检查httpd的语法。通过运行httpd conf文件。exe -t在命令行。

I found that the I had to

我发现我必须这么做

Change SetEnv PATH "C:\Bitnami\wampstack-5.6.26-2\apache2\bin;${PATH}" in httpd.conf

改变SetEnv路径“C:\Bitnami\wampstack-5.6.26-2\apache2\bin;${PATH}

to

SetEnv PATH "C:\Bitnami\wampstack-5.6.26-2\apache2\bin;%PATH%"

SetEnv路径“C:\ Bitnami这样\ wampstack-5.6.26-2 \输入\ bin,% %”

#10


0  

I had the same problem. My port 80 was not in use.

我也有同样的问题。我的端口80没有使用。

After thorough research, all I did was to download Update for Universal C Runtime.

在深入研究之后,我所做的就是下载Universal C运行时的Update。

Once installed and my PC restarted, all was OK.

安装完毕,我的电脑重新启动,一切正常。

#11


0  

I was having the same problem, the mysql service was starting but not the apache service, the main problem about that is one of your virtual hosts isn't config. correctly, all i did was deleted the virtual host that i created "D:\wamp\bin\apache\apache2.4.23\conf\extra\httpd-vhosts, restarted all services apache service started working correctly and so i just went to localhost and added a virtual host automatically and so it worked!!

我遇到了同样的问题,mysql服务开始了但不是apache服务,主要的问题是你的虚拟主机不是配置。正确的是,我所做的只是删除了我创建的虚拟主机“D:\wamp\bin\apache\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \

#12


-1  

Sometimes it is Skype or another application "Holding" on to port 80. Jusct close Skype

有时是Skype或其他应用程序“坚持”到端口80。Jusct关闭Skype


推荐阅读
  • 本文介绍了在Mac上搭建php环境后无法使用localhost连接mysql的问题,并通过将localhost替换为127.0.0.1或本机IP解决了该问题。文章解释了localhost和127.0.0.1的区别,指出了使用socket方式连接导致连接失败的原因。此外,还提供了相关链接供读者深入了解。 ... [详细]
  • 本文介绍了在Windows环境下如何配置php+apache环境,包括下载php7和apache2.4、安装vc2015运行时环境、启动php7和apache2.4等步骤。希望对需要搭建php7环境的读者有一定的参考价值。摘要长度为169字。 ... [详细]
  • Nginx使用AWStats日志分析的步骤及注意事项
    本文介绍了在Centos7操作系统上使用Nginx和AWStats进行日志分析的步骤和注意事项。通过AWStats可以统计网站的访问量、IP地址、操作系统、浏览器等信息,并提供精确到每月、每日、每小时的数据。在部署AWStats之前需要确认服务器上已经安装了Perl环境,并进行DNS解析。 ... [详细]
  • vue使用
    关键词: ... [详细]
  • 一、Hadoop来历Hadoop的思想来源于Google在做搜索引擎的时候出现一个很大的问题就是这么多网页我如何才能以最快的速度来搜索到,由于这个问题Google发明 ... [详细]
  • 本文介绍了在mac环境下使用nginx配置nodejs代理服务器的步骤,包括安装nginx、创建目录和文件、配置代理的域名和日志记录等。 ... [详细]
  • C++字符字符串处理及字符集编码方案
    本文介绍了C++中字符字符串处理的问题,并详细解释了字符集编码方案,包括UNICODE、Windows apps采用的UTF-16编码、ASCII、SBCS和DBCS编码方案。同时说明了ANSI C标准和Windows中的字符/字符串数据类型实现。文章还提到了在编译时需要定义UNICODE宏以支持unicode编码,否则将使用windows code page编译。最后,给出了相关的头文件和数据类型定义。 ... [详细]
  • Go Cobra命令行工具入门教程
    本文介绍了Go语言实现的命令行工具Cobra的基本概念、安装方法和入门实践。Cobra被广泛应用于各种项目中,如Kubernetes、Hugo和Github CLI等。通过使用Cobra,我们可以快速创建命令行工具,适用于写测试脚本和各种服务的Admin CLI。文章还通过一个简单的demo演示了Cobra的使用方法。 ... [详细]
  • Java在运行已编译完成的类时,是通过java虚拟机来装载和执行的,java虚拟机通过操作系统命令JAVA_HOMEbinjava–option来启 ... [详细]
  • 本文讨论了如何在codeigniter中识别来自angularjs的请求,并提供了两种方法的代码示例。作者尝试了$this->input->is_ajax_request()和自定义函数is_ajax(),但都没有成功。最后,作者展示了一个ajax请求的示例代码。 ... [详细]
  • 本文介绍了在Windows系统上使用C语言命令行参数启动程序并传递参数的方法,包括接收参数程序的代码和bat文件的编写方法,同时给出了程序运行的结果。 ... [详细]
  • 解决github访问慢的问题的方法集锦
    本文总结了国内用户在访问github网站时可能遇到的加载慢的问题,并提供了解决方法,其中包括修改hosts文件来加速访问。 ... [详细]
  • 本文介绍了一种轻巧方便的工具——集算器,通过使用集算器可以将文本日志变成结构化数据,然后可以使用SQL式查询。集算器利用集算语言的优点,将日志内容结构化为数据表结构,SPL支持直接对结构化的文件进行SQL查询,不再需要安装配置第三方数据库软件。本文还详细介绍了具体的实施过程。 ... [详细]
  • 本文介绍了关系型数据库和NoSQL数据库的概念和特点,列举了主流的关系型数据库和NoSQL数据库,同时描述了它们在新闻、电商抢购信息和微博热点信息等场景中的应用。此外,还提供了MySQL配置文件的相关内容。 ... [详细]
  • Ihaveaworkfolderdirectory.我有一个工作文件夹目录。holderDir.glob(*)>holder[ProjectOne, ... [详细]
author-avatar
fdsafjlkjgklg_431
这个家伙很懒,什么也没留下!
PHP1.CN | 中国最专业的PHP中文社区 | DevBox开发工具箱 | json解析格式化 |PHP资讯 | PHP教程 | 数据库技术 | 服务器技术 | 前端开发技术 | PHP框架 | 开发工具 | 在线工具
Copyright © 1998 - 2020 PHP1.CN. All Rights Reserved | 京公网安备 11010802041100号 | 京ICP备19059560号-4 | PHP1.CN 第一PHP社区 版权所有