CSCI-690 Computer Networks: Shrinking the globe one click at a time Lecture 5 - PowerPoint PPT Presentation

1 / 34
About This Presentation
Title:

CSCI-690 Computer Networks: Shrinking the globe one click at a time Lecture 5

Description:

Computer Networks: Shrinking the globe one click at a time. Lecture 5. Khurram Kazi ... algorithms that have continued to evolve throughout the history of networking ... – PowerPoint PPT presentation

Number of Views:51
Avg rating:3.0/5.0
Slides: 35
Provided by: iris6
Category:

less

Transcript and Presenter's Notes

Title: CSCI-690 Computer Networks: Shrinking the globe one click at a time Lecture 5


1
CSCI-690Computer NetworksShrinking the globe
one click at a timeLecture 5
  • Khurram Kazi

2
Major sources of the slides for this lecture
  • Computer Networks A Systems Approach, Larry
    Peterson
  • The Internet and Its Protocol, Adrian Farrels
    book.

3
Reference Network For discussion purposes
4
Internet Control Message Protocol (ICMP)
  • ICMP is carried inside an IP datagram
  • Is considered to be at the internet layer
    (network layer)
  • ICMP is fundamental to the operation of IP
    networks and is so closely related to IP that it
    is not possible to operate hosts within an IP
    network without supporting ICMP
  • Used by the routers to identify the hosts and
    other routers Most commonly ICMP is used for
  • Sending error message about unreachable
    destinations
  • Sending error and status messages about routes
    and gateways
  • Sending echo requests and replies to indicate
    status of reachable hosts
  • Sending error message about traffic that has
    timed-out (TTL drops too low)

5
ICMP Message format
6
ICMP Messages
Message Type Message
0 Echo reply. Sent in direct response to an ICMP echo request message
3 Destination Unreachable. An error message sent when a node cannot forward any IP datagram towards its destination
4 Source Quench. Sent by a destination node to slow down the rate at which a source node sends IP datagrams
5 Redirect. Used to tell a source node that there is a better first hop for it to use when trying to send IP datagrams to a given destination.
8 Echo. Sent by a node to probe the network for reachability to a particular destination
9 Router Advertisement. Used by a router to tell hosts in its network that it exists and is ready for service.
10 Router Solicitation. Used by a host to discover which routers are available for use.
11 Time Exceeded. An error message generated by a router when it cannot forward an IP datagram because the TTL has expired.
12 Parameter Problem. An error sent by any node that discovers a problem with an IP datagram it has received
13 Timestamp Request. Used to probe the network for the transmission and processing latency of message to a give destination.
14 Timestamp Reply. Used in direct response to a Timestamp Request Message
15 Information request. Used by a host to discover the subnet to which its is attached.
16 Information Reply. Used in direct response to an Information Request message
17 Address Mask request. Used by a host to discover the subnet mask for the network to which it is attached
18 Address Mask Reply. Used in direct response to an Address Mask Request message.
7
ICMP
  • Ground rules for ICMP
  • ICMP message cannot generate ICMP error messages
  • ICMP cannot generate broadcast or multicast
    messages
  • These rules help avoid broadcast storms that
    can easily flood a network
  • Unreachability Message
  • Indicate that there has been a failure somewhere
    in the process of addressing the datagram that
    triggers the message.
  • For example, incorrectly addressed datagrams
    will cause unreachable messages to be sent
  • More often, if a host is simply turned off or
    even when the specified protocol is not available
    (e.g., trying to connect to a network application
    port that is prohibited or restricted).

8
ICMP
  • ICMP Routing Messages
  • Routing messages include requests for a list of
    available routers and replies that include list
    of other available routers along with a priority
    number for each router.
  • Hosts sometimes make these requests when they
    boot up to initialize their routing tables
  • Routers advertise gateways when they bootup.
  • Routers also periodically broadcast this
    information.
  • Another type of routing message is generated when
    a router becomes overloaded, whether from
    high-volume stream of traffic from a single host
    or from a generally high load due to many hosts.
  • ICMP message may carry routing information when a
    host sends traffic to one router and a different
    router advertises a better route (route with
    fewer hops). This is called redirect. Commonly
    happens on networks with more than one router,
    where the hosts start out with only a single
    router in their routing tables

