# DNS caching issue

**URL:** <https://www.ruby-forum.com/t/dns-caching-issue/213906>\
**Category:** NGINX\
**Created:** [November 15, 2011, 10:58pm UTC](https://www.ruby-forum.com/t/dns-caching-issue/213906 "2011-11-15T22:58:56Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![luislavena](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/l/0ea827/32.png) [@luislavena](https://www.ruby-forum.com/u/luislavena)\
**Post date:** [November 15, 2011, 10:58pm UTC](https://www.ruby-forum.com/t/dns-caching-issue/213906/1 "2011-11-15T22:58:56Z")

</div>

So we are using nginx from a few builds back as upgrading consistently  
has proven difficult for our ops team to keep up with where I work. I  
think we’re on 1.0.5.

We have some hosts setup to handle subrequests using proxy\_pass  
directive. When the DNS record is changed, and the host command on  
the machine is reporting a _new_ host ip in the dns result. That host  
does not see traffic like it should.

We have always attributed this to caching in dns and we perform “nginx  
reconfigure” to reparse conf and re-read dns. This isn’t working for  
us though and i’m not sure why. We did upgrade to 1.0.5 relatively  
recently and i’m wondering if we inherited a bug. Two things are odd  
though.

When we pulled the host ip _out_ of the dns, and performed nginx  
reconfigure, the traffic to the machine ceased. But now that our work  
is done, and we’re trying to put it back into rotation, nginx  
reconfigure does not seem to be working.

Doing a restart is harder, as we have to drain the machine in  
question. But is there any known behavior that might be the root  
cause of this? Far as I’m aware the TTL on the DNS is 5m. But its  
been hours since the change.

-James-

---

<div class="post-metadata">

**Author:** ![James\_Lyons](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/b2d939/32.png) [@James\_Lyons](https://www.ruby-forum.com/u/James_Lyons)\
**Post date:** [November 16, 2011, 9:24am UTC](https://www.ruby-forum.com/t/dns-caching-issue/213906/2 "2011-11-16T09:24:12Z")

</div>

James,

On Nov 16, 2011, at 1:58 AM, James Lyons wrote:

> reconfigure" to reparse conf and re-read dns. This isn’t working for  
> question. But is there any known behavior that might be the root  
> cause of this? Far as I’m aware the TTL on the DNS is 5m. But its  
> been hours since the change.

Can you please show the relevant portion of your proxy configuration?
