Commit Graph
41351 Commits
Author SHA1 Message Date
Aydın Mercan 068bfa6a21 more temporary probing 2024-06-10 13:10:59 +03:00
Aydın Mercan 617a9ee373 unbarrier 2024-06-08 20:50:58 +03:00
Aydın Mercan c1a945cfdc temporary trace: 2024-06-08 18:58:16 +03:00
Evan Hunt 206e67b008 remove unnecessary argument to find_deepest_zonecut()
a minor bit of code refactoring - the 'node' argument wasn't
being used; it was just being treated as a local variable.
2024-06-07 17:24:46 -07:00
Evan Hunt c7a236e49e experiment: improve locking around decref()
instead of always calling decref() with a node lock, we now only
acquire the lock if the node needs to be cleaned or deleted.
2024-06-07 17:24:46 -07:00
Evan Hunt 19674c5c6e experiment: make header->trust atomic 2024-06-07 17:24:46 -07:00
Evan Hunt c6d5e8bc86 experiment: increase QP chunk size 2024-06-07 17:24:46 -07:00
Evan Hunt 90f29d61d2 minor findnode optimization
when searching for a node so that we can delete an rdataset,
it is not necessary to set the 'create' flag. if the node doesn't
exist yet, we wouldn't be able delete anything from it.
2024-06-07 17:24:45 -07:00
Evan Hunt a7e6c06ef7 in findnode, use a read transaction when possible
when findnode() is called with the 'create' flag set, instead of
automatically opening a write transaction, we will now try to look up
the name with a read transaction, and only open a write transaction if
that failed.
2024-06-07 17:24:45 -07:00
Evan Hunt 0ea634a5db reduce node locking
some calls to bindrdataset were node-locked; this is no longer necessary.
2024-06-07 17:24:45 -07:00
Evan Hunt 893571a19d access node attributes atomically
in the qpcnode struct, the .delegating, .nsec, and .dirty
members are now atomic, enabling us to avoid acquiring the
node lock when those are the only things we need to check.

also, renamed the check_zonecut() function to the more
correctly descriptive has_dname().
2024-06-07 17:24:45 -07:00
Ondřej SurýandEvan Hunt 6f8a75e6e1 compact the cache database less often
to speed up the cache, compact the database only when nodes
have been added or removed.
2024-06-07 17:24:45 -07:00
Ondřej SurýandEvan Hunt 929fb51612 add an isc_loop_rcu_barrier() for memory cleanup to finish
when adding data to the cache while over memory limits, add an
RCU barrier to ensure that memory is cleaned right away.
2024-06-07 17:24:20 -07:00
Ondřej SurýandEvan Hunt fb39babdff Add a function to call rcu_barrier once per loop
isc_loop_rcu_barrier() sets a flag so that rcu_barrier() will be
called at the end of the current loop tick. This allows us to minimize
time spent synchronizing between threads.
2024-06-07 17:24:19 -07:00
Evan Hunt b649786423 use dns_qpmulti instead of dns_qp in the cache
replace the single-threaded dns_qp objects in the qpcache
database with dns_qpmulti and eliminate the tree lock.
2024-06-07 17:24:19 -07:00
Evan Hunt 05823eb1b0 Merge branch '4728-allow-transfer-none' into 'main'
change allow-transfer default to "none"

Closes #4728

