Local Networking 101: A Closer Look at Data Link Layer Devices

Local Networking 101: A Closer Look at Data Link Layer Devices

Local area networks (LANs) connect computers, servers, printers, cameras, wireless access points, and other devices so they can exchange information. Behind this everyday communication is the data link layer, which defines how devices communicate across a shared physical or wireless network connection.

Understanding the data link layer helps network administrators select the right Ethernet switches, network interface cards, and wireless access points, as well as troubleshoot connectivity problems. It also explains why proper switching, network segmentation, and link configuration are important for building reliable business networks.


Local-Networking-101


Understanding the Data Link Layer

The data link layer is Layer 2 of the seven-layer Open Systems Interconnection (OSI) model. It provides communication between devices on the same local network link by organizing data into frames and using link-layer addressing and error detection.

When an application sends information over a network, that information passes through several networking layers. At the data link layer, data from the network layer is encapsulated into frames suitable for transmission across a particular network link.

Key responsibilities of the data link layer include:

  • Framing: Organizing data into frames with headers and, depending on the protocol, trailers that carry addressing and control information.
  • MAC addressing: Using Media Access Control (MAC) addresses to identify network interfaces and support local frame delivery.
  • Error detection: Detecting transmission errors through mechanisms such as the Frame Check Sequence (FCS), which uses a cyclic redundancy check (CRC).
  • Media access: Defining how devices access a shared communication medium, particularly in wireless networks and older shared-media Ethernet technologies.
  • Link control: Supporting link-specific communication functions, depending on the networking technology in use.

An important distinction is that the data link layer does not perform all the functions required for end-to-end reliable communication. Ethernet's CRC can detect many frame errors, but Ethernet generally discards corrupted frames rather than correcting them. Higher-layer protocols, such as TCP, may handle retransmission when necessary.

The Data Link Layer in the OSI Model

The OSI model divides networking functions into seven layers. Each layer serves a different purpose, from transmitting electrical or optical signals to supporting applications.

OSI layer Primary responsibility Example
Layer 7 — Application Provides network services to applications HTTP, DNS
Layer 6 — Presentation Data representation, encoding, and encryption functions Data formatting and encryption
Layer 5 — Session Establishes and manages logical communication sessions Session management
Layer 4 — Transport End-to-end transport and, for TCP, reliable delivery TCP, UDP
Layer 3 — Network Logical addressing and routing between networks IP routers
Layer 2 — Data Link Frames, MAC addressing, and local link communication Ethernet switches, network interfaces
Layer 1 — Physical Transmits signals over copper, fiber, or radio Cables, fiber, radio signals


These layers work together, but the OSI model is a conceptual framework rather than a strict description of how every modern protocol is implemented.

For example, a computer may send an IP packet to another device on the same LAN. The packet is encapsulated in an Ethernet frame containing the appropriate source and destination MAC addresses. A switch uses the destination MAC address to determine where to forward that frame.

If the destination is on a different IP network, the computer typically sends the frame to its configured default gateway. A router then forwards the IP packet toward the destination network.

This distinction between local frame forwarding and network-layer routing is fundamental to understanding how switches and routers work together.

Common Data Link Layer Devices

Several network devices perform Layer 2 functions. Their capabilities vary depending on their design, configuration, and supported protocols.

1. Ethernet switches

Ethernet switches connect devices in a wired LAN and forward Ethernet frames based on their destination MAC addresses. Most modern Ethernet switches operate primarily at Layer 2, although Layer 3 switches can also route IP traffic between networks.

Switches learn which MAC addresses are reachable through their ports and use that information to forward frames efficiently. They are widely used in business networks, industrial facilities, surveillance systems, data centers, and other environments that require reliable wired connectivity.

Explore Versitron's Ethernet network switches for options used in a variety of network applications.

2. Network interface cards (NICs)

A network interface card connects a computer, server, printer, camera, or other device to a network. NICs may provide Ethernet connectivity over copper or fiber, or wireless connectivity through a compatible interface.

An Ethernet NIC participates in Layer 2 communication by transmitting and receiving Ethernet frames and using a MAC address. Although MAC addresses are commonly assigned by manufacturers, some interfaces support configurable or software-overridden addresses.

NICs also work with the physical layer to transmit and receive signals using the appropriate medium and link technology.

3. Bridges

A network bridge connects Layer 2 network segments and forwards frames between them based on MAC addresses. Bridges can reduce unnecessary traffic between segments by filtering frames that do not need to cross the bridge.

