Week 1Network Fundamentals35 min

What Actually Happens When Two Devices Communicate

Learning objectives

  • Describe the end-to-end path of a simple LAN conversation
  • Distinguish between application data, segments/packets, and frames
  • Explain why both MAC and IP addresses are needed
  • Trace how encapsulation changes at each hop through a gateway

Watch first

Recommended video

Network Devices (Day 1)

Video credit: Jeremy's IT Lab

Watch on YouTube
Recommended video

The Life of a Packet (Day 12)

Video credit: Jeremy's IT Lab

Watch on YouTube

Also watch — playlist supplement

Recommended video

What is a Network? (Video #1)

Video credit: David Bombal

Watch on YouTube
Recommended video

How Do Networks Actually Work? (Video #10)

Video credit: David Bombal

Watch on YouTube

Plain-English explanation

When PC A sends data to PC B, nothing travels as a single blob. The application hands bytes to a transport protocol (TCP or UDP), which adds port numbers. IP wraps that in a packet with source and destination IP addresses. Ethernet then wraps the packet in a frame with source and destination MAC addresses.

On the same subnet, the frame goes directly to B's MAC after ARP resolves it. On a different subnet, A still puts B's IP in the packet, but the frame is addressed to the default gateway's MAC. The router strips the old frame, reads the IP destination, and forwards — creating a new frame on the next hop.

Deep dive

Think of two address systems working together:

  • IP (Layer 3) — logical, end-to-end, survives routing hops
  • MAC (Layer 2) — physical on the local segment, changes every L2 hop

Each router hop is a new encapsulation story: decapsulate frame → inspect IP → route lookup → encapsulate new frame with the next-hop MAC.

Key PDU names CCNA expects:

| Layer | PDU name | |-------|----------| | Transport | Segment (TCP) or Datagram (UDP) | | Network | Packet | | Data Link | Frame |

Step-by-step — ping across a gateway

PC A: 192.168.1.10/24, gateway 192.168.1.1, target PC B: 10.0.0.50/24

  1. A compares B's IP to its own mask — different network → use default gateway
  2. A ARPs for 192.168.1.1 (if not cached) to learn the gateway MAC
  3. A builds ICMP inside IP (src 192.168.1.10, dst 10.0.0.50), frames it to gateway MAC
  4. Router receives frame, strips L2, decrements TTL, routes toward 10.0.0.0/24
  5. Router ARPs on the outbound interface, builds new frame toward B (or next router)
  6. B replies — same process in reverse; source IP stays A, source MAC changes per hop

Commands to know

Verify local ARP and routing on a host

Windows

arp -a route print

Linux/macOS

arp -n ip route

Cisco router — see what the router knows

show ip arp show ip route show interfaces status

Troubleshooting

| Symptom | Likely layer | First check | |---------|--------------|-------------| | No connectivity at all | L1/L2 | Link lights, show interfaces status | | IP works locally, not remotely | L3 | Default gateway, show ip route | | Ping to gateway fails | L2/L3 | ARP table, VLAN, mask | | Ping works, app fails | L4/L7 | Port/firewall, DNS, TCP vs UDP |

Always ask: where did the packet stop? If ARP fails, IP never gets a fair test. If routing is wrong, the packet dies at the first router.

Exam relevance

Common exam trap

The source IP typically stays the same end-to-end. The source MAC changes on every Layer 2 hop. Exam scenarios love asking what changes at each router.

Encapsulation direction

Data goes down the stack (encapsulation) on send and up the stack (decapsulation) on receive. Routers only go up to Layer 3.

Practice checklist

  • Draw a two-PC same-subnet exchange and label segment, packet, and frame
  • Draw a cross-subnet ping and mark where ARP targets the gateway, not the remote host
  • List which headers change at each router hop (IP TTL, MAC src/dst)
  • Use the packet walk tool to trace one scenario aloud without notes
  • Explain why switches do not rewrite IP addresses

PC A (192.168.1.10/24) pings PC B (192.168.1.20/24). Which address appears in the Ethernet destination field?

A packet crosses two routers to reach its destination. How many times is the Layer 2 header rebuilt?

Video credits

These are free, open educational videos from independent creators. We link and embed them with attribution; all rights belong to the respective channels.

Related tools