<div dir="ltr"><div style="font-family:arial,sans-serif;font-size:14px">Hello,lists:</div><div style="font-family:arial,sans-serif;font-size:14px">I am using varnish in a CentOS6.4 box,bellow is version info:</div><div><div>
<font face="arial, sans-serif"><span style="font-size:14px"><br></span></font></div><div><font face="arial, sans-serif"><span style="font-size:14px">[root@cdn001 ~]# uname -r</span></font></div><div><font face="arial, sans-serif"><span style="font-size:14px">2.6.32-358.2.1.el6.x86_64</span></font></div>
<div><font face="arial, sans-serif"><span style="font-size:14px">[root@cdn001 ~]# rpm -q varnish</span></font></div><div><font face="arial, sans-serif"><span style="font-size:14px">varnish-3.0.3-3.el6.art.x86_64</span></font></div>
<div style="font-family:arial,sans-serif;font-size:14px"><br></div></div><div style="font-family:arial,sans-serif;font-size:14px">and in my /etc/varnish/default.vcl</div><div style="font-family:arial,sans-serif;font-size:14px">
I use ' <span class="" style="background-color:rgb(255,255,204)">dns</span> director':</div><div style="font-family:arial,sans-serif;font-size:14px"><br></div><div style="font-family:arial,sans-serif;font-size:14px">
director dnsdomain <span class="" style="background-color:rgb(255,255,204)">dns</span> {</div><div style="font-family:arial,sans-serif;font-size:14px"> .list = {</div><div style="font-family:arial,sans-serif;font-size:14px">
.port = "80";</div><div style="font-family:arial,sans-serif;font-size:14px"> "10.0.0.0"/24;</div><div style="font-family:arial,sans-serif;font-size:14px"> }</div><div style="font-family:arial,sans-serif;font-size:14px">
.<span class="" style="background-color:rgb(255,255,204)">ttl</span> = 12h;</div><div style="font-family:arial,sans-serif;font-size:14px">}</div><div style="font-family:arial,sans-serif;font-size:14px">notice that the ttl has been set to 12h because I want to reduse dns resolve time,there is a domain <a href="http://www.example.com">www.example.com</a> which resolved to 10.0.0.2 ,after the dns changed <a href="http://www.example.com">www.example.com</a> to 10.0.0.3, varnish cannot find the real backend as the ttl been set to 12h.so I must do a 'service varnish reload' to update the director.</div>
<div style="font-family:arial,sans-serif;font-size:14px"><br></div><div style="font-family:arial,sans-serif;font-size:14px">Is there any other way to flush the director ttl without a service reload ? thanks. </div></div>