Issue encountered while running Apache2 on Ubuntu system.
Issue encountered while running Apache2 on Ubuntu system.
I am currently trying to use LAMP on my Linux Ubuntu computer. The first install went successful but I am trying to add PHPMyAdmin to the web server and I keep getting this error every time I try and reload the web server using 'systemctl'. Job for apache2.service failed because the control process exited with error code. Here is the information from "systemctl status apache2.service": ● apache2.service - The Apache HTTP Server Loaded: loaded (/lib/systemd/system/apache2.service; enabled; vendor preset: enabled) Drop-In: /lib/systemd/system/apache2.service.d └─apache2-systemd.conf Active: failed (Result: exit-code) since Fri 2018-09-28 19:31:48 BST; 3min 41s ago Process: 3284 ExecStart=/usr/sbin/apachectl start (code=exited, status=1/FAILURE) Sep 28 19:31:48 Stentorian-Ubuntu systemd[1]: apache2.service: Control process exited, code=exited status=1 Sep 28 19:31:48 Stentorian-Ubuntu apachectl[3284]: AH00558: apache2: Could not reliably determine the server's fully qualified domain Sep 28 19:31:48 Stentorian-Ubuntu apachectl[3284]: (98)Address already in use: AH00072: make_sock: could not bind to address [::]:80 Sep 28 19:31:48 Stentorian-Ubuntu apachectl[3284]: (98)Address already in use: AH00072: make_sock: could not bind to address 0.0.0.0: Sep 28 19:31:48 Stentorian-Ubuntu apachectl[3284]: no listening sockets available, shutting down Sep 28 19:31:48 Stentorian-Ubuntu apachectl[3284]: AH00015: Unable to open logs Sep 28 19:31:48 Stentorian-Ubuntu systemd[1]: apache2.service: Failed with result 'exit-code'. Sep 28 19:31:48 Stentorian-Ubuntu apachectl[3284]: Action 'start' failed. Sep 28 19:31:48 Stentorian-Ubuntu apachectl[3284]: The Apache error log may have more information. Sep 28 19:31:48 Stentorian-Ubuntu systemd[1]: Failed to start The Apache HTTP Server. Any help would be amazing! Thanks in advance!
The system reports conflicts on the specified port. One address is already in use, and another attempt is being made twice. Check the network interface with netstat to identify the conflicting process.
Review the output for any active connections on ports 80 and 443, then terminate those services. Verify your settings to ensure they aren't incorrectly configured as listening on all interfaces.
I executed the command and received this result: stentorian@Stentorian-Ubuntu:~$ sudo netstat -lnp | grep -e :80 -e :443 tcp 0 0 0.0.0.0:80 0.0.0.0:* LISTEN 954/nginx: master p tcp6 0 0 :::80 :::* LISTEN 954/nginx: master p stentorian@Stentorian-Ubuntu:~$ sudo netstat -lnp | grep -e :80 -e :443 tcp 0 0 0.0.0.0:80 0.0.0.0:* LISTEN 954/nginx: master p tcp6 0 0 :::80 :::* LISTEN 954/nginx: master p I really don’t understand this. If you could assist. I’m still learning Linux and it’s just starting out. Also, how to view the config and terminate those processes would be helpful! Read what I said above.]
You're attempting to use two web servers on the same port. Nginx is running on port 80, causing Apache to report an address already in use. To run Apache, you must either stop Nginx or adjust the port you're trying to use. Refer to the guides for changing Apache's default port.