A peer-to-peer (P2P) network is a series of interconnected devices sharing information and storing a single data set. Each member of the P2P network acts as a separate node. Usually, all nodes perform the same tasks and provide the same computing power to the network.

Peer-to-peer technology emerged in 1984 during IBM’s development of the Advanced Peer-to-Peer Networking (APPN) networking architecture for data routing. P2P networks started being used more widely in the 1990s, along with the spread of Internet access and the emergence of software for decentralized file sharing. Over time, peer-to-peer architecture began to be used in such areas as: 

  • data exchange; 
  • information search;
  • online commerce;
  • streaming;  
  • distributed computing, etc.

Peer-to-peer networks became one of the key technologies in developing blockchain projects as they decentralized them. 

How It Works

P2P Networks: What Are They?

The peer-to-peer network works like this:

  • there is a certain number of computers between which a network connection is provided;
  • each network participant has an exact copy of the database;
  • each device simultaneously acts as a server and a client, that is, it sends and processes requests;
  • any changes in the network are mutually processed.

The process of exchanging and updating information in the database is continuous and uninterrupted, as each node must respond to any network change. Unlike a centralized system, the peer-to-peer network has no single point of failure. 

Peer-to-Peer Networks and Cryptocurrencies

P2P Networks: What Are They?

The impact of P2P architecture on cryptocurrencies is obvious. Just look at the title of the white paper in which Satoshi Nakamoto initially described the first cryptocurrency: “Bitcoin: A Peer-to-Peer Electronic Cash System.” Cryptocurrency uses a distributed ledger — a blockchain operating on the peer-to-peer network principle. 

All nodes of the blockchain network are directly connected to each other, however, in the blockchain, network participants can perform various functions. For example, full nodes provide storage and updating of the entire blockchain network’s data set, while miners generate new data blocks.

Classification of Peer-to-Peer Networks

P2P Networks: What Are They?

There are three basic types of P2P networks: 

  1. Unstructured. This architecture involves no clear interaction pattern between nodes in the network; participants communicate with each other randomly. This type of network organization is stable when its members change constantly. 
  2. Structured. This type has a distinct pattern of relations between nodes, which allows for data to be exchanged more effectively. 
  3. Hybrid. This structure combines some elements of the previous two types, providing a fairly high level of performance, stability, and decentralization.

Pros and Cons of Peer-to-Peer Networks

P2P Networks: What Are They?

The main advantages of P2P networks, achieved by distributing data among all participants in the network, are:

  • decentralization; 
  • high performance thanks to resource separation;
  • resistance to DDoS attacks, failures, malfunctions within the network, and restrictions from government agencies.

The key disadvantages of P2P networks include the following:

  • inconvenient administration; 
  • the need to keep a backup copy of the entire network on each node and constantly update and check its relevance;
  • the lack of opportunities for centralized information searches and data access control.

It’s important to note that many blockchain networks share some of the characteristics of P2P networks, but these two concepts aren’t synonymous. Peer-to-peer networks are most commonly used in distributed file sharing. You’ve probably heard of BitTorrent, a network protocol for cooperative file sharing, which is organized as a peer-to-peer network. 

The most promising area where P2P networks are being used, outside of the cryptocurrency market, is currently distributed computing protocols. The most famous practical example is the program of distributed computing of protein molecular dynamics, a joint project of Sony and Pande Lab of Stanford University. The calculations were performed on PlayStation 3 consoles, and the network of 30,000 devices was 10% more productive than the most powerful supercomputer of the time. 

Author: Evgeny Zatsepin