9
ICMP
  • Ping and ICMP Echo Messages
  • Ping (or PING) is named from Packet InterNet
    Groper
  • Ping sends an ICMP echo request out to a specific
    host, and the host responds to ICMP echo requests
    by sending out an ICMP echo reply
  • Represents the simple level of connectivity
    possible between two hosts on an internetwork
  • Useful for testing whether a remote host is
    reachable or whether the network connection for a
    local host is properly configured and installed
  • Command has the format
  • Ping lt IP host name IP address gt

10
Traceroute (tracert command DOS)
  • Used to attempt to trace the route between two
    hosts on an internetwork
  • Uses TTL field and multiple passes to collect
    information.
  • Starts with a TTL of 1, the neighboring router
    drops that packet and sends back an ICMP message
  • Sends the next packet with TTL of 2. This allows
    the packet to go to the second hop. The second
    hop router sends an ICMP message back to the
    origination host that indicates that the
    offending datagram expired on the network
  • The origination host keeps on increasing the TTL
    until it has all the relevant information it is
    looking for about the route between it and the
    destination host.
  • Examining the list of nodes that returned errors
    gives us the path through the network to the
    destination.
  • Examining the turnaround time for the error
    messages gives a measure of which hops in the
    network are consuming how much time

11
Routing
  • There are two basic routing problems
  • Interior Routing
  • Routing traffic within the organizational
    internetwork
  • Exterior Routing
  • Ensuring traffic is routed within the larger
    internetwork (Internet)
  • Internet at large must address exterior routing
    issues
  • Interior routing is managed by the local
    administrators of the organization

12
Routing and Forwarding
  • Distinction between forwarding and routing
  • Forwarding consists of taking a packet, looking
    at its destination address, consulting a table,
    and sending the packet in a direction determined
    by that table
  • Relatively simple and well-defined process
    performed locally at a node
  • Routing is the process by which forwarding tables
    are built.
  • Routing depends on complex distribution
    algorithms that have continued to evolve
    throughout the history of networking
  • Terms Forwarding table and Routing table are at
    times used interchangeably

13
Routing and Forwarding
  • Forwarding table contains enough information so
    that the packet can be forwarded
  • Needs to be optimized for quick lookup of a
    network number when forwarding a packet (mostly
    implemented in special hardware)
  • Routing table on the other hand is a table that
    is built by routing algorithms as a precursor to
    building the forwarding table
  • Needs to be optimized for the purpose of
    calculating changes in topology
  • Contains mapping from network numbers to next
    hops
  • May also contain information about how this
    information was learnt, so that the router will
    be able to decide when it should discard some
    information

14
Routing and Forwarding
  • What are intradomain and interdomain routing
    protocols?
  • First we have to define what a Routing Domain
    is
  • A good working definition is an internetwork in
    which all routers are under the same
    administrative control (e.g., a single university
    campus or a network of a single, or Internet
    Service Provider)
  • In defining routing protocols, one key question
    that needs to be asked is
  • Does the solution scale?
  • For now we will concentrate on small to midsized
    networks.

15
Routing and Forwarding
  • Routing is essence, a problem of graph theory
  • Nodes of the graph labeled A F
  • They could be hosts, switches, routers, or
    networks
  • For now assume nodes are routers
  • The edges of the graph correspond to the network
    links
  • Each edge has an associated cost
  • Can be used in deciding where to direct traffic
    to from local node
  • Basic problem of routing is to find the
    lowest-cost path between any two nodes.
  • Cost equals the sum of the costs of all edges
    that make up the path

