Error 502, bad gateway.

Questions regarding the Web Server
Apache + Nginx, Nginx + PHP5-FPM
Totte
Posts: 12
Joined: Wed Apr 26, 2017 9:16 am

Error 502, bad gateway.

Postby Totte » Mon Sep 11, 2017 10:56 am

Hi, recently I've been getting error 502 from CloudFlare. My server has been running just fine for over 3 years and this problem appeared out of nowhere. It's been almost 2 weeks now and I can't figure it out. It even went to the point where I installed the server entirely, still getting the same problem.

My nginx error.log is empty.
Apache looks more or less like this

Code: Select all

Sep 10 13:50:53.886376 2017] [:notice] [pid 6463] mod_ruid2/0.9.8 enabled
[Sun Sep 10 13:50:53.888285 2017] [mpm_prefork:notice] [pid 6463] AH00163: Apache/2.4.18 (Ubuntu) mod_fcgid/2.3.9 OpenSSL/1.0.2g configured -- resuming no$
[Sun Sep 10 13:50:53.888304 2017] [core:notice] [pid 6463] AH00094: Command line: '/usr/sbin/apache2'
[Sun Sep 10 13:50:54.164527 2017] [mpm_prefork:notice] [pid 6463] AH00171: Graceful restart requested, doing restart
[Sun Sep 10 13:50:54.271159 2017] [:notice] [pid 6463] mod_ruid2/0.9.8 enabled
[Sun Sep 10 13:50:54.272956 2017] [mpm_prefork:notice] [pid 6463] AH00163: Apache/2.4.18 (Ubuntu) mod_fcgid/2.3.9 OpenSSL/1.0.2g configured -- resuming no$
[Sun Sep 10 13:50:54.272976 2017] [core:notice] [pid 6463] AH00094: Command line: '/usr/sbin/apache2'

skurudo
VestaCP Team
Posts: 7776
Joined: Fri Dec 26, 2014 2:23 pm
Location: Moscow
Contact:

Re: Error 502, bad gateway.

Postby skurudo » Tue Sep 12, 2017 8:46 am

What's about domains error logs?
top / htop - what's about memory/cpu/hdd ?
-> DigitalOcean competition - please, support us
-> fix for phpmyadmin - nice and sweet now

Totte
Posts: 12
Joined: Wed Apr 26, 2017 9:16 am

Re: Error 502, bad gateway.

Postby Totte » Tue Sep 12, 2017 11:15 am

skurudo wrote:What's about domains error logs?
top / htop - what's about memory/cpu/hdd ?


Mem/CPU/HDD looks all fine both in htop and running HP's system health check thing.

So I found another nginx log inside the Vesta folder.

Code: Select all

7/09/09 17:27:20 [error] 5464#0: *549 FastCGI sent in stderr: "PHP message: PHP Notice:  Undefined index: HTTP_CLIENT_IP in /usr/local/vesta/web/inc/main.php on line 14
PHP message: PHP Notice:  Undefined index: HTTP_X_FORWARDED_FOR in /usr/local/vesta/web/inc/main.php on line 14
PHP message: PHP Notice:  Undefined index: HTTP_X_FORWARDED in /usr/local/vesta/web/inc/main.php on line 14
PHP message: PHP Notice:  Undefined index: HTTP_FORWARDED_FOR in /usr/local/vesta/web/inc/main.php on line 14
PHP message: PHP Notice:  Undefined index: HTTP_FORWARDED in /usr/local/vesta/web/inc/main.php on line 14" while reading response header from upstream, client: 83.255.X.X, server: _, request$
2017/09/10 13:45:16 [error] 5464#0: *763 FastCGI sent in stderr: "PHP message: PHP Notice:  Undefined index: HTTP_CLIENT_IP in /usr/local/vesta/web/inc/main.php on line 14
PHP message: PHP Notice:  Undefined index: HTTP_X_FORWARDED_FOR in /usr/local/vesta/web/inc/main.php on line 14
PHP message: PHP Notice:  Undefined index: HTTP_X_FORWARDED in /usr/local/vesta/web/inc/main.php on line 14
PHP message: PHP Notice:  Undefined index: HTTP_FORWARDED_FOR in /usr/local/vesta/web/inc/main.php on line 14


My /var/log/nginx/domains/ folder is empty tho, or is there another location for domain logs?

Totte
Posts: 12
Joined: Wed Apr 26, 2017 9:16 am

Re: Error 502, bad gateway.

Postby Totte » Fri Sep 15, 2017 6:46 am

Someone may close the thread. Solved it by changing to Virtualmin.


Return to “Web Server”



Who is online

Users browsing this forum: Bing [Bot] and 4 guests