Week 1 · Lesson 2

Understanding Switches and Addressing

A switch is the quiet workhorse of every LAN. It does not need an IP address to do its job — it builds its own map of who is where and forwards frames accordingly. This lesson shows exactly how that map is built, how a switch decides where to send a frame, and the three addresses that ride inside every single communication.

CCNA 200-301 Domain 1.0/1.3 Verified 2026-10-11
Part 1

Why switches replaced hubs

The first Ethernet networks used a hub (also called a repeater). A hub is a Layer 1 device: it takes every bit that arrives on one port and repeats it out of every other port. It makes no decisions and reads no addresses. The consequence is severe — all devices attached to a hub share one collision domain and one pool of bandwidth, so when two devices transmit at once their signals collide and both must be retransmitted.

A switch is a Layer 2 device that fixes all of this. It reads the Ethernet header, records which device is on which port, and forwards a frame only toward the port where the destination lives. Each switch port becomes its own collision domain — a technique called microsegmentation.

PropertyHubSwitch
OSI layerLayer 1 (Physical)Layer 2 (Data Link)
DecisionsNone — repeats signalsForwards by destination MAC address
Collision domainsOne shared by all portsOne per port
DuplexHalf-duplexFull-duplex per port
BandwidthShared by all devicesDedicated per port
EfficiencyDegrades as devices are addedScales well
Analogy. A hub is one large room where everyone shouts and only one person can speak at a time; when two speak at once, everyone has to repeat themselves. A switch is a receptionist who keeps a list of which room each person is in and connects calls directly, so two conversations can happen at once without interfering. That list is the MAC address table.
Hub or switch? · select a device
PC A PC B PC C Hub Layer 1 one shared collision domain

Part 2

Switch fundamentals

A switch forwards Ethernet frames based on the destination MAC address inside the frame. To do that it maintains a MAC address table (also called the CAM table or forwarding table) that maps each known MAC address to the port on which it was seen, within a VLAN. A frame that arrives on a port is called ingress; the port it leaves by is egress.

Every Ethernet MAC address is 48 bits long, written as 12 hexadecimal digits. The first 24 bits are the Organizationally Unique Identifier (OUI), assigned by the IEEE Registration Authority to a manufacturer; the remaining 24 bits identify the individual interface. Cisco writes the address in dotted notation — 001a.2b3c.4d5e — while other systems use colons or hyphens: 00:1a:2b:3c:4d:5e.

Definition — MAC address. A 48-bit Layer 2 address burned into a network interface card, unique on the local link. The all-ones address ff:ff:ff:ff:ff:ff (written ffff.ffff.ffff by Cisco) is the broadcast address, addressed to every device.

Two special cases matter for the switch: an address whose Individual/Group (I/G) bit is 0 is a unicast (one destination); if that bit is 1 it is a multicast/group address. Switches treat broadcasts and most multicasts as traffic that must be sent to many ports.

Decode a MAC address · type one in

Part 3

Building the MAC address table

A switch starts with an empty table and fills it automatically as traffic flows. The behaviour for every frame is decided by four actions.

  1. Learning. The switch reads the source MAC address of the frame and records it together with the ingress port (and VLAN). If that MAC was already known, the port is updated. This is how the table is populated without any administrator involvement.
  2. Forwarding (known unicast). If the destination MAC is already in the table and the entry points to a different port, the switch sends the frame out that one port only.
  3. Flooding. If the destination is unknown (not in the table), or the frame is a broadcast (ffff.ffff.ffff) or a multicast, the switch sends it out of every port in the same VLAN except the port it arrived on.
  4. Filtering. If the destination MAC is on the same port as the frame's ingress port, the switch drops the frame — there is no reason to send it back out the way it came.
Exam tip. A switch learns from the source MAC and forwards on the destination MAC. A frame is never sent back out of the port it arrived on. And the classic one-liner: unknown unicast and broadcast are flooded; known unicast is forwarded out one port.
Build the table · step through the traffic
Mac AddressTypePorts

Entries are not permanent. Every learned address is given an aging timer; if no frame from that address is seen again before the timer expires, the entry is removed. On Cisco Catalyst switches the default aging time is 300 seconds (5 minutes). Aging keeps the table accurate when a device is unplugged and moved to a different port.

Part 4

Three switching behaviours

How much of a frame the switch buffers before it forwards depends on its switching method. There are three, and the exam expects you to weigh latency against error checking.

MethodWhat it waits forError checkingLatency
Store-and-forwardThe whole frameFull — computes the CRC and drops bad framesHighest (grows with frame size)
Cut-throughOnly the destination MAC (first 6 bytes)None — can forward corrupted framesLowest
Fragment-freeThe first 64 bytesDetects collision fragments (runts)Medium

