0% found this document useful (0 votes)
86 views23 pages

IP Addressing & Interdomain Routing: IP Addressing Hierarchy (Prefixes, Class A, B, C, Subnets)

IP addressing uses hierarchical prefixes to allow for scalable routing on the internet. Interdomain routing separates routing into autonomous systems (AS) and uses protocols like BGP between ASes. BGP uses a path vector protocol where routers advertise the full path to destinations, allowing them to apply policies in route selection.

Uploaded by

Shahban ktk
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
86 views23 pages

IP Addressing & Interdomain Routing: IP Addressing Hierarchy (Prefixes, Class A, B, C, Subnets)

IP addressing uses hierarchical prefixes to allow for scalable routing on the internet. Interdomain routing separates routing into autonomous systems (AS) and uses protocols like BGP between ASes. BGP uses a path vector protocol where routers advertise the full path to destinations, allowing them to apply policies in route selection.

Uploaded by

Shahban ktk
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 23

IP Addressing & Interdomain

Routing

Next Topic

 IP Addressing
 Hierarchy (prefixes, class A, B, C, Application
subnets) Presentation
Session
Transport
Network
 Interdomain routing
Data Link
Physical
Scalability Concerns

 Routing burden grows with size of an inter-network


 Size of routing tables
 Volume of routing messages
 Amount of routing computation

 To scale to the size of the Internet, apply:


 Hierarchical addressing
 Route aggregation

IP Addresses
 Reflect location in topology; used for scalable routing
 Unlike “flat” Ethernet addresses

 Interfaces on same network share prefix


 Prefix administratively assigned (IANA or ISP)
 Addresses globally unique

 Routing only advertises entire networks by prefix


 Local delivery in a single “network” doesn’t involve
router
Getting an IP address
 Old fashioned way: sysadmin configured each machine

 Dynamic Host Configuration Protocol (DHCP)


 One DHCP server with the bootstrap info
• Host address, gateway address, subnet mask, …
• Find it using broadcast
 Addresses may be leased; renew periodically

 “Stateless” Autoconfiguration (in IPv6)


 Get rid of server – reuse Ethernet addresses for lower portion of
address (uniqueness) and learn higher portion from routers

IPv4 Address Formats

7 24

Class A 0 Network Host

14 16

Class B 1 0 Network Host

21 8

Class C 1 1 0 Network Host

 32 bits written in “dotted quad” notation, e.g., 18.31.0.135


IPv6 Address Format

001 RegistryID ProviderID SubscriberID SubnetID InterfaceID

 128 bits written in 16 bit hexadecimal chunks


 Still hierarchical, just more levels

Updated Forwarding Routine


 Used to be “look up destination address for next hop”

 Now addresses have network and host portions:


 Source host:
• if destination network is the same as the host network, then deliver
locally (without router)
• Otherwise send to the router
 Intermediate router:
• look up destination network in routing table to find next hop and
send to next router.
• If destination network is directly attached then deliver locally.

 (Note that it will get a little more complicated later)


Subnetting – More Hierarchy
 Split up one network
number into multiple
physical networks
Network number Host number
 Helps allocation
efficiency -- can hand Class B address
out subnets

 Rest of internet does


not see subnet
structure
 subnet is purely
internal to network Network number Subnet ID Host ID
 aggregates routing
info Subnetted address

Subnet Example

Subnet mask: 255.255.255.128


Subnet number: 128.96.34.0
128.96.34.15
128.96.34.1
H1
R1

128.96.34.130 Subnet mask: 255.255.255.128


Subnet number: 128.96.34.128

128.96.34.139
128.96.34.129
H2
R2
H3
128.96.33.1
128.96.33.14
Subnet mask: 255.255.255.0
Subnet number: 128.96.33.0
CIDR (Supernetting)
 CIDR = Classless Inter-Domain Routing
 Generalize class A, B, C into prefixes of arbitrary length; now must
carry prefix length with address
 Aggregate adjacent advertised network routes
 e.g., ISP has class C addresses 192.4.16 through 192.4.31
 Really like one larger 20 bit address class …
 Advertise as such (network number, prefix length)
 Reduces size of routing tables

 But IP forwarding is more involved


 Based on Longest Matching Prefix operation

CIDR Example
 X and Y routes can be aggregated because they form a bigger
contiguous range.

Corporation X
(11000 00000 00010 00001)
/20
Border gateway Regional network
(advertises path to
11000 00000 00010 0000)
Corporation Y
/19 (11000 00000 00010 00000)
/20
 But aggregation isn’t always possible.
 can only aggregate power of 2
IP Forwarding Revisited
 Routing table now contains routes to “prefixes”
 IP address and length indicating what bits are fixed

 Now need to “search” routing table for longest matching prefix, only