16
Routing and Forwarding
  • For this simple network one can calculate the
    shortest path and load the values into some
    non-volatile storage on each node
  • This has drawbacks
  • It does not deal with node or link failures
  • It does not consider the addition of new nodes or
    links
  • It implies that edge cost cannot change, even
    though we might reasonably wish to assign a high
    cost to a link that is heavily congested

17
Routing
  • Achieved in most practical networks by running
    routing protocols among the nodes
  • These protocols provide distributed, dynamic way
    to solve the problem of finding lowest-cost path
    in presences of link and node Failures and
    changing edge costs
  • Difficult to make centralized solutions scalable,
    hence commonly used routing protocols use
    distributed algorithms
  • Challenges For example, distributed algorithms
    raise the possibility that two routers will at
    one instant have different ideas about the
    shortest path to some destination

18
Adding Router means must have the capability to
advertise reachability
Before addition of the new router.what is the
route between network A and Network D? How many
hops? When the new router was added, how many
hops? Routing protocols allow routers to
communicate network connectivity across network
boundaries to other routers. Reachability data is
passed along, as well as changes in
reachbility If a router fails, routing protocols
allow neighboring routers to report the failure
to the neighbors
19
Vector/Distance vs. Link State Routing
  • Routing protocols can use two basic methods to
    measure connectivity across internetwork
  • Vector/Distance
  • Routers share their routing tables and make
    additions and corrections based on reports from
    other routers
  • Routers are advertised as data pairs, with the
    router reporting each network it can reach along
    with the number of hops it takes to reach it
  • Receiving router looks at the information,
    compares it with its routing table, if there is
    new information it updates its routing table,
    e.g.,
  • Additional network that did not exist before
  • Network connectivity showing few hops to a
    certain destination
  • This approach can be quite cumbersome as the
    network grows as routers track connections and
    pass the information to each other. This results
    into processing of larger and larger list of
    network routes

20
Distance Vector (Routing Information Protocol,
RIP)
  • Idea behind distance-vector algorithm is that
    each node constructs a one-dimensional array (a
    vector) containing distances (costs) to all
    other nodes and distributes that vector to its
    immediate neighbors
  • It is assumed that each node knows the cost of
    the link to each of its directly connected
    neighbors.
  • Link that is down is assigned an infinite cost

21
Distance Vector (Routing Information Protocol,
RIP)
Information stored at each node A B C D E F G
A 0 1 1 8 1 1 8
B 1 0 1 8 8 8 8
C 1 1 0 1 8 8 8
D 8 8 1 0 8 8 1
E 1 8 8 8 0 8 8
F 1 8 8 8 8 0 1
G 8 8 8 1 8 1 0
Initial distances stored at each node (global
view)
22
Distance Vector (Routing Information Protocol,
RIP)
Destination Cost Next hop
B 1 B
C 1 C
D 8 - (unreachable)
E 1 E
F 1 F
G 8 - (unreachable)
Initial routing table at node A
23
Distance Vector (Routing Information Protocol,
RIP) (Each node sending a message to its
neighbor)
Destination Cost Next hop
B 1 B
C 1 C
D 2 C
E 1 E
F 1 F
G 2 F
e.g. F tells A that it can reach G at a cost of
1 A knows it can reach F at cost of 1 gt cost of
2 C tells A that it can reach D at a cost of
1 Hence, 2 is the cost for A to reach D
Final routing table at node A
24
Distance Vector (Routing Information Protocol,
RIP) (Final distances stored at each node
global view)
Information stored at each node A B C D E F G
A 0 1 1 2 1 1 2
B 1 0 1 2 2 2 3
C 1 1 0 1 2 2 2
D 2 2 1 0 3 3 1
E 1 2 2 3 0 2 3
F 1 2 2 2 2 0 1
G 2 3 2 1 3 1 0
  • In absence of any topology changes, it takes only
    few exchanges of information between neighbors
    before each node has a complete routing table
  • The process of getting consistent routing
    information to all nodes is called CONVERGENCE

