I’m hosting a discourse instance (running latest), on aws with 7.5gb ram and 2 CPU’s (it’s a m3.large).
While sometimes discourse works okay, some other times requests seem to get stuck and people either see a infinite loading or get 502 from ngnix.
taking a look at our
error.log from ngnix the following message pops up at these times:
upstream timed out (110: Connection timed out) while connecting to upstream, client: 126.96.36.199, server: _, request: "GET / HTTP/1.1", upstream: "http://127.0.0.1:3000/", host: "www.guj.com.br"
Which seems strange as most of times the machine still has 2-3 GB of free memory, and CPU and RDS don’t show any excessive usage.
Any ideas on tunings we could try, or what could we be doing wrong?