Peer-to-peer (P2P) is a decentralized communications model in which each party has the same capabilities and either party can initiate a communication session. Unlike the client/server model, in which the client makes a service request and the server fulfills the request, the P2P network model allows each node to function as both a client and server.
P2P systems can be used to provide anonymized routing of network traffic, massive parallel computing environments, distributed storage and other functions. Most P2P programs are focused on media sharing and P2P is therefore often associated with software piracy and copyright violation.
Typically, peer-to-peer applications allow users to control many parameters of operation: how many member connections to seek or allow at one time; whose systems to connect to or avoid; what services to offer; and how many system resources to devote to the network. Some simply connect to some subset of active nodes in the network with little user control, however.
Although uses for the P2P networking topologies have been explored since the days of ARPANET, the advantages of the P2P communications model didn't become obvious to the general public until the late 1990s, when music-sharing P2P applications like Napster appeared. Napster and its successors, including Gnutella and BitTorrent, cut into music and movie industry profits and changed how people thought about acquiring and consuming media.
system administrators tend to discourage the use of P2P applications. In addition to tying up bandwidth and possibly exposing the administrator's organization legally, P2P applications can be used to bypass firewalls and distribute malware. Networks are often set up to prevent peer-to-peer “side talk” by PCs.
How peer-to-peer networks work
Typically, when a user downloads a file, the user opens a web browser, visits the appropriate website and downloads the file. In this case, the website acts as a server and the user’s computer acts as a client that receives the data. This can be compared to a one-way street where the downloaded file is transferred from point A, the website, to point B, the user’s computer.
However, if the user downloads the same file through a peer-to-peer network, the download is handled differently. In this case, the user has to install peer-to-peer software on his computer, which creates a virtual network of peer-to-peer application users. Then when the user downloads a file, it is received in bits that come from various computers in the network that already have that file.
Simultaneously, the data is also sent from the user’s computer to the computers that ask for it. This situation is similar to a two-way street – the file is like numerous small bits of data that come to the user’s computer but also leave when requested. In fact, the file transfer load is distributed between the peer computers.
Architecture of P2P
In a peer-to-peer network architecture, each computer has the same responsibilities and capabilities. Since there is no server, the computers connect with each other in a workgroup to share files, printers and access to the Internet. This architecture is practical for workgroups of 12 or fewer computers. As such, it is common in small home or office environments where each PC acts as an independent workstation, storing data on its own hard drive but with the ability to share the data with all the other PCs on the network.
Advantages and disadvantages of P2P
There are a number of advantages as well as disadvantages to peer-to-peer networks.
- No need to buy an expensive server.
- Each user manages his or her own computer, which means there is no need for a network manager.
- Users do not have to have any technical knowledge as the setup is done via wizards in the software.
- A P2P network can be can be set up in homes and small businesses. However, each computer has to be maintained individually.
- Less network traffic than a client/server network.
- Users cannot centrally back up the files and folders.
- Each computer can be accessed by the other computers, which slows down the performance for the user.
- The files are not centrally organized into a specific shared area. Rather, they’re stored on individual computers. Consequently, it might be hard to locate the files, if whoever owns the computer doesn't have a logical filing system.
- Each individual user is responsible for ensuring that viruses aren’t introduced into the network.
- There is little to no security other than the permissions.
Peer to peer vs. client/server
A peer-to-peer network involves two or more computers that share individual resources, including DVD players, printers and disk drives. Each computer in the network acts as the client as well as the server, communicating with the other computers directly. On a peer-to-peer network, a printer on one computer can be used by any of the other computers on the network. All that’s necessary is a way to connect them, such as a Wi-Fi router.
A client/server network involves numerous clients that connect to at least one central server where most applications and data are installed. Clients access these resources from the server. Client/server networks typically have faster access speeds because of the large number of clients they’re designed to support.
The clients can function as workstations without sharing resources. Upgrading applications and files is easier because they are only installed on a single computer. In a client/server network, security is handled by the server, not by each individual user.
History of P2P
The very first use of P2P networks occurred shortly after personal computers were introduced in the 1980s. The Internet Relay Chat, developed in August 1988, was one of the first peer-to-peer networks built for sharing text and chatting.
On June 1, 1999, Napster enabled music sharing on its own centralized P2P network. Napster – and other first-generation P2P networks – allowed an individual to connect directly across the network to another person who was using a copy of the same program.
Established in 2000, Gnutella was first decentralized P2P file sharing network. It allowed users to access files on other users’ computers via a designated folder. Over the next few years, additional P2P media file sharing services were developed. This set the stage for other P2P networks, including the Bitcoin network, which was released on January 3, 2009.