[emerg]: getpwnam(“nginx”) failed


[root@localhost nginx-1.11.2]# /usr/local/nginx/sbin/nginx 
nginx: [emerg] getpwnam("nginx") failed

 

没有安装nginx用户导致的无法启动

[root@localhost nginx-1.11.2]# useradd -s /sbin/nologin -M nginx
[root@localhost nginx-1.11.2]# id nginx

 

 

[root@localhost nginx-1.11.2]# /usr/local/nginx/sbin/nginx 
[root@localhost nginx-1.11.2]# netstat -tlunp | grep nginx
tcp        0      0 0.0.0.0:80              0.0.0.0:*               LISTEN      9709/nginx: master  

  

 


免责声明!

本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。



 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM