What happens to a frame on the switch receives it?

"As I understand it, when one PC sends a frame to another PC through a switch, the frame remains unchanged."

You are correct; switches do not modify the frames they forward in any way. This is known as transparent bridging as explained in this O'Reilly article titled Basic Switch Operation:

Ethernet switches are designed so that their operations are invisible to the devices on the network, which explains why this approach to linking networks is also called transparent bridging. “Transparent” means that when you connect a switch to an Ethernet system, no changes are made in the Ethernet frames that are bridged.


"But what happens if we have two PCs connected to a router and we send something between them?"

TL;DR

Any packet forwarded by a router will be modified. Required modifications include a new destination MAC address and a new Frame Check Sequence. But that's only a small part of what happens at the router...


Unlike switches, routers decide what to do with a packet based on its OSI Layer 3 destination address. In this case that is an Internet Protocol (IP) address. Therefore what happens to the packet depends on where the packet is headed. Let's use the image you referred to as an example:

Here we have a router with two interfaces: e1/1/1 (which I'll refer to as E1) and e1/1/2 (which I'll refer to as E2). Notice that the router's two interfaces are in separate subnets, which must always be the case for a router:

  • E1 is connected to subnetwork 10.0.0.0/24
  • E2 is connected to subnetwork 10.0.1.0/24

Now, suppose Computer A (with IP address 10.0.0.2/24 and therefore in subnetwork 10.0.0.0/24) sends a packet to destination IP address 10.0.1.2. Once that packet arrives at the router, the following happens:

  1. Packet arrives on interface E1
  2. Router determines the destination address is 10.0.1.2
  3. Router examines its routing table to determine where the packet should go
  4. The routing table indicates interface E2 is connected to subnetwork 10.0.0.0/24
  5. The router prepares the packet for transmission on interface E2. This requires modifying the packet in several ways. For example, the new packet will have:
    • The old destination Layer 2 (MAC) address replaced with a new destination address, which will be the broadcast address FF:FF:FF:FF:FF:FF for the first such packet sent on the interface
    • A new Frame Check Sequence (FCS) calculated and added to the packet
  6. The new packet is transmitted on interface E2

Once the packet is sent to the network segment connected to router interface E2 it is received by Computer B with the IP address 10.0.1.2.

Suppose Computer A sends a packet to the destination IP address 10.0.7.44. Once the packet reaches the router, the following occurs:

  1. Packet arrives on interface E1
  2. Router determines the destination address is 10.0.7.44
  3. Router examines its routing table to determine where the packet should go

Now what happens?

Well, if as shown in the graphic, the router truly only has the two interfaces, the router drops the packet because it doesn't have a valid route to the destination network.

In the real world, however, a router is likely to have at least one interface that is configured to be the default route or route of last resort. In the routing table, this is the interface with which network 0.0.0.0/0 is associated. If the router does not have a specific route to a valid network for the packet destined to 10.0.7.44, as its action of "last resort" it will transmit the packet on the interface associated with the default route.

The default route functionality is very important. Without it the router would be required to have a routing table entry for many (though not all) IP networks on the Internet. Such a table would be very large. Compared to a router with a default route, such a router would require:

What happens when a switch receives a frame and the calculated CRC value is different than the value that is in the FCS field?

What happens when a switch receives a frame and the calculated CRC value is different than the value that is in the FCS field?

  • The switch notifies the source of the bad frame.
  • The switch places the new CRC value in the FCS field and forwards the frame.
  • The switch drops the frame.
  • The switch floods the frame to all ports except the port through which the frame arrived to notify the hosts of the error.

Explanation: The purpose of the CRC value in the FCS field is to determine if the frame has errors. If the frame does have errors, then the frame is dropped by the switch.

More Questions: Introduction to Networks (Version 7.0) – ITNv7 Practice Final Exam

Post navigation

← Previous Question

What is a characteristic of a switch virtual interface (SVI)?​

Next Question →

Two network engineers are discussing the methods used to forward frames through a switch. What is an important concept related to the cut-through method of switching?

What happens when a switch receives a packet?

As the switch receives a data packet, it reads the source address and maps the port number to the MAC address in that source field. The following diagram shows what a MAC Address Table entry looks like if Workstation A is plugged into Port 1 of our switch and sends a frame.

What happens if an incoming frame arrives to the switch and the switch doesn't have the address in it's table?

If the destination MAC address is not in the table, the switch forwards the frame out all ports except the incoming port. This is called an unknown unicast. As shown in Figure 7-16, the switch does not have the destination MAC address in its table for PC-D, so it sends the frame out all ports except port 1.