I have an Apache installation that is falling over when called on boot from init.d:
Oct 28 15:29:38 Myth systemd[1]: Starting The Apache HTTP Server...
Oct 28 15:29:39 Myth apachectl[958]: (99)Cannot assign requested address: AH00072: make_sock: could not bind to address 192.168.5.100:773
Oct 28 15:29:39 Myth apachectl[958]: no listening sockets available, shutting down
Oct 28 15:29:39 Myth apachectl[958]: AH00015: Unable to open logs
Oct 28 15:29:39 Myth apachectl[958]: Action 'start' failed.
Oct 28 15:29:39 Myth apachectl[958]: The Apache error log may have more information.
Oct 28 15:29:39 Myth systemd[1]: apache2.service: Control process exited, code=exited status=1
Oct 28 15:29:39 Myth systemd[1]: apache2.service: Failed with result 'exit-code'.
Oct 28 15:29:39 Myth systemd[1]: Failed to start The Apache HTTP Server.
Once the host is booted up, I can start Apache manually without any problem. Nothing in the apache error log files.
The proxy to a .php page on port 773 is the issue. Something is stopping that connection from happening, and the whole thing is shutting down.
Things I've tried:
Disabling ufw and rebooting. (Thinking that maybe the firewall "allow" rule took some time to establish itself).
Disabling apache2 and starting manually to see if it was a boot issue, or a "first attempt issue" - (it's a boot issue).
Putting a short delay in the init.d script for apache. (Sleep command seemed to be ignored.)
Changing #Required-Start to $all in the init.d script
What should I try next, and is there a way to set these kind of errors to "ignore"?
Checking process using port 773 immediately after boot:
# sudo netstat -ntpl | grep 773
#
# sudo systemctl list-units | grep apache2
● apache2.service loaded failed failed The Apache HTTP Server
# sudo systemctl is-enabled apache2
enabled
Checking process using port 773 after manually starting apache2:
#sudo netstat -ntpl | grep 773
tcp 0 0 192.168.5.100:773 0.0.0.0:* LISTEN 2122/apache2
#sudo systemctl list-units | grep apache2
apache2.service loaded active running
The Apache HTTP Server
#sudo systemctl is-enabled apache2
enabled
sudo netstat -ntpl | grep 773
sudo systemctl list-units | grep apache2
lets see its state and then if enabledsudo systemctl is-enabled apache2