C
C
Corp_Habra_Clients2020-01-18 23:46:04
Nginx
Corp_Habra_Clients, 2020-01-18 23:46:04

NGINX validation error?

Hello!
When trying to start Nginx on port 80, an error pops up:

[email protected]:/# sudo nginx -t
nginx: the configuration file /etc/nginx/nginx.conf syntax is ok
nginx: [emerg] bind() to 0.0.0.0:80 failed (13: Permission denied)
nginx: configuration file /etc/nginx/nginx.conf test failed
[email protected]:/#
At the same time, if you put nginx on a non-standard port, it works, but Let's Encrypt does not want to confirm the domain! How to run nginx on port 80 or how to check a domain in Let's Encrypt on a non-standard port?!
Tell me please!

Answer the question

In order to leave comments, you need to log in

4 answer(s)
A
Alexey Dmitriev, 2020-01-19
@SignFinder

apparently something else occupied port 80.
Look in the output of the
netstat -pna|grep 80 command, what hangs on this port

D
Dim Boy, 2020-01-18
@twix007

443 port ssl, and there are no psychics here

K
Karpion, 2020-01-19
@Karpion

Ports up to 1023 are allowed only for root. What user are you running under?
Well, as already said - someone else could capture the port earlier.
"Permission denied" seems to hint at the first point.

N
Nikita, 2020-01-19
@Extar93

Strange, I just stop nginx, start certbot and it confirms everything itself, then service nginx start and everything is fine. You can also try

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question