Modern Ethernet switches essentially provide multiport bridging functionality, which is why standalone bridges are less common in contemporary networks.

Bridges do not inherently connect different IP subnets. Communication between separate IP networks generally requires a router or a Layer 3 switching function.

4. Wireless access points

A wireless access point (WAP) allows Wi-Fi devices to connect to a network. It manages wireless communication and bridges traffic between wireless clients and the wired LAN.

Access points also support wireless security features, such as WPA2 or WPA3, depending on the equipment and configuration. These security mechanisms protect wireless communications, while VLANs, authentication policies, and other network controls can help limit access to network resources.

Although an access point may perform additional functions, its bridging role is closely associated with the data link layer.

Ethernet Switches: The Backbone of Local Networks

Ethernet switches are among the most important devices in modern LANs. They connect multiple wired devices and help control how local traffic moves through a network.

Understanding the following switching functions makes it easier to choose and configure equipment for a particular application.

MAC address learning and forwarding

When a switch receives an Ethernet frame, it examines the source MAC address and learns which port the address is associated with. The switch stores this information in a MAC address table, also called a forwarding database.

When another frame arrives, the switch examines the destination MAC address:

  • If the destination is known, the switch normally forwards the frame through the associated port.
  • If the destination is unknown, the switch generally floods the frame to eligible ports within the same VLAN, except the port on which it arrived.
  • If the destination is the broadcast MAC address, the switch forwards the frame to eligible ports in the same VLAN, excluding the incoming port.

Multicast traffic may be flooded or selectively forwarded depending on the switch's configuration and features, such as Internet Group Management Protocol (IGMP) snooping.

These forwarding decisions help reduce unnecessary traffic compared with a traditional hub, which repeats incoming signals to its other ports without using a MAC address table.

Collision domains and full-duplex Ethernet

Each switch port creates a separate collision domain in the traditional Ethernet sense. However, modern switched Ethernet links generally operate in full-duplex mode, allowing devices to transmit and receive simultaneously without Ethernet collisions.

This differs from older shared-media Ethernet networks, where multiple devices competed to use the same communication medium and collisions could occur.

In a modern full-duplex switched network, troubleshooting is more likely to involve issues such as incorrect VLAN configuration, link negotiation problems, cabling faults, congestion, or duplex mismatches with older equipment than collisions on a properly functioning link.

VLAN support and network segmentation

Virtual LANs (VLANs) allow administrators to divide a physical switching infrastructure into separate logical Layer 2 networks.

For example, an organization might place office computers, IP cameras, voice devices, and guest connections in separate VLANs. This arrangement helps limit broadcast traffic and establishes boundaries between groups of devices.

However, VLANs alone do not enforce all security policies. Traffic that must pass between VLANs generally requires Layer 3 routing, where access control lists or firewall policies can control which communications are permitted.

The switch must support the VLAN features and configuration required by the network design.

Quality of Service (QoS)

Quality of Service (QoS) features help switches prioritize selected traffic when network resources are constrained.

For example, a network carrying voice calls, video streams, and ordinary office traffic may use QoS to give time-sensitive traffic preferential treatment. Depending on the equipment, this can involve traffic classification, priority queues, and scheduling policies.

QoS does not create additional bandwidth or guarantee that congestion will never occur. It helps manage how available resources are allocated.

Uplinks, redundancy, and network growth

Uplink ports connect switches to other switches, routers, servers, or network backbones. Depending on the model, uplinks may support copper Ethernet, fiber-optic connections through SFP transceivers, or higher-speed interfaces.

Fiber uplinks are useful when connecting equipment over longer distances or between buildings, while copper connections are often suitable for shorter runs within a facility.

Networks can expand by connecting additional switches, but the topology must be designed carefully. Redundant links can improve availability when supported by appropriate mechanisms, such as spanning tree protocols, link aggregation, or other supported redundancy technologies. Simply adding extra uplinks does not automatically provide failover and can create switching loops if they are not configured correctly.

Managed vs. unmanaged switches

Ethernet switches generally fall into two broad categories: managed and unmanaged.

Unmanaged switches typically provide straightforward plug-and-play connectivity with little or no configuration. They can be suitable for small networks or applications that do not require advanced monitoring or traffic controls.

Managed switches offer configuration and monitoring capabilities that may include VLANs, QoS, port mirroring, access controls, and redundancy features. Available functions vary by model.

Managed switching can be especially useful in larger business networks, industrial installations, and security systems where administrators need greater control over traffic and network behavior.

