Fixed the upstream sent too big header error

I was trying to set up a rather new CMS on my Nginx server just now,  after playing with the rewrite rule for some time , finally the script is up and running, but some of the module is display  502 gateway error. Checking on the log file and this are main error message.

upstream sent too big header while reading response header from upstream


Checking through Google and it seem like a common error, the solution is adding these 2 line on nginx.conf

fastcgi_buffers 8 16k;
fastcgi_buffer_size 32k;

once you added this 2 config, restart you Nginx server and PHP 5 FPM too , if you only restart the server it seem like still showing the same error, I spending some time to realise that I need to restart the PHP5 FPM too in order for the config to work.

Share it with your friends, thanks !
Share on FacebookTweet about this on TwitterShare on Google+Share on TumblrBuffer this pagePin on PinterestEmail this to someone

You may also like...