peer-to-peer spatial queries in sensor networks murat demirbas hakan ferhatosmanoglu the ohio state...

30
Peer-to-Peer Spatial Queries in Sensor Networks Murat Demirbas Hakan Ferhatosmanoglu The Ohio State University

Post on 20-Dec-2015

220 views

Category:

Documents


1 download

TRANSCRIPT

Page 1: Peer-to-Peer Spatial Queries in Sensor Networks Murat Demirbas Hakan Ferhatosmanoglu The Ohio State University

Peer-to-Peer Spatial Queries in Sensor Networks

Murat Demirbas

Hakan Ferhatosmanoglu

The Ohio State University

Page 2: Peer-to-Peer Spatial Queries in Sensor Networks Murat Demirbas Hakan Ferhatosmanoglu The Ohio State University

Sensor networks

• A sensor node:

8K RAM, 4Mhz processor magnetism, heat, sound, vibration, infrared wireless communication up to 200 feet costs ~$10 (right now costs $100)

• Applications include:

ecology monitoring, precision agriculture military and surveillance

• In OSU, we developed a tracking service for DARPA-NEST

classify trespassers as car, soldier, civilian report the tracking information to a base-station (laptop) for

visualization

Page 3: Peer-to-Peer Spatial Queries in Sensor Networks Murat Demirbas Hakan Ferhatosmanoglu The Ohio State University

Spatial queries in sensor networks

• The primary goal of sensor networks is to monitor spatial information about a region of interest

Nearest neighbor (NN) queries are essential :

What is the location of the nearest data object to (x,y) ?

• Database systems

R-tree for efficient execution of nearest neighbor queries

Page 4: Peer-to-Peer Spatial Queries in Sensor Networks Murat Demirbas Hakan Ferhatosmanoglu The Ohio State University

Challenges in sensor networks

• energy constrained nodes, network contention :

programs should avoid excessive communication centralized programs are not suitable work in database systems not readily applicable

• faults :

data is noisy nodes fail in complex ways on site maintenance is not feasible

self-healing programs are needed

Page 5: Peer-to-Peer Spatial Queries in Sensor Networks Murat Demirbas Hakan Ferhatosmanoglu The Ohio State University

P2P spatial queries in sensor networks

• Pursuer- evader tracking

• A pursuer should be able to query a node for the location of the closest evader

• Every node is a peer : – each node (not only the base-

station) can insert a query

– each node can participate in the processing of the query

• query is processed as local as possible

Page 6: Peer-to-Peer Spatial Queries in Sensor Networks Murat Demirbas Hakan Ferhatosmanoglu The Ohio State University

Our contributions

We present a peer-to-peer query processing system where

only the relevant nodes for the correct execution of the query

are involved in the query execution (for minimizing energy and

response time)

the indexing structure, peer-tree, is self-stabilizing (for

achieving eventually correct answers in the presence of faults)

Page 7: Peer-to-Peer Spatial Queries in Sensor Networks Murat Demirbas Hakan Ferhatosmanoglu The Ohio State University

Outline

• Model

• Peer-tree structure

• P2P nearest neighbor queries

• Pursuer – evader tracking revisited

• Conclusions

Page 8: Peer-to-Peer Spatial Queries in Sensor Networks Murat Demirbas Hakan Ferhatosmanoglu The Ohio State University

Model

Geometric network model (2-D) Connected graph; duplex links Transient faults Maximal parallelism in node actions

Page 9: Peer-to-Peer Spatial Queries in Sensor Networks Murat Demirbas Hakan Ferhatosmanoglu The Ohio State University

Outline

• Model

• Peer-tree structure

• P2P nearest neighbor queries

• Pursuer – evader tracking revisited

• Conclusions

Page 10: Peer-to-Peer Spatial Queries in Sensor Networks Murat Demirbas Hakan Ferhatosmanoglu The Ohio State University

CB

R-tree structure

• Approximately balanced tree• A node holds n to 2n (c,mbr)

pairs :– c is the child pointer

– mbr is the minimum bounding rectangle (MBR) of all rectangles at c

• Rectangles at any level may be overlapping

