You are on page 1of 68

MCA-309, Advanced Computer Networks

Advanced Computer
Networks
UNIT - II

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U1.
1

Learning Objectives
In this Unit we will discuss :
Network Layer
ARP, RARP
ICMP
Routing Algorithms and Protocols
Router Operation and Configuration
Internetworking
IPV4 Protocol
IPV6 Protocol

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
2

Network Layer

Network Layer is responsible for host-to-host delivery and


for routing the packets through the routers.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
3

U2.1
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

ARP
Address Mapping
ARP Protocol
ARP Package

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
4

ARP and RARP

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
5

ARP and RARP


Position of ARP and RARP in TCP/IP protocol suite

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
6

U2.2
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

ARP
ARP associates an IP address with its physical address. On a
typical physical network, such as a LAN, each device on a
link is identified by a physical or station address that is usually
imprinted on the NIC.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
7

ARP
It may be noted that the knowledge of hosts IP address is not
sufficient for sending packets, because data link hardware
does not understand internet addresses. For example, in an
Ethernet network, the Ethernet controller card can send and
receive using 48-bit Ethernet addresses. The 32-bit IP
addresses are unknown to these cards. This requires a
mapping of the IP addresses to the corresponding Ethernet
addresses. This mapping is accomplished by using a
technique known as Address Resolution Protocol (ARP).

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
8

ARP
An ARP request is broadcast to all stations in the network
An ARP reply is an unicast to the host requesting the
mapping

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
9

U2.3
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

ARP

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
10

ARP
ARP Packet

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
11

ARP
Encapsulation of ARP packet

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
12

U2.4
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

ARP
Four cases using ARP

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
13

ARP
Example
A host with IP address 130.23.43.20 and physical address
B2:34:55:10:22:10 has a packet to send to another host with
IP address 130.23.43.25 and physical address
A4:6E:F4:59:83:AB (which is unknown to the first host). The
two hosts are on the same Ethernet network. Show the ARP
request and reply packets encapsulated in Ethernet frames.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
14

ARP
Note that the ARP data field in this case is 28 bytes, and
that the individual addresses do not fit in the 4-byte
boundary. That is why we do not show the regular 4-byte
boundaries for these addresses. Also note that the IP
addresses are shown in hexadecimal.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
15

U2.5
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

ARP

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
16

Proxy ARP

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
17

ARP Package
This ARP package involves five modules:
1. a cache table,
2. queues,
3. an output module,
4. an input module,
5. and a cache-control module.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
18

U2.6
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

ARP Package

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
19

Summary
Delivery of packet to a host or router requires two levels of
addresses : logical and physical.
A logical address identifies a host or router at the network
level. TCP/IP call this logical address an IP address.
A physical address identifies a host or router at the physical
level.
ARP protocol is used to find physical address given a logical
address.
ARP request is broadcast to all devices on the network.
ARP reply is unicast to the host requesting the mapping.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
20

RARP
Introduction
RARP Protocol
RARP Package

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
21

U2.7
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

RARP
The TCP/IP protocols include another related protocol
known as reverse ARP, which can be used by a computer
such as a diskless host to find out its own IP address. It
involves the following steps:
Diskless host A broadcasts a RARP request specifying
itself as the target
RARP server responds with the reply directly to host A
Host A preserves the IP address in its main memory for
future use until it reboots

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
22

RARP
RARP finds the logical address for a machine that only
knows its physical address.

The RARP request packets are broadcast;


the RARP reply packets are unicast.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
23

RARP

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
24

U2.8
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

RARP Packet

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
25

RARP Packet
Encapsulation of RARP packet

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
26

Summary
RARP is used to find the logical address for a machine that
only knows its physical address.
RARP request is created and broadcast on the local network.
Another machine on the local network that knows all the IP
addresses will respond with a RARP reply.
Requesting machine must be running at RARP client
program.
Responding machine must be running at RARP server
program.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
27

U2.9
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

ICMP
Introduction
Messages
Debugging Tools
ICMP Package

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
28

ICMP
To make efficient use of the network resources, IP was
designed to provide unreliable and connectionless besteffort datagram delivery service. As a consequence, IP has
no error-control mechanism and also lacks mechanism for
host and management queries. A companion protocol
known as Internet Control Message Protocol (ICMP), has
been designed to compensate these two deficiencies.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
29

ICMP
Position of ICMP in the network layer

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
30

U2.10
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

ICMP
ICMP encapsulation

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
31

ICMP
ICMP Messages

ICMP messages are divided into error-reporting


messages and query messages. The error-reporting
messages report problems that a router or a host
(destination) may encounter. The query messages get
specific information from a router or another host.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
32

ICMP
ICMP Messages

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
33

U2.11
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

ICMP
ICMP messages

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
34

ICMP
Message Format
An ICMP message has an 8-byte header and a
variable-size data section.
Although the general
format of the header is different for each message
type, the first 4 bytes are common to all.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
35

ICMP
Message Format

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
36

U2.12
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

ICMP
ERROR REPORTING
IP, as an unreliable protocol, is not concerned with error
checking and error control. ICMP was designed, in part, to
compensate for this shortcoming. ICMP does not correct
errors, it simply reports them.

ICMP always reports error messages to the


original source.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
37

ICMP

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
38

ICMP
Contents of data field for the error messages

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
39

U2.13
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

ICMP
Destination-unreachable format

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
40

ICMP
Destination-unreachable format
Destination-unreachable messages with codes 2
or 3 can be created only by the destination host.
Other destination-unreachable messages can be
created only by routers.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
41

ICMP
Source-quench format

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
42

U2.14
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

ICMP
Source-quench format
A source-quench message informs the source
that a datagram has been discarded due to
congestion in a router or the destination host.
The source must slow down the sending of
datagrams until the congestion is relieved.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
43

ICMP
Source-quench format

One source-quench message is sent for each


datagram that is discarded due to congestion.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
44

ICMP
Time-exceeded message

Whenever a router decrements a datagram with a


time-to-live value to zero, it discards the datagram
and sends a time-exceeded message to the
original source.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
45

U2.15
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

ICMP
Time-exceeded message

When the final destination does not receive all of


the fragments in a set time, it discards the
received fragments and sends a time-exceeded
message to the original source.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
46

ICMP
Time-exceeded message

code 0 is used only by routers to show that the


value of the time-to-live field is zero. Code 1 is
used only by the destination host to show that not
all of the fragments have arrived within a set time.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
47

ICMP
Time-exceeded message format

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
48

U2.16
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

ICMP
Time-exceeded message format

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
49

ICMP
Parameter-problem

A parameter-problem message can be created by


a router or the destination host.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
50

ICMP
Parameter-problem message format

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
51

U2.17
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

ICMP
Redirection concept

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
52

ICMP
Redirection concept

A host usually starts with a small routing table


that is gradually augmented and updated. One of
the tools to accomplish this is the redirection
message.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
53

ICMP
Redirection message format

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
54

U2.18
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

ICMP
Redirection message

A redirection message is sent from a router to a


host on the same local network.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
55

ICMP
QUERY Messages

ICMP can also diagnose some network problems


through the query messages, a group of four
different pairs of messages. In this type of ICMP
message, a node sends a message that is answered
in a specific format by the destination node.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
56

ICMP

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
57

U2.19
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

ICMP

An echo-request message can be sent by a host


or router. An echo-reply message is sent by the
host or router which receives an echo-request
message.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
58

ICMP

Echo-request and echo-reply messages can be


used by network managers to check the operation
of the IP protocol.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
59

ICMP

Echo-request and echo-reply messages can test


the reachability of a host. This is usually done by
invoking the ping command.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
60

U2.20
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

ICMP
Echo-request and echo-reply messages

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
61

ICMP

Timestamp-request and timestamp-reply

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
62

ICMP

Timestamp-request and timestamp-reply


messages can be used to calculate the round-trip
time between a source and a destination machine
even if their clocks are not synchronized.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
63

U2.21
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

ICMP

The timestamp-request and timestamp-reply


messages can be used to synchronize two clocks
in two machines if the exact one-way time
duration is known.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
64

ICMP
Timestamp-request and timestamp-reply
message format

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
65

ICMP
Mask-request and mask-reply message format

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
66

U2.22
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

ICMP
Router-solicitation message format

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
67

ICMP
Router-advertisement message format

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
68

ICMP
Debugging Tools
Two tools that use ICMP for debugging:
1. ping
2. traceroute.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
69

