I. Error message:

Job for httpd.service failed because the control process exited with error code. See “systemctl status httpd.service” and “journalctl -xe” for details. Ii. Troubleshooting Steps:

1. Run journalctl-xe to view log messages.

2. Run systemctl status HTTPD to check the Apache status.

3, use netstat antlp | grep 80 to check 80 port is being used.

/ root @ localhost ~ # netstat antlp | grep TCP 80 0 0 0.0.0.0:0.0.0.0:80 * 23917 / nginx LISTEN: Master TCP 0 0 192.168.1.130:52908 117.18.237.29:80 ESTABLISHED 23957/ Firefox TCP 0 0 192.168.1.130:35046 8.43.84.214:80  FIN_WAIT2 - tcp6 0 0 :::80 :::* LISTEN 23917/nginx: masterCopy the code

Port 80 is occupied by the Nginx service.

1, there are two ways to solve this problem. If you do not use Nginx, you can drop the kilI of the Nginx service that occupies port 80.

2, the second is to change the Apache port to another port.

[root@localhost ~]# vi /etc/httpd/conf/httpd.conf Change this to Listen on specific IP addresses as shown below to Prevent Apache from glomming onto all bound IP addresses. #Listen 12.34.56.78:80 Listen 80 // The 8080 can be 1 ️ and restart HTTPD service can be.  [root@localhost ~]# systemctl start HTTPD [root@localhost ~]# systemctl enable 2 firewall-cmd --zone=public --add-port=8080/tcp --permanentCopy the code