1. Compile and install
During the compilation process, there will be a problem that the class library cannot be found. Just install the class library first and then execute it again
2. Test the NGINX environment
Execute the following statement
Seeing the following prompt means that you have all the environments to start
What I encountered The error is like this
You need to add the nginx user group before starting nginx, otherwise you will be prompted
<span>[</span>emerg<span>]</span>: getpwnam<span>(</span>“nginx”<span>)</span> failed Copy after login |
Add user group
<span>sudo</span> adduser <span>--system</span><span>--no-create-home</span><span>--disabled-password</span><span>--group</span> nginx Copy after login |
Three , Start NGINX
Start NGINX
See the following prompt to indicate that the startup is successful
The above introduces the compilation, installation and configuration of NGINX, including the relevant aspects. I hope it will be helpful to friends who are interested in PHP tutorials.