L2 Switching Principle

Source: Internet
Author: User

L2 switching principle:
1. receive all data frames in the network segment;
2. Use the source MAC address of the received data frame to create a MAC Address Table (Source Address self-learning), and use the update and aging mechanism to maintain the address table;
3. search for the destination address in the data frame in the MAC address table. If yes, send the data to the corresponding port (excluding the source port). If no destination address is found, send data to all ports (excluding the source port;
4. forward broadcast messages and group broadcasts to all ports (excluding source ports.
Features of L2 switches:
Supports MAC forwarding and vlan division.
L2 switches that support VLANs:
Role: Divide broadcast domains to suppress broadcast storms;
Vlan: Virtual LAN, which logically divides a group of users and servers located in different physical network segments into end station groups. VLANs are completely isolated, just like two switches that are not connected to each other, however, any layer-2 traffic will be forwarded to other VLANs across vlan restrictions, and the VLANs are interconnected through the truck port.
L2 switches are located at the data link layer of the OSI model.
Easy to understand:
If a PC in a LAN needs to access a website, the first network device that sends a data frame is a layer-2 switch or HUB. The layer-2 switch checks whether the mac address accessed by the data frame is in the LAN, if the IP address is located, the IP address is directly sent to the destination address. If the IP address is not located, the device at the higher layer (Network Layer) of the network sends the IP address to the destination IP address, search for target IP Address

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.