at routers
 Search routing table for the prefix that the destination belongs
to, and use that to forward as before
 There can be multiple matches; take the longest prefix

 This is the IP forwarding routine used at routers.

Structure of the Internet

 Inter-domain versus intra-domain routing

You at work Large corporation

“Consumer ” ISP

Peering
point
Backbone service provider Peering
point
“ Consumer” ISP

“Consumer”ISP
Large corporation

Small
corporation
You at home
Inter-Domain Routing
 Network comprised of many
Autonomous Systems (ASes) or
domains
 To scale, use hierarchy: 23
separate inter-domain and
intra-domain routing
 Also called interior vs exterior 12 7
gateway protocols (IGP/EGP)
 IGP = RIP, OSPF 44 321
1123
 EGP = EGP, BGP

Inter-Domain Routing

 Border routers summarize and AS1


advertise internal routes to
external neighbors and vice-
versa R1
R3

 Border routers apply policy


R2 Border router
 Internal routers can use notion Autonomous system 1

of default routes
R4

 Core is “default-free”; routers


Border router
Autonomous system 2

must have a route to all


networks in the world
R5 R6 AS2
Hierarchical Routing May Pay a Price for Path Quality

AS 4

AS 3

AS 2

AS 1

Many Routing Processes Can Run on a Single Router

RIP process OSPF process BGP process


BGP RIP routing table OSPF Routing table BGP routing table

OS kernel
RIP
domain OSPF Forwarding Table Manager
domain

Forwarding Table
Border Gateway Protocol (BGP-4)

 Features:
 Path vector routing
 Application of policy
 Operates over reliable transport (TCP)
 Uses route aggregation (CIDR)

Internet Interdomain Routing: BGP


 BGP (Border Gateway Protocol): the de facto standard
 Path Vector protocol:
 similar to Distance Vector protocol
 a border gateway sends to a neighbor entire path
(i.e., a sequence of ASes) to a destination, e.g.,
• gateway X sends to neighbor N its path to dest. Z:
path (X,Z) = X,Y1,Y2,Y3,…,Z
 if N selects path(X, Z) advertised by X, then: Z
path (N,Z) = N, path (X,Z) N X

Question: what are the implications of path vector?


BGP Routing Decision Process

route
selection
policy: rank
paths

select best
routing cache
path

export
export path policy:
to neighbors which
paths to
export to
which
neighbors

BGP Operations (Simplified)

Establish session on AS1


TCP port 179

BGP session
Exchange all
active routes
AS2

while (connection is ALIVE)


Exchange incremental exchange UPDATE message
select best available route
updates if route changes, export to neigh.
BGP Messages

 Four types of messages

 OPEN: opens TCP connection to peer and


authenticates sender

 UPDATE: advertises new path (or withdraws old)

 KEEPALIVE keeps connection alive in absence of


UPDATES; also ACKs OPEN request

 NOTIFICATION: used to close connection

Internet Routing Architecture


 Divided into Autonomous Systems
 Distinct regions of administrative control
 Routers/links managed by a single “institution”
 Service provider, company, university, …
 Hierarchy of Autonomous Systems
 Large, tier-1 provider with a nationwide backbone
 Medium-sized regional provider with smaller backbone
 Small network run by a single company or university
 Interaction between Autonomous Systems
 Internal topology is not shared between ASes
 … but, neighboring ASes interact to coordinate routing
Autonomous System Numbers
AS Numbers are 16 bit values.
Currently just over 20,000 in use.
• Level 3: 1
• MIT: 3
• Washington AS: 73
• Princeton: 88
• AT&T: 7018, 6341, 5074, …
• UUNET: 701, 702, 284, 12199, …
• Sprint: 1239, 1240, 6211, 6242, …
• …

AS Topology

 Node: Autonomous System


 Edge: Two ASes that connect to each other

4
3

2
7 6

1
What is an Edge, Really?

 Edge in the AS graph


 At least one connection between two ASes
 Some destinations reached from one AS via the other
d
d

AS 1 AS 1

Exchange Point

AS 2 AS 2 AS 3

Interdomain Paths
Path: 6, 5, 4, 3, 2, 1

2
7 6

1
Web server
Client
Business Relationships

 Neighboring ASes have business contracts


 How much traffic to carry
 Which destinations to reach
 How much money to pay
 Common business relationships
 Customer-provider
• E.g., UW is a customer of NTT
• E.g., MIT is a customer of Level 3
 Peer-peer
• E.g., AT&T is a peer of Sprint

Customer-Provider Relationship

 Customer needs to be reachable from everyone


 Provider tells all neighbors how to reach the customer
 Customer does not want to provide transit service
 Customer does not let its providers route through it
