trickle code propagation and maintenance in wireless
play

Trickle: Code Propagation and Maintenance in Wireless Sensor - PowerPoint PPT Presentation

Trickle: Code Propagation and Maintenance in Wireless Sensor Networks Philip Levis Scott Shenker Neil Patel David Culler UC Berkeley UC Berkeley UC Berkeley UC Berkeley Intel Berkeley ICIR Intel Berkeley Embedded Sensor Networks 36m


  1. Trickle: Code Propagation and Maintenance in Wireless Sensor Networks Philip Levis Scott Shenker Neil Patel David Culler UC Berkeley UC Berkeley UC Berkeley UC Berkeley Intel Berkeley ICIR Intel Berkeley

  2. Embedded Sensor Networks 36m 33m: 111 32m: 110 30m: 109,108,107 20m: 106,105,104 10m: 103, 102, 101

  3. Sensor Network Behavior

  4. Problem Statement • Sensor network characteristics – Long lifetimes – Embedded and unreachable – Large numbers – Transient, lossy networks • Changes to running code are inevitable • Need to efficiently – Rapidly propagate new code into a network – Cheaply maintain a consistent code image

  5. Trickle • Simple, “polite gossip” algorithm • “Every once in a while, broadcast what code you have, unless you’ve heard some other nodes broadcast the same thing.” • Behavior (simulation and deployment): – Scalability: thousand-fold density changes – Maintenance: a few sends per hour – Propagation: less than a minute

  6. Outline • Problem statement • Trickle algorithm • Maintenance • Propagation • Future Work

  7. Trickle Assumptions • Broadcast medium • Concise, comparable metadata • Metadata is the significant cost – 1 packet/minute for a day is 1440 messages – Equivalent to a 40K code image – Code will often be small: parameters, etc.

  8. Communication • As long as each mote communicates with one other, inconsistencies will be found • Transmission or reception • Maintain a lower communication bound over time: ( receptions + transmissions ) <= k • The closer to k , the better (efficiency)

  9. Trickle Algorithm • Time interval of length t • Redundancy constant k (e.g., 1, 2) • Pick a time t from [0, t ] • Maintain a counter c • At time t , transmit code metadata if c < k • Increment c when you hear identical metadata to your own • At end of t , pick a new t

  10. Example Trickle Execution, k = 1 A t 1 t 2 B t 1 t 2 C t 1 t 2 t time transmission reception suppressed transmission

  11. Outline • Problem statement • Trickle algorithm • Maintenance • Propagation • Future Work

  12. Maintenance Evaluation • Start with three assumptions, relax each – Lossless cell – Perfect synchronization – Single cell • Single, lossless, synchronized cell – k transmissions per interval – First k nodes to transmit suppress all others – Independent of density • In experiments (unless said otherwise), k =1

  13. Loss 12 10 Transmissions/Interval 8 60% 40% 6 20% 0% 4 2 0 1 2 4 8 16 32 64 128 256 Motes

  14. Logarithmic Behavior of Loss • Transmission increase is due to the probability that one node has not heard n transmissions • Example: 10% loss – 1 in 10 nodes will not hear one transmission – 1 in 100 nodes will not hear two transmissions – 1 in 1000 nodes will not hear three, etc. • Fundamental bound to maintaining per- interval communication

  15. Synchronization 14 12 Transmissions/Interval 10 8 Not Synchronized Synchronized 6 4 2 0 1 2 4 8 16 32 63 128 256 Motes

  16. Short Listen Effect • Lack of synchronization leads to the “short listen effect” • For example, B transmits three times: t A B C D Time

  17. Solution • Add a listening period: t from [0.5 t , t ] Listen-only period

  18. Effect of Listen Period 14 12 Transmissions/Interval 10 Not Synchronized 8 Synchronized 6 Listening 4 2 0 1 2 4 8 16 32 63 128 256 Motes

  19. Multi-Cell Case • TOSSIM simulation – No synchronization – Loss sampled from empirical models – Nodes uniformly distributed in 50’x50’ area • Logarithmic scaling holds 16 14 Transmissions/Interval 12 10 8 6 4 2 0 1 2 4 8 16 32 64 128 256 Hidden Terminal Motes No Hidden Terminal

  20. Empirical Validation • Redundancy: ( transmissions + receptions ) - k intervals Efficiency over Density 1.6 1.4 1.2 Efficiency 1 0.8 0.6 0.4 0.2 0 1 2 4 8 16 32 64 Empirical Motes Simulated

  21. Outline • Problem statement • Trickle algorithm • Maintenance • Propagation • Future Work

  22. Speeding Propagation • Adjust t : t l , t h • When t expires, double t up to t h • When you hear newer metadata, set t to t l • When you hear newer code, set t to t l • When you hear older metadata, send code – Blind transmission at 1, 3, and 7 seconds – Could use Trickle for suppression as well

  23. Rate Change Illustration Hear Newer Metadata 2 t l t h t l t h t h 2 Time

  24. Empirical Propagation • Deployed 19 nodes in office setting • Instrumented nodes for accurate time measurements • Introduce new code, log installation times • k=1, t l =1 second, t h =1 minute • 40 test runs

  25. Network Layout

  26. Empirical Results Time to Complete Propagation Propagation Time Distribution 70 35.00% 30.00% 60 25.00% 50 20.00% Time (seconds) Motes 40 15.00% 30 10.00% 20 5.00% 0.00% 10 0 5 10 15 20 25 30 35 40 45 Time (seconds) 0

  27. Conclusions • Trickle efficiency scales logarithmically with density • Can obtain rapid propagation with low maintenance – At most 3 sends/hour, propagates in 30 seconds • Uses beyond code propagation – Changes to data such as routing tables – E.g., predicates can scope distance • Further examination of t l , t h and k needed

  28. Questions

  29. Multi-cell Case, Simulated 16 14 Transmissions/Interval 12 10 8 6 4 2 0 1 2 4 8 16 32 64 128 256 Hidden Terminal Motes No Hidden Terminal

  30. Empirical Scaling • Nodes evenly spaced on a table • Very low signal strength for packet loss

  31. Simulated Propagation • TOSSIM, 20x20 node grid • Change spacing between nodes • k=1, t l =1 second, t h =1 minute

  32. Time To Reprogram, Tau, 5 Foot Spacing (seconds) 16-18 14-16 12-14 10-12 8-10 6-8 4-6 2-4 0-2

  33. Time To Reprogram, Tau, 10 Foot Spacing (seconds) 18-20 16-18 14-16 12-14 10-12 8-10 6-8 4-6 2-4 0-2 Time

  34. Time To Reprogram, Tau, 15 Foot Spacing (seconds) 45-50 40-45 35-40 30-35 25-30 20-25 15-20 10-15 5-10 0-5 Time

  35. Time To Reprogram, Tau, 20 Foot Spacing (seconds) 56-64 48-56 40-48 32-40 24-32 16-24 8-16 0-8 Time

  36. Changing t h to 20 minutes k=1 k=2 70 70 60 60 50 50 Time (seconds) Time (seconds) 40 40 30 30 20 20 10 10 0 0

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend