Download ppt1

Document related concepts

Distributed firewall wikipedia , lookup

AppleTalk wikipedia , lookup

Computer network wikipedia , lookup

Cracking of wireless networks wikipedia , lookup

Backpressure routing wikipedia , lookup

Distributed operating system wikipedia , lookup

Recursive InterNetwork Architecture (RINA) wikipedia , lookup

Airborne Networking wikipedia , lookup

IEEE 802.1aq wikipedia , lookup

CAN bus wikipedia , lookup

List of wireless community networks by region wikipedia , lookup

Routing wikipedia , lookup

Kademlia wikipedia , lookup

Routing in delay-tolerant networking wikipedia , lookup

Transcript
15-441 Computer Networking
Lecture 10 – Geographic Ad Hoc
Routing
1
Readings
• [I.1] GPSR: Greedy Perimeter Stateless Routing for Wireless
Networks, Karp, B., and Kung. H. T., Proc. 6th Annual International
Conference on Mobile Computing and Networking (MobiCom 2000),
243-254.
• [I.7] Jinyang Li, John Jannotti, Douglas S. J. De Couto, David R.
Karger, and Robert Morris, "A Scalable Location Service for
Geographic Ad Hoc Routing." Proceedings of the sixth ACM
International Conference on Mobile Computing and Networking
(MobiCom '00), July 2000, Boston, Massachusetts. Pages 120-130.
• [I.11] Ananth Rao, Sylvia Ratnasamy, Christos Papadimitriou, Scott
Shenker, and Ion Stoica. Geographic Routing without Location
Information. In Proc. of ACM Mobicom 2003, Sept. 2003.
• OPTIONAL
• [I.12] Young-Bae Ko and Nitin H. Vaidya, "Location-Aided Routing(LAR) in
Mobile Ad Hoc Networks" In Proceedings of the 4th Annual International
Conference on Mobile Computing and Networking (MOBICOM'98),
October, 1998.
2
Context
• Early 90s: availability of off-the-shelf wireless
network cards and laptops
• 1994: first papers on Destination-Sequenced
Distance Vector (DSDV) routing and Dynamic
Source Routing (DSR) spark tremendous interest
in routing on mobile wireless (ad hoc) networks
• 1998: Broch et al.’s comparison of leading ad hoc
routing protocol proposals in ns-2 simulator in
MobiCom
• [2000: GPSR in MobiCom]
• 2000: Estrin et al.’s Directed Diffusion in MobiCom
sparks interest in wireless sensor networks
3
Scaling Routing (cont’d)
• Dominant factors in cost of DV, LS, DSR:
• rate of change of topology (bandwidth)
• number of routers in routing domain (b/w, state)
• Scaling strategies:
• Hierarchy: at AS boundaries (BGP) or on finer scale
(OSPF)
• Goal: reduce number of routers in routing domain
• Assumption: address aggregation
• Caching: store source routes overheard (DSR)
• Goal: limit propagation of future queries
• Assumption: source route remains fixed while cached
4
Problem
D
t10
C
A
S
X
D
B
E
5
Route Discovery Using Flooding
route request
C
route reply
A
S
X
D
B
E
6
Location-Aided Routing
• Main Idea
• Using location information to reduce the number of
nodes to whom route request is propagated.
• Location-aided route discovery based on “limited”
flooding
• Consider a node S that needs to find a route to
node D.
• each host in the ad hoc network knows its current
location
• node S knows that node D was at location L at time t0,
and that the current time is t1
7
Location Information
• Consider a node S that needs to find a route to
node D.
• Assumption:
• each host in the ad hoc network knows its current
location precisely (location error considered in one of
their simulations)
• node S knows that node D was at location L at time t0,
and that the current time is t1
8
Expected Zone
expected zone of D ---- the region that node S
expects to contain node D at time t1, only an
estimate made by node S
9
Request Zone
• LAR’s limited flooding
• A node forwards a route
request only if it belongs to
the request zone
• The request zone should
include
• expected zone
• other regions around the
expected zone
• No guarantee that a path
can be found consisting only
of the hosts in a chosen
request zone.
• timeout
• expand request zone
• Trade-off between
• latency of route
determination
• the message overhead
10
Greedy Perimeter Stateless Routing
(GPSR)
Central idea:
Machines can know their
geographic locations
• by GPS (outdoors)
• by surveyed position (for non-mobile nodes)
• by short-range localization (indoors, [AT&T
Camb, 1997], [Priyantha et al., 2000])
Route using geography.
• packet destination field: location of destination
11
Assumptions
• Bi-directional radio links (unidirectional links
may be blacklisted)
• Network nodes placed roughly in a plane
• Radio propagation in free space; distance
from transmitter determines signal strength
at receiver
• Fixed, uniform radio transmitter power
12
Greedy Forwarding
• Nodes learn immediate neighbors’ positions from
beaconing/piggybacking on data packets
• Neighbor
Locally optimal,
next
hop choice:
must begreedy
strictly
closer
to avoid loops
• Neighbor geographically nearest destination
D
x
y
13
In Praise of Geography
• Self-describing
• As node density increases, shortest path
tends toward Euclidean straight line
between source and destination
• Node’s state concerns only one-hop
neighbors:
• Low per-node state: O(density)
• Low routing protocol overhead: state pushed
only one hop
14
Greedy Forwarding Failure
Greedy forwarding not always possible! Consider:
D
v circumnavigate voids?z
How can we
…based only on one-hop neighborhood?
void
y
w
x
15
Node Density and Voids
Voids more prevalent in sparser topologies
16
Void Traversal: The Right-hand Rule
Well-known graph traversal: right-hand rule
Requires only neighbors’ positions
z
y
x
17
Planar vs. Non-planar Graphs
On graphs with edges that cross (non-planar
graphs), right-hand rule may not tour enclosed face
boundary
How to remove crossing edges without
partitioning graph?
And using only single-hop neighbors’ positions?
18
Planarized Graphs
Relative Neighborhood Graph (RNG) [Toussaint, ’80] and
Gabriel Graph (GG) [Gabriel, ’69]: long-known planar graphs
Assume edge exists between any pair of nodes separated by
less than threshold distance (i.e., nominal radio range)
RNG and GG can be constructed from only neighbors’
positions, and can be shown not to partition network!
Euclidean MST (so connected)
 RNG
w  GG
w
u
v
u
v

Delaunay
Triangulation
(so
planar)
?
?
RNG
GG
19
Planarized Graphs: Example
200 nodes, placed uniformly at random on
2000-by-2000-meter region; 250-meter radio
range
Full Graph
GG Subgraph
RNG Subgraph
20
Full Greedy Perimeter
Stateless Routing
• All packets begin in greedy mode
• Greedy mode uses full graph
• Upon greedy failure, node marks its location in
packet, marks packet in perimeter mode
• Perimeter mode packets follow simple planar
graph traversal:
• Forward along successively closer faces by right-hand
rule, until reaching destination
• Packets return to greedy mode upon reaching node
closer to destination than perimeter mode entry point
21
Perimeter Mode Forwarding Example
D
x
• Traverse face closer to D along xD by right-hand
rule, until crossing xD
• Repeat with next-closer face, &c.
22
Packet Delivery Success Rate
(50, 200; Dense)
23
State Size (200; Dense)
How would you expect GPSR’s state size
to change the number of nodes in the
network increases?
Why does DSR hold state for more nodes
than there are in the network?
24
Critical Thinking
• Based on the results thus far (indeed, all
results ininthe
paper),
what
do nothing
we know
Evaluation
paper
reveals
nearly
aboutperformance
the performance
of GPSR’s
about
of perimeter
mode! perimeter
mode?
Why
doesn’t
it?
• Would
you expect
it to be more or less reliable
than greedy mode?
• Would you expect use of perimeter mode to
affect path length?
25
Other Issues
• How to route geographically in 3D?
• Greedy mode?
• Perimeter mode?
• Effect of radio-opaque obstacles?
• Effect of position errors?
26
Geographic Forwarding
Scales Well
C’s radio range
A
C
B
D
F
G
E
• A addresses a packet to G’s latitude, longitude
• C only needs to know its immediate neighbors to
forward packets towards G.
• Geographic forwarding needs a location service!
27
Possible Designs for a
Location Service
• Flood to get a node’s location (LAR, DREAM).
• excessive flooding messages
• Central static location server.
• not fault tolerant
• too much load on central server and nearby
nodes
• the server might be far away for nearby nodes
or inaccessible due to network partition.
• Every node acts as server for a few others.
• good for spreading load and tolerating failures.
28
Desirable Properties of a
Distributed Location Service
•
•
•
•
Spread load evenly over all nodes.
Degrade gracefully as nodes fail.
Queries for nearby nodes stay local.
Per-node storage and communication
costs grow slowly as the network size
grows.
29
Grid Location Service (GLS)
Overview
E
B
H
L
D
J
G
A
F
“D?”
I
K
C
Each node has a few servers that know its location.
1. Node D sends location updates to its servers (B, H, K).
2. Node J sends a query for D to one of D’s close servers.
30
Grid Node Identifiers
• Each Grid node has a unique identifier.
• Identifiers are numbers.
• Perhaps a hash of the node’s IP address.
• Identifier X is the “successor” of Y if X is the
smallest identifier greater than Y.
31
GLS’s spatial hierarchy
level-0
level-1
level-2
level-3
All nodes agree on the global origin of the grid hierarchy
32
3 Servers Per Node Per Level
sibling level-0
squares
sibling level-1
squares
sibling level-2
squares
s
n s
s
s
s
s
s
s
s
• s is n’s successor in that square.
(Successor is the node with “least ID greater than” n )
33
Queries Search for Destination’s
Successors
s
n s
s
s
Each query step:
visit n’s successor at
surrounding level.
s
s
s
s1
x
s2
s
s3
location query path
34
GLS Update (level 0)
9
11
2
1
9
11
3
6
23
23
16
29
7
6
17
5
26
21
25
4
Invariant (for all levels):
For node n in a square,
n’s successor in each
sibling square “knows”
about n.
Base case:
Each node in a level-0
square “knows” about
all other nodes in the
same square.
8
19
location table content
35
GLS Update (level 1)
9
11
2
1
9
11 2
3
6
23
23 2
2
16
Invariant (for all levels):
For node n in a square,
n’s successor in each
sibling square “knows”
about n.
29
7
6
17
5
26
21
25
4
location table content
8
19
location update
36
GLS Update (level 1)
...
11
2
...
9
1
9
11, 2
6
23
23, 2
Invariant (for all levels):
For node n in a square,
n’s successor in each
sibling square “knows”
about n.
...
3
...
2
16
29
...
7
6
...
...
17
...
26
...
21
5
...
25
...
4
...
8
...
19
location table content
37
GLS Update (level 2)
... 1
11
2
...
9
1
9
11, 2
6
23
23, 2
Invariant (for all levels):
For node n in a square,
n’s successor in each
sibling square “knows”
about n.
...
3
...
2
16
29
...
7
6
...
...
17
...
26
...
21
5
...
25
...
4
...
location table content
8
...
19
location update
38
GLS Query
... 1
11
2
...
9
1
9
11, 2
6
23
23, 2
...
3
...
2
16
29
...
7
6
...
...
17
...
26
...
21
5
...
25
...
4
location table content
...
8
...
19
query from 23 for 1
39
Challenges for GLS in a
Mobile Network
• Slow updates risk out-of-date information.
• Packets dropped because we can’t find the
destination.
• Aggressive updates risk congestion.
• Update packets leave no bandwidth for data.
• Large mobile ad-hoc nets usually suffer from
one or the other.
40
GLS Finds Nodes in Big Mobile
Networks
Biggest network simulated:
600 nodes, 2900x2900m
(4-level grid hierarchy)
Number of nodes
• Failed queries are not retransmitted in this simulation
• Queries fail because of out-of-date information for
destination nodes or intermediate servers
42
GLS Protocol Overhead
Grows Slowly
Number of nodes
• Protocol packets include: GLS update, GLS query/reply
43
Why geographic routing without
location information
• GPS takes power, doesn’t work indoors
• Obstacles, non-ideal radios
• Coordinates computed will reflect true
connectivity and not the geographic
locations of the nodes
44
Step by Step Approach
Nothing is known about the perimeter
Perimeter node detection
Perimeter nodes are known but their locations are
not known
Balls and Springs
Perimeter nodes and their locations are known
Degree of Information
Relaxation algorithm
45
Rubber Bands
Every node
moves to the
average of its
neighbors
coordinates
at each step
in the
iteration
46
Perimeter nodes are known (10
iterations)
47
Perimeter nodes are known (100
iterations)
48
Perimeter nodes are known (1000
iterations)
49
Perimeter Nodes are Known but
Their Locations are not Known
• Stage 1 : Each perimeter node broadcasts a HELLO
message to the entire network
• Stage 2 : Each perimeter node broadcasts its
perimeter vector to the entire network
• Stage 3 : Every perimeter node uses a triangulation
algorithm to compute the coordinates of all other
perimeter nodes by minimizing
50
Balls and Springs
• Balls and Springs
• Ball : each perimeter
node
• Spring : each ball is
attached by a spring
• Spring’s length : the
hop count distance
• Seen as minimizing
the potential energy
when a ball attached to
every other ball by a
spring
51
Nothing is Known about the Perimeter
• Bootstrap Nodes flood the network and every
node discovers its distance to these bootstrap
nodes
• Nodes use the following criterion
• Perimeter Criterion “if a node is farthest away, among
all its two-hop neighbors from the first bootstrap node,
then the node decides that it is on the perimeter.”
• False Positives are relatively low and have little
effect on the eventual outcome.
52
Perimeter node detection
53
Overall algorithm - Bootstrap the
coordinate assignment
1. Two designated bootstrap beacon nodes
broadcast to the entire network
2. Every perimeter node sends a broadcast
message to the entire network to enable every
other node to compute its perimeter vector
3. Perimeter and bootstrap nodes broadcast their
perimeter vectors to the entire network
4. Each node uses these inter-perimeter distances
to compute normalized coordinates for both itself
and the perimeter nodes
54
Overall Algorithms[Cont’d] –
normal operation
5. Perimeter nodes stay fixed while other
nodes run a relaxation algorithm
6. A designated bootstrap node periodically
broadcasts by which nodes periodically reasses whether they lie on the perimeter or
not
55
Two metrics to measure
• Success rate
• The fraction of times packets reach their
intended destination using purely greedy
routing
• Average Path length
• The average number of hops taken along the
path
56
Success Rate vs. Iterations
57
Path Length vs. Number of Nodes
identical
58
Recap:
Scalability via Geography with GPSR
Key scalability properties:
• Small state per router: O(D), not O(N) or O(L) as
for shortest-path routing, where D = density
(neighbors), N = total nodes, L = total links
• Low routing protocol overhead: each node merely
single-hop broadcasts own position periodically
• Approximates shortest paths on dense networks
• Delivers more packets successfully on dynamic
topologies than shortest-paths routing protocols
59