U2.23
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

ICMP
Example

$ ping fhda.edu
PING fhda.edu (153.18.8.1) 56 (84) bytes of data.
64 bytes from tiptoe.fhda.edu (153.18.8.1): icmp_seq=0 ttl=62 time=1.91 ms
64 bytes from tiptoe.fhda.edu (153.18.8.1): icmp_seq=1 ttl=62 time=2.04 ms
64 bytes from tiptoe.fhda.edu (153.18.8.1): icmp_seq=2 ttl=62 time=1.90 ms
64 bytes from tiptoe.fhda.edu (153.18.8.1): icmp_seq=3 ttl=62 time=1.97 ms
64 bytes from tiptoe.fhda.edu (153.18.8.1): icmp_seq=4 ttl=62 time=1.93 ms

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
70

ICMP
The traceroute program operation

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
71

ICMP
Example
We use the traceroute program to find the route from the
computer voyager.deanza.edu to the server fhda.edu. The
following shows the result:

$ traceroute

fhda.edu

traceroute to fhda.edu (153.18.8.1), 30 hops max, 38 byte packets


1 Dcore.fhda.edu (153.18.31.254) 0.995 ms 0.899 ms 0.878 ms
2 Dbackup.fhda.edu (153.18.251.4) 1.039 ms 1.064 ms 1.083 ms
3 tiptoe.fhda.edu (153.18.8.1) 1.797 ms 1.642 ms 1.757 ms

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
72

U2.24
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

ICMP
ICMP Package
To give an idea of how ICMP can handle the sending and
receiving of ICMP messages, an ICMP package made of two
modules: an input module and an output module.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
73

ICMP
ICMP Package

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
74

Summary
ICMP send five types of error reporting messages and four
types pairs of query messages to support the unreliable and
connectionless Internet Protocol.
ICMP messages are encapsulated in IP datagrams.
Packet InterNet Groper (Ping) is an application program
that uses the services of ICMP to test the reachablity of a
host.
A simple ICMP design can consist of an input module that
handles incoming ICMP packets and an output module that
handles demands for ICMP services.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
75

U2.25
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

Routing Algorithms
Introduction
Routing Protocols
Unicast Routing Protocols
Multicast Routing protocols

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
76

Routing Algorithms
Unicast Routing Protocols:
RIP, OSPF, and BGP

1. intra and inter domain routing


2. distance vector routing and RIP
3. link state routing and OSPF
4. path vector routing and BGP

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
77

Routing Algorithms
Intra and Inter Domain Routing Protocols

Routing inside an autonomous system is referred to


as intradomain routing.

Routing between autonomous systems is referred to


as interdomain routing.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
78

U2.26
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

Routing Algorithms

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
79

Routing Algorithms

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
80

Routing Algorithms
Distance Vector Routing

In distance vector routing, the least cost route between any


two nodes is the route with minimum distance. In this
protocol each node maintains a vector (table) of minimum
distances to every node

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
81

U2.27
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

Routing Algorithms

In distance vector routing, each node shares its


routing table with its immediate neighbors
periodically and when there is a change.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
82

Routing Algorithms

In distance vector routing, each node shares its


routing table with its immediate neighbors
periodically and when there is a change.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
83

Routing Algorithms
Distance vector routing tables

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
84

U2.28
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

Routing Algorithms
Initialization of tables in distance vector routing

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
85

Routing Algorithms
Updating in distance vector routing

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
86

Routing Algorithms
Two-node instability

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
87

U2.29
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

Routing Protocol
RIP
The Routing Information Protocol (RIP) is an
intradomain routing protocol used inside an autonomous
system. It is a very simple protocol based on distance
vector routing.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
88

Routing Protocol
RIP
The Routing Information Protocol (RIP) is one of the
most commonly used Interior Gateway Protocol on
internal networks which helps a router dynamically adapt
to changes of network connections by communicating
information about which networks each router can reach
and how far away those networks are. Although RIP is
still actively used, it is generally considered to have been
obsolete by Link-state routing protocol such as OSPF.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
89

Routing Protocol

RIP uses the services of UDP on


well-known port 520.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
90

U2.30
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

Routing Protocol
Example of a domain using RIP

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
91

