Asked
Updated
Viewed
111.3k times

😟 I'm new to server stuff and I've just install Apache so I can learn PHP. I'm running Windows XP w/SP 2 installed.

When I start Apache, I get the error message:

Only one usage of each socket address (protocol/network address/port) is normally permitted. :make_sock: could not bind to address 0.0.0.:80
Unable to open logs.

I think it means something else on my machine is using port 80.

1) How do I find out what else is using port 80?

2) I found something about a conflict with Apache & IIS (Internet Information Service) webserver but don't know anything about IIS .

How do I check to see if I have that on my PC?
If it's on my PC how do I disable it?

2) Is there another port I can use for Apache?
If so,

What other ports are available?
Do I only have to change the port number in the 'Servername=' parameter in the Configuration file?

I'd appreciate assistance on this so I can proceed with learning PHP. Thanks!

add a comment
0

24 Answers

  • Votes
  • Oldest
  • Latest
Answered
Updated

Hi, Chuck, Welcome to Ozzu. I don't use Apache but someone else can help you with that, don't worry, there's a lot of friendly and skilled people here 😉 (I am the black sheep 🤣 )

To stop IIS try this

1- Goto control panel > Administrative Tools > Internet Information Service (IIS) Manager
2- In IIS Manager, right click the local computer, point to All Tasks, then click Restart IIS
3- In the What do you want IIS to do list, select Stop Internet Services on <yourcomputername>

Your account must be an administrative account to do this.

//EDIT: I also found this about changing conf file on Apache to avoid this error:

Open up your httpd.conf file in apache2/conf, look for the line that starts with Listen usually around line number 120 or so.See that it is set up to Listen on 80 or whatever port you wanted, look for ServerName line and put either localhost or 127.0.0.1, save the file and check again

add a comment
0
Answered
Updated

If the 0.0.0:80 in your error message is not actually a typo in the forum message, then you could look for 0.0.0 in the httpd.conf file too - it is a bogus IP address and if the config file actually contains that as a bind address it will certainly fail 🙂

add a comment
0
Answered
Updated

Thanks for your input Finndel, Chuck already solved his problem, here's a PM he sent me:

Apache is working!! I noticed the icon in my system tray that indicated 'Running all Apache Services'. I must have started Apache and didn't know it????

Maybe that's why I got that error since port 80 was already being used by the 1st instance of Apache ?

Anyway, I had changed the servername to 'localhost' (with no :80), then went to my browser and entered 'localhost' in the url and got the default start page!

Thank you for your suggestions! Forums like this are what makes the Internet GREAT!

Chuck

add a comment
0
Answered
Updated

Cool, glad he's sorted 🙂

Steve.

add a comment
0
Answered
Updated

😁

This was great help to me as well. Thank you!!

add a comment
0
Answered
Updated

You are welcome redcreative, glad we can help you. And BTW, welcome to Ozzu.

add a comment
0
Answered
Updated

I am replying here because I had the same problem, but fixed it with your solution here.

However,
I am able to access it locally (localhost or 127.0.0.1)
but I cannot access it within my local lan, (on the router)
and also I cannot access it outsite the lan.

I changed the port to 81 to see if that would make a difference, but no dice

Any Suggestions?

Btw:
Windows 2000
No Firewall Installed.

I am fairly sure that for some reason the port doesnt seem to be available to other comptuers.

add a comment
0
Answered
Updated

For those experiencing similar problems:

I was able to resolve this by changing from localhost/ 127.0.0.1
to my internal IP (192.168.1.3)

Now it works fine.

I dont suppose anyone can explain this to me?

Sometime I think computers do things to mess with us.

add a comment
0
Answered
Updated

hi guys,

i am totally new to apache n all.....
i am having the same problem and tries all the things as mentioned in the above posts....
but none of them seem to work and i get the sam error...is there anything else i can do?

thanks

add a comment
0
Answered
Updated

Well I got that issue taken care of, I had made a typo. Now the problem is when I type http://localhost in the browser i get an error. In Internet Explorer the error is:

HTTP 403: The website requires you to login.

and in Mozilla Firefox the error is:

Forbidden
You do not have permission to access / on this server.

Can you kindly help me out with the problem?

add a comment
0
Answered
Updated

With reference to the question above,

I was getting the following error:

