Presentation is loading. Please wait.

Presentation is loading. Please wait.

ECE 544 Protocol Design Project 2016 Nirali Shah Thara Philipson Nithin Raju Chandy.

Similar presentations


Presentation on theme: "ECE 544 Protocol Design Project 2016 Nirali Shah Thara Philipson Nithin Raju Chandy."— Presentation transcript:

1 ECE 544 Protocol Design Project 2016 Nirali Shah Thara Philipson Nithin Raju Chandy

2 Network Architecture & Topology Assumptions ● Service Objective: k-out-of-n “packet datagram” multicast ● Max number of destinations is 3 (N) ● Packet to be delivered to K out of N destinations ● No direct links between end-nodes ● Packet loss probability of p ● Each end node is attached to only one router ● All links have hop cost 1 and same MTU 1500 bytes ●About 50-100 nodes and up to 256 total hosts in the network

3 Network Diagram H1 (Sender) H2 H3 H4 H5 R1 R2 R3 R4 R5 R6 R7 R8 R9 R10 R11 R12 ●Total Number of Nodes = 9 ●Each Link has cost of 1 H6 Optimal multicast path Receivers Router where copy/forward occurs Sender When K=2

4 Addressing Scheme How to address routers and hosts? ●There could be up to 256 end-hosts and up to 100 routers in the network. ●We can use 8 bit addresses (1 byte) for routers and hosts. ●Host network addresses referred to as H1, H2… H255 ●Router network addresses referred to as R1, R2…. R100 ●We can uniquely identify a host by addressing like H1.N1

5 Protocol Concept ●Our Protocol will first find the best “k” (out of N) destinations for a given sender S. ●It then finds the best multicast distribution tree (path) connecting those k destinations such that it minimizes the TOTAL hop cost. ●Multicast packets will have the distribution tree in its header. ●Routers will copy and forward whenever there is a branch in the distribution tree.

6 Protocol Concept ●How to find the best K destinations? Run Dijkstra's algorithm at the sender’s designated router and once the algorithm converges select the first “K” hosts that are directly connected to the routers which are nearest to the sender. ●Once the nearest routers are known, how will we find the nearest “K” hosts? Using centralized mapping server.

7 Centralized Server for Host - Router Mapping RouterNo: of Connected Hosts Connected Hosts R10 -- R20 -- R30 -- R42 D1, D2 R52 D4, D5 R61 D3 ●Gives an idea about the different hosts and the total number of hosts attached to all routers in the network. ●This table is populated from “hello” messages. Each router talks to this server periodically and informs the list and count of connected hosts. ● Cons: More control overhead Centralized mapping server table

8 Finding best K hosts (destinations) RouterNo: of Conne cted Hosts Connec ted Hosts R11 H2 R20 -- R31 H3 R40 -- R40 -- R61 H4 Destinat ion Next Hop Cost R1R3 2 R2 0 R3 1 R4R3 2 R5R3 3 R6R3 4 R7R3 4 R8R3 5 R9R3 5 R10R3 6 R11R3 7 R12R3 6 R2’S Routing Table Centralized Router-Host Mapping Table 1st least cost 2nd least cost Selects H3 Selects H2 Dest : H2, H3

9 Protocol Concept ● How to find the best multicast distribution tree for ‘k’ known destinations? Minimum Steiner tree ● Minimum Steiner Tree Construction Given an undirected weighted graph G(V,E), and a set of nodes S, it finds the minimum cost tree that spans the nodes in S.

10 Protocol Concept Steiner tree computation --> NP-complete problem. KMB approx. Algorithm computes trees that have approximately 5% higher costs than the cost for the minimal Steiner Tree - Nearest optimal solution

11 Protocol Concept ● How KMB works? Starting from a graph G, a complete (every node is connected with every other node) graph G1 is constructed. For G1, a minimal spanning tree (using prim’s algorithm) T1 is constructed The edges in T1 are replaced by the shortest paths in G, which gives a subgraph G2. For G2, a minimal spanning tree T2 is constructed. The branches in T2 that don’t contain nodes that are members of the MC group are pruned.

12 Protocol Concept How every router gets to know about the multicast tree we built at the sender? We can use some encoding scheme - Prufer Sequence Whenever a router get the multicast packet, it checks the prufer sequence and locally computes steiner tree to make the decision. Router duplicates whenever there’s a branch in the tree (can easily be identified from duplicate entries in the prufer sequence. Leaf nodes also. )

13 Protocol Concept Prufer Sequence N nodes to N-2 prufer code

14 Services provided by protocol ●Router and Host Discovery ●Finding K-nearest destinations ●Multicast distribution tree construction ●Multicast packet delivery with ACKs

15 ARQ ●Stop and wait Protocol. ●Sender waits for the the ACK from receiver. ●New packet is only send after sender receives ACK for the previous packet. ●Timeout timer at sender side to ensure packet is received at receiver. ●Receiver stores data packet and ACK in case of packet loss. ●The packets at memory are destroyed when packet with next sequence number is received.

16

17 Protocol Design : SYNTAX & SEMANTICS Packets Structures: ●Hello and Hello ACK packet ●Type: 00 ● Subtype: 0 for Hello Packet, 1 for Hello ACK Packet ●The router connected to the Host receives the Packet and sends an ACK with SRC as its own Address and DEST as the Host’s Address. ●This way each host discovers its default router. TypeSubtypeSeq. NumberSRCDESTPayload

18 ●Routing Hello and ACK ●Type: 01 ● Subtype: 0 for Hello Packet(for router), 1 for Hello ACK Packet(for router) TypeSubtypeSeq. NumberSRCDESTPayload ●Same way the routers send Hello packets to discover their neighbor's in order to exchange LSP packets to implement Dijikstra’s Algorithm.

19 SEQ NUM TYPESubtypeSRCDEST1DEST2DEST3KPRUFER ENCODED SEQ TTL MAX PAYLOAD ●Multicast Data Packet and ACK Type: 10 Subtype: 0 for DATA, 1 for ACK Once a Node receives a packet of a different Sequence Number as well as an ACK of the same SEQ NUM, it flushes the packet. If it receives a packet with the same SEQ NUM again, it sends the ACK to the preceding Node and ignores the packet. Type = 2 (8 bit) for Data Packet Subtype = 0 for Data Packet, 1 for Data Packet ACK SRC(8 bit) = the address of the Node that sends the packet Each Node when receives a packet checks the Prufer Sequence to know whether it has to accept the packet or discard it.

20 ●It puts itself as the SRC and forwards the Packet to the succeeding router in the Prufer Sequence. ●The ACK is sent by the next router to the SRC address only. ●DEST1,DEST2,DEST3=all the possible destinations from which K best destinations have to be found. Here maximum DEST=3(assumption) ●K= Number of Hosts to which the packets are to be sent from N Hosts. ●Prufer Encoded Sequence= Contains the best path calculated by the Steiner Tree. ●Each router decodes the Sequence and takes a decision whether to accept a packet or not,forwards or copies it to the next router in the sequence. ●TTLMAX=Time after which the packet is to be killed. ●It is decremented each time it reaches a node. SEQ NUM TYPESubtypeSRCDEST1DEST2DEST3KPRUFER ENCODED SEQ TTLMA X PAYLO AD

21 ●LSP Packet and ACK The LSP Packet is flooded at the start by all the routers to its neighbours for them to update their Routing Table till the Dijikstra’s Algorithm converges. ●SEQ NUM = Each LSP packet has a unique SEQ NUM. ●Router keeps track of the SEQ NUM and updates its Routing Table periodically. ●If it gets a packet with previous sequence number it discards it as it is not the latest info. SEQ NUMTYPESUBTYPESRCPAYLOAD

22 ●TYPE =3 for LSP Packet ●SUBTYPE= 0 for LSP packet =1 for ACK of LSP packet ●SRC=The Address of the router which floods the LSP. ●The routers send ACK to the address in the SRC field. ●Each router checks if it gets ACK from all its neighbouring router else resends it if the timer times out. ●Payload= a table with the routers and the costs. Payload Table: DEST: address of all neighbors of the sender of LSP COST: number of hops to reach the neighbors SEQ NUMTYPESUBTYPESRCPAYLOAD DESTCOST

23 ●Each Router will check its ports at the start to check who it is connected to. ●If it identifies a Host address then it will send a packet to the Server to update the Host-Router Mapping Table. ●We assume that the routers and the Host do not fail or change in between. ●Packet and ACK to keep Centralized Server updated TYPESUBTYPESRCSEQ NUMDATA

24 ●TYPE =4 for packets updating server table ●SUBTYPE= 0 for packet = 1 for ACK ●SRC= Address of the router connected to a Host and sending packet to the Server. ●The Server sends an ACK to SRC address. ●SEQ NUM= each packet will have unique sequence number. ●PAcket of same SEQ NUM is discarded. ●DATA= ROUTER= routers address which is connected to one of teh Hosts HOST=address of the Host it is connected to. TYPESUBTYPESRCSEQ NUMDATA ROUTERHOST

25 Packets used TypeSubtypeSeq. NumSRCDESTPayload TypeSubtypeSeq. NumSRCDESTPayload Hello packet and ACK Routing hello and ACK Multicast Data packet and ACK LSP Packet Host to Router mapping packet and ACK SEQ NUM TYPESubtypeSRCDEST1DEST2DEST3KPRUFER ENCODED SEQ TTL MAX PAYLOA D SEQ NUMTYPESUBTYPESRCPAYLOAD TYPESUBTYPESRCSEQ NUMDATA

26 Estimated Size of Packets ●Hello packet and ACK Size: 48 bits, 6 bytes Frequency : 2sec ●Routing hello and ACK Size: 48 bits, 6 bytes Frequency : 2sec ●Multicast Data packet and ACK Size: 180 bits,23 bytes (13 bytes for prufer and rest 9 bytes) 23 bytes + data ●LSP Packet Frequency: Only once if topology is not changing Size: 32 bits +1600 bits(16*100 bits), 204 bytes ●Centralized server packet and ACK Size: If maximum nodes is 5 and if all nodes are connected to 1 router the Max packet size is 2 bytes*5 nodes =10 bytes. Total size= 10 bytes + 4 bytes

27 Example Networks: Network 1 If k=3, D1,D2, and D3 will be the destinations

28 D1 D2 D3 S R1 R2 R3 R4 R5 R6 R7 R1 RT R5 RT R6 RT R7 RT R4 RT

29 Example Networks: Network 2 Show how routing works for message sent to D1,D2,D3

30 S D1 D2 D3 R1 R2 R3 R4 R5 R6 Table :R1 Table:R3 Table: R6 Table:R4

31 Summary of Sequence of Processes ●Address assignment is done for all the Hosts and the Routers. ●Hello packets are sent from all the Hosts to discover their default routers and are sent between the routers to discover their neighbors. ●Update the Centralized Server Table for Router-Host mapping. ●User specifies the Sender Host and the number of destinations (K) ●LSP packets are reliably flooded between the routers. ●Dijkstra's Algorithm is implemented to generate the Routing table at each router and then the “k” nearest hosts are found. ●Steiner tree builds an optimal multicast path of least total cost connecting hosts and k hosts. ●Prufer Sequence is generated for the tree and included in the multicast packet header. ●The Packets are forwarded by making use of prufer sequence and forwarding table at each router.

32 Summary ● Performance ● Highly scalable as we are using Steiner tree ● Lot of overheads (LSP packets, Packets to update centralized server) ● Implementation complexity ● Dijkstra's complexity - O(n^2) ●Steiner tree using Prim’s algorithm - O((|V| + |E|) log |V|) ●Prufer Encoding - O(n log n) or even O(n^2)

33 Thank you


Download ppt "ECE 544 Protocol Design Project 2016 Nirali Shah Thara Philipson Nithin Raju Chandy."

Similar presentations


Ads by Google