• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion

nginx: 502 Bad Gateway with every domain change

CGI1979

Basic Pleskian
Hi Plesk friends,

since we switched to Plesk 12 and activated nginx the problem reoccurs reliably on every domain change.
As soon as a customer creates a new domain or alias and Apache restarts nginx delivers 502 errors for maybe 10 seconds. After that everything is fine again.

The system is Debian 6.0.10 with Plesk 12.0.18 Update #38

That might not be a problem in small environments, but with >100 domains the timeout is annoying enough for customers to pick up the phone.

Adding this to /etc/sw-cp-server/config did not do the trick.

http {

fastcgi_buffers 32 32k;
fastcgi_buffer_size 64k;
fastcgi_read_timeout 600;
fastcgi_send_timeout 600;

}
 
There are many related KB articles. Try to use "502 error" search string there and apply suggested solutions from articles. I hope it will help.
 
Right. Apache graceful restart often helps with this error.
 
Back
Top