25
Distance Vector (Routing Information Protocol,
RIP)
  • No one node in the network has all the
    information in the table
  • Each node only knows about the contents of its
    own routing table
  • Beauty of the distributed algorithm like this is
    that it enables all nodes to achieve a consistent
    view of the network in the absence of any
    centralized authority

26
Distance Vector (Routing Information Protocol,
RIP)
  • Two different circumstances under which a given
    node decides to send a routing update to its
    neighbors
  • Periodic update
  • Each node automatically sends an update message,
    even if nothing changed. This serves to let the
    other nodes know that this node is still running
  • Frequency of these updates varies from protocol
    to protocol
  • Typically is in the order of several seconds
  • Triggered update
  • Happens whenever a node receives an update from
    one of its neighbors that causes it to change one
    of the routes its routing table

27
Distance Vectors Review with IP addresses
28
Routing Table at Router E. After Full
Distribution
Loopback IP/local host address
Destination Outgoing Interface Distance Next Hop
E 127.0.0.1 0 -
B 10.0.6.2 1 B
F 10.0.7.1 1 F
C 10.0.6.2 2 B
D 10.0.7.1 2 F
A 10.0.6.2 2 B
29
Distance Vectors e.g., Routing Table at Router
E. Initial routing Distribution while the link
between Routers A and B Disabled
Loopback IP/local host address
Destination Outgoing Interface Distance Next Hop
E 127.0.0.1 0 -
B 10.0.6.2 1 B
F 10.0.7.1 1 F
C 10.0.6.2 2 B
D 10.0.7.1 2 F
A 10.0.7.1 3 F
30
Vector/Distance vs. Link State Routing
  • Link State
  • Keeps the volume of information passed along to
    other routers to a minimum
  • Each router periodically checks on the status of
    neighboring routers, reporting which links are
    alive to all the other participating routers
  • With the this information each router can then
    create its own map of the internetwork

31
RIP Routing Protocol RFC 1058
  • RIP is one of a class of algorithms known as
    "distance vector algorithms".
  • RIP is intended for use within the IP-based
    Internet. The Internet is organized into a number
    of networks connected by gateways. The networks
    may be either point-to-point links or more
    complex networks. Hosts and gateways are
    presented with IP datagrams addressed to some
    host.
  • Limitations of the protocol
  • This protocol does not solve every possible
    routing problem. Its is primary intended for use
    as an IGP, in reasonably homogeneous networks of
    moderate size.
  • The protocol is limited to networks whose longest
    path involves 15 hops.
  • It is inappropriate to use this for larger
    networks
  • The protocol depends upon "counting to infinity"
    to resolve certain unusual situations
  • Routing messages received from
  • This protocol uses fixed "metrics" to compare
    alternative routes. It is not appropriate for
    situations where routes need to be chosen based
    on real-time parameters such a measured delay,
    reliability, or load. The obvious extensions to
    allow metrics of this type are likely to
    introduce instabilities of a sort that the
    protocol is not designed to handle.

32
RIPv2 message format
RIPv2 message consists of a 4-byte header
followed by from 1 to 125 route entries
33
RIP Details commands
1 Request A request for the responding system to send all or part of its routing table
2 Response A message containing all or part of the senders routing table. This message may be sent in response to a request or poll, or it may be an update message generated by the sender.
3 Traceon Obsolete (should be ignored)
4 Traceoff Obselete
5 -- reserved
Rest of the datagram contains a list of
destination, with information about each. Each
entry in this list contains a destination or
host, and the metric for it.
34
RIP Details
  • RIP can carry routing information for several
    different protocols. For IP the address family
    identifier is 2.
  • The IP address is the usual Internet address,
    stored as 4 octets in network order.
  • The metric field must contain a value between 1
    and 15 inclusive, specifying the current metric
    for the destination, or the value 16, which
    indicates that the destination is not reachable.
  • Metric" measuring the total distance to the
    entity. Distance is a somewhat generalized
    concept, which may cover the time delay in
    getting messages to the entity, the dollar cost
    of sending messages to it, etc.
Write a Comment
User Comments (0)
About PowerShow.com