Routing Protocol
RIP message format

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
92

Routing Protocol
Request messages

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
93

U2.31
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

Routing Protocol
RIP timers
RIP uses certain timers to regulate its performance. The
biggest drawback to a RIP router is the broadcast it makes.
RIP uses numerous timers to regulate its performance.
These include a routing-update timer, a route-timeout timer,
and a route-flush timer. The routing-update timer clocks the
interval between periodic routing updates, each router
periodically transmits it entire routing table to all the other
routers on the network. Generally, it is set to 30 seconds,
with a small random amount of time added whenever the
timer is reset.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
94

Routing Protocol
RIP timers

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
95

Routing Protocol
RIP version 2 format

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
96

U2.32
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

Routing Protocol
RIP version 2 format
RIP Version 2 (RIPv2) RIP Version 2 adds a "network
mask" and "next hop address" field to the original RIP
packet while remaining completely compatible with RIP.
Thus RIPv2 routers can coexist with RIP routers without
any problems.
The subnet mask field contains the network bit mask
associated with the destination; it also allows the
implementation of CIDR addressing. This will allow RIP to
function in a variety of environments, which may implement
variable subnet masks on a network.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
97

Routing Algorithms
Link State Routing
In link state routing, if each node in the domain has the entire
topology of the domain, the node can use Dijkstras
algorithm to build a routing table.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
98

Routing Algorithms

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
99

U2.33
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

Routing Algorithms
Link state knowledge

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
100

Routing Algorithms
Dijkstra algorithm

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
101

Routing Algorithms
Example of formation of shortest path tree

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
102

U2.34
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

Routing Algorithms
Routing table for node A

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
103

Routing Protocol
OSPF
Open Shortest Path First (OSPF) is another Interior
Gateway Protocol. It is a routing protocol developed for
Internet Protocol (IP) networks by the Interior Gateway
Protocol (IGP) working group of the Internet Engineering
Task Force (IETF). The working group was formed in 1988
to design an IGP based on the Shortest Path First (SPF)
algorithm for use in the Internet. OSPF was created
because in the mid-1980s, the Routing Information Protocol
(RIP) was increasingly incapable of serving large,
heterogeneous internetworks. OSPF being a SPF algorithm
scales better than RIP.
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
104

Routing Protocol
OSPF

The Open Shortest Path First (OSPF) protocol is an intra


domain routing protocol based on link state routing. Its
domain is also an autonomous system.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
105

U2.35
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

Routing Protocol
OSPF also has the following features:
Advertise about neighborhood: Instead of sending its
entire routing table, a router sends information about its
neighborhood only.
Flooding: Each router sends this information to every
other router on the internetwork, not just to its neighbors. It
does so by a process of flooding. In Flooding, a router
sends its information to all its neighbors (through all of its
output ports). Every router sends such messages to each of
its neighbor, and every router that receives the packet
sends copies to its neighbor. Finally, every router has a
copy of same information.
Active response: Each outer sends out information about
the neighbor when there is a change.
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
106

Routing Protocol

OSPF packets are encapsulated in IP datagrams.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
107

Routing Protocol
Areas in an autonomous system

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
108

U2.36
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

Routing Protocol

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
109

Routing Protocol

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
110

Routing Protocol

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
111

U2.37
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

Routing Protocol

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
112

Routing Protocol

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
113

Routing Protocol

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
114

U2.38
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

Routing Protocol
OSPF common header

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
115

Routing Protocol
Link state update packet

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
116

Routing Protocol
LSA general header

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
117

U2.39
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

Routing Protocol
Router link

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
118

Routing Protocol
Router link LSA

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
119

Routing Protocol
Link types, link identification, and link data

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
120

U2.40
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

Routing Protocol
Example - Give the router link LSA sent by router 10.24.7.9

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
121

Routing Protocol
This router has three links: two of type 1 (point-to-point) and
one of type 3 (stub network).

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
122

Routing Algorithms
Path Vector Routing

Path vector routing is similar to distance vector routing.


There is at least one node, called the speaker node, in
each AS that creates a routing table and advertises it to
speaker nodes in the neighboring ASs..

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
123

U2.41
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

Routing Algorithms

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
124

Routing Algorithms

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
125

Routing Protocol
Border Gateway Protocol

