nginx: [emerg] bind() to 0.0.0.0:80 failed (13: Permission denied)

Zhang Chao zchao1995 at gmail.com
Tue Jul 11 01:24:19 UTC 2017


Hi!

Only the root can bind the ports small than 1024. You should start your
nginx service with the sudo prefix.


On 11 July 2017 at 09:20:40, Viaduct Lists (lists at viaduct-productions.com)
wrote:

Hi there.

Looking to get port 80 serving. Changed to root, but the error keeps the
user from running:

nginx: [warn] the "user" directive makes sense only if the master process
runs with super-user privileges, ignored in
/usr/local/etc/nginx/nginx.conf:2
nginx: the configuration file /usr/local/etc/nginx/nginx.conf syntax is ok
nginx: [emerg] bind() to 0.0.0.0:80 failed (13: Permission denied)
nginx: configuration file /usr/local/etc/nginx/nginx.conf test failed

Is there any way to get nginx working as root? Is this a bad idea? I just
don’t like running as port 8080. It complicates things down the road as I
want to implement SSL (port 443) later on. Port numbers also get into my
code later on.

Any advice appreciated how I can get this on normal ports 80 and 443.

_____________
Rich in Toronto @ VP






_______________________________________________
nginx mailing list
nginx at nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.nginx.org/pipermail/nginx/attachments/20170710/0493d10a/attachment-0001.html>


More information about the nginx mailing list