Data Link Layer Addresses

The two types of addresses are data link layer and network layer addresses. Data link layer addresses—also known as Media Access Control (MAC) addresses and physical layer addresses—are unique to every device. In a local-area network (LAN), for instance, each device has a MAC address which identifies itself on the LAN. This enables computers to know who is sending what message. If you look at an Ethernet frame, the first 12 bytes are the destination and source MAC addresses.

If you use an Ethernet LAN switch, the traffic is routed through the switch based on the data link layer address (the MAC address). If you use a repeater or hub to connect the devices to the LAN, the packet is forwarded to all ports, regardless of the MAC address. This is because forwarding through a hub is based upon the physical layer and not the data link layer.

When traffic is routed based on the MAC layer address, it is generally referred to as being switched or bridged. Before routing became prominent in the late 1980s, many companies developed bridges to connect two disparate networks. This enabled a simple and inexpensive method of connecting two networks at the data link layer. Because these bridges did not look at the network layer address, however, unwanted traffic such as broadcasts and multicasts could be transmitted across the bridge, which consumed a large amount of bandwidth.

Most LANs in the 1980s and early 1990s used a hub to connect their Ethernet workstations. This device was known as a repeater and replicated the Layer 1 information only. So, if a corporation had an eight-port hub and one of the eight ports received a packet, the packet would be repeated (exactly, errors and all) to the other seven ports.

In the early 1990s, companies began developing LAN switches, which were basically a combination of a hub and bridge. In this scenario, the LAN switch learned which Layer 2 addresses were attached to each of its physical interfaces and forwarded traffic based on the Layer 2 address. If the switch did not have a list of a particular destination Layer 2 address in its switching table, or if the packet were a broadcast packet, the packet was repeated to all other interfaces on the switch.

This transition to network switches enabled networks to make better use of the available bandwidth. This saving in bandwidth was accomplished by preventing unnecessary IP packets from being transmitted on a physical port where the receiving device did not reside.

Now that you understand MAC addresses and how networks use them to route packets, it is time to discuss how networks use IP addressing to further route those packets.

0 0

Post a comment