How Bridges Learn MAC Addresses

Bridges perform three main functions, as mentioned earlier. One of those key functions is to learn the MAC addresses in the network to build its bridging table. With a full, accurate bridging table, the bridge can make accurate forwarding and filtering decisions.

Bridges build the bridge table by listening to incoming frames and examining the source MAC address in the frame. If a frame enters the bridge and the source MAC address is not in the bridge table, the bridge creates an entry in the table. The MAC address is placed into the table, along with the interface in which the frame arrived. Bridge learning logic is that simple.

Figure 9-4 depicts the same network as Figure 9-3, but before the bridge has built any bridge table entries. In the figure, the first two frames sent in this network are shown—first a frame from Fred, addressed to Barney, followed by Barney's response, addressed to Fred.

Figure 9-4 Bridge Learning: Empty Table and Adding Two Entries

0200 1111 1111^^ I learned Fred's MAC when he sentL P . f frame 1-

0200.2222.2222 Barney

0200.3333.3333 Wilma

Figure 9-4 Bridge Learning: Empty Table and Adding Two Entries

0200.3333.3333 Wilma

0200 1111 1111^^ I learned Fred's MAC when he sentL P . f frame 1-

0200.2222.2222 Barney

0200.4444.4444 Betty

0200.4444.4444 Betty

Bridge Table: Before Either Frame is sent

Bridge Table: After Frame 1 (Fred to Barney)

Address: Interface

0200.1111.1111 E0

Bridge Table: After Frame 2 (Barney to Fred)

Address: Interface

0200.1111.1111 E0

0200.2222.2222 E0

As seen in the figure, after Fred sends his first frame to Barney, the bridge has an entry for 0200.1111.1111, Fred's MAC address, associated with interface E0. When Barney replies at Step 2, the bridge adds a second entry, this one for 0200.2222.2222, Barney's MAC address. Learning always occurs by looking at the source MAC address in the frame.

0 0

Post a comment