• Every descending path in the tree is a sequence of nested rectangles with the last one containing the actual data

AE

FD

G

H

F E D G H

B C

A .

x

y

Page 11: Peer-to-Peer Spatial Queries in Sensor Networks Murat Demirbas Hakan Ferhatosmanoglu The Ohio State University

Peer-tree construction

• Hierarchical partitioning of a sensor network based on the number of nodes (n to 2n) contained at each cluster

every node cooperates at level 1 of the partitioning

only clusterheads of level i cooperate for level i+1

• Every node v maintains

l.v : highest level of construction v has cooperated p.v(i), 0<i=<l.v : parent of v at level i c.v(i), 0<i=<l.v : children of v at level i mbr.v(i) : MBR of v(i) calculated using c.v(i) Peer-tree is the tree that c pointers embed over the network

• Two actions Join/form cluster Split a cluster

Page 12: Peer-to-Peer Spatial Queries in Sensor Networks Murat Demirbas Hakan Ferhatosmanoglu The Ohio State University

Join/form a cluster

v executes a join/form cluster action if l.v=i yet p.v(i)=nil

• v searches for a node with l= i+1, at increasingly larger radii :

if such a node is encountered v joins that node’s cluster

• Else, if v encounters n nodes with l=i during its search :

v waits for a random time (to avoid formation of multiple clusters that are concurrently started by multiple nearby nodes)

if v is not contacted within this wait, v forms a cluster

p.v(i)=v, l.v=i+1,

c.v(i+1) is set, mbr.v(i+1) is calculated

Page 13: Peer-to-Peer Spatial Queries in Sensor Networks Murat Demirbas Hakan Ferhatosmanoglu The Ohio State University

Split cluster

• During concurrent executions of join/form cluster action by

multiple nodes, a level i clusterhead v may end up with > 2n

children

• v assigns extra level i clusterheads among its children and

ensures that each cluster has n to 2n nodes

Page 14: Peer-to-Peer Spatial Queries in Sensor Networks Murat Demirbas Hakan Ferhatosmanoglu The Ohio State University

Peer-tree

Page 15: Peer-to-Peer Spatial Queries in Sensor Networks Murat Demirbas Hakan Ferhatosmanoglu The Ohio State University

Self-stabilization of peer-tree

• v’s i’th level cluster is collapsed if:

c.v(i)<n, or

there is a node u in c.v(i) s.t.,

u mbr.v(i), or p.u v

• the nodes in the collapsed cluster join neighboring clusterheads or form their clusters

Page 16: Peer-to-Peer Spatial Queries in Sensor Networks Murat Demirbas Hakan Ferhatosmanoglu The Ohio State University

Outline

• Model

• Peer-tree structure

• P2P nearest neighbor queries

• Pursuer – evader tracking revisited

• Conclusions

Page 17: Peer-to-Peer Spatial Queries in Sensor Networks Murat Demirbas Hakan Ferhatosmanoglu The Ohio State University

NN queries over traditional R-tree

The search starts from the root (highest) level, and performs a traversal of the relevant MBRs

• The MBRs that are guaranteed not to have the closest data point are pruned

e.g., MINDIST, the shortest possible distance from a point in an

MBR to (x,y), is larger than the current candidate for NN

• At every iteration, the algorithm

sorts the MBRs with respect to their MINDIST,

considers the first item in the list, expands its children, and inserts them to the list for processing

Page 18: Peer-to-Peer Spatial Queries in Sensor Networks Murat Demirbas Hakan Ferhatosmanoglu The Ohio State University

P2P NN queries over Peer-tree

Any node in the network can submit an NN query concerning any coordinate (x,y)

• If the query can be answered locally, there is no need to propagate it till the root (highest) level :

query is propagated up if (x,y) is not enclosed within current MBR

• At some level a clusterhead that contains (x,y) is reached :

from this point on, the query is sent to children

children are ordered with respect to MINDIST

this way only the most relevant children are queried

Page 19: Peer-to-Peer Spatial Queries in Sensor Networks Murat Demirbas Hakan Ferhatosmanoglu The Ohio State University