Border Gateway Protocol (BGP) is an inter domain routing


protocol using path vector routing. It first appeared in 1989
and has gone through four versions.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
126

U2.42
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

Routing Protocol

BGP supports classless addressing and CIDR.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
127

Routing Protocol

BGP uses the services of TCP


on port 179.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
128

Routing Protocol
Internal and external BGP sessions

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
129

U2.43
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

Routing Protocol

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
130

Routing Protocol
BGP packet header

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
131

Routing Protocol
Open message

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
132

U2.44
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

Routing Protocol
Update message

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
133

Routing Protocol
Keepalive message

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
134

Routing Protocol
Notification message

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
135

U2.45
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

Routing Protocol

A message can be unicast, multicast, or broadcast.


Let us clarify these terms as they relate to the
Internet.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
136

Routing Protocol
Unicast :-

the router forwards the received packet


through only one of its interfaces

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
137

Routing Protocol
Multiicast :- the router may forward the received packet
through several of its interfaces

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
138

U2.46
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

Routing Protocol

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
139

Routing Protocol

Emulation of multicasting through multiple


unicasting is not efficient and may create long
delays, particularly with a large group.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
140

Routing Protocol

In unicast routing, each router in the domain has


a table that defines a shortest path tree to
possible destinations.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
141

U2.47
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

Routing Protocol

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
142

Routing Protocol

In multicast routing, each involved router needs


to construct a shortest path tree for each group.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
143

Routing Protocol

In the source-based tree approach, each router


needs to have one shortest path tree for each
group.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
144

U2.48
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

Routing Protocol

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
145

Routing Protocol

In the group-shared tree approach, only the core


router, which has a shortest path tree for each
group, is involved in multicasting.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
146

Routing Protocol

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
147

U2.49
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

Routing Protocol

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
148

Summary
A metric is the cost assigned for passage of a packet
through a network.
A router consults its routing table to determine the best path
of a packet.
An autonomous system is a group of networks and routers
under the authority of a single administration.
RIP and OSPF are popular intra domain routing protocols
used to update routing table in an AS.
RIP use three timers.
BGP is an inter autonomous system routing protocol used
to update routing tables.
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
149

Router Operation
Introduction to Routers
Overview of Router Modes
Router Interfaces

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
150

U2.50
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

Router Configuration
Overview of Router Configuration
Static Routing
Dynamic Routing
Default Routing

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
151

IPV4 Protocol
Introduction
Datagrams
Fragmentation
IP Package

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
152

IPV4 Protocol
IP is an unreliable and connectionless best-effort delivery
service protocol. By best effort we mean that there is no
error and flow control. However, IP performs error detection
and discards a packet, if it is corrupted. To achieve
reliability, it is necessary to combine it with a reliable
protocol such as TCP. Packets in IP layer are called
datagrams. The IP header provides information about
various functions the IP performs.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
153

U2.51
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

IPV4 Protocol

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
154

IPV4 Protocol
A packet in the IP layer is called a datagram, a variablelength packet consisting of two parts: header and data.
The header is 20 to 60 bytes in length and contains
information essential to routing and delivery.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
155

IPV4 Protocol
IP Datagram

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
156

U2.52
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

IPV4 Protocol
Service type or differentiated services

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
157

IPV4 Protocol

The precedence subfield was designed, but never


used in version 4.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
158

IPV4 Protocol
Types of service

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
159

U2.53
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

IPV4 Protocol
Multiplexing

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
160

IPV4 Protocol
Protocols

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
161

IPV4 Protocol
Fragmentation
The format and size of a frame depend on the protocol
used by the physical network. A datagram may have to
be fragmented to fit the protocol regulations.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
162

U2.54
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

IPV4 Protocol
Fragmentation
Each network imposes a limit on maximum size, known
as maximum transfer unit (MTU) of a packet because of
various reasons. One approach is to prevent the
problem to occur in the first place, i.e. send packets
smaller than the MTU. Second approach is to deal with
the problem using fragmentation. When a gateway
connects two networks that have different maximum and
or minimum packet sizes, it is necessary to allow the
gateway to break packets up into fragments, sending
each one as an internet packet. The technique is known
as fragmentation.
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
163

IPV4 Protocol
Maximum Transfer Unit (MTU)

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
164

