dht.statistics reports the IPv6 DHT (BEP 32) beside the IPv4 one. Companion of libtorrent's IPv6 DHT, which runs a second DHT instance for IPv6 and adds its figures to torrent::tracker::DhtController::statistics_type: upstream since 801f29f8 (2026-11-10), in libtorrent 0.16.28 (until D405 libtorrent-dht-ipv6.patch, then a backport). dht.statistics gains active6, cycle6, queries_received6, queries_sent6, replies_received6, nodes6, buckets6, peers6 and torrents6; the existing keys keep the IPv4 DHT's figures, which the firewall checks in DhtManager::log_statistics() read. Needs that libtorrent commit. Upstream: rakshasa/rtorrent#2036, merged 2026-11-23 as 5761e7da, after 0.16.28; retire at the first release that contains it. diff --git a/src/core/dht_manager.cc b/src/core/dht_manager.cc index d9f3d33..fef8506 100644 --- a/src/core/dht_manager.cc +++ b/src/core/dht_manager.cc @@ -320,6 +320,17 @@ DhtManager::dht_statistics() { dhtStats.insert_key("peers", stats.num_peers); dhtStats.insert_key("peers_max", stats.max_peers); dhtStats.insert_key("torrents", stats.num_trackers); + + // The IPv6 DHT (BEP 32, libtorrent 801f29f8): its own table beside the IPv4 one. + dhtStats.insert_key("active6", stats.active6); + dhtStats.insert_key("cycle6", stats.cycle6); + dhtStats.insert_key("queries_received6", stats.queries_received6); + dhtStats.insert_key("queries_sent6", stats.queries_sent6); + dhtStats.insert_key("replies_received6", stats.replies_received6); + dhtStats.insert_key("nodes6", stats.num_nodes6); + dhtStats.insert_key("buckets6", stats.num_buckets6); + dhtStats.insert_key("peers6", stats.num_peers6); + dhtStats.insert_key("torrents6", stats.num_trackers6); } return dhtStats;