Questions tagged [dht]

A Hash Table is a data structure used to store data in the form of Key=>Value pairs. A Distributed Hash Table (DHT) is basically a hash table distributed across a network of computers(nodes). A DHT uses a Routing Protocol to determine which node to store a piece of data on.

A distributed hash table (DHT) is a class of a decentralized distributed system that provides a lookup service similar to a hash table; (key, value) pairs are stored in a DHT, and any participating node can efficiently retrieve the value associated with a given key. Responsibility for maintaining the mapping from keys to values is distributed among the nodes, in such a way that a change in the set of participants causes a minimal amount of disruption. This allows a DHT to scale to extremely large numbers of nodes and to handle continual node arrivals, departures, and failures.

A DHT uses a Routing Protocol to determine which node(s) a data should be stored on. This routing protocol usually takes care of replicating data and also updating data stores to make sure that the data survives on the DHT for the long term. Some popular routing protocols are Kademlia, Chord and Pastry

275 questions
190
votes
4 answers

Simple basic explanation of a Distributed Hash Table (DHT)

Could any one give an explanation on how a DHT works? Nothing too heavy, just the basics.
Gustavo Carreno
  • 9,499
  • 13
  • 45
  • 76
111
votes
4 answers

DHT in torrents

I'm coding a P2P implementation that I would like to make decentralized. However I'm having some trouble grasping how DHT in protocols like BitTorrent works. How does the client know where the peers are if there is no tracker? Are peers stored in…
Christopher Tarquini
  • 11,176
  • 16
  • 55
  • 73
90
votes
8 answers

How does a DHT in a Bittorent client get "bootstrapped"?

If I have a torrent w/o any trackers in it, and I just started a bittorent client so I have no peers yet...how do I know who to first connect with in the DHT? It seems like I would have to know at least ONE node in the DHT to get started....
puffpio
  • 3,402
  • 6
  • 36
  • 41
32
votes
1 answer

How NAT traversal works in case of peer to peer protocols like bittorrent.

I know about NAT traversal and about STUN, TURN and ICE and its use. I want to know whether these are implemented in peer to peer file sharing application like bittorrent. Whether trackers facilitate peers behind NATs to communicate with each other…
user1887464
  • 533
  • 2
  • 6
  • 11
30
votes
1 answer

How to get the first peer from a torrent-magnet link?

I've been trying to understand the torrent-magnet technology, but I can't seem to figure out how you get connected to the first peer when opening a magnet link. When you get a magnet link like below, it contains no initial peer - only the BitTorrent…
kba
  • 19,333
  • 5
  • 62
  • 89
27
votes
2 answers

What's the difference between distributed hashtable technology and the bitcoin blockchain?

This question could go into a bitcoin forum but I am trying to understand from a programming point of view. There are technologies used for distributed storage, like distributed hashtables (say kademlia or similar). How is the bitcoin blockchain…
transient_loop
  • 5,984
  • 15
  • 58
  • 117
25
votes
7 answers

java distributed cache for low latency, high availability

I've never used distributed caches/DHTs like memcached, jboss cache, ehcache, etc. I'm wondering which, if any, is appropriate for my use. First, I'm not doing web applications (as most of these project seem to be geared towards web apps). I write…
Shahbaz
  • 10,395
  • 21
  • 54
  • 83
22
votes
1 answer

How PEX protocol (Magnetic links) finds it first IP?

I'm trying to understand how can a magnetic link work, as I've read they use DHT and PEX to get the peers, but if I'm a new node in the network how can I find peers with only the hash of the file?! Doesn't it always require a link to a known…
Marco Martins
  • 359
  • 1
  • 5
  • 15
18
votes
1 answer

Operations on Python hashes

I've got a rather strange problem. For a Distributed Hash Table I need to be able to do some simple math operations on MD5 hashes. These include a sum (numeric sum represented by the hash) and a modulo operation. Now I'm wondering what the best way…
cdecker
  • 4,515
  • 8
  • 46
  • 75
18
votes
4 answers

The easiest DHT to implement

Which Distributed Hash Table (DHT) is easiest to implement in Python? Any good example that is not bloated? I not am looking for a definition of DHT because I am more oriented and focused on design and implementation of such.
mtasic85
  • 3,905
  • 2
  • 19
  • 28
17
votes
4 answers

How does "DHT search engine" work?

I'm interested in the Btdigg.org which is called a "DHT search engine". According to this article, it doesn't store any content and even has no database. Then how does it work? Doesn't it need to gather meta infos and store them in database like…
user2025043
  • 171
  • 1
  • 1
  • 3
15
votes
5 answers

Distributed Storage of BLOBs for .NET?

I am looking for a reasonably well tested library+server to store a persistent distributed hash table. I am hesistant to use SQL-based solutions as the data is highly document oriented, consisting of millions of ~64KB blobs with only a single index…
Adam Frisby
  • 358
  • 5
  • 20
13
votes
5 answers

Simple open source DHT implementation in Java for learning purposes

I'm looking for recommendations for a simple open source implementation of a Distributed Hash Table in Java to play around with. No fancy features, just for learning purposes, no production functionality needed. It should be simple to set up (e.g. 1…
danirod
  • 1,011
  • 3
  • 9
  • 18
13
votes
1 answer

How Distributed Hash Table in IPFS and Bittorrent prevent abuse?

My understanding is that IPFS and Bittorrent Mainline DHT are built on top of a Distributed hash Table (Kademlia). They use the file hash as Kademlia key to find a list of peer that might have this file. 1- What I don't understand is if this is all…
skyde
  • 2,816
  • 4
  • 34
  • 53
12
votes
1 answer

How the DHT protocol works ? Are my thoughts correct?

Im trying to understand how the DHT protocol works, specially on the file-sharing-torrent world. I read many articles, but im still confused with the filename-value hash generation. My thoughs how the dht works are the following: Lets say im joining…
user711189
  • 4,383
  • 4
  • 30
  • 48
1
2 3
18 19