How does a DHT in a Bittorent client get "bootstrapped"?
Solution 1:
The mainline DHT bootstrap nodes are router.utorrent.com
and a CNAME to it, router.bittorrent.com
. Port 6881
.
Solution 2:
When a BitTorrent client connects to DHT, there is an initial place that it goes to find peers. With the original BitTorrent client, there was a url to bitorrent.com that would help get things started. I tried looking up the reference but I couldn't find it. Once you've established connections with other clients, then you can do an announce
on the DHT network to find peers for the torrent you're looking for.
Here's a link to the BitTorrent specs that discuss DHT.
A trackerless torrent dictionary does not have an "announce" key. Instead, a trackerless torrent has a "nodes" key. This key should be set to the K closest nodes in the torrent generating client's routing table. Alternatively, the key could be set to a known good node such as one operated by the person generating the torrent. Please do not automatically add "router.bittorrent.com" to torrent files or automatically add this node to clients routing tables.
Solution 3:
the graph at the bottom of this DHT monitoring project site shows
- dht.transmissionbt.com
- router.utorrent.com
- router.bittorrent.com
as bootstrapping peers
Solution 4:
In BiTTorrent, you have three main options:
-
Torrent File: some torrent files can embed
nodes
for you to link into the DHT with (in fact, it's recommended when making a torrent file) - Hardcoding: Some torrent clients hard code a few bootstrap nodes (like the ones mentioned by stk). These are usually run by companies and organizations with long-running servers.
- PEX / Peer Conversations: You can usually ask for DHT nodes from the people you are downloading other torrents from (if your clients understand eachothers language. ie some versions are incompatible).