Traffic to the customer Traffic from the customer

d provider
advertisements

provider
traffic
customer
d customer
Customer Connecting to a Provider
Provider Provider

1 access link 2 access links

Provider Provider

2 access routers 2 access PoPs

Multi-Homing: Two or More Providers

 Motivations for multi-homing


 Extra reliability, survive single ISP failure
 Financial leverage through competition
 Better performance by selecting better path
 Gaming the 95th-percentile billing model

Provider 1 Provider 2
Example

 Internet: customer of AT&T and RegionalAS


 Research universities/labs: customer of Internet2

AT&T RegionalAS Internet2

Peer-Peer Relationship
 Peers exchange traffic between customers
 AS exports only customer routes to a peer
 AS exports a peer’s routes only to its customers
 Often the relationship is settlement-free (i.e., no $$$)

Traffic to/from the peer and its customers

advertisements

peer peer
traffic

d
Implication of Business Relationship on Policies

 Route selection (ranking) policy:


 the typical route selection policy is to prefer
customers over peers/providers to reach a
destination, i.e., Customer > Peer > Provider

 Route export policy:


 since the export of a path to a neighbor is an
indication that the AS is willing to transport traffic for
the neighbor, an AS may not export routes to all
neighbors

Typical Export Policies


provider
case 1: routes learned from customer
customer routes learned from a
customer are sent to
customer all other neighbors

peer

case 2: routes learned from provider case 3: routes learned from peer
provider provider
provider peer

customer customer

routes learned from peer routes learned from peer


a provider are sent a peer are sent only
only to customers to customers
Example Export Policy: No-Valley Routing

P1
P2

A advertises path A advertises path


to C, but not P2 to C, but not P1
A learns A
paths to A advertises to C
C, P1, P2 paths to P1 and P2

C IP traffic

Suppose P1 and P2 are providers of A; A is a provider of C

AS Structure: Tier-1 Providers


 Tier-1 provider
 Has no upstream provider of its own
 Typically has a national or international backbone
 UUNET, Sprint, AT&T, Level 3, …
 Top of the Internet hierarchy of 9-15 ASes
 Full peer-peer connections between tier-1 providers
Efficient Early-Exit Routing
Customer B  Diverse peering locations

 Comparable capacity at all


peering points
Provider B
 Can handle even load
 Consistent routes
 Same destinations
multiple advertised at all points
peering
 Same AS path length for a
points Early-exit
routing destination at all points

Provider A

Customer A

AS Structure: Other ASes


 Tier-2 and Tier-3 providers
 Provide transit service to downstream customers
 … but, need at least one provider of their own
 Typically have national or regional scope
 E.g., Minnesota Regional Network
 Includes a few thousand of the Ases

 Stub ASes
 Do not provide transit service to others
 Connect to one or more upstream providers
 Includes vast majority (e.g., 85-90%) of the ASes
Characteristics of the AS Graph

 AS graph structure
 High variability in node degree (“power law”)
 A few very highly-connected ASes
 Many ASes have only a few connections
1 All ASes have 1 or more neighbors
0.1
CCDF

0.01 Very few have degree >= 100

0.001
1 10 100 1000 AS degree

Characteristics of AS Paths

 AS path may be longer than shortest AS path


 Router path may be longer than shortest path
2 AS hops,
8 router hops

s d

3 AS hops, 7 router hops


Shared Risks
 Co-location facilities (“co-lo hotels”)
 Places ISPs meet to connect to each other
 … and co-locate their routers, and share space & power
 E.g., 32 Avenue of the Americas in NYC
 Shared links
 Fiber is sometimes leased by one institution to another
 Multiple fibers run through the same conduits
 … and run through the same tunnels, bridges, etc.
 Difficult to identify and accounts for these risks
 Not visible in network-layer measurements
 E.g., traceroute does not tell you links in the same ditch

Convergence

 Recently, it was realized that BGP convergence can undergo a process


analogous to count-to-infinity!

Prefix P X 1 2
In AS X

View from
here 4 3

 AS 4 uses path 4 1 X. A link fails and 1 withdraws 4 1 X.


 So 4 uses 4 2 1 X, which is soon withdrawn, then 4 3 2 1 X, …
 Result is many invalid paths can be explored before convergence
Impact of Policies – Example

 Early Exit / Hot Potato


 “if it’s not for you, bail”

 Combination of best local


policies not globally best A

 Side-effect: asymmetry
B

Key Concepts

 Internet is a collection of Autonomous Systems (ASes)


 Policy dominates routing at the AS level
 Structural hierarchy helps make routing scalable
 BGP routes between autonomous systems (ASes)

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy