版權說明:本文檔由用戶提供并上傳,收益歸屬內(nèi)容提供方,若內(nèi)容存在侵權,請進行舉報或認領
文檔簡介
1、1,第9講 路由與組播,Routing modules in ns-2,2,講課內(nèi)容,單播及仿真方法 組播協(xié)議 仿真元件 組播仿真示例,3,1.1 Static Dijkstras SPF,Simulator instproc run $self check-node-num $self rtmodel-configure;# 4 dynamic schemes $self get-routelogic configure $self instvar scheduler_ Node_ link_ started_ set started_ 1 return $scheduler_ run ,S
2、imulator instproc get-routelogic $self instvar routingTable_ if !info exists routingTable_ set routingTable_ new RouteLogic return $routingTable_ ,ns-route.tcl,ns-lib.tcl,4,1.1 Static Dijkstras SPF,Simulator instproc run $self check-node-num $self rtmodel-configure;# 4 dynamic schemes $self get-rout
3、elogic configure return $scheduler_ run ,RouteLogic instproc configure $self instvar rtprotos_ if info exists rtprotos_ foreach proto array names rtprotos_ eval Agent/rtProto/$proto init-all $rtprotos_($proto) else Agent/rtProto/Static init-all ,route-proto.tcl,ns-lib.tcl,$ns rtproto Static $ns rtpr
4、oto Session $ns rtproto DV . $ns rtproto LS .,Simulator proc compute-routes,Simulator proc compute-flat-routes,A pure OTcl class,5,1.1 Static Dijkstras SPF,Simulator instproc compute-flat-routes set r $self get-routelogic $self cmd get-routelogic $r ;# propagate rl in C+ foreach ln array names link_
5、 set L split $ln : set srcID lindex $L 0 set dstID lindex $L 1 if $link_($ln) up? = up $r insert $srcID $dstID $link_($ln) cost? else $r reset $srcID $dstID $r compute set n Node set nn_ $self populate-flat-classifiers $n ,ns-route.tcl,4 each nodes chassifiers,Dijkstra algo. Impl.ed in C+ class,6,1.
6、2 Multipath routing,/tcl/test/test-suite-linkstate.tcl,7,Codes brief,. Node set multiPath_ 1 . $ns link $n2 $n4 cost 2 $ns link $n4 $n2 cost 2 . $ns rtmodel Deterministic .35 .25 $n2 $n4 . $ns rtproto LS .,Default: cost =1,0.5,0.35,0.25,VT,Link State routing,8,2. Properties of multicasting,The most
7、complex service, vs uni-casting and broad-casting Underlined recipients can be over one million,9,Group management,IGMP,IGMP,IGMP,Mcast routing protocols,10,2.1 Internet Group Management Protocol (IGMP),It lets all the systems on a physical network know which hosts currently belong to which multicas
8、t groups. Format of datagram is similar to ICMP with constant length, IP header + IGMP message (8 bytes). Support joining, querying and reporting functions.,11,An example (v1. RFC 1112),The router is asking each host to identify each group on that interface.,Multicast Router,Host,IGMP query, TTL=1 I
9、GMP group addr =0 Dest IP addr = 224.0.0.1(all-hosts group) Src IP addr = routers IP addr,IGMP report, TTL=1 IGMP group addr = group addr Dest IP addr = group addr Src IP addr = hosts IP addr,12,2.2 Flood and Prune Protocols,known as reverse-path multicast algorithm. DVMRP (Distance Vector Multicast
10、 Routing Protocol) and Dense-mode PIM (Protocol Independent Multicast).,prune,prune,Routers not on the delivery tree need to store prune state.,13,2.3 Center-based Trees,To map the multicast group address to a particular unicast address of a router, and build explicit distribution trees centered aro
11、und this particular router. Core-Based Trees (CBT), Sparse-mode PIM (SM-PIM) and the Border Gateway Multicast Protocol (BGMP).,14,Formation of a CBT bidirectional shared tree,CBT never properly solved the problem of how to map a group address to the address of a core. Good core placement is a hard p
12、roblem. So, ,15,Sparse-Mode PIM,Rendezvous Point (RP), is the equivalent of a CBT Core and largely serves the same purpose,16,Summary of multicast routing,Dense mode DVMRT, MOSFP, PIM-DM Sparse mode CBT, PIM-SM Scalable and reliable multicast (SRM) S.Floyd etal 95, by ns-2,17,2.4 SRM, motivation,ACK
13、,NACK,NACK-storm,18,SRM scheme,Randomize NACKs (request repairs) All traffic including request repairs and repairs are multicast A repair can be sent by any node that heard the request A node suppresses its request repair if another node has just sent a request repair for the same data item A node s
14、uppresses a repair if another node has just sent the repair,19,2.4 SRM, an illustration,NACK,repair,R1,R2,R3,R4,R5,20,3.1 Enable mcast in Nodes,set ns new Simulator multicast on #creating nodes $ns mrtproto .,Node instproc mk-default-classifier Node instvar module_list_ # At minimum we should enable
15、 base module foreach modname Node set module_list_ $self register-module new RtModule/$modname ,Node,module_list_,init,RtModule/Base,RtModule/Mcast,RtModule/Hier,RtModule/Manul,init multicast Node:enable-module Mcast,21,3.2 CtrMcast, a pure OTcl class,set ns new Simulator multicast on #creating node
16、s $ns mrtproto .,Onle 3 protocols supported: CtrMcast (PIM-SM) DM: Dense Mode ST: Shared Tree (CBT?),McastProtocol,CtrMcast,BST,DM,ST,CtrMcastComp,CtrRPComp,ctrrpcomp,Glist_, Mlist_,Node,mrtObject_,agent_,22,Routing computations,set ns new Simulator multicast on #creating nodes $ns mrtproto . $node join-group $recv $group ,McastProtocol,CtrMcast,BST,DM,ST,CtrMcastComp,ctrrpcomp,Glist_, Mlist_,Node,mrtObject_,agent_,compute-branch,23,CtrMcactComp:compute-branch,S,R,RP,In SPT: dest = S
溫馨提示
- 1. 本站所有資源如無特殊說明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請下載最新的WinRAR軟件解壓。
- 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請聯(lián)系上傳者。文件的所有權益歸上傳用戶所有。
- 3. 本站RAR壓縮包中若帶圖紙,網(wǎng)頁內(nèi)容里面會有圖紙預覽,若沒有圖紙預覽就沒有圖紙。
- 4. 未經(jīng)權益所有人同意不得將文件中的內(nèi)容挪作商業(yè)或盈利用途。
- 5. 人人文庫網(wǎng)僅提供信息存儲空間,僅對用戶上傳內(nèi)容的表現(xiàn)方式做保護處理,對用戶上傳分享的文檔內(nèi)容本身不做任何修改或編輯,并不能對任何下載內(nèi)容負責。
- 6. 下載文件中如有侵權或不適當內(nèi)容,請與我們聯(lián)系,我們立即糾正。
- 7. 本站不保證下載資源的準確性、安全性和完整性, 同時也不承擔用戶因使用這些下載資源對自己和他人造成任何形式的傷害或損失。
最新文檔
- 廟灘村財務制度
- 道教場所財務制度
- 混凝土生產(chǎn)單位財務制度
- 安全管理協(xié)會財務制度
- 汽修財務制度范本
- 重要財務制度
- 內(nèi)部報銷制度
- 關于環(huán)境法規(guī)制度
- 公文抄襲整治制度
- 施工現(xiàn)場施工防高空墜物制度
- 2026年安徽皖信人力資源管理有限公司公開招聘宣城市涇縣某電力外委工作人員筆試備考試題及答案解析
- 2026中國煙草總公司鄭州煙草研究院高校畢業(yè)生招聘19人備考題庫(河南)及1套完整答案詳解
- 陶瓷工藝品彩繪師崗前工作標準化考核試卷含答案
- 居間合同2026年工作協(xié)議
- 醫(yī)療機構信息安全建設與風險評估方案
- 化工設備培訓課件教學
- 供熱運行與安全知識課件
- 2026年及未來5年市場數(shù)據(jù)中國3D打印材料行業(yè)發(fā)展前景預測及投資戰(zhàn)略數(shù)據(jù)分析研究報告
- 2026年長沙衛(wèi)生職業(yè)學院單招職業(yè)技能考試題庫及答案詳解1套
- 煤礦三違行為界定標準及處罰細則
- 服裝廠安全生產(chǎn)責任制度制定
評論
0/150
提交評論