nixCraft published a tutorial about how to fix the "Nginx upstream sent too big header while reading response header from upstream" error.
Nginx upstream sent too big header while reading response error - nixCraft
Explains how to fix Nginx error, "upstream sent too big header while reading response header from upstream" with proxy_pass and reverse proxy
Nginx upstream sent too big header while reading response error - nixCraft