I am attempting to install and run apache 2.4 on my windows 7 system I went to the apache 2.4 bin directory and ran the following: Note: I opened the cmd window as administrator. C:\Apache24\bin>httpd.exe -k install
Its output was as follows:
Installing the Apache2.4 service The Apache2.4 service is successfully installed. Testing httpd.conf.... Errors reported here must be corrected before the service can be started. (OS 10013)An attempt was made to access a socket in a way forbidden by its acces s permissions. : AH00072: make_sock: could not bind to address [::]:80 (OS 10013)An attempt was made to access a socket in a way forbidden by its acces s permissions. : AH00072: make_sock: could not bind to address 0.0.0.0:80 AH00451: no listening sockets available, shutting down AH00015: Unable to open log
So it installed apache 2.4 as a service but it could not be started. It seems like the localhost port 80 is being used. Is this what "[::]:80" means?
I then stopped both the the apache 2.0 service which I had left running and the mysql service, hoping stopping one of them might free up localhost port 80.
I also run netstat -o to see if port 80 is being used. It was not.
But, I then found that a process was using the above socket it is a process that is listening on the above socket
TCP [::]:80 User-PC:0 LISTENING 4
I then ran tasklist and found out that System is using pid 4. 4 is under the pid column
System 4 Services 0 544 K
Finally, from the failed attempt to start the service I got an error which was recorded in windows systems events.
Log Name: System Source: Service Control Manager Date: 2/21/2013 1:58:03 PM Event ID: 7024 Task Category: None Level: Error Keywords: Classic User: N/A Computer: User-PC Description: The Apache2.4 service terminated with service-specific error Incorrect function. Event Xml: <Event xmlns="http://schemas.microsoft.com/win/2004/08/events/event"> <System> <Provider Name="Service Control Manager" Guid="{555908d1-a6d7-4695-8e1e-26931d2012f4}" EventSourceName="Service Control Manager" /> <EventID Qualifiers="49152">7024</EventID> <Version>0</Version> <Level>2</Level> <Task>0</Task> <Opcode>0</Opcode> <Keywords>0x8080000000000000</Keywords> <TimeCreated SystemTime="2013-02-21T18:58:03.723988900Z" /> <EventRecordID>87756</EventRecordID> <Correlation /> <Execution ProcessID="560" ThreadID="7596" /> <Channel>System</Channel> <Computer>User-PC</Computer> <Security /> </System> <EventData> <Data Name="param1">Apache2.4</Data> <Data Name="param2">%%1</Data> </EventData> </Event>
The error from the attempt to start says that beacause of lack of access, make-sock could not bind to sockets which to me looked like localhost port 80. For example,
(OS 10013)An attempt was made to access a socket in a way forbidden by its acces s permissions. : AH00072: make_sock: could not bind to address [::]:80
Can anyone tell what I am doing wrong?
There are several reasons your Apache server might fail to run. Something could be blocking the port it uses; there could be another instance of Apache already running; or there might be an incompatibility with the version of PHP you're using in MAMP.
Sorry for the belabored question. To solve my problem I just told apache 2.4 to listen to a different port in httpd.conf. Since System was using pid 4 which was listening on port 80, I did not want to explore this any further.
I put the following into httpd.conf. Listen 127.0.0.1:122
The most likely culprit is Microsoft Internet Information Server. You can stop the service from the command line on Windows 7/Vista:
net stop was /y
or XP:
net stop iisadmin /y
read this http://www.sitepoint.com/unblock-port-80-on-windows-run-apache/
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With