As shown in the figure: Check port usage: View the process occupying the port: From the results, we can see that port 80 is occupied by Nginx itself. You can kill the process and restart Nginx. After successfully killing the process, start Nginx Start Nginx successfully. Enter the IP address of the system where Nginx is located in the browser to verify whether Nginx is started successfully. The following describes how to start, stop, and restart Nginx. start up Startup code format: nginx installation directory address -c nginx configuration file address For example: [root@LinuxServer sbin]# /usr/local/nginx/sbin/nginx -c /usr/local/nginx/conf/nginx.conf stop There are three ways to stop nginx: Stop calmly 1. Check the process number [root@LinuxServer ~]# ps -ef|grep nginx 2. Kill the process [root@LinuxServer ~]# kill -QUIT 2072 Quick Stop 1. Check the process number [root@LinuxServer ~]# ps -ef|grep nginx 2. Kill the process [root@LinuxServer ~]# kill -TERM 2132 or [root@LinuxServer ~]# kill -INT 2132 Force Stop [root@LinuxServer ~]# pkill -9 nginx Restart 1. Verify whether the nginx configuration file is correct Method 1: Enter the nginx installation directory sbin and enter the command ./nginx -t The following shows that nginx.conf syntax is ok This indicates that the configuration file is correct! Method 2: Add -t before the startup command -c 2. Restart Nginx service Method 1: Enter the nginx executable directory sbin and enter the command ./nginx -s reload Method 2: Find the current nginx process number, and then enter the command: kill -HUP process number to restart the nginx service Summarize The above is what I introduced to you about the prompt that the port is occupied when starting Nginx: Address already in use. I hope it will be helpful to you. If you have any questions, please leave me a message and I will reply to you in time. I would also like to thank everyone for their support of the 123WORDPRESS.COM website! You may also be interested in:
|
<<: Implementation of vscode custom vue template
>>: MySql 5.6.35 winx64 installation detailed tutorial
When using vue to develop projects, the front end...
Online Preview https://jsrun.pro/AafKp/ First loo...
MySql is a data source we use frequently. It is v...
Start cleaning carefully! List unused volumes doc...
1. Clear floating method 1 Set the height of the ...
Nginx is used as the server, Mongo is used as the...
The image tag is used to display an image in a we...
#Case: Query employee salary levels SELECT salary...
The examples in this article run on MySQL 5.0 and...
1. Single row overflow 1. If a single line overfl...
1. Object-oriented class inheritance In the above...
introduce Vue Router is the official routing mana...
This is a pretty cool feature that makes web page...
1. mpstat command 1.1 Command Format mpstat [ -A ...
nohup command: If you are running a process and y...