Computer networks are made up of software and hardware components that allow one device to communicate with another.
Hardware provides the set of commands that use the network device to transmit data, while software specifies the sequence of commands (communication protocol) that uses the hardware device to transmit data.
The basic data transmission process is made up of multiple stages that take place at different layers of a computer network. The most established communication stack is the OSI 7-layer model.
Communication networks can also be classified into two broad models:
- Peer to Peer network model
- Client-Server network model (Client-Server)
In this article, we will look at Peer-to-Peer and Client-Server based network models to learn how data is transmitted and received at computers, and compare and discuss the two types. above network communication.
Define peer-to-peer model (Peer to Peer)
A P2P (peer-to-peer) network is a set of decentralized computers that have been established to exchange information (such as file documents, songs, movies, software, etc.) with everyone or just a few people. certain users.
In a p2p network, all computers on the network are considered equal, with each workstation providing access to resources and data.
This means that each node in the p2p network model can request services from other peers or provide services to other peers. Each node can be both a client and a server.
Peer-to-Peer can be huge networks in which computers can interact with each other and share what is on or linked to their machines with others.
It is also one of the simplest architectures to build if you have the right software on each node.
Definition of the Client-Server Model (Client-Server)
The client-server model architecture is a centralized network in which the server stores, delivers, and maintains the majority of client data and services.
In this network model, there must be a central server and all clients (computers) are connected to the central server to obtain data or use its services.
The diagram above shows a server connected to a network (shown as the Internet above but could be any other type of network) with various clients.
The server acts as a midpoint of the network. The server waits for the request from the client to render before responding.
Compare Peer-to-Peer and Client Server
For example, about client-server architecture (Client Server)
Client-server networks are suitable for larger networks, especially if they are expected to grow in size.
If your network contains sensitive data, you should also use a client-server architecture.
When you use a web browser to access a particular website, the browser (client) sends a request to the web server that is processing the website’s content.
The server then responds to the request and sends the data and cookies back to the browser, which displays that data according to the configuration.
Same goes for database servers. The client sends a request/query to the server, which checks the legitimacy of the request. If everything checks out, the server sends the data back to the client.
The server used in the Internet mail system is a form of distributed client-server.
Clients send and receive messages through communication with the server, while servers communicate with each other.
Outgoing mail can be sent directly to the server (MTA), which delivers it to the recipient’s inbox, or to another MTA, which delivers it.
By organizing servers in a layer, the system is designed to be extremely scalable. Another example of a distributed client-server is a DNS network that contains root servers and other second-level servers in the hierarchy.
For example: about the peer-to-peer (p2p) model
1999, when Napster launched, was a pivotal moment in the history of P2P. People used Napster to exchange and download music through file sharing programs.
Most of the music exchanged on Napster is not copyrighted, so its distribution is illegal. However, that doesn’t stop many people from getting it.
Peer-to-peer technology has faced a lot of backlash for its use in illegal file sharing (torrenting).
Another example is Windows 10 updates. Microsoft and P2P servers are both used to deliver Windows 10 upgrades.
Some online gaming platforms use peer-to-peer (P2P) technology to allow players to download games.
Due to the peer-to-peer structure of blockchain, all cryptocurrencies can be exchanged globally without the need for intermediaries, intermediaries, or central storage (servers).
Anyone who wants to participate in the process of validating and verifying blocks can set up a Bitcoin node on the decentralized peer-to-peer network.
In this process, the database is maintained by every member of the network, unlike banks where all the databases are handled by a centralized server.
Advantages and disadvantages of the peer-to-peer model (Peer to Peer)
Advantages and disadvantages of the Client-Server Model (Client-Server)
Good luck!
Xem tiếp...