Store-and-forward is Cisco's primary LAN switching method. The switch receives the entire frame, checks the Frame Check Sequence (FCS/CRC), discards it if it is corrupt, then forwards it. It is the most reliable but adds the most latency. Cut-through (Cisco calls the common variant fast-forward) reads only the destination address and immediately begins forwarding — very fast, but it propagates errors because the checksum at the end of the frame has not been read yet. Fragment-free is the compromise: it stores the first 64 bytes, the window in which nearly all collisions occur, before forwarding.

Switching method · pick one

Bytes the switch buffers before it begins forwarding the frame.

Part 5

The three addresses in every communication

Every exchange between two applications carries three different kinds of address. Each lives at a different layer and answers a different question.

LayerAddressSizeAnswers the question
Layer 2MAC address48 bitsWhich device on this local link?
Layer 3IP addressIPv4: 32 bits / IPv6: 128 bitsWhich host on the end-to-end path?
Layer 4Port number16 bits (0–65535)Which application on that host?

Take a browser opening https://example.com. The frame that leaves your PC carries:

Layer 2 · MAC
Source00:1a:2b:3c:4d:5e
Destinationgateway MAC
Layer 3 · IP
Source192.168.1.10
Destination203.0.113.10
Layer 4 · Port
Source49152
Destination443 (HTTPS)
Port ranges (IANA). Port numbers are 16-bit values. IANA divides them into System/well-known ports 0–1023, User/registered ports 1024–49151, and Dynamic/private ports 49152–65535. Servers listen on well-known ports (443 for HTTPS); clients pick a temporary high-numbered source port.
Analogy. Address a parcel three ways. The street address gets it to the right building across the country — that is the IP address. The name on the door identifies which resident accepts it on the last leg — that is the MAC address, which changes at every router. The department or extension tells the building who inside should handle it — that is the port number.
Part 6

Duplex and reading the MAC address table

Duplex describes whether a link can send and receive at the same time.

Warning — duplex mismatch. If one end of a link is set to full-duplex and the other to half-duplex, the link still comes up but performs badly: the half-duplex side reports late collisions and dropped frames. On modern ports, leave duplex on auto; if you must configure it manually, set both ends identically.

Reading the MAC address table

A Cisco IOS switch displays learned addresses with show mac address-table. Each row lists the VLAN, the MAC address, whether the entry is static or dynamic, and the port it was learned on.

switch# show mac address-table
          Mac Address Table
-------------------------------------------

Vlan    Mac Address       Type        Ports
----    -----------       --------    -----
   1    001a.2b3c.4d5e    DYNAMIC     Gi1/0/1
   1    001a.2b3c.4d5f    DYNAMIC     Gi1/0/2
   1    001a.2b3c.4d60    DYNAMIC     Gi1/0/3
   1    001a.2b3c.4d61    DYNAMIC     Gi1/0/4
   1    ffff.ffff.ffff    STATIC      CPU
Total Mac Addresses for this criterion: 5

Useful variations include show mac address-table dynamic to see only learned entries, show mac address-table interface Gi1/0/1 to list addresses on one port, and clear mac address-table dynamic to remove all dynamic entries (for example, after moving a device). The DYNAMIC type means the switch learned the address from traffic; STATIC entries are configured by an administrator or added automatically for reserved addresses.

Part 7 · Your turn

Review

Check what you have learned with these review questions.

Review · 6 questions

Sources

Sources & references

  1. IEEE. IEEE Std 802.3™ — Ethernet (MAC frame format, 48-bit address fields, minimum 64-byte and maximum 1518-byte frame sizes). standards.ieee.org/ieee/802.3.
  2. IEEE Registration Authority. MAC Addresses / OUI assignments. standards.ieee.org/products-programs/regauth.
  3. Braden, R. RFC 1122: Requirements for Internet Hosts — Communication Layers (1989). rfc-editor.org/rfc/rfc1122.
  4. Socolofsky, T. & Kale, C. RFC 1180: A TCP/IP Tutorial (1991), Sections 2–3 (MAC vs IP addressing and switching). rfc-editor.org/rfc/rfc1180.
  5. IANA. Service Name and Transport Protocol Port Number Registry (port ranges). iana.org/assignments/service-names-port-numbers.
  6. Cisco. CCNA (200-301) Exam Topics, Network Fundamentals. cisco.com.

Target exams: CCNA 200-301 v1.1 · CyberOps Associate 200-201. Last content verification: 2026-10-11.