重启nginx
systemctl restart nginx
报错如下
Job for nginx.service failed because the control process exited with error code. See "systemctl status nginx.service" and "journalctl -xe" for details.
查看端口80
netstat -lnp|grep 80
tcp 0 0 0.0.0.0:21 0.0.0.0:* LISTEN 20805/vsftpd
tcp6 0 0 127.0.0.1:8005 :::* LISTEN 12106/java
tcp6 0 0 :::80 :::* LISTEN 13745/httpd
tcp6 101 0 :::8080 :::* LISTEN 12978/java
udp6 0 0 fe80::5054:ff:fe9c::123 :::* 631/ntpd
杀掉占用进程
kill -9 13745
再次重启nginx
systemctl restart nginx