How a LAN switch decides to forward a frame destined for a broadcast MAC address?

  • Home
  • Networking
  • CCENT/CCNA ICND1 100-105

41.

Which of the following statements describes part of the process of how a switch decides to forward a frame destined for a known unicast MAC address?

  • A.

    It compares the unicast destination address to the bridging, or MAC address, table.
  • B.

    It compares the unicast source address to the bridging, or MAC address, table.
  • C.

    It forwards the frame out all interfaces in the same VLAN except for the incoming interface.
  • D.

    It compares the destination IP address to the destination MAC address.
  • E.

    It compares the frame’s incoming interface to the source MAC entry in the MAC address table.

Answer : [A]
Explanation :

42.

Which of the following statements describes part of the process of how a LAN switch decides to forward a frame destined for a broadcast MAC address?

  • A.

    It compares the unicast destination address to the bridging, or MAC address, table.
  • B.

    It compares the unicast source address to the bridging, or MAC address, table.
  • C.

    It forwards the frame out all interfaces in the same VLAN except for the incoming interface.
  • D.

    It compares the destination IP address to the destination MAC address.
  • E.

    It compares the frame’s incoming interface to the source MAC entry in the MAC address table.

Answer : [C]
Explanation :

43.

Which of the following statements best describes what a switch does with a frame destined for an unknown unicast address?

  • A.

    It forwards out all interfaces in the same VLAN except for the incoming interface.
  • B.

    It forwards the frame out the one interface identified by the matching entry in the MAC address table.
  • C.

    It compares the destination IP address to the destination MAC address.
  • D.

    It compares the frame’s incoming interface to the source MAC entry in the MAC address table.

Answer : [A]
Explanation :

44.

Which of the following comparisons does a switch make when deciding whether a new MAC address should be added to its MAC address table?

  • A.

    It compares the unicast destination address to the bridging, or MAC address, table.
  • B.

    It compares the unicast source address to the bridging, or MAC address, table.
  • C.

    It compares the VLAN ID to the bridging, or MAC address, table.
  • D.

    It compares the destination IP address’s ARP cache entry to the bridging, or MAC address, table.

Answer : [B]
Explanation :

45.

A Cisco Catalyst switch has 24 10/100 ports, numbered 0/1 through 0/24. Ten PCs connect to the ten lowest numbered port, with those PCs working and sending data over the network. The other ports are not connected to any device. Which of the following answers lists facts displayed by the show interfaces status command?

  • A.

    Port Ethernet 0/1 is in a connected state.
  • B.

    Port Fast Ethernet 0/11 is in a connected state.
  • C.

    Port Fast Ethernet 0/5 is in a connected state.
  • D.

    Port Ethernet 0/15 is in a notconnected state.

Answer : [C]
Explanation :

  • Pages
  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • 11
  • 12
  • 13
  • 14
  • 15
  • 16
  • 17
  • 18
  • 19
  • 20
  • 21
  • 22
  • 23
  • 24
  • 25
  • 26
  • 27
  • 28
  • 29
  • 30

In the last article, we looked at everything that happens for two hosts to communicate directly with one another. In this article, we will add a common network device: a switch. We will take a look at what happens for communication from Host to Host through a Switch.

This article will be the practical application of everything that was discussed when we looked at a Switch as a key player in packet traveling. It might be worth reviewing that section before proceeding.

We will start by looking at the individual switch functions, and then take a look at an animation which shows their collaborative operation.

Switch Functions

A Switch primarily has four functions: Learning, Flooding, Forwarding, and Filtering:

Learning

Being a Layer 2 device, a Switch will make all its decisions based upon information found in the L2 Header. Specifically, a Switch will use the Source MAC address and Destination MAC address to make its forwarding decisions.

One of the goals of the Switch is to create a MAC Address Table, mapping each of its switchports to the MAC address of the connected devices.

The MAC address table starts out empty, and every time a Switch receives anything, it takes a look at the Source MAC address field of the incoming frame. It uses the Source MAC and the switchport the frame was received on to build an entry in the MAC Address Table.

Sooner or later, as each connected device inevitably sends something, the Switch will have a fully populated MAC Address Table. This table can then be used to smartly forward frames to their intended destination.

Flooding

However, despite the learning process above, it is unavoidable that a Switch will at some point receive a frame destined to a MAC address of which the Switch does not know the location.

In such cases, the Switch’s only option is to simply duplicate the frame and send it out all ports. This action is known as Flooding.

Flooding assures that if the intended device exists and if it is connected to the switch, it will definitely receive the frame.

Of course, so will every other device connected to that particular Switch. And though not ideal, this is perfectly normal. The NIC of each connected device will receive the frame and take a look at the Destination MAC address field. If they are not the intended recipient, they will simply silently drop the frame.

If they are the intended device, however, then the Switch can rest satisfied knowing it was able to deliver the frame successfully.

Moreover, when the intended device receives the frame, a response will be generated, which when sent to the Switch will allow the switch to learn and create a MAC Address Table mapping that unknown device to its switchport.

Forwarding

Ideally, of course, the Switch will have an entry in its MAC Address Table for every Destination MAC it comes across.

When this happens, the Switch happily forwards the frame out the appropriate switchport.

