I am working on Mac OS 10.5.6 Leopard. Today I recognized, that every 10 seconds Apache forced the following error messages to appear in my console.log:

org.apache.httpd[10664] (13)Permission denied: make_sock: could not bind to address [::]:80
org.apache.httpd[10664] (13)Permission denied: make_sock: could not bind to address 0.0.0.0:80
org.apache.httpd[10664] no listening sockets available, shutting down
org.apache.httpd[10664] Unable to open logs
com.apple.launchd[79] (org.apache.httpd[10664]) Exited with exit code: 1
com.apple.launchd[79] (org.apache.httpd) Throttling respawn: Will start in 10 seconds

OS X Console.app Errors

After searching the web for this error(s), I got rid that somehow the httpd- service tries to listen on port :80, but which is already listened on by something else. The message “Unable to open logs” may refer to that Apache was not started with root-privileges, but which it needs to startup properly.

I was able to fix this error lines by doing the following steps:

  1. Go to my System Preferences.app and open “Sharing” pane. Disabling the Web-Sharing-service.
    OS X Sharing Panel Services
  2. Launch Terminal.app and stopping the httpd-service (apache) with the following command:
    sudo apachectl -k stop
  3. Going into the Activity Monitor.app and searching for “httpd”. Select both processes and click on “Stop”.
    OS X Activity Monitor.app
  4. Shutdown and then start-up my Mac again (do a proper shutdown, not restart!)
  5. When the Mac was back up running: go in to Terminal.app and execute:
    sudo apachectl -k start

Now Apache was running again and no more errors appeared in the console.log!

However, I noticed the “Web-Sharing” service in the Sharing panel to be still inactive, even if Apache IS running. I let it this way, because the Web Server was available. And I even guess that this service was the cause of the before mentioned errors.

Share:
  • 1
  • 0

1 thought on “OS X: org.apache.httpd (13)Permission denied: make_sock: could not bind to address 0.0.0.0:80”

  1. I had the same problem. I think there is a simpler way to fix this, that doesn’t involve a reboot.

    I think your analysis is correct, that it is launchd trying to start Apache as an unprivileged user, maybe as a result of an accidental launchctl start org.apache.httpd as non-root.

    Try:
    $ launchctl unload /System/Library/LaunchDaemons/org.apache.httpd.plist
    as the same unprivileged user.

Questions? Suggestions? Let us know with a comment!

This site uses Akismet to reduce spam. Learn how your comment data is processed.