Title: Data Storage Schemas in Sensor Networks
1Data Storage Schemas in Sensor Networks
- Presenter Chengdu Huang
- 09-16-2002
2Data-Centric Storage in Sensornets S.
Ratnasamy, D. Estrin, R. Govindan, B. Karp,
S. Shenker, L. Yin and F. Yu (2002) GPSR Greedy
Perimeter Stateless Routing for Wireless Network
B. Karp and H. Kung (Mobicom2000)
3Outline
- Background
- Network model assumptions
- Existing schemas
- Data-centric storage
- Extensions
- Performance
- Discussion
4Data in a Sensor Network
- What kind of data reside in sensor networks?
- Data Storage
- What, where and how?
- Others (how long, consistency etc.)
- Subject to resource limitations
- Communication bandwidth
- Power consumption
- Computation capability
5Network Model Assumptions
- Randomly, evenly spread out
- Fairly dense
- Location service
- Stationary and stable
- Nodes are peers
6Observations/Events/Queries
- Observation
- Low-level output from sensors
- Event
- Constellations of low-level observations
- E.g. fire, intruder
- Clients use Queries to elicit event information
from sensor network - E.g. Locations of fires in the network
- E.g. Images of intruders detected
7Possible Approaches
- External Storage (ES)
- Local Storage (LS)
- Data-Centric Storage (DS)
- Directed Diffusion
- Geographically Targeted
8External Storage (ES)
Base station
9ES Problems
10Local Storage (LS)
11Local Storage (LS)
12Data-Centric Storage (DCS)
- Data-Centric data are named
- Event data are stored, by name, at some home
nodes. - Queries also go to the home nodes instead of
the nodes detected events
13The Big Picture
- Based on geographic routing (Karp) and P2P lookup
algorithm (Ratnasamy)
14Distributed Hash Table (DHT)
- void Put(key, value)
- Stores value to home node in the sensor
networks according to key - Value Get(key)
- Retrieve value from home node in the sensor
networks according to key
15DCS Example Revisit
(11, 28)
(11,28)Hash(elephant)
16DCS Example
Get(elephant)
(11, 28)
(11,28)Hash(elephant)
17DCS Example
elephant
fire
18Properties of DHT
- Distributed Hash Function
- Known to everybody
- Every home node takes care of roughly the same
amount of event types - Evenly distributed geographically
- Candidate Message Digest Algorithms
- Such as SHA-1, MD5
19DHT - Example
Elephant
(11, 28)
MD5
Mapping to Area
5a76e813d6a0a40548b91acc11557bd2
20GPSR
- Location service required
- Send(value, x, y)
- Nodes know identifications and positions of their
neighbors - Greedy forwarding
- Packets are greedily forwarded to neighbor
closest to destination coordinates - Perimeter forwarding
21GPSR Greedy Forwarding
22GPSR - Void
23GPSR Perimeter Forwarding
Right Hand Rule Each node to receive a packet
forwards the packet to the next link
counterclockwise about itself from the ingress
link
2
X
Z
3
1
Y
24GPSR Perimeter Forwarding
Right Hand Rule Each node to receive a packet
forwards the packet to the next link
counterclockwise about itself from the ingress
link
25Comparison Study
- Metrics
- Total Messages
- total packets sent in the sensor network
- Hotspot Messages
- maximal number of packets sent by any particular
node
26Comparison Study contd
- DCS is preferable if
- Sensor network is large
- Dtotal gtgt maxDq, Q
- Summaries are used
27Problems with DCS
- Not robust enough
- Home nodes could fail
- Nodes could move (new home node?)
- Not scalable
- Home nodes could become communication bottleneck
- Storage capacity of home nodes
28Solutions
- Perimeter Refresh Protocol
- Extension for robustness
- Handles nodes failure and topology change
- Structured Replication
- Extension for scalability
- Load balance
29Perimeter Refresh Protocol
(replica)
(replica)
E
D
- Key stored at location L.
- Home node A.
- Replicas D and E on the home perimeter
L
F
A
(home)
C
B
30Perimeter Refresh Protocol
(replica)
(replica)
E
D
- Some time after node A fails, replica D
initiates a fresh for L
L
F
C
B
31Perimeter Refresh Protocol
(replica)
(replica)
E
- Node F becomes the new home node
- Node F recruits replicas B, C, D and E
D
L
F
(home)
C
(replica)
B
(replica)
32Structured Replication
- Home node -gt Root (4d-1) mirror images for a
given hierarchy depth - Storage cost reduces
- O(N 1/2) -gt O(N 1/2/2d)
- Query cost increases
- O(N 1/2) -gt O(2dN 1/2)
33Performance
- Metrics
- Total Usage total packets sent in the sensor
network - Hotspot Usage maximal number of packets sent by
any particular node - Map to energy consumption
34Performance contd
Total Messages, varying queries
35Performance contd
Hotspot Messages, varying queries
36Performance contd
Total Messages, varying network size
37Discussion
- Related Works
- Distributed database approach
- DataSpace
- COUGAR
- Data-centric routing/in-network aggregation
- Directed Diffusion
- Building Efficient Wireless Sensor Networks with
Low-level Naming (SOSP 2001) - Modeling Data-Centric Routing in Wireless Sensor
Networks (INFOCOM 2002) - Tiny AGgregation
38Discussion contd
- Critiques
- Data consistency in storages
- Oversimplified summary
- Tradeoff of extensions not evaluated
- Ignored event data size as a factor impacts
performance
39Our Extension
- Modified Schema
- Instead of sending the raw event data to home
nodes, nodes just send links to themselves to the
home nodes - Clients contact home node to get the locations of
events first, then contact the nodes and get the
event data there - Tradeoff
- Total amount of data sent through the the network
is greatly reduced - Another indirection
40Our extension - Performance