dns-cache.asciidoc 1.1 KB

123456789101112131415161718
  1. [[networkaddress-cache-ttl]]
  2. === DNS cache settings
  3. Elasticsearch runs with a security manager in place. With a security manager in
  4. place, the JVM defaults to caching positive hostname resolutions
  5. indefinitely. If your Elasticsearch nodes rely on DNS in an environment where
  6. DNS resolutions vary with time (e.g., for node-to-node discovery) then you might
  7. want to modify the default JVM behavior. This can be modified by adding
  8. http://docs.oracle.com/javase/8/docs/technotes/guides/net/properties.html[`networkaddress.cache.ttl=<timeout>`]
  9. to your
  10. http://docs.oracle.com/javase/8/docs/technotes/guides/security/PolicyFiles.html[Java
  11. security policy]. Any hosts that fail to resolve will be logged. Note also that
  12. with the Java security manager in place, the JVM defaults to caching negative
  13. hostname resolutions for ten seconds. This can be modified by adding
  14. http://docs.oracle.com/javase/8/docs/technotes/guides/net/properties.html[`networkaddress.cache.negative.ttl=<timeout>`]
  15. to your
  16. http://docs.oracle.com/javase/8/docs/technotes/guides/security/PolicyFiles.html[Java
  17. security policy].