CLOUD CONCEPT

Ethernet Switching

Ethernet switching forwards Ethernet frames within a Layer 2 network using destination MAC addresses and VLAN membership.

Cloud Concepts Hub →

What is Ethernet Switching

An Ethernet switch learns which MAC addresses are reachable through its ports and uses that information to deliver frames within a broadcast domain. Understanding where switching ends and IP routing begins is essential when connecting on-premises networks to cloud environments, especially when configuring VLANs, gateways, and dedicated connectivity.

Ethernet switching operates at Layer 2 of the network stack. A switch receives an Ethernet frame, learns the source MAC address on the ingress port, and looks up the destination MAC address in its forwarding database, commonly called a MAC address table. Entries are normally associated with a VLAN and age out after inactivity. For a known unicast destination, the switch forwards the frame through the appropriate port, or filters it if the destination is reachable through the ingress port.

When the destination MAC address is unknown, a traditional switch floods the frame through other forwarding ports in the same VLAN. Broadcast frames are also flooded within that VLAN. Multicast forwarding depends on configuration and capabilities such as multicast snooping. This behavior makes broadcast-domain size operationally important: large domains increase broadcast exposure and the potential impact of loops or misbehaving endpoints.

VLANs divide switching infrastructure into separate Layer 2 broadcast domains. An access port typically carries one VLAN without an endpoint-visible tag, while a trunk carries multiple VLANs using IEEE 802.1Q tags. VLAN identifiers must match the intended configuration across the connection. A VLAN is not an IP subnet, although assigning one IP subnet to each VLAN is a common design. VLAN separation also does not replace firewall policy or provide encryption.

Switching and routing solve different problems. Consider a host at 192.168.10.20/24 sending traffic to 192.168.20.30. Because the destination is outside its local subnet, the host resolves its default gateway's MAC address using ARP and sends the frame to that gateway. The IP packet still identifies 192.168.20.30 as its destination. The router selects an IP route and creates the appropriate link-layer encapsulation for the next hop. IPv6 uses Neighbor Discovery rather than ARP for neighbor resolution.

Cloud networks often expose Ethernet-compatible interfaces without providing a conventional, customer-controlled Ethernet switch fabric. In Amazon VPC, an instance interface has a MAC address, but the subnet is not a traditional Ethernet broadcast domain. VPC does not support general Ethernet broadcast or arbitrary Layer 2 adjacency. Do not assume that broadcast discovery, spanning tree, or an application requiring transparent Ethernet bridging will work merely because instances share a subnet.

AWS Direct Connect illustrates the boundary between Layer 2 connectivity and Layer 3 cloud access. Its Ethernet connection uses 802.1Q VLAN tagging to distinguish virtual interfaces, while BGP exchanges IP routes over those interfaces. For example, an engineer configuring a private virtual interface must align the VLAN configuration, BGP peer addressing, and autonomous system settings with the intended connection. The VLAN carries the peering traffic; it does not extend an on-premises broadcast domain into a VPC. Reaching workload subnets also requires correct route propagation or route-table entries and appropriate security policy.

Traditional switched networks need loop prevention because Ethernet frames lack an IP-style hop limit. Spanning Tree Protocol can block redundant paths, while supported link aggregation combines physical links into a logical connection. Layer 2 extension can preserve addressing for legacy workloads, but it enlarges failure domains and complicates troubleshooting; routed boundaries generally provide clearer isolation. When diagnosing hybrid connectivity, verify physical link state, VLAN tagging, MAC learning, and MTU before investigating IP addressing, gateway reachability, BGP, routes, and filtering. A healthy Ethernet link alone does not establish end-to-end IP connectivity.

Key aspects of Ethernet Switching

Ethernet switching depends on MAC learning, VLAN boundaries, controlled flooding, and loop prevention, while cloud integration requires an explicit distinction between Layer 2 transport and Layer 3 routing.

MAC-based frame forwarding

Switches learn source MAC addresses and forward frames according to destination MAC addresses within a VLAN. MAC-table inspection helps identify incorrect cabling, unexpected endpoint movement, and missing Layer 2 reachability.

VLAN segmentation and tagging

VLANs create separate broadcast domains on shared switching infrastructure. Configure access-port membership and 802.1Q trunk tagging consistently, especially at dedicated cloud connectivity handoffs.

Broadcast and unknown-unicast handling

Traditional switches flood broadcasts and unknown unicasts within the relevant VLAN. Limit broadcast-domain scope and avoid assuming that cloud virtual networks reproduce this behavior.

Separation from IP routing

Switching delivers frames within a Layer 2 domain; routing moves IP packets between networks. Hosts use their subnet configuration to determine whether to resolve the destination directly or send traffic through a gateway.

Loop prevention and resilient links

Layer 2 loops can cause broadcast storms and unstable MAC learning. Use supported spanning-tree and link-aggregation designs on physical networks rather than adding redundant links without loop controls.

Cloud abstraction boundaries

An Ethernet-compatible virtual interface does not guarantee transparent bridging, broadcast support, or customer-managed switching. Validate the cloud network's actual forwarding model before deploying software that depends on Layer 2 behavior.

Cloud services for Ethernet Switching

AWS Direct Connect supplies the Ethernet handoff and VLAN-tagged virtual interfaces used for dedicated connectivity, while BGP establishes the IP routing relationship. Amazon VPC provides workload subnets and route tables without extending the on-premises Ethernet broadcast domain. AWS Transit Gateway can provide routed transit between multiple VPCs and on-premises networks through a Direct Connect gateway association. Together, these services separate link-level configuration from end-to-end routing: VLAN tagging must be correct at the handoff, and routes, return paths, security controls, and MTU must also support the intended traffic.

AWS Direct Connect image AWS Direct Connect

Provides dedicated Ethernet connectivity to AWS with 802.1Q-tagged virtual interfaces and BGP-based IP routing. Engineers must coordinate VLAN tagging and Layer 3 peering; the service does not transparently extend an on-premises VLAN into a VPC.

Open AWS Direct Connect →
Virtual private cloud VPC_32 image Amazon VPC

Provides isolated virtual networks, subnets, route tables, and virtual network interfaces. Although interfaces have MAC addresses, VPC networking is not a customer-controlled Ethernet switching fabric and does not support general Ethernet broadcast.

Open Amazon VPC →
AWS Transit Gateway image AWS Transit Gateway

Connects VPCs and on-premises networks through a managed Layer 3 transit hub. It is relevant when replacing broad Layer 2 extension with routed connectivity and explicit route-table segmentation.

Open AWS Transit Gateway →