NN query execution

query

(x,y)

Page 20: Peer-to-Peer Spatial Queries in Sensor Networks Murat Demirbas Hakan Ferhatosmanoglu The Ohio State University

NN query execution

query

(x,y)

Page 21: Peer-to-Peer Spatial Queries in Sensor Networks Murat Demirbas Hakan Ferhatosmanoglu The Ohio State University

P2P NN queries

• If (x,y) is not within MBR of v at level i, mbr.v(i), then forward query to p.v(i)

• let u be the first encountered clusterhead that contains (x,y)

u forwards query to relevant children in c.u

• While the query is traveling downwards, each clusterhead

sorts the children wrt MINDIST prunes list using the replies from queried children

• A level 0 node returns its nearest distance NN, reply is propagated up

• u aggregates the replies

if (x,y) is encapsulated by c.u, the reply is sent to querying node

else, u punts the query to its clusterhead

Page 22: Peer-to-Peer Spatial Queries in Sensor Networks Murat Demirbas Hakan Ferhatosmanoglu The Ohio State University

NN query execution

query

(x’,y’)

Page 23: Peer-to-Peer Spatial Queries in Sensor Networks Murat Demirbas Hakan Ferhatosmanoglu The Ohio State University

Tradeoff : time vs. energy

• Minimal response time

The clusterhead forwards the query to its relevant children in

parallel (concurrent execution)

• Minimal energy consumption

The clusterhead forwards the query to its relevant children sequentially (to maximize pruning)

• Optimizing both

Hybrid of the above

Page 24: Peer-to-Peer Spatial Queries in Sensor Networks Murat Demirbas Hakan Ferhatosmanoglu The Ohio State University

Outline

• Model

• Peer-tree structure

• P2P nearest neighbor queries

• Pursuer – evader tracking revisited

• Conclusions

Page 25: Peer-to-Peer Spatial Queries in Sensor Networks Murat Demirbas Hakan Ferhatosmanoglu The Ohio State University

Pursuer-evader problem

• Evader is omniscient;Strategy of evader is unknown

• Pursuer can only see state of nearest node;Pursuer moves faster than evader

• Required is to design a program for nodes and pursuer so that pursuer can catch evader (despite the occurrence of faults)

[Demirbas, Arora, Gouda]

Page 26: Peer-to-Peer Spatial Queries in Sensor Networks Murat Demirbas Hakan Ferhatosmanoglu The Ohio State University

Evader-centric program (cont.)

• Tracking tree is dynamically rooted at the evader

• Parent of a node is closer to the evader

Page 27: Peer-to-Peer Spatial Queries in Sensor Networks Murat Demirbas Hakan Ferhatosmanoglu The Ohio State University

Evader-centric program (cont.)

• Tracking tree is dynamically rooted at the evader

• Parent of a node is closer to the evader

Page 28: Peer-to-Peer Spatial Queries in Sensor Networks Murat Demirbas Hakan Ferhatosmanoglu The Ohio State University

Evader-centric program (cont.)

• Tracking tree is dynamically rooted at the evader

• Parent of a node is closer to the evader

Page 29: Peer-to-Peer Spatial Queries in Sensor Networks Murat Demirbas Hakan Ferhatosmanoglu The Ohio State University

Pursuer-evader tracking viaP2P spatial queries

• The pursuer submits an NN query with its own location to find out the location of the nearest evader to itself

On demand approach

No tracking tree is maintained, a clusterhead is only aware of the existence of an evader in its region, but does not know where it is

Page 30: Peer-to-Peer Spatial Queries in Sensor Networks Murat Demirbas Hakan Ferhatosmanoglu The Ohio State University

Conclusions

• We have presented for the first time a peer-to-peer spatial query processing system for sensor networks

• We are implementing this system in the context of our work on tracking services for sensor network (LITS)

• Indexing in database systems, peer-to-peer systems, sensor networks have a lot of similarities (as well as distinctions)

peer-tree is based on R-tree concept in database systems

possible to extend peer-tree for wired systems

since energy is no longer an issue, scalability and load balancing can be improved by inserting long links