H
H
HellWalk2018-04-24 15:27:17
Nginx
HellWalk, 2018-04-24 15:27:17

What could break in nginx?

nginx was on the working computer for about a year - everything worked, I did not know any problems.
Today I installed MongoDB, immediately after installation there were problems with the operation of this database, I tried to fix it for three hours, trying one or the other instruction on the Internet, as a result, when I opened one of the local sites, I found that it did not open:

502 Bad Gateway
nginx/1.10.3 (Ubuntu)

The situation is similar with all other local sites.
In the logs:
2018/04/24 15:16:53 [error] 6873#6873: *1 connect() failed (111: Connection refused) while connecting to upstream, client: 127.0.0.1, server: site.loc, request: "GET index.php HTTP/1.1", upstream: "fastcgi://127.0.0.1:9000", host: "site.loc"

Checking nginx:
sudo nginx -t
nginx: configuration file /etc/nginx/nginx.conf syntax is ok
nginx: configuration file /etc/nginx/nginx.conf test is successful

I tried to dig deeper into the nginx settings - it didn’t give any results, which is logical - nothing changed in nginx.
I'm still confused by this thing:
nmap -p 9000 127.0.0.1
Starting Nmap 7.01 ( https://nmap.org ) at 2018-04-24 13:36 MSK
Nmap scan report for localhost (127.0.0.1)
Host is up (0.000078s latency).
PORT STATE SERVICE
9000/tcp closed cslistener

But perhaps this is normal - I checked it on another machine (it's true Apache and not nginx) - similarly.
In general, I have no idea what could break in nginx. Has anyone encountered a similar problem - when you do not touch anything in it, but it stops working?
PS If you need other configs - write.

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question