IPV4 Protocol
MTUs for some networks

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
165

U2.55
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

IPV4 Protocol
Fragmentation Example

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
166

IPV4 Protocol

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
167

IPV4 Protocol
OPTIONS
The header of the IP datagram is made of two parts: a
fixed part and a variable part. The variable part
comprises the options that can be a maximum of 40
bytes.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
168

U2.56
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

IPV4 Protocol
OPTION Format

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
169

IPV4 Protocol
Categories of Option

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
170

IPV4 Protocol
No Operation Option

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
171

U2.57
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

IPV4 Protocol
Record Route Option

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
172

IPV4 Protocol
Record Route Concept

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
173

IPV4 Protocol
Time Stamp Concept

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
174

U2.58
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

IPV4 Protocol
Checksum
The error detection method used by most TCP/IP
protocols is called the checksum. The checksum
protects against the corruption that may occur during the
transmission of a packet. It is redundant information
added to the packet.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
175

IPV4 Protocol
Checksum
To create the checksum the sender does the following:
The packet is divided into k sections, each of n bits.
All sections are added together using 1s complement
arithmetic.
The final result is complemented to make the
checksum.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
176

IPV4 Protocol

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
177

U2.59
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

IPV4 Protocol

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
178

IPV4 Protocol

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
179

IPV4 Protocol
IP Package
IP software package to show its components and the
relationships between the components. This IP package
involves following modules.
1. Header-Adding Module
2. Processing Module
3. Queues
4. Routing Table
5. Forwarding Module
6. MTU Table
7. Fragmentation Module
8. Reassembly Table
9. Reassembly Module
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
180

U2.60
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

IPV4 Protocol
IP Components

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
181

IPV4 Protocol
MTU Table

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
182

IPV4 Protocol
Reassembly Table

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
183

U2.61
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

Summary
IP is an unreliable connectionless protocol responsible for
source-to-destination delivery.
Packets in the IP layer are called datagrams.
A datagram consists of a header (20 to 60 bytes) and data.
The maximum length of a datagram is 65535 bytes.
MTU is the maximum number of bytes that a data link
control can encapsulate. MTU is vary from protocol to
protocol.
The options section of the IP header is used for network
testing and debugging.
The error detection method used by IP is the checksum.
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
184

IPV6 Protocol
Introduction
Packet Format
Transition from IPV4 to IPV6

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
185

IPV6 Protocol
The network layer that is present in use in commonly
referred to as IPv4. Although IPv4 is well designed and has
helped the internet to grow rapidly, it has some
deficiencies, These deficiencies has made it unsuitable for
the fast growing internet. To overcome these deficiencies,
Internet Protocol, Version 6 protocol has been proposed
and it has evolved into a standard.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
186

U2.62
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

IPV6 Protocol
Important features of IPv6 are highlighted below:
IPv6 uses 128-bit address instead of 32-bit address to
provide larger address space
Uses more flexible header format, which simplifies and
speeds up the routing process
Basic header followed by extended header
Resource Allocation options, which was not present in
IPv4
Provision of new/future protocol options
Support for security with the help of encryption and
authentication
Support for fragmentation at source

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
187

IPV6 Protocol
IPv6 has these advantages over IPv4:
1. larger address space
2. better header format
3. new options
4. allowance for extension
5. support for resource allocation
6. support for more security

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
188

IPV6 Protocol
IPv6 Address

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
189

U2.63
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

IPV6 Protocol
IPv6 Datagram

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
190

IPV6 Protocol
IPv6 Datagram

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
191

IPV6 Protocol
Comparison between IPv4 and IPv6 packet header

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
192

U2.64
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

IPV6 Protocol

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
193

IPV6 Protocol
IPV6 Extension Header

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
194

IPV6 Protocol

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
195

U2.65
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

IPV6 Protocol
Comparison between
IPv4 options and IPv6 extension headers

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
196

Summary
IPV6, the latest version of Internet Protocol., has a 128-bit
address space, a revised header format, new options, an
allowance for extension, support for resource allocation, and
increased security measures.
IPV6 uses hexadecimal colon notation with abbreviation
methods available.
An IPV6 datagram is composed of a base header and a
payload.
ICMP6, like version 4, report errors, handles group
memberships, updates specific router and host tables, and
checks the viability of a host.

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
197

