efficient and robust query processing in dynamic environments using random walk techniques chen avin...
TRANSCRIPT
Efficient and Robust Query Processing in DynamicEnvironments Using Random Walk Techniques
Chen Avin
Carlos Brito
IPSN04 - Berkeley - 04/27/2004 2
Outline
Motivation Random Walk and Partial Cover Time Efficiency Robustness Quality Load Balancing, Scalability and Latency Discussion
IPSN04 - Berkeley - 04/27/2004 3
Motivation
Sensor Network as large, dense and dynamic networks
Task: Query the network Common systems depend on state information
stored in the nodes for proper operation and control (i.e. spanning trees, cluster heads)
Critical points of failure lead to recovery mechanism Explore the properties of uncontrolled scheme like
random walk Simple process, no critical point of failure, all nodes
are equally unimportant at all times
IPSN04 - Berkeley - 04/27/2004 4
Random Walk
Visiting the nodes of the graph in a random order
At each step, a token moves to a neighbor with some distribution(simple = uniform)
IPSN04 - Berkeley - 04/27/2004 5
Random Walk for Sensor Nets Easily implemented in sensor networks: base
station issues a token with a query (almost) Assumption free method, the
protocol does not require knowledge of: Location Neighbors Transmission range Symmetric connection
High density and redundancy are advantage
IPSN04 - Berkeley - 04/27/2004 6
Cover Time
Cover Time: the expected time to visit all the nodes in a random walk (starting at the worst case node)
How efficient is the process ? hij : the expected time to go from node i to j
hmax: max (hij | all nodes in the graph)
Matthew’s Bound: C ≤ hmax·log(n)
IPSN04 - Berkeley - 04/27/2004 7
Cover Time
Known results: Worst cases: O(n3)
Lollipop graph Line: O(n2)
Best cases: O(n·log(n)) Star Complete Graph Hypercube
Grid: O(n·log2(n)) Random sensor networks ?
IPSN04 - Berkeley - 04/27/2004 8
Partial Cover Time (PCT) In sensor network we don’t need to consult every
node How efficient is to visit 80% of the nodes ?
Lemma:PCT(c) ≤ O(hmax )
0
0.1
0.2
0.3
0.4
0.5
0.6
0.7
0.8
0.9
1
0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1
Unvisited nodes Visited nodes
O(n) in Hypercube O(n·log(n)) in Grid
IPSN04 - Berkeley - 04/27/2004 10
Outline
Overview of our approach Random Walk and Partial Cover Time Efficiency Robustness Quality Load Balancing, Scalability and Latency Discussion
IPSN04 - Berkeley - 04/27/2004 11
Efficiency – Simple Walk
0
2
4
6
8
10
12
14
16
10 20 30 40 50 60 70 80 90 100
Num
ber
of s
teps
nor
mal
ize
to n
% of Cover
3.12
GridRandom 15Random 19Hyper Cube
IPSN04 - Berkeley - 04/27/2004 12
Biased Random Walk
Can we improve this results? Give priority to unvisited nodes Define bias parameter: 0 ≤ bias ≤ 1 Visited neighbor selected with probability
(1- bias) / d Unvisited with
(1- bias) / d + bias / du
The protocol remain (almost) the same
IPSN04 - Berkeley - 04/27/2004 13
Biased Random Walk
0
1
2
3
4
5
6
7
8
0 10 20 30 40 50 60 70 80 90 100
Nu
mb
er
of
ste
ps
no
rma
lize
to
n
% of Cover
Bias = 0Bias = 0.1Bias = 0.2Bias = 0.4Bias = 0.6Bias = 0.8
Bias = 1
3.12
IPSN04 - Berkeley - 04/27/2004 14
Comparison with Clustering
1
2
3
4
5
6
7
8
9
10
100 1000 10000 100000 1e+06
Exp
ect
ed
nu
mb
er
of m
ess
ag
es
norm
aliz
e t
o n
Network size
10 X 10 25 X 25 50 X 5075 X 75
100 X 100
250 X 250500 X 500
1000 X 1000
80% cover walk on grid with bias 0.580% cover walk on grid with no bias
Optimal Cluster head protocol for grid
Analytical result for Cluster Head scheme shows that the number of messages for optimal protocol on grid require ≈ 0.945n7/6
The efficiency ofboth systems issimilar
IPSN04 - Berkeley - 04/27/2004 15
Outline
Overview of our approach Random Walk and Partial Cover Time Efficiency Robustness Quality Load Balancing, Scalability and Latency Discussion
IPSN04 - Berkeley - 04/27/2004 16
Robustness to Dynamics The probability that a node will fail when it
has the token is negligible No critical point of failure (but do need
reliable token passing) All we require is connectivity in the token
neighborhood Robust to independent and dependent
failures (disaster areas)
IPSN04 - Berkeley - 04/27/2004 17
Spanning tree in dynamic env. Nodes close to the root are more important When a node fails all nodes in the sub-tree
are disconnected from the root and must participate in recovery mechanism
Assuming independent failure (or duty cycle) probability p, (q=1-p) the expected number of nodes to report is O(qh)
Since R << network area, h is large p=0.1. h=10 65% will not report to the root.
IPSN04 - Berkeley - 04/27/2004 18
Outline
Overview of our approach Random Walk and Partial Cover Time Efficiency Robustness Quality Load Balancing, Scalability and Latency Discussion
IPSN04 - Berkeley - 04/27/2004 19
How far are the unvisited nodes from visited ones ?
90% are atmost 2 hops
Expected random walkwill not leavelarge area uncovered
Quality of Partial Cover - 1
0
0.1
0.2
0.3
0.4
0.5
0.6
0.7
0.8
0.9
1
Random Network Grid
Network Type
Exp
ecte
d p
ort
ion
fro
m u
nco
vere
d n
od
es 12
11
10
9
8
7
6
5
4
3
2
1
IPSN04 - Berkeley - 04/27/2004 20
Quality of Partial Cover - 2
0%
10%
20%
30%
40%
50%
60%
70%
80%
90%
100%
Expected Walk on Random Graph
Net
wo
k p
ort
ion
4 Walks
3 Walks
2 Walks
1 Walk
0 Walks
How long must a node wait before a walk will visit its neighborhood?
85% are visitedat most every other run
At most will need to wait4 runs
IPSN04 - Berkeley - 04/27/2004 21
Application Example
Nodes temperature 30 25 20 15 10 5
0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1X Location 0
0.1 0.2
0.3 0.4
0.5 0.6
0.7 0.8
0.9 1
Y Location
0 5
10 15 20 25 30 35
Temp
0
0.02
0.04
0.06
0.08
0.1
0.12
0.14
0.16
0 5 10 15 20
Netw
ork
port
ion
21 Bar histogram between min and max temperature
80% random walkReal data
Find the histogram of the data in the network Assume non uniform distribution Token report after seeing 80% of the nodes
IPSN04 - Berkeley - 04/27/2004 22
Outline
Overview of our approach Random Walk and Partial Cover Time Efficiency Robustness Quality Load Balancing, Scalability and Latency Discussion
IPSN04 - Berkeley - 04/27/2004 23
Load Balancing
0
0.005
0.01
0.015
0.02
0.025
0.03
0.035
0.04
0.045
0.05
0.055
0.06
0.5 1 1.5 2 2.5 3 3.5 4 4.5 5 5.5 6 6.5
Netw
ort
port
ion
Expected number of visits to a node in 80% random walk
Expected PCT of 80%
The stationary distribution of the Markov chain π = (π1, …, πn) is πi=di/2m
In regular graphsπ is uniform,but this only afterlong walks
Here we issue many“short” walks
IPSN04 - Berkeley - 04/27/2004 24
Scalability
0
2
4
6
8
10
12
14
0 10 20 30 40 50 60 70 80 90 100
Exp
ect
ed
nu
mb
er
of
ste
ps
no
rma
lize
to
n
% of Cover
1024 Random Network R = 0.082048 Random Network R = 0.05656
4096 Random Network R = 0.048192 Random Network R = 0.02828
16384 Random Network R = 0.02
2.92n
3.37n
X 16
IPSN04 - Berkeley - 04/27/2004 25
Latency
Random walk is sequential process The latency is proportional to the number of
steps to accomplish the task Reduce the range of applicability Future work: combine result from few parallel
random walks in the network
IPSN04 - Berkeley - 04/27/2004 26
Discussion
Achieving control in highly dynamic env. is problematic, and in many cases not energy efficient do to recovery mechanism
How do we do with uncontrolled process such as random walk? Not Bad !
Not applicable in all cases, but, When applicable provides an elegant, simple
and efficient solution