Get your server issues fixed by our experts for a price starting at just 25 USD/Hour. Click here to register and open a ticket with us now!

Author Topic: While accessing Plesk Panel, "502 Bad Gateway" error is returned  (Read 2303 times)

0 Members and 1 Guest are viewing this topic.

jominj

  • Guest
while accessing the plesk panel we may get "502 Bad Gateway " error.

When we look the log file /var/log/sw-cp-server/error_log we could see error like following :
recv() failed (104: Connection reset by peer) while reading response header from upstream, client: 123.123.123.123, server: , request: "POST  <some url>


This issue is due to small value being set for  the fastcgi_buffer in the Plesk Panel configuration file for Nginx.

To solve this issue we have to increase the fastcgi_buffer size in the file etc/sw-cp-server/config . Increase size for following directives.
Code: [Select]
fastcgi_buffers 32 32k;
    fastcgi_buffer_size 64k;
After editing the configuration file restart the following services:
Code: [Select]
root@hostname:~# /etc/init.d/sw-cp-server restart

root@hostname:~# /etc/init.d/sw-engine restart