Read Versitron's guide to managed vs. unmanaged switches to learn more about the differences and how to evaluate the options.

Network security

Switches can support network security through features such as VLAN segmentation, port security, IEEE 802.1X authentication, access control lists, and monitoring, where supported.

These functions can help restrict unauthorized connections and limit access between network segments. Their effectiveness depends on the specific features available and how the network is configured.

A basic unmanaged switch does not provide the same security controls as a fully managed switch. Organizations should evaluate their security requirements before selecting equipment.

Data Link Layer Protocols

The data link layer is not limited to Ethernet. Different networking technologies define their own frame formats, addressing methods, and rules for communication over a link.

Ethernet (IEEE 802.3)

Ethernet is the dominant technology for wired local area networks.

An Ethernet frame includes destination and source MAC addresses, a field identifying the payload type or length, the payload, and a Frame Check Sequence used for error detection.

Ethernet uses MAC addresses to support local frame delivery. Switches learn source addresses and use destination addresses to make forwarding decisions.

The FCS helps a receiving device detect many forms of frame corruption. Frames that fail the check are generally discarded; the FCS does not provide end-to-end error correction.

Ethernet can run over twisted-pair copper cabling or fiber-optic links, depending on the selected interface and supported standard. The choice of medium affects supported distance, speed, and installation requirements.

Wi-Fi (IEEE 802.11)

Wi-Fi provides wireless LAN connectivity using radio signals. Like Ethernet, it uses link-layer frames and MAC addressing, but its frame structures and media-access procedures differ.

Wireless devices share radio channels, so Wi-Fi must coordinate access to the wireless medium. Signal strength, interference, channel utilization, access-point placement, and client capabilities can all affect performance.

Wireless networks also use security mechanisms to protect communications. WPA2 and WPA3 are examples of Wi-Fi security protocols, with the appropriate choice depending on device compatibility and security requirements.

Wireless access points commonly bridge Wi-Fi traffic into a wired Ethernet network, allowing wireless clients to communicate with permitted resources on the LAN.

Token Ring: A Legacy Networking Technology

Token Ring was a LAN technology in which devices gained permission to transmit by receiving a special control frame called a token.

A device holding the token could transmit data according to the network's access rules before releasing the token for another device to use. This controlled access method helped avoid collisions on the shared logical ring.

Token Ring was historically used in some enterprise networks, but it has largely been replaced by Ethernet and Wi-Fi. It is now primarily of historical interest or relevant to specialized legacy environments rather than new network installations.

Troubleshooting Common Data Link Layer Problems

Understanding Layer 2 functions can help narrow down the cause of a network connectivity problem. When a device cannot communicate with other devices on its local network, the following checks can be useful.

  1. Check the physical link. Confirm that cables, fiber connectors, transceivers, and switch ports are compatible and properly connected. Check link indicators and port status.
  2. Verify speed and duplex settings. Confirm that connected devices negotiate compatible link settings. Mismatched settings, particularly with older equipment, can cause performance problems.
  3. Review VLAN configuration. Make sure the device's switch port is assigned to the intended VLAN and that trunk links carry the required VLANs.
  4. Check MAC address learning. Review the switch's MAC address table to determine whether the expected device address is being learned on the correct port.
  5. Look for Layer 2 loops. Unexpected broadcast traffic or unstable connectivity may indicate a switching loop or an incorrectly configured redundant link.
  6. Inspect error counters. Interface statistics may reveal CRC errors, dropped frames, or other link problems that warrant further investigation.
  7. Review security and access policies. Port security, authentication requirements, or VLAN restrictions may prevent a device from communicating even when the physical link is active.

If the device can communicate with other devices on its local VLAN but cannot reach an external network, the problem may instead involve IP addressing, the default gateway, routing, or firewall rules.

Conclusion

The data link layer is a fundamental part of local networking. It provides the framing, MAC addressing, and link-level mechanisms that allow devices to exchange information across Ethernet and Wi-Fi networks.

Ethernet switches, network interface cards, bridges, and wireless access points all contribute to Layer 2 communication, although each has a different role. Switches are especially important because they learn MAC addresses, forward frames, and can support segmentation, prioritization, and security controls.

For organizations building or upgrading a LAN, understanding these functions helps guide equipment selection and troubleshooting. Choosing switches with the appropriate port types, speeds, management capabilities, and environmental ratings can help create a network that meets current needs while supporting future expansion.

Explore Versitron's Ethernet network switches to learn more about switching solutions for business and industrial network applications.

Related Blogs

Back to blog