


How to realize one-to-one communication in LAN
We know that LAN uses broadcast channels for transmission, and broadcast channels can achieve one-to-many communication. But in reality, one-to-many communication is not always required, so how to perform one-to-one communication between two hosts? This problem is not that simple. We need to consider multiple aspects:
How the host transmits the generated information to the channel
Multiple hosts share the channel, so how to prevent collisions between messages
How to send messages to a specific host
The role of the network adapter (network card)
The network adapter is what we usually call the network card. When the host communicates with the external LAN, it is adapted through the network card. Because the host and network card use parallel transmission, while the network card and LAN home use serial transmission, the network card needs to adapt between the two.
In the ROM (read-only memory) of the network card, write the computer’s hardware address, that is, the MAC address. This MAC address is very important, it is the key to achieving one-to-one communication. We will talk about it later.
CSMA/CD protocol
Because the LAN uses a shared channel, since it is a shared channel, we need to control the first and second sending of the host. A later problem. Because if multiple hosts send information at the same time, confusion will occur. There is a well-known LAN protocol CSMA/CD (Carrier Sense Multiple Access/Collision Detection) that solves this problem.
The protocol is very easy to understand. Let's use an example to illustrate: In a venue, there are some people attending the meeting. There is no moderator at the meeting and everyone can speak freely. However, you can only speak after others have finished speaking and the venue is quiet. If multiple people are speaking at the same time, everyone who speaks at the same time will finish speaking, and then wait for a random time before speaking again if the venue is quiet. It is easy to understand why it is a random time here. If it is a fixed time, people who speak at the same time will still speak at the same time after a while.
One-to-one communication through MAC address
After solving the above problem, let’s look at how one-to-one communication is performed between hosts. As mentioned above, there is a MAC address on the network card. The following is a MAC address
A0-A4-C2-4B-9F-56
It is composed of 48 bits ( 6 bytes), the MAC address of each network card is globally unique. Since it is unique, it can be used for one-to-one communication between hosts.
The basic unit of communication in the local area network is the data frame. When host A in the LAN wants to communicate with another host B in the same LAN, the destination address (B's MAC address) must be written in the header of the data frame sent by A, and then the data frame will be broadcast to the LAN. All hosts, when the network cards of other hosts accept this data frame, check whether its destination address is consistent with its own MAC address, and discard it if it is inconsistent. In this way, a LAN with broadcast characteristics realizes one-to-one communication.
The above is the detailed content of How to realize one-to-one communication in LAN. For more information, please follow other related articles on the PHP Chinese website!

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

Video Face Swap
Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Article

Hot Tools

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver CS6
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Hot Topics

What should I do if win11 cannot connect to the LAN printer? Many users' win11 systems cannot connect to the shared printer normally when using the LAN printer function. This problem may occur because the connection steps or a certain functional service are not turned on. Today, the editor has brought you a variety of solutions. Many friends do not know how to operate in detail. The editor below has compiled tips for solving the problem of Win11 computers not being able to connect to shared printers. If you are interested, follow the editor to read below. Look! Tips for solving the problem that win11 computer cannot connect to a shared printer 1. First, press the Win+X key combination on the keyboard, or right-click the Windows start icon on the taskbar, and select Run from the hidden menu item that opens; 2. Run window

How to view all IP addresses on the LAN using cmd: 1. Press the "Win+R" shortcut key to open the "Run" window; 2. After entering "CMD" in the "Run" window, press the Enter key; 3. In the open "Command" In the "Prompt" interface, enter the command "arp -a" and press the Enter key; 4. From the returned results, you can see the IP addresses of all computers in the local LAN that communicate with the machine.

People who configure routers often use the default IP address of the router as the gateway. Changing it to another IP address is both confusing and troublesome. Don’t believe it yet, people who often do network maintenance set IP addresses, and input “192.168” very smoothly. But this is not the root cause.

EasyTier is an open source, free, decentralized intranet penetration remote networking tool. It is an easy-to-use and feature-rich remote networking solution, suitable for remote office collaboration, game connection and other scenarios. The following is a brief introduction to how to use EasyTier remote networking. Download the easytier-gui program and install it. Download address: https://github.com/EasyTier/EasyTier Just set it up as shown above on the computer that needs to be networked. Virtual IPv4 address: required. For example, computer A is 10.10.10.1, B is 10.10.10.2, and C is 10.10.10.3. It cannot be repeated. (Such IP segments are available: 10.

How to solve the problem that other computers in the LAN cannot be found in the Win11 network? The method is very simple. Users can go to Change Advanced Sharing Settings under Network and Internet Settings under the Control Panel, and then select Start Network Discovery to perform the operation. Let this site carefully introduce to users the solution to the problem that other computers on the LAN cannot be found in the Win11 network. Solution to the problem that other computers on the LAN cannot be found in the Win11 network 1. First, we open the control panel. 2. Then enter the network and internet settings. 3. Then open the Network and Sharing Center. 6. There is also a check mark in the guest options below to enable network discovery. It should be noted that both sides of the LAN must be turned on. If one side

Many users share files with other computers through the LAN, but some Windows 10 users report that they cannot see other computers in the LAN. What should they do? You first open the advanced sharing settings and select "Enable network discovery" and "Turn on file and printer sharing." Later, open the service panel, find the Server service item, and right-click to start it. Then open the Programs and Functions panel, choose to turn on or off Windows features, and check "SMB1.0/CIFS shared file support". What to do if you can't see other computers in Windows 10 LAN: 1. First, right-click the "This PC" logo and select the "Properties" menu item in the pop-up menu; 2. Then, in the opened Network and Sharing Center window,

lan is the abbreviation of "Local Area Network", which means local area network; the coverage area of a local area network is generally within a few kilometers, and can realize file management, application software sharing, printer sharing and other functions. During use, by maintaining the local area network Network security can effectively protect data security and ensure the normal and stable operation of the local area network.

Reasons for using an intranet: 1. Resource sharing, which can provide convenient sharing of software and hardware resources, especially in the direction of hardware resources. Office automation equipment such as printers and scanners are fully utilized. 2. Facilitate teamwork. Most modern LANs provide a platform that allows multiple users to work on the same file and always use the latest version. 3. It is easy to find information, and the intranet can be used as a place to place all trusted information. 4. Reduce management costs. With the help of the intranet, online forms can be easily provided, streamlining the work process from the beginning, and greatly improving work efficiency.