There are three methods by which a Switch can forward frames. They are briefly described below.

  • Store and Forward – The Switch copies the entire frame (header + data) into a memory buffer and inspects the frame for errors before forwarding it along. This method is the slowest, but allows for the best error detection and additional features like prioritizing certain types of traffic for faster processing.
  • Cut-Through – The Switch stores nothing, and inspects only the bare minimum required to read the Destination MAC address and forward the frame. This method is the quickest, but provides no error detection or potential for additional features.
  • Fragment Free – This method is a blend of the prior two. The Switch inspects only the first portion of the frame (64 bytes) before forwarding the frame along. If a transmission error occurred, it is typically noticed within the first 64 bytes. As such, this method provides “good enough” error detection, while gaining the speed and efficiency of avoiding storing the entire frame in its memory before forwarding it.

It is worth pointing out that these three methods were at one point very significant when Switch technologies were newer and switching induced noticeable latency. In modern days, with line-speed switching, the difference in speed between these three is negligible, and most switches operate in Store and Forward mode.

Filtering

And finally, the last function of the switch is filtering. Mainly, this function states that a Switch will never forward a frame back out the same port which received the frame.

Most commonly, this happens when a Switch needs to flood a frame — the frame will get duplicated and sent out every switchport except the switchport which received the frame.

Rarely, a host will send a frame with a destination MAC address of itself. This is usually a host experiencing some sort of error condition or being malicious. Either way, when this happens, the Switch simply discards the frame.

Switch Operation

Now that we’ve looked at each of the individual functions of a Switch, we can look at them in action. The animation below includes a Switch going through all four functions as it processes traffic.

Ordinarily, the hosts in the animation below would need to perform an ARP resolution, but for the sake of focusing on the Switch’s operation, we will omit ARP and proceed as if all the hosts already knew each other’s IP and MAC addresses.

Host A has “something” to send to Host B. The contents of the “something” is entirely irrelevant, so long as its understood that the frame has a L2 header which includes a Source and Destination MAC address.

Initially, the MAC Address Table of the Switch is empty. Remember, it only gets populated when a frame is received.

When Host A sends the frame to the switch, it includes a Source MAC address of aaaa.aaaa.aaaa. This prompts the Switch to learn a MAC Address Table entry mapping Port 1 to MAC Address aaaa.aaaa.aaaa.

Then, when deciding how to forward the frame, the Switch realizes there is no entry for bbbb.bbbb.bbbb. This leaves the Switch only one option: duplicate and flood the frame out all ports. Notice the frame was duplicated out all ports, except Port 1 (the port it came in on) – this is an example of the Switch performing its filtering function.

This frame will then be received by Host C and Host B. Host C, when inspecting the L2 header will realize the frame is not intended for them and will simply discard it. Conversely, when Host B receives the frame and realizes they indeed are the intended recipient, they will accept the frame and generate a response.

When the response arrives on the Switch, another MAC Address Table mapping can be learned: Port 2 contains the MAC address bbbb.bbbb.bbbb.

Then the Switch looks up the Destination MAC address (aaaa.aaaa.aaaa) and realizes this address exists out Port 1. The Switch can then simply forward the frame, since it knows the location of the Destination MAC address.

The animation above illustrate the four switch functions on a single switch. To see how the process scales to multiple switches, check out this article.

Broadcasts

There is often some confusion about a switch in regards to a Broadcast and a Switch’s flooding behavior. The confusion is understandable, because the end result is the same, but it is also important to understand the distinction.

A Broadcast frame is a frame which is addressed to everyone on the local network. This is done using the same Ethernet header we’ve been discussing, except the Destination MAC address field is populated with a special address: ffff.ffff.ffff. The “all F’s” address is specially reserved for the purpose of broadcasting.

By definition, if the Switch ever encounters a packet with a destination MAC of ffff.ffff.ffff, it will always flood the frame (after learning the Source MAC, of course).

Another way of looking at it, is since the address ffff.ffff.ffff is reserved, the switch is unable to learn a MAC Address Table mapping for it. As such, any frame destined to this MAC address will always be flooded.

In summary, a Broadcast is a frame addressed to everyone on the local network (ffff.ffff.ffff), and Flooding is an action a switch can take. A broadcast frame, by definition, will always be flooded by a switch. But a switch will never broadcast a frame (since broadcasting is not a function of a switch).

This article intentionally omits the Address Resolution Protocol (ARP) in order to focus purely on the actions of a Switch. ARP is a function of the client, and will never be performed by the switch itself. It is assumed that the clients in the animation above already know each other’s MAC address. To learn more about ARP, check out this video.

How does a network switch decide to forward a frame destined for a known unicast MAC address?

A switch compares the destination address to the MAC address table. If a matching entry is found, the switch knows out which interface to forward the frame. If no matching entry is found, the switch floods the frame.

Which forwarding action does a switch take when the destination MAC address of an Ethernet frame is an unknown unicast?

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.

How does a switch identify the MAC address?

At the center of the learning function is a part of the switch's memory. We refer to this memory location as the MAC Address Table. 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.

What happens when a switch needs to forward an Ethernet frame with a destination MAC address that it does not know?

If the destination MAC address is not known by a switch, then the packet will be flooded to all unblocked ports.

Toplist

Neuester Beitrag

Stichworte