httpd.service failed to start with an error "Cannot assign requested address: AH00072: make_sock: could not bind to address" during system boot

Solution Verified - Updated -

Issue

httpd.service fails to start during system boot when both of the following cases are satisfied:
- httpd is configured to listen on a specific IP address in its configuration
- NetworkManager.service is disabled

The following messages can be seen when attempting to start the httpd service during system boot:

httpd: (99)Cannot assign requested address: AH00072: make_sock: could not bind to address 12.34.56.78:80
httpd: no listening sockets available, shutting down
httpd: AH00015: Unable to open logs
systemd: httpd.service: main process exited, code=exited, status=1/FAILURE
kill: kill: cannot find process ""
systemd: httpd.service: control process exited, code=exited status=1
systemd: Failed to start The Apache HTTP Server.
systemd: Unit httpd.service entered failed state.
systemd: httpd.service failed.
  • During boot systemd executes httpd.service before the network is completely up and running, which causes httpd to fail. This was reported in Fedora 17 as Bug 921566 - httpd does not wait for network start and fails. When it is going to be fixed in RHEL7?
  • Is there a fix available for https://bugzilla.redhat.com/show_bug.cgi?id=1352139 in RHEL7?

  • The issue occurs with IPv6 and it is not fixed by the newer package than systemd-219-42.el7.

Environment

  • Red Hat Enterprise Linux 7.3
    • httpd-2.4.6-45.el7.x86_64
    • NetworkManager-1.4.0-12.el7.x86_64

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content