Conclusion
Network Layer
ARP
Address Mapping
ARP Protocol
ARP Package

Routing Algorithms and Protocols


Introduction
Routing Protocols
Unicast Routing Protocols
Multicast Routing protocols
Router Operation and Configuration

RARP
Introduction
RARP Protocol
RARP Package
ICMP
Introduction
Messages
Debugging Tools
ICMP Package

IPV4 Protocol
Introduction
Datagrams
Fragmentation
IP Package
IPV6 Protocol
Introduction
Packet Format
Transition from IPV4 to IPV6

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
198

U2.66
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

Objective Type
1. Network layer is responsible for ____ to ____ delivery.
2. ARP is used to find ______ address to _______ address.
3. RARP is used to find _________ address to ____ address.
4. An autonomous system is a _______ of network.
5. BGP is a _________ protocol.
6. ICMP is a companion to the _______ protocol.
7. _______ and _______ are two types of ICMP messages.
8. In IPV4 address is of _____ bits.
9. In IPV6 address is of _____ bits.
10. Router works on _____ layer.
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
199

Short Questions
1. Which layer determines path selection in an internet
work?
2. What is one method mapping network addresses to
MAC addressed?
3. What is one method mapping MAC address to
network address.
4. What do you mean by Encapsulation.?
5. What do you mean by BGP ?
6. What is fragmentation in IP protocol ?
7. What are the various roles played by the Network
Layer?
8. Compare link-state and distance vector routing
algorithms.
9. Compare IPV4 and IPV6 header fields.
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
200

Short Questions
10)Explain the following ICMP messages
11)Write a Short note on RARP header.
12)Explain debugging tools in ICMP.
13)Explain different types of messages in ICMP.
14)How does ARP protocol work when a packet is to be
sent?
15)Explain the working of RARP.
16)Write the commands for configuring the router for
giving address to various interfaces. Give commands
for establishing connection between two networks &
communicating between them using some protocol.
Save the configuration. Write commands for seeing
other commands. How will you give password to a
router?

Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
201

U2.67
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

MCA-309, Advanced Computer Networks

Long Questions
1. Draw IPV4 header and explain in detail.
2. A host with IP address 130.23.43.20 and physical
address Ox B23455102210 has a packet to send to
another host with address 130.23.43.25 and physical
address Ox A46EF45983AB. The two hosts are on
the same Ethernet network. Show ARP request and
reply packet encapsulated in Ethernet frame.
3. Explain RIP protocol in detail.
4. Draw and differentiate between IPV 4 and IPV 6
header.
5. Compare ARP and RARP. Give their respective
operations.
6. Explain various parameters set during router
configuration.
7. Explain ARP package
8. Explain RARP package
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
202

Long Questions
9. Explain the types of BGP messages. Explain the
various fields involved.
10. Explain the various query messages in ICMP. Also
draw and explain the packet formats.
11. Describe the various links in OSPF.
12. What are the various components of a CISCO
Router? Explain them briefly.
13. Discuss the header of the Internet Protocol (IP).
Explain how fragmentation is done in IP with the help
of an example. What is the need of fragmentations?
14. What is proxy ARP? Explain with the help of an
example.
15. What are the problems associated with RIP? How can
these problems b overcome. Explain with the help of
example.
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
203

References
Main Reading Books:
1. Behrouz A. Forouzan, TCP/IP Protocol Suit, TMH, 4th Edition
2. Behrouz A. Forouzan, Data Communication and Networking,
TMH, 3rd edition
Reference Books:
1. Black U, Computer Networks-Protocols, Standards and
Interfaces, PHI, 1996.
2. Stallings W., Data and Computer Communications, 6th Ed.,
PHI, 2002.
3. Stallings W., SNMP, SNMPv2, SNMPv3, RMON 1 & 2, 3rd
Ed., Addison Wesley,1999.
4. Laurra Chappell (Ed), Introduction to Cisco Router
Configuration, Techmedia, 1999.
5. Tananbaum A. S., Computer Networks, 3rd Ed., PHI, 1999.
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

U2..
204

U2.68
Bharati Vidyapeeths Institute of Computer Applications and Management, New Delhi-63 by Vishal Jain

You might also like