Installing the Apache2.2 service
The Apache2.2 service is successfully installed.
Testing httpd.conf....
Errors reported here must be corrected before the service can be started.
httpd.exe: Could not reliably determine the server's fully qualified domain na
, using xxx.xxx.xxx.xx for ServerName
(OS 10048)Only one usage of each socket address (protocol/network address/port
is normally permitted. : make_sock: could not bind to address 0.0.0.0:xxxx
no listening sockets available, shutting down
Unable to open logs
Note the errors or messages above, and press the <ESC> key to exit. 14...

The trick, I found, was to edit the configuration files, and add listen <ipaddress>:<port>

where <ipaddress> is the public IP address of the server, not the loopback address.

add a comment
0
Answered
Updated

With reference to the question above,

I was getting the following error:

Installing the Apache2.2 service
The Apache2.2 service is successfully installed.
Testing httpd.conf....
Errors reported here must be corrected before the service can be started.
httpd.exe: Could not reliably determine the server's fully qualified domain na
, using xxx.xxx.xxx.xx for ServerName
(OS 10048)Only one usage of each socket address (protocol/network address/port
is normally permitted. : make_sock: could not bind to address 0.0.0.0:xxxx
no listening sockets available, shutting down
Unable to open logs
Note the errors or messages above, and press the <ESC> key to exit. 14...

The trick, I found, was to edit the configuration files, and add listen <ipaddress>:<port>

where <ipaddress> is the public IP address of the server, not the loopback address.

I was having the exact same issue and this worked for me, too. I don't know why the .conf was set, by default, to just "listen 80" with no address. Anyway, thank you, and thanks to the other posters and forum in general for making my apache server work :>

add a comment
0
TO
0 0
Answered
Updated

hey dananos
thanks for the post

as im a complete moron with sysadmin stuff
i must ask you -
when you say "the public IP address of the server"
how i find that information?

im trying to run apache on my personal window xp laptop

thanks for your help

add a comment
0
Answered
Updated

Hi guys,
Thank you in advance for your help, actually regarding ":make_sock: could not bind to address 0.0.0.:80 " problem I have the same problem
I have the same problem also,but I don't use IIS and I checked the "httpd" file everything is O.K!
so any other comments I guess it is network prob, this is my 2nd day with PHP and Apache.
Thanks alot,,
Jo.

add a comment
0
Answered
Updated

Hi,

I had the same problem. By me the problem was Skype running. When I turned it off, the Apache server started correctly.

If I start Skype after the Apache, both work fine.

add a comment
0
Answered
Updated

just use xampp, it works wonders for windows but i personally rather lampp on linux. Better server control using linux, i have it running on vmware so when i need to use it boot up ubuntu and pump away.

add a comment
0
Answered
Updated

I gat the same problem on Windows Server 2008 so I stopped the Web Deployement Service in the Task Manager

Hi guys,.
Thank you in advance for your help, actually regarding ": make_sock: could not bind to address 0.0.0.: 80" problem I have the same problem
I have the same problem also, but I do not use IIS and I checked the "httpd" file everything is okay!
so any other comments I guess it is network prob, this is my 2nd day with PHP and Apache.
Thanks alot,
OJ.

add a comment
0
Answered
Updated

OMG... You guys are amazing. Thanks to jeyhey. I had skype running as well. As soon as I turned off skype, I was able to start Apache service. I look forward to interacting more with this group.

add a comment
0
Answered
Updated

Hi,

I had the same problem. By me the problem was Skype running. When I turned it off, the Apache server started correctly.

If I start Skype after the Apache, both work fine.

Hi Jeyhey,
Thanks for your help. I had skype running and after I turned it off, the Apache server started for me. Would have taken a while to figure out if not for your post.

add a comment
0
Answered
Updated

hello, I am having the same issue on a Windows 8 machine. I have successfully install Apache 2.4 as a windows service---when I put localhost into my browser I get the famous "IT WORKS!" but, when I open the cmd and try to open the httpd.exe in conf I get the error:

<OS 10048>Only one usage of each socket address (protocol/network address/port is normally permitted. : AHOOO72: make_sock: could not bind to address [::]:80 <OS 10048>Only one usage of each socket address (protocol/network address/port is normally permitted. : AHOOO72: make_sock: could not bind to address 0.0.0.0:80 AH00451:no listening sockets available, shutting down AH00015: Unable to open logs I went into conf and changed the line "listen 80" to "listen <my ip>80" and made every change that I have read about on the net concerning this. In my Task Manager, Apache is showing two services running, 1.) Apache http server with 2.5mb memory usage, pid 2032 and 2.) Apache http server with 1.1mb memory usage, pid 1588(port 80) but this one also has a drop down that shows Apache 2.4 How can I get rid of this error? I have no icon showing that apache is running or anything like that. Any advice will be greatly appreciated, thanks Brian P.s. I have uninstalled skype and I have done the netstat -aon which shows that apache is running on port 80. I have set up my router for port forwarding ad I have also turned off IIS. I shouldn't complain cause it is working but something is not right. I also have installed MySQL successfully and Wordpress. All I have left to install is PHP. Should I just ignore this error? I really do not want to get into the registry if I can bypass it. Thanks
add a comment
0
Answered
Updated

If you are getting that it works in your browsers, what exactly is the problem? Sounds like it would be functioning correctly if you see that in your browser?

Once Apache is running and serving web pages, why would run cmd and type httpd.exe? It is already running, there is no reason to type that.

I might not be understanding what you are trying to do, maybe you can explain in more detail.

add a comment
0
Answered
Updated

i didnt realize it was actually running when I ran httpd.exe and got the errors. I couldnt get it to work at all. Then, just for kicks I typed "localhost" into my browser and there was "IT WORKS!" Which I had been trying all along with nothing showing.

I first got the error about the servername and I fixed that by removing the "#" in front of it in conf. I then typed in "Localhost" into a browser with nothing, restarted, again "localhost" and again nothing. I went back and repeated the httpd.exe multiple times and kept on getting the error that I posted here about.

I am still getting the error but, if this will not cause any harm-the way it is, I will just leave it and ignore the errors.

I know this sounds confusing and I feel that way. But, I tried everything to get these to go away--put everything back the way it was and --viola-it works.

I will just leave it alone , Thanks

add a comment
0
Answered
Updated

Yup, since it was already running it was around bound to that IP address and port. You can only be bound once at a particular IP and port. Wo when you tried to run httpd.exe again you were not able to bind to that ip address and port, and thus that is why you got the errors because another service was already bound to it.

At least from my understanding of what is going on here. Hope that makes sense 🙂

add a comment
0
Answered
Updated

Helped for me in httpd.conf to change line 58 from:
Listen 80
to:
Listen 127.0.0.1:80

add a comment
0