See merge request isc-projects/bind9!9046
2024-06-05 21:50:47 +00:00
Evan Hunt 2b7cbd8d95 CHANGES and relnotes for [GL #4728] 2024-06-05 10:50:06 -07:00
Evan Hunt c3d3d12911 change allow-transfer default to "none"
Changed the default value for 'allow-transfer' to 'none'; zone
transfers now require explicit authorization.

Updated all system tests to specify an allow-transfer ACL when needed.

Revised the ARM to specify that the default is 'none'.
2024-06-05 10:50:06 -07:00
Ondřej Surý 74cbaf46c9 Merge branch 'ondrej/use-rcu-stack-for-qpcache-deadnodes' into 'main'
Use RCU wait-free stack for qpcache deadnodes

See merge request isc-projects/bind9!8907
2024-06-05 17:40:30 +00:00
Ondřej Surý 086b63f56d Use isc_queue to implement wait-free deadnodes queue
Replace the ISC_LIST based deadnodes implementation with isc_queue which
is wait-free and we don't have to acquire neither the tree nor node lock
to append nodes to the queue and the cleaning process can also
copy (splice) the list into a local copy without acquiring the list.

Currently, there's little benefit to this as we need to hold those
locks anyway, but in the future as we move to RCU based implementation,
this will be ready.

To align the cleaning with our event loop based model, remove the
hardcoded count for the node locks and use the number of the event loops
instead.  This way, each event loop can have its own cleaning as part of
the process.  Use uniform random numbers to spread the nodes evenly
between the buckets (instead of hashing the domain name).
2024-06-05 09:19:56 +02:00
Ondřej Surý a9b4d42346 Add isc_queue implementation on top of cds_wfcq
Add an isc_queue implementation that hides the gory details of cds_wfcq
into more neat API.  The same caveats as with cds_wfcq.

TODO: Add documentation to the API.
2024-06-05 09:19:56 +02:00
Mark Andrews 67b9510988 Merge branch '4736-isc_r_hostdown-was-not-being-handled-by-resolver-c' into 'main'
Resolve "ISC_R_HOSTDOWN was not being handled by resolver.c"

Closes #4736

See merge request isc-projects/bind9!9055
2024-06-04 07:35:36 +00:00
Mark Andrews 71cfa8dfba Add CHANGES note for [GL #4736] 2024-06-04 00:16:30 +10:00
Mark Andrews 56c3dcc5d7 Update resquery_senddone handling of ISC_R_TIMEDOUT
Treat timed out as an address specific error.
2024-06-04 00:15:48 +10:00
Mark Andrews 4e3dd85b8d Update resquery_senddone handling of ISC_R_CONNECTIONRESET
Treat connection reset as an address specific error.
2024-06-04 00:15:48 +10:00
Mark Andrews 180b1e7939 Handle ISC_R_HOSTDOWN and ISC_R_NETDOWN in resolver.c
These error codes should be treated like other unreachable error
codes.
2024-06-04 00:15:48 +10:00
Michał Kępień e7971f6ac8 Merge branch '4706-4707-add-more-label-checks-to-dangerfile.py' into 'main'
Add more label checks to dangerfile.py

Closes #4706 and #4707

See merge request isc-projects/bind9!9040
2024-06-03 11:10:55 +00:00
Michał Kępień aae51cf28d Fail for merge requests with "Affects v9.x" labels
Setting "Affects v9.x" labels on a merge request duplicates information
already present on the GitLab issue associated with that merge request.
For trivial merge requests that are not associated with any GitLab
issue, setting the "Affects v9.x" label(s) is considered unnecessary.
Trigger a failure for every merge request marked with at least one
"Affects v9.x" label.
2024-06-03 13:07:21 +02:00
Michał Kępień 80ec57f198 Warn about auto-generated merge request titles
Merge request titles auto-generated by GitLab are often a source of
confusion regarding the actual contents of a given merge request.  Warn
for merge requests containing titles that look like auto-generated ones.
2024-06-03 13:07:21 +02:00
Michał Kępień 09851e6230 Fail for branches using old-style version suffixes
Using "-v9_x" and "-v9.x" version suffixes for branch names is now
deprecated since some automation logic does not handle these.  Fail for
any merge request using such old-style version suffixes.
2024-06-03 13:07:21 +02:00
Michał Kępień 9359cb9c99 Fail for backports with "Affects v9.x" labels set
Backports are not expected to have any "Affects v9.x" labels set since
those are only meant to be set for merge requests that should have
backports created for them.
2024-06-03 13:07:21 +02:00
Mark Andrews 89d7d52010 Merge branch '3472-ipv4-only-mode-not-respected-for-zone-transfers' into 'main'
Resolve "IPv4-only mode not respected for zone transfers"

Closes #3472

See merge request isc-projects/bind9!8522
2024-06-03 09:59:44 +00:00
Mark Andrews 3834e433f7 Add CHANGES note for [GL #6288] 2024-06-03 18:35:02 +10:00
Mark Andrews 05472e63e8 Don't do DS checks over disabled address families 2024-06-03 18:34:31 +10:00
Mark Andrews d026dbe536 Don't forward UPDATE messages over disabled address families 2024-06-03 18:34:31 +10:00
Mark Andrews 5d99625515 Don't send NOTIFY over disabled address families 2024-06-03 18:34:31 +10:00
Mark Andrews 07cdf3e945 Check that no primaries is logged with -4 or -6
When in -4 mode check that "IPv6 disabled and no IPv4 primaries"
is logged and when in -6 mode check that "IPv4 disabled and no IPv6
primaries" is logged.
2024-06-03 18:34:31 +10:00
Mark Andrews 2cd4303249 Report non-effective primaries
When named is started with -4 or -6 and the primaries for a zone
do not have an IPv4 or IPv6 address respectively issue a log message.
2024-06-03 18:34:31 +10:00
Mark Andrews ecdde04e63 Zone transfers should honour -4 and -6 options
Check if the address family has been disabled when transferring
zones.
2024-06-03 18:34:31 +10:00
Mark Andrews 9be1873ef3 Add helper function isc_sockaddr_disabled 2024-06-03 18:34:31 +10:00
Matthijs Mekking 50a2c308d6 Merge branch '4708-uv-tcp-close-reset-issue' into 'main'
Deal with uv_tcp_close_reset more gracefully

Closes #4708

See merge request isc-projects/bind9!9022
2024-06-03 08:15:35 +00:00
Matthijs Mekking 113968f3a0 Add CHANGES entry for [GL #4708] 2024-06-03 10:15:18 +02:00
Matthijs Mekking c40e5c8653 Call reset_shutdown if uv_tcp_close_reset failed
If uv_tcp_close_reset() returns an error code, this means the
reset_shutdown callback has not been issued, so do it now.
2024-06-03 10:14:47 +02:00
Matthijs Mekking 5b94bb2129 Do not runtime check uv_tcp_close_reset
When we reset a TCP connection by sending a RST packet, do not bother
requiring the result is a success code.
2024-06-03 10:14:47 +02:00
Mark Andrews 91d5c9a878 Merge branch 'marka-placeholder' into 'main'
add placeholder

See merge request isc-projects/bind9!9083
2024-06-03 07:46:04 +00:00
Mark Andrews 728e53be47 add placeholder 2024-06-03 17:18:24 +10:00
Mark Andrews 52a2fb1ab3 Merge branch '2744-warning-checkhints-unable-to-get-root-ns-rrset-from-cache-not-found' into 'main'
Resolve "warning: checkhints: unable to get root NS rrset from cache: not found"

Closes #2744

See merge request isc-projects/bind9!8745
2024-05-31 06:16:24 +00:00
Mark Andrews 5be6ceebc4 Add CHANGES entry for [GL #2744] 2024-05-31 15:40:32 +10:00
Mark Andrews 87e3b9dbf3 Pass a memory context in to dns_cache_create 2024-05-31 15:40:32 +10:00
Mark Andrews 5e77edd074 Use a new memory context when flushing the cache
When the cache's memory context was in over memory state when the
cache was flushed it resulted in LRU cleaning removing newly entered
data in the new cache straight away until the old cache had been
destroyed enough to take it out of over memory state.  When flushing
the cache create a new memory context for the new db to prevent this.
2024-05-31 15:40:32 +10:00