proxy_pass error: host not found in upstream

Igor Sysoev igor at sysoev.ru
Mon May 10 17:04:29 MSD 2010


On Mon, May 10, 2010 at 08:46:53PM +0800, 任晓磊 wrote:

> On Mon, May 10, 2010 at 5:15 PM, Igor Sysoev <igor at sysoev.ru> wrote:
> > Host upload.wikipedia.org not found: 3(NXDOMAIN)
> Thank you for pointing out my mistake.
> But I wonder why is the domain name resolved when testing config file?
> I think NXDOMAIN should be a runtime error, not occured before nginx
> runs. Or else, what would happen if the domain name is deleted during
> nginx running?

nginx resolves hosts at configuration phase, because for a long time
nginx has no non-blocikng resolver. Currently it has, but resolves
hosts at run-time only if proxy_pass contains variables in any place,
not necessarily in the host part.


-- 
Igor Sysoev
http://sysoev.ru/en/



More information about the nginx mailing list