CCN 3
CCN 3
3. Define Datagram
A datagram is a self-contained, independent packet of data that carries enough
information to be routed from the source to the destination without relying on
earlier exchanges between the source and destination computers and the
transporting network. In the context of networking, datagrams are used in
connectionless communication where each packet is treated independently.
To illustrate how a datagram network works, let's go through the example provided:
1. Message Preparation:
A process P1 on host H1 has a message to send to process P2 on host H2. P1
passes the message to the transport layer with instructions for delivery to P2.
2. Transport Layer Processing:
The transport layer on H1 adds a transport header to the message, resulting in
a transport layer segment. This segment is then handed to the network layer.
3. Fragmentation:
If the message is too large, it is divided into smaller packets (datagrams). For
instance, if the message is four times the maximum packet size, it is split into
four smaller packets.
4. Routing through Routers:
Each packet (datagram) is sent to the first router (Router A).
Router A's Processing:
Router A has an internal routing table that specifies where to send packets
based on their destination addresses.
It forwards packets to the appropriate next-hop routers (B or C).
5. Independent Routing:
Each datagram is routed independently. For example:
Packet 1 might be routed through Router C to E, then F, and finally
delivered to H2.
Packets 2 and 3 follow the same route.
Packet 4, due to a traffic jam on the ACE path, is rerouted through Router B.
6. Dynamic Routing Decisions:
Routers make dynamic routing decisions based on current network conditions.
Routing algorithms update routing tables and decide the best path for each
datagram.
Routing can be classified into several types based on different criteria and
algorithms used for determining the paths that data packets should take through a
network. Here are the primary classifications of routing:
7. How the packets cost referred in distance vector and link state routing?
Metric Selection: The packet cost can be defined based on various metrics, such
as hop count (number of routers between the source and destination), delay
(time taken for packets to traverse the path), bandwidth (capacity of the link),
or a combination thereof.
Path Selection: Routers select paths with lower packet costs. For example, if the
metric is hop count, routers prefer paths with fewer hops. If the metric is delay,
routers prefer paths with lower transmission delays.
Exchange and Calculation: Routers exchange their routing tables with
neighboring routers to update their knowledge of the network topology and
calculate the total cost to each destination based on the received information.
1. Packet Switching: Internet traffic is divided into small packets that are routed
independently across multiple networks based on destination addresses. This
efficient method allows for optimal use of network resources.
2. Protocols: Various protocols such as TCP/IP (Transmission Control
Protocol/Internet Protocol) govern how data is transmitted, routed, and
received across the Internet. These protocols ensure reliable communication
and data integrity.
3. Routing: Routers play a crucial role in directing packets between networks.
They use algorithms to determine the best path for each packet based on
network conditions, such as traffic load and link availability.
4. DNS (Domain Name System): DNS translates domain names (like
example.com) into IP addresses (like 192.0.2.1) that computers use to
identify each other on the Internet. This translation is essential for locating
resources and services.
5. Peering and Transit: Internet service providers (ISPs) and networks connect
with each other through peering (direct interconnection) or transit (paid
access). These agreements ensure global connectivity and data exchange.
6. Security and Encryption: Measures such as firewalls, encryption protocols
(e.g., SSL/TLS), and authentication mechanisms protect data privacy and
integrity during transmission over the Internet.
7. Content Delivery: Content delivery networks (CDNs) and caching systems
optimize the delivery of web content by storing copies closer to users,
reducing latency and improving performance.
8. Internet Governance: Various organizations and standards bodies (e.g.,
ICANN, IETF) oversee the coordination, management, and development of
Internet protocols and resources globally.