DNS resolution not refreshed
Description
Gliffy Diagrams
Activity

Kamil Burzynski December 17, 2012 at 9:06 AM
@Richard: well, my point is that, when you can't connect for long time, despite many tries, refreshing DNS should be attempted.
@Jordan: I'll try that once I'll be playing with logstash configuration next time, thanks. If it will work, it should be good enough. TTL of 15 minutes is definitely bearable (especially when logstash will buffe all output anyway), and way better than infinity. And 15 minutes TTL should be acceptable for all network components, without overloading any DNS servers.
Jordan Sissel December 17, 2012 at 2:11 AM
Eeeeh this is probably a java "feature"
Can you try disabling the jvm's dns caching? The default is to cache forever, which is a horrible tragedy of a default.
Setting java -Dnetworkaddress.cache.ttl=0 (default is -1 aka forever)

Richard Pijnenburg December 17, 2012 at 2:02 AM
I don't believe that this is really a bug.
It loads the config once and does the DNS resolving at that moment and saves that to avoid doing DNS resolving all the time.
To get the new ip address behind the name you will indeed need to restart/reload logstash.
Details
Details
Assignee

Reporter

I have a cluster of logstash log collectors, all sending logs to central elasticsearch server. I.e.:
I had some serious problems with the server at logstash.example.com, and I had no choice but to create new one (it was on Amazon EC2, and SSHD got so misconfigured that kept me locked out, so I basically ended up creating new instance). Either way, I've changed DNS entry to point to the new IP address. Needless to say, all running logstash instances kept connecting to the old IP. I had to manually restart all logstash processes to get it working.