]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
Change default stale-answer-client-timeout to off
authorMatthijs Mekking <matthijs@isc.org>
Fri, 2 Apr 2021 12:33:54 +0000 (14:33 +0200)
committerMatthijs Mekking <matthijs@isc.org>
Wed, 7 Apr 2021 12:10:31 +0000 (14:10 +0200)
Using "stale-answer-client-timeout" turns out to have unforeseen
negative consequences, and thus it is better to disable the feature
by default for the time being.

12 files changed:
CHANGES
bin/named/config.c
bin/tests/system/serve-stale/ns1/named1.conf.in
bin/tests/system/serve-stale/ns1/named2.conf.in
bin/tests/system/serve-stale/ns1/named3.conf.in
bin/tests/system/serve-stale/ns3/named2.conf.in
bin/tests/system/serve-stale/ns3/named3.conf.in
bin/tests/system/serve-stale/ns3/named6.conf.in
bin/tests/system/serve-stale/ns3/named7.conf.in
bin/tests/system/serve-stale/tests.sh
doc/arm/reference.rst
doc/notes/notes-current.rst

diff --git a/CHANGES b/CHANGES
index e446dd9a41a567ee6b6bb54aa99c28c204942656..17c04181bd52c2bee95857a0a389d4d2f8ac4dcf 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -1,3 +1,6 @@
+5611.  [func]          Set "stale-answer-client-timeout" to "off" by default.
+                       [GL #2608]
+
 5610.  [bug]           Prevent a crash which could happen when a lookup
                        triggered by "stale-answer-client-timeout" was attempted
                        right after recursion for a client query finished.
index a6a918100b6517c99308d302f39c537a311de7e7..76fc72eca9d51597793e70ccf81168c8d8bc8c1f 100644 (file)
@@ -196,7 +196,7 @@ options {\n\
        servfail-ttl 1;\n\
 #      sortlist <none>\n\
        stale-answer-enable false;\n\
-       stale-answer-client-timeout 1800; /* in milliseconds */\n\
+       stale-answer-client-timeout off;\n\
        stale-answer-ttl 30; /* 30 seconds */\n\
        stale-cache-enable false;\n\
        stale-refresh-time 30; /* 30 seconds */\n\
index a8410a0e448166116531fef8569bb6035da38878..41347871cdec0dacfc66ec3a843f12d2475fa498 100644 (file)
@@ -30,7 +30,6 @@ options {
        max-stale-ttl 3600;
        stale-answer-ttl 4;
        stale-answer-enable yes;
-       stale-answer-client-timeout disabled;
        stale-cache-enable yes;
        stale-refresh-time 30;
        servfail-ttl 0;
index c8a8daeee1a22e8593aba536bb3a90bccb6c1456..06fae5369c2c61d90e62e41d66d80fc1ecacb746 100644 (file)
@@ -30,7 +30,6 @@ options {
        max-stale-ttl 20;
        stale-answer-ttl 3;
        stale-answer-enable yes;
-       stale-answer-client-timeout disabled;
        stale-cache-enable yes;
        servfail-ttl 0;
 };
index 6fed86ae4052230a18a8c70b0c7d40106ff51c61..f97dea958de86c5242ee4c684ee055d29341db25 100644 (file)
@@ -30,7 +30,6 @@ options {
        max-stale-ttl 20;
        stale-answer-ttl 3;
        stale-answer-enable yes;
-       stale-answer-client-timeout disabled;
        stale-cache-enable yes;
        stale-refresh-time 0;
        servfail-ttl 0;
index e91f67b0442f3de707e18a8c20ffbb96b3578b92..40c053e07feb102ecc57503fd3154ca087717f64 100644 (file)
@@ -37,6 +37,7 @@ options {
        stale-cache-enable yes;
        stale-answer-ttl 3;
        stale-refresh-time 0;
+       stale-answer-client-timeout 1800;
        max-stale-ttl 3600;
        resolver-query-timeout 10;
 };
index 0520e514c15e144ffaa58b97e9ad1e4f4a9a5654..7d50bc8ff8f588e9f462142e8711f787214a21d3 100644 (file)
@@ -36,7 +36,6 @@ options {
        stale-answer-enable yes;
        stale-cache-enable yes;
        stale-answer-ttl 3;
-       stale-answer-client-timeout off;
        stale-refresh-time 0;
        max-stale-ttl 3600;
        resolver-query-timeout 10;
index 1aea7c85c2f7ef0f53ec837362e5eeb95840d6c8..2b7c42c456f518df9c37a0306ec126c444b7dc15 100644 (file)
@@ -36,7 +36,6 @@ options {
        stale-answer-enable no;
        stale-cache-enable yes;
        stale-answer-ttl 3;
-       stale-answer-client-timeout disabled;
        stale-refresh-time 4;
        resolver-query-timeout 10;
        fetches-per-zone 1 fail;
index 403a6fa9e2555cc066f15ce613087819fee61b69..10e77d7d2571595b3f431eb2e4494c3de5ce137f 100644 (file)
@@ -40,7 +40,6 @@ options {
        stale-answer-enable yes;
        stale-cache-enable yes;
        stale-answer-ttl 3;
-       stale-answer-client-timeout disabled;
        stale-refresh-time 4;
        resolver-query-timeout 10;
        fetches-per-zone 1 fail;
index 02535b002d1ba739771fda188653cc7f7c12beac..2205962c7d918f57f12ed1eeffe2f8a8d6249d7e 100755 (executable)
@@ -1573,10 +1573,10 @@ grep -F "#NXDOMAIN" ns5/named.stats.$n.cachedb > /dev/null && ret=1
 status=$((status+ret))
 if [ $ret != 0 ]; then echo_i "failed"; fi
 
-########################################################
-# Test for stale-answer-client-timeout (default 1.8s). #
-########################################################
-echo_i "test stale-answer-client-timeout (default 1.8)"
+################################################
+# Test for stale-answer-client-timeout (1.8s). #
+################################################
+echo_i "test stale-answer-client-timeout (1.8)"
 
 n=$((n+1))
 echo_i "updating ns3/named.conf ($n)"
index 2a3ff1ffd31eea942029b4145d41821ac48f9a6f..e51f320df4efa3ff2ecb9f70b68ae4fd5df6029f 100644 (file)
@@ -1856,18 +1856,21 @@ Boolean Options
    log category.
 
 ``stale-answer-client-timeout``
-   This option defines the amount of time ``named`` waits before attempting to
-   answer the query with a stale RRset from cache. If a stale answer is found,
-   ``named`` continues the ongoing fetches, attempting to refresh the RRset in
-   cache until the ``resolver-query-timeout`` interval is reached.
-
-   The default value is ``1800`` (in milliseconds) and the maximum value is
-   bounded to ``resolver-query-timeout`` minus one second. A value of ``0``
-   immediately returns a cached RRset if available, and still attempts a refresh
-   of the data in cache.
-
-   The option can be disabled by setting the value to ``off`` or ``disabled``.
-   It also has no effect if ``stale-answer-enable`` is disabled.
+   This option defines the amount of time (in milliseconds) that ``named``
+   waits before attempting to answer the query with a stale RRset from cache.
+   If a stale answer is found, ``named`` continues the ongoing fetches,
+   attempting to refresh the RRset in cache until the
+   ``resolver-query-timeout`` interval is reached.
+
+   This option is off by default, which is equivalent to setting it to
+   ``off`` or ``disabled``. It also has no effect if ``stale-answer-enable``
+   is disabled.
+
+   The maximum value for this option is ``resolver-query-timeout`` minus
+   one second. The minimum value, ``0``, causes a cached RRset to be
+   immediately returned if it is available while still attempting to
+   refresh the data in cache. :rfc:`8767` recommends a value of ``1800``
+   (milliseconds).
 
 ``stale-cache-enable``
    If ``yes``, enable the retaining of "stale" cached answers.  Default ``no``.
index 1758bbdd47993b643ca1d989fe16712dc5441cd5..ec47cf85d15499c73f9b677d1f0c0a42ac305de2 100644 (file)
@@ -41,6 +41,10 @@ Feature Changes
   9.17.2, but it was not included in the release notes at the time.
   [GL #2607]
 
+- The default value for the ``stale-answer-client-timeout`` option was
+  changed from ``1800`` (ms) to ``off``. The default value may be
+  changed again in future releases as this feature matures. [GL #2608]
+
 Bug Fixes
 ~~~~~~~~~