yn@uestc.edu.cn1Chapter12MulticastingandMulticastRoutingProtocolsIntroductionMulticastaddressesandIGMPMulticastroutingMulticastroutingprotocolMBONEyn@uestc.edu.cn212.1IntroductionIPUnicasting,IP单播通信OnesourceOnedestinationintheInternetunicastunicastaddressaddressIPMulticasting,IP多播通信OnesourceAgroupofdestinationsintheInternetunicastmulticastaddressaddressIPBroadcasting,IP广播通信OnesourceAllofdestinationsinoneIPnetworkunicastbroadcastaddressaddressyn@uestc.edu.cn3DataLinkLayerPhysicalmulticastsupportMostLANssupportphysicalmulticastaddressingMappingIPmulticastaddressestophysicalmulticastaddressesNophysicalmulticastsupportMostWANsDONOTsupportphysicalmulticastaddressingUsingtunneling(隧道技术)toencapsulatethemulticastIPpacketinaunicastIPpacketOrbeencapsulatedaslinklayerbroadcastyn@uestc.edu.cn4Multicastingvs.MultipleUnicasting•Lessbandwidth•Lessloadofsource•LessdelayMoreefficientyn@uestc.edu.cn5MulticastApplicationsAccesstodistributeddatabase访问分布式数据库Informationdissemination信息传播DisseminationofNews传播新闻Teleconferencing电视会议Distancelearning远程学习yn@uestc.edu.cn612.2MulticastAddressandIGMPMulticastaddressFunction:defineahostgroupIPmulticastaddressesMACmulticastaddressesMappingclassDtoEthernetMACaddressIGMPInternetGroupManagementProtocol网际组管理协议yn@uestc.edu.cn712.2.1IPMulticastAddressAllocation:IANA(RFC3171)ClassD:224.0.0.0~239.255.255.255LocalNetworkControlBlock224.0.0.0/24:224.0.0.0~224.0.0.255NotbeforwardedbyrouterInternetworkControlBlock224.0.1.0/24:224.0.1.0~224.0.1.255MustbeforwardedthroughtheInternetAdministrativelyScopedAddressBlock239.0.0.0/8:239.0.0.0~239.255.255.255类似于私有IP单播地址(如10.0.0.0/8)yn@uestc.edu.cn812.2.2MACMulticastAddressIEEEMACaddressformatStandardGroupMACAddressesAllocation:IEEERegistrationAuthorityIEEE802.1DMACBridgeFilteredMACGroupAddresses01-80-C2-00-00-00~01-80-C2-00-00-0FStandardMACGroupAddresses01-80-C2-00-00-10~01-80-C2-FF-FF-FFOthers-IP-mappedEthernetMACgroupaddresses01-00-5E-xx-xx-xxxxxxxxxxx1xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxbitsyn@uestc.edu.cn912.2.3MappingClassDtoEthernetMACAddressExampleProblem:不明确的MAC地址IP多播地址:MAC多播地址=25:1=32:1例:0x0100.5E01.0101表示32个IP多播地址224.1.1.1,224.128.1.1,225.1.1.1,225.128.1.1,…239.128.1.1239.255.0.101-00-5E-7F-00-011110MulticastID:28bitsLost5bitsPrefix:25bitsMulticastID:23bitsIPmulticastaddressMACaddressPrefixyn@uestc.edu.cn1012.2.4IGMPInternetGroupManagementProtocol网际组管理协议Version1:RFC1112Version2:RFC2236Version3:RFC3376,RFC4604FunctionUsedbetweenhostsandmulticastroutersonasinglephysicalnetworkHelpthemulticastrouterscreateandupdatealistofloyalmembersrelatedtoeachrouterinterfaceNotamulticastroutingprotocol,butinconjunctionwithamulticastroutingprotocoltosupportIPmulticastingyn@uestc.edu.cn11IGMPOperationIGMPoperateslocallyJoiningagroupLeavingagroupMonitoringmembershipyn@uestc.edu.cn1212.3MulticastRoutingObjectivesofmulticastingOptimalroutingMulticastforwardingyn@uestc.edu.cn1312.3.1ObjectivesofMulticastingEverymemberofthegroupshouldreceiveone,andonlyonecopyofthemulticastpacketNonmembersmustnotreceiveacopyTheremustbenoloopsinrouting,thatis,apacketmustnotvisitaroutermorethanonceThepathtraveledfromthesourcetoeachdestinationmustbeoptimalyn@uestc.edu.cn1412.3.2OptimalRouting:ShortestPathTreesShortestpathtreeinunicastroutingEachrouterhasaroutingtablethatdefinesashortestpathtopossibledestinationsRoot:eachrouteritselfLeaf:possibledestinationsShortestpathtreeinmulticastroutingEachinvolvedrouterneedstoconstructashortestpathtreeforeachgroupTwotypesoftrees:source-based,group-sharedyn@uestc.edu.cn15ShortestPathTreeinUnicastRoutingyn@uestc.edu.cn16Flooding,洪泛FloodingisrelatedtobothmulticastingandbroadcastingMethodForwardsapacketoutofallofitsinterfacesexcepttheonefromwhichthepacketcameFeatureProvidebroadcastingCreateloopsandtrafficjams:severalcopiesofthesamepacketarecirculatedyn@uestc.edu.cn17ShortestPathTreeinMulticastRoutingSource-BasedTree源点基准树or有源树EachcombinationofsourceandgrouphasasingletreeEx.:NgroupsandMsourcesNxMtreesNotation:(S,G)——S=多播源IP地址,G=多播组地址Group-SharedTree组共享树or共享树EachgroupsharesthesametreeSteinertree,rendezvous-pointtree(汇集点树,RPT)Ex.:NgroupsNtreesNotation:(*,G)——*=所有的多播源,G=多播组地址yn@uestc.edu.cn18Source-BasedTree主机A主机B主机CR1R2R4R6192.1.1.1192.2.2.2192.3.3.3假设:A、B、C在多播组224.1.1.1中R1R5R3ABC(192.1.1.1,224.1.1.1)R5R3R1BCA(192.1.1.2,224.1.1.1)R3R5yn@uestc.edu.cn19Discuss:(S,G)(S,G):最短路径树(SPT)树根:多播组G的信息源(S)在具体的多播路由协议中,S通常指源子网树叶:多播组G的接收成员(S,G)是单向树多播信息流只能沿树的下行方向传播典型的多播路由协议DVMRP:单播D-V路由选择的扩展MOSPF:单播L-S路由选择的扩展PIM-DM:根据需要使用单播路由选择协议yn@uestc.edu.cn20Group-SharedTree:RPT主机A主机B主机CR1R2R4R6192.1.1.1192.2.2.2192.3.3.3R3R5主机D192.4.4.4根主机E192.5.5.5(*,224.2.2.2)R5R2R4CR6R3BD假设:A、B、C、D、E在多播组224.2.2.2中R1AEyn@uestc.edu.cn21BidirectionalRPT主机A主机B主机CR1R2R4R6192.1.1.1192.2.2.2192.3.3.3假设:A、B、C、D、E在多播组224.2.2.2中R3R5主机D192.4.4.4(*,224.2.2.2)R5R2R1R4CAR6R3EB根主机E192.5.5.5D上行下行yn@uestc.edu.cn22UnidirectionalRPT主机A主机B主机CR1R2R4R6192.1.1.1192.2.2.219