The topological structure of LAN
The main features of LAN are: The network is owned by a unit, and the geographical range and the number of sites are limited.
LAN has broadcast function, from a site can easily access the entire network, the host on the local area network can share a variety of hardware and software resources connected to the LAN.
The local area network can be divided into bus structure, ring type structure, star structure, net structure, tree structure and mixed structure according to the topological structure.
Ethernet
Ethernet was originally developed by the American Xerox company based on the baseband bus LAN, with the history of the transmission of electromagnetic waves in the ether (ether) to name.
DIX Ethernet V2 is the world's first LAN product (Ethernet) protocol, on this basis, the IEEE developed 802.3 standard, DIX Ethernet V2 Standard and IEEE 802.3 standard only very small difference, Therefore, the 802.3 LAN can be referred to as "Ethernet".
In order to better adapt the data link layer to a variety of LAN standards, the 802 committee has split the data link layer of the LAN into two sub-tiers:
Logical Link Control LLC (Logical Link Control) sub-layer
media access Control MAC (Medium Access Control) child layer.
Content related to access to the transport media is placed on the Mac Sublayer, while the LLC Sublayer is independent of the transport media, regardless of which protocol the LAN is transparent to the LLC sublayer
Ethernet in the LAN market has achieved a monopoly position, and almost become synonymous with local area network, because the Internet has developed rapidly and TCP/IP system is often used in the LAN only dix Ethernet V2 instead of the IEEE 802.3 standard LAN, As a result, the role of the logical link Control Sub-Layer LLC developed by the 802 committee has disappeared, and many manufacturers have installed only MAC protocols on the Adapters and no LLC protocol.
The connection of the computer to the external LAN is through the adapter . The adapter is equipped with a processor and memory, and the communication between the adapter and the LAN is carried out serially via a cable or twisted pair, while the communication between the adapter and the computer is carried out in parallel via the I/O bus on the motherboard of the computer. Therefore, an important function of the adapter is to perform data serial transmission and parallel transfer conversion .
The adapter accepts and sends various frames without using the computer's CPU. When the adapter receives the correct frame, it uses an interrupt to notify the computer and delivers it to the network layer in the protocol stack, and when the computer sends an IP datagram, the IP datagram is forwarded down to the adapter by the protocol stack, assembled into a frame and sent to the local area network.
It is important to note that the hardware address of the computer is in the Rom of the adapter, while the computer's IP address is in the computer's memory.
CSMA/CD protocol
For the convenience of communication, Ethernet has taken the following two measures:
First, a non-connected way of working, that is, you do not have to establish a connection before you can send data directly. As a result, the services provided by Ethernet are unreliable deliveries, but are delivered with the utmost effort.
Second, the data sent by Ethernet is a coded signal from Manchester.
We know that, as long as there is a computer on the bus to send data, the bus transmission resources are occupied, so at the same time can only allow one computer to send information, or the computer will interfere with each other, the result is that everyone can not send data.
The coordinated approach used by Ethernet is to use a special protocol CSMA/CD, the carrier-monitored multipoint access/collision detection (carriersense Multiple Access with Collision Detection).
" Multi-point access " means that this is a total Linetype network, many computers connected to a bus in a multi-point way, the essence of the protocol is "carrier monitoring" and "collision detection."
" Carrier monitoring " is "listen before sending", that is, each station before sending data to detect whether there are other stations on the bus to send data, if there is, you have to wait until the channel is free to send again.
" Collision Detection " is the "side of the transmission edge monitoring", that is, the adapter side to send data edge detection channel signal voltage changes, so as to determine whether the other stations in the sending data is also sending data. Once a collision occurs, the adapter will immediately stop sending.
Obviously, when using the CSMA/CD protocol, a station cannot send and receive at the same time, so Ethernet using the CSMA/CD protocol is not possible for full-duplex communication and only half-duplex communication .
MAC address
In a local area network, the hardware address is also called the physical address, or the MAC address.
The IEEE 802 standard specifies a 48-bit global address for the LAN, which is the address in each computer on the LAN that is cured in the adapter's ROM .
The IEEE registry RA is responsible for assigning the first three bytes of the Address field (that is, the high 24 bits) to the manufacturer. The latter three bytes in the Address field (that is, the low 24 bits) are assigned by the manufacturer, called an extension identifier, and must be guaranteed to have no duplicate addresses for the produced adapter.
The adapter has the filter function, the adapter from the network every received a Mac frame first with the hardware to check the destination address in the Mac frame, if the frame is sent to the site to accept, otherwise discarded. The frames sent to this site include the following three types of frames:
(1) unicast frame, that is, the MAC address of the received frame is the same as the hardware address of the site.
(2) A broadcast frame, which is a frame sent to all sites on the local area network.
(3) A multicast frame, which is a frame sent to a portion of the site on the local area network.
Ethernet is most commonly used in Ethernet V2 format for Mac frames, in the following format:
Consists of five fields. The first two fields are the destination address and the source address. The third field is the Type field, which identifies what protocol was used on the previous layer in order to give the received Mac frame data to the previous layer of this Protocol. The fourth field is the data field, and the last one is the frame test sequence FCS (using the CRC test).
Expansion hubs for LAN
Use the hub to extend the LAN at the physical layer
Advantages
Enables computers on a local area network that originally belonged to different collision domains to communicate across collision domains.
Expanded the geographic scope of LAN coverage.
Disadvantages
The collision domain increased, but the total throughput did not increase.
If different collision domains use different data rates, you cannot use hubs to interconnect them.
Network Bridge
The network Bridge is used to extend the LAN at the Data link layer .
The bridge works at the data link layer, which forwards the received frames based on the destination address of the MAC frame.
The bridge has the function of filtering frames. When a bridge receives a frame, it does not forward the frame to all the interfaces, but instead checks the destination MAC address of the frame before determining which interface the frame is forwarded to.
Advantages
Filter traffic.
Expanded the physical range.
Improved reliability.
LANs that interconnect different physical layers, different MAC sub-tiers, and different rates (such as 10mb/s and S/MB Ethernet)
Disadvantages
Storage forwarding increases latency.
There is no traffic control function on the MAC sub-layer.
Network segments with different MAC sub-layers are bridged together and are extended more often.
Bridges are only suitable for local area networks where the number of users is not too high (no more than hundreds of) and traffic is not very large, otherwise there is sometimes a network congestion due to the propagation of too much broadcast information. This is called a broadcast storm .
Switch
An Ethernet switch typically has more than 10 interfaces. Therefore, the Ethernet switch is essentially a multi-interface bridge , and the visible switch works at the data link layer.
For shared Ethernet with a total of ten MB/s, if there are N users, the average bandwidth occupied by each user is only one of the total bandwidth (ten MB/s) of N.
When using an Ethernet switch, the total capacity for a switch with N-to-interface is n?10 MB/s, although the bandwidth per interface to the host is still ten MB/s, because one user is exclusive instead of sharing the bandwidth of the transport media with other network users while communicating. This is the biggest benefit of the switch.
It is easy to realize virtual local area network with Ethernet switch, and virtual LAN VLAN is a logical group composed of some local area network segments that is independent of the physical location. Each VLAN frame has an explicit identifier indicating which VLAN the workstation that sent the frame belongs to.
Virtual local Area network is only a kind of service provided by LAN to users, not a new type of local area network.
Copyright NOTICE: This article for Bo Master original article, without Bo Master permission not reproduced.