Date: Thursday, March 6th, 2003 5:31 p.m. on Wes Montgomery's birthday From: Mark Jacobson To: 810-023-01@uni.edu Subject: Bridges, MAC addresses, routing tables, pipes, input/output redirect Hi 023 students, Here are the Fall 2002 quiz questions I showed you in class on Tuesday, plus one additional one you did not see: 3. What does a bridge (or switch) do with a packet whose destination address and whose source address both do not exist in the bridge's routing table? a. Describe everything that happens to the packet? b. Describe how the bridge will be different afterwards. -------------------------------------------------------------------------- Finally, the routing table for a bridge, we covered in class on Wednesday during the review section. 3. What does a bridge (switch) do with a packet whose destination address and whose source address both do not exist in the bridge's routing table? a. Describe everything that happens to the packet? Hard to do here without drawing a diagram. I will try. Computers A1 to A88 # # B R I D G E # R G =====port A====I D==== port C======Computers C1 to C125 D I G R E G D I R B # # port B # #============= computers B1 to B50 Suppose the packet is from computer A1 and it to computer B8. The packet comes in on port A to the bridge. The bridge looks in its routing table and does not see the address B8, so the bridge sends it out both port B and port C. It send it out all of the ports, except the incoming port. Obviously, the port it came in on does not need to have the packet on its ethernet cable again, as all those computers got to "see" the packet as it went by. But both the subnetwork areas B and C will have to deal with the traffic of this packet on their information highways (or side streets, it is just part of a LAN, after all, and not out on the Internet with its Information Superhighways). So the packet "crosses" the bridge and is now "traffic" on the B and the C wires. In summary, the packet came in on port A (which has its own network interface card (NIC) or network adapter card (NAC). Each port has its own Network Interface Card or MAC address. And the packet went out or was sent out both port B and port C. We can say one last thing that happened to the packet. Its source address was added to the routing table for the bridge, so now the bridge "knows" that anything destined for the computer with MAC address A1 is going to be sent out port A, if it was received at port B or port C, and is going to be discarded or stopped and NOT let across the bridge, if it comes in to the bridge from port A. The bridge (switch) is learning, right? Hopefully, you are too! :-) b. Describe how the bridge will be different afterwards. The bridge (switch) will have a new entry in its routing table. Mac address Port to get to it ----------- ----------------- A1 A Now, in the Wednesday class we carried this a couple more steps. Suppose next packet is from source A5 to destination A1. Two things happen at the bridge: It receives the packet, examines the destination and sees that the destination is out on the subnetwork of the port where the packet came in, so it will NOT let it cross the bridge and add to the traffic over on either the B or C subnets. It examines the source (return address of sender) and sees that A5's MAC address is not in the routing table. It adds A5 48 bit, 6 byte MAC address to the table. The routing table now looks like this: Mac address Port to get to it ----------- ----------------- A1 A A5 A Now, suppose a packet comes in from C44 to port C and it is destined for A1. What happens? 1. The bridge sees that A1 destination is on a different port that port C, so puts the packet across the bridge. Out you go, little packet, on your way, on the wires coming out of port A. The bridge does NOT put the packet out port B. Just sends it out port A. 2. The bridge sees the origin or source address was C44 and looks in its table and does not find the MAC address C44. So it adds the C44 NIC address and it's now known port to the routing table, which will make it look like this. Mac address Port to get to it ----------- ----------------- A1 A A5 A C44 C Before long, the routing table will be huge and the bridge will know where everything is. If the network breakdown has been well planned and the communications are typical (say A is the Marketing group area, B is Personnel/Management, and C is Sales/Accounting/Payroll/Customer Services, for example), then 80% or so of the packets that are sent out by computers on the A subnetwork area (Marketing) will have destinations on A, so the majority of that traffic will not tie up the LAN information side streets and two lane highways and gravel roads of subnetwork B or C. The network groups will be kept from being flooded by traffic that is now relevant or destined for computers or servers or printers in their group. Truly, a bridge over troubled H O molecules. 2 B R I D G E R G I D D I G R E G D I R B ~~~~~~~~~~~~~~~~~~~~~~~~~~~ <---- Troubled Waters (Sorry, could not resist! Simon and Garfunkle would strongly approve of this bridge, however). Mark Computers A1 to A88 # # B R I D G E # R G =====port A====I D==== port C======Computers C1 to C125 D I G R E G D I R B # # port B # #============= computers B1 to B50 Or a SWITCH over troubled waters, since it has three ports (roads) connected to it. Technically, a bridge has just two ports.