How switches learn hosts’ locations
How switches learn hosts’ locations In the figure, four hosts are attached to a switch. The switch has nothing in the MAC address table when it is powered on. The figure shows the switch’s MAC filter table after each device has communicated with the switch. The following steps show how the table is populated: 1. Station 1 sends a frame to station 3. Station 1 has a MAC address of 0000.8c01.1111. Station 3 has a MAC address of 0000.8c01.3333. 2. The switch receives the frame on Ethernet interface 0/1, examines the source and destination MAC addresses, and places the source address in the MAC address table. 3. Because the destination address is not in the MAC database, the frame is forwarded out of all interfaces; this is called flooding. 4. Station 3 receives the frame and responds to station 1. The switch receives this frame on interface E0/3 and places the source hardware address in the MAC database. 5. The switch knows the interface associated with station 1’s MAC address and forwards the frame only out of that interface. Effectively, station 1 and station 3 now have a point-topoint connection, and only those two devices will receive the frames. Stations 2 and 4 do not see the frames. If the two devices do not communicate with the switch again within a certain time limit, the switch flushes the entries from the database to keep the database as current as possible. Forwarding/Filtering Decision The layer 2 switch also uses the MAC filter table to both forward and filter frames received on the switch. This is called the forwarding and filtering decision . When a frame arrives at a switch interface, the destination hardware address is compared to the forward/filter MAC database. If the destination hardware address is known and listed in the database, the frame is sent out only E0/1 E0/3 E0/2 E0/4 0000.8c01.1111 0000.8c01.2222 0000.8c01.3333 0000.8c01.4444 1 3 2 4 Station 1 sends a frame to station 3. Destination is known; frame is not flooded. E0/1: 0000.8c01.1111 E0/2: 0000.8c01.2222 E0/3: 0000.8c01.3333 E0/4: 0000.8c01.4444
271 times read
|
|
|
Did you enjoy this article?
(total 0 votes)
|