OLD | NEW |
(Empty) | |
| 1 .. include:: replace.txt |
| 2 .. highlight:: cpp |
| 3 |
| 4 Epidemic Routing |
| 5 ---------------- |
| 6 |
| 7 Epidemic Routing protocol is a controlled flooding routing protocol |
| 8 designed specifically for use in multi-hop wireless ad hoc networks |
| 9 of mobile nodes. This routing protocol is designed for intermittent· |
| 10 or sparse networks. Packets are held in the source nodes' buffer until |
| 11 the source node comes into communication range with another node.·· |
| 12 The packets are transmitted to the new node, which becomes a transit· |
| 13 node for those packets. Transit nodes hold all packets received until· |
| 14 they come into range with other nodes, at which point they each send· |
| 15 the other any packets the other doesn't already have. The name "epidemic"· |
| 16 is drawn from the way packets spread virally by communication |
| 17 contact between nodes. At the source and all transit nodes, packets are |
| 18 eventually dropped when the expire or the epidemic routing buffer· |
| 19 becomes full, in which case the oldest packets are dropped. It is· |
| 20 not useful for dense networks since the number of duplicate packets· |
| 21 will be very large. |
| 22 |
| 23 This model was developed by· |
| 24 the `ResiliNets research group <http://www.ittc.ku.edu/resilinets>`_ |
| 25 at the University of Kansas.·· |
| 26 |
| 27 |
| 28 Epidemic Routing Routing Overview |
| 29 ********************************* |
| 30 |
| 31 This implementation is based on the paper titled 'Epidemic Routing |
| 32 for Partially-Connected Ad Hoc Networks.'[#Vahdat]_ |
| 33 |
| 34 In the original paper, the implementation was on top of top of |
| 35 the Internet MANET Encapsulation Protocol (IMEP) layer, |
| 36 which is responsible for notifying the epidemic agent |
| 37 when a new node comes into radio range. However, since IMEP |
| 38 is not implemented in |ns3|, a beacon mechanism is added to the implementation. |
| 39 |
| 40 |
| 41 Useful parameters |
| 42 ================= |
| 43 |
| 44 Epidemic routing supports these options: |
| 45 |
| 46 +-----------------------+-----------------------------------+---------------+ |
| 47 | Parameter | Description | Default | |
| 48 +=======================+===================================+===============+ |
| 49 | HopCount | Maximum number of hops a packet | 64 | |
| 50 | | can be forwarded through. | |· |
| 51 | | HopCount serves a similar | | |
| 52 | | function to TTL, but the 8-bit | | |
| 53 | | range of TTL is too small, so we | | |
| 54 | | use a 32-bit field as in | | |
| 55 | | the paper. | | |
| 56 +-----------------------+-----------------------------------+---------------+ |
| 57 | QueueLength | Maximum number of packets that | 64 | |
| 58 | | can be stored in Epidemic buffer | | |
| 59 +-----------------------+-----------------------------------+---------------+ |
| 60 | QueueEntryExpireTime | Maximum time a packet can live | | |
| 61 | | since generated at the source. | Seconds(100) | |
| 62 | | Network-wide synchronization | | |
| 63 | | is assumed. | | |
| 64 +-----------------------+-----------------------------------+---------------+ |
| 65 | HostRecentPeriod | Time in seconds for host recent | | |
| 66 | | period, in which hosts can not | Seconds(10) | |
| 67 | | re-exchange summary vectors. | | |
| 68 +-----------------------+-----------------------------------+---------------+ |
| 69 | BeaconInterval | Mean time interval between sending| Seconds(1) | |
| 70 | | beacon packets. | | |
| 71 +-----------------------+-----------------------------------+---------------+ |
| 72 | BeaconRandomness | Random number of milliseconds | 100 | |
| 73 | | added at the beginning | | |
| 74 | | of the BeaconInterval to avoid | | |
| 75 | | collisions. | | |
| 76 +-----------------------+-----------------------------------+---------------+ |
| 77 |
| 78 |
| 79 Dropping Packets |
| 80 ================ |
| 81 Packets, stored in buffers, are dropped if they exceed HopCount, they are |
| 82 older than QueueEntryExpireTime, or the holding buffer exceed QueueLength.·· |
| 83 |
| 84 |
| 85 Helper |
| 86 ****** |
| 87 |
| 88 To have a node run Epidemic Routing Protocol, the easiest way would be to use· |
| 89 the EpidemicHelper |
| 90 in your simulation script. For instance (assuming ``mainNodes``· |
| 91 is a ``NodeContainer``):: |
| 92 |
| 93 EpidemicHelper epidemic; |
| 94 mainNodes.Install (epidemic, adhocNodes); |
| 95 |
| 96 This will run the epidemic routing using the default values. To use· |
| 97 different parameter values:: |
| 98 |
| 99 EpidemicHelper epidemic; |
| 100 epidemic.Set ("HopCount", UintegerValue (20)); |
| 101 epidemic.Set ("QueueLength", UintegerValue (100)); |
| 102 epidemic.Set ("QueueEntryExpireTime", TimeValue (Seconds (60))); |
| 103 epidemic.Set ("BeaconInterval", UintegerValue (5)); |
| 104 mainNodes.Install (epidemic, adhocNodes); |
| 105 |
| 106 |
| 107 Examples |
| 108 ******** |
| 109 First example creates an N-node wireless network, which is set by· |
| 110 default to 10 nodes. The mobility model can be either static Grid· |
| 111 or Randomwaypoint, which by default is selected to be Grid. |
| 112 The data traffic is generated using OnOff application and received· |
| 113 by PacketSink. There is one source and one sink in this configuration. |
| 114 One example can be found in ``src/epidemic/examples/epidemic-example.cc``·· |
| 115 |
| 116 This example creates the scenarios presented in the paper.· |
| 117 [#Vahdat]_ We have 50 nodes in an area of 1500 m x 300 m.· |
| 118 45 nodes are selected to send a packet of size 1KB to the other 44 nodes.· |
| 119 The total packets are 45 * 44 = 1980 packets. The buffer size is 2000· |
| 120 which can hold all packets in each simulation. The ranges for the transmission· |
| 121 are from 10 m to 250 m while the default is set to 50 m.· |
| 122 The example can be found in ``src/epidemic/examples/epidemic-benchmark.cc`` |
| 123 |
| 124 |
| 125 Validation |
| 126 ********** |
| 127 |
| 128 This model has been tested as follows: |
| 129 |
| 130 * Unit tests have been written to verify the internals of Epidemic. This can· |
| 131 be found in ``src/epidemic/test/epidemic-test-suite.cc``. These tests verify· |
| 132 whether the methods inside Epidemic module which deal with packet buffer,· |
| 133 headers work correctly. |
| 134 |
| 135 LIMITATIONS· |
| 136 *********** |
| 137 Epidemic does not work with more than one address per each interface. Additiona
l· |
| 138 addresses are ignored.· |
| 139 |
| 140 Epidemic routing protocol assume many beacons are exchanged in the time nodes· |
| 141 are in range. If not, packets will not be delivered. |
| 142 |
| 143 |
| 144 References |
| 145 ********** |
| 146 |
| 147 .. rubric:: Footnotes |
| 148 |
| 149 .. [#Vahdat] Amin Vahdat and David Becker, "Epidemic Routing for |
| 150 Partially-Connected Ad Hoc Networks," Duke University, Technical |
| 151 Report CS-200006, http://issg.cs.duke.edu/epidemic/epidemic.pdf |
OLD | NEW |