Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
0% found this document useful (0 votes)
103 views

Computer Network Fundamentals - Engineering

Complete details explanation from basics of computer networking . This is mostly used by engineering students

Uploaded by

c pardha krishna
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
103 views

Computer Network Fundamentals - Engineering

Complete details explanation from basics of computer networking . This is mostly used by engineering students

Uploaded by

c pardha krishna
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 98

12150G48A - Network Fundamentals | II Yr / IV Sem

PRIST UNIVERSITY
(Estd. u/s 3 of UGC Act, 19 5 6)
_____________________________________________________________________________

12150G48A - NETWORK
FUNDAMENTALS
IV SEM / II YEAR

PREPARED BY
K.SANKAR GANESH
ASST. PROF / CSE

Dec - 2013
FACULTY OF ENGINEERING AND TECHNOLOGY

1|
12150G48A - Network Fundamentals | II Yr / IV Sem

12150G48A - NETWORK FUNDAMENTALS


AIM:

To understand the layers and basic components of network theory.

OBJECTIVES:

Identify the major network communications methods.


Identify network data delivery methods.
List and describe network media and hardware components.
Identify the major types of network implementations.
Identify the components of a TCP/IP,LAN,WAN implementation.
Explore tools, methods, and techniques used in managing a network.
Describe how to troubleshoot network issues.

UNIT I INTRODUCTION 9

Communication-Network as a platform- The architecture of the internet-trends in networking-


elements of communication-components of network-LAN – WAN - network protocols-
interaction of protocols - the benefits of a layered model- TCP/IP model-communication
process-PDU and encapsulation-OSI model-Comparing the OSI to the TCP\IP model-
Addressing in the network-Getting the data to the end device, internetwork and to the right
application.

UNIT II APPLICATION AND TRANSPORT LAYER 9

User applications, services and application layer protocols-functions-client/server model-servers-


P2P networking and applications-DNS services and protocols-WWW service and HTTP-E-mail
services and SMTP/POP protocols-MTA and MDA-FTP-DHCP-File sharing services and SMB
protocol-p2p services and Gnutella protocol- telnet services and protocol- Roles of transport layer-
TCP server processes-Connection establishment and termination-Three way handshake-session
termination-retransmission-congestion control-UDP.

UNIT III NETWORK LAYER AND ADDRESSING 9

Introduction to IPv4-Dividing hosts into groups-Routing- Device parameters – IP packets-


Gateway-Route-Destination network-Next HOP-packet forwarding-Routing process-Static and
dynamic routing-routing protocols-IPv4 Addresses-Types of Addresses- subnet mask-public and
private addresses- legacy IPV4 addressing – static or dynamic addressing- IANA-ISPs-
calculating addresses-testing the network layer.

2|
12150G48A - Network Fundamentals | II Yr / IV Sem

UNIT IV DATA LINK AND PHYSICAL LAYER 9

Accessing the media-MAC for shared media-MAC for Nonshared media-Logical topology vs
physical topology- Data link layer protocols-Framing- Addressing-The physical layer operations-
standards- fundamental principles-signaling bits for the media-data carrying capacity- Types of
physical media- media connectors.

UNIT V ETHERNET, CABLING AND CONFIGURING 9

Ethernet standards and implementation-Layer 1 and Layer 2 – logical link control-historic


Ethernet- legacy Ethernet-current Ethernet- Ethernet frame- Ethernet MAC- Ethernet physical
layer-HUBs and Switches-ARP-LAN and WAN getting connected-addressing scheme-
calculating the subnets – device interconnections-IOS basics-configuration using CISCO IOS-
verifying connectivity- monitoring and documenting networks.

TOTAL:45hrs

TEXT BOOK:

1) CCNA Exploration Companion Guide – Mark Dye, Rick McDonald

REFERENCES:

1) Cisco Routers: An Overview – Mark Tripod – Publisher Sams


2) Overview of Cisco Routers – Alex Zenin – IBM Red books

3|
12150G48A - Network Fundamentals | II Yr / IV Sem

UNIT – 1 INTRODUCTION
COMMUNICATION
Establishing the Rules

Before beginning to communicate with each other, we establish rules or agreements to


govern the conversation. These rules, or protocols, must be followed in order for the message to
be successfully delivered and understood. Among the protocols that govern successful human
communication are:

 An identified sender and receiver


 Agreed upon method of communicating (face-to-face, telephone, letter, photograph)
 Common language and grammar
 Speed and timing of delivery
 Confirmation or acknowledgement requirements

Communication between individuals is determined to be successful when the meaning of the


message understood by the recipient matches the meaning intended by the sender.

External Factors

External factors affecting the success of communication include:

 The quality of the pathway between the sender and the recipient
 The number of times the message has to change form
 The number of times the message has to be redirected or readdressed
 The number of other messages being transmitted simultaneously on the communication
network
 The amount of time allotted for successful communication

Inte rnal Factors

Internal factors affecting the successful communication across the network include:
 The size of the message
 The complexity of the message
 The importance of the message

Basic Elements of Network


 Rules or agreements to govern how the messages are sent, directed, received and
interpreted.
 The messages or units of information that travel from one device to another
 A means of interconnecting these devices - a medium that can transport the messages
from one device to another
 Devices on the network that exchange messages with each other

4|
12150G48A - Network Fundamentals | II Yr / IV Sem

(1) Rules

Devices interconnected by medium to provide services must be governed by rules, or


protocols. In the chart, some common services and a protocol most directly associated with
that service are listed.

Fig.1.1 Elements of Network

(2) Messages

In the first step of its journey from the computer to its destination, our instant message
gets converted into a format that can be transmitted on the network. All types of
messages must be converted to bits, binary coded digital signals, before being sent to
their destinations. This is true no matter what the original message format was: text,
video, voice, or computer data. Once our instant message is converted to bits, it is ready
to be sent onto the network for delivery.

(3) Devices

The following are some of the devices and symbols used:

The right side of the figure shows some of the most common intermediate devices, used to
direct and manage messages across the network, as well as other common networking
symbols. Generic symbols are shown for:

5|
12150G48A - Network Fundamentals | II Yr / IV Sem

Common Data Network Symbols

Fig 1.2 Common Data Network Symbols

 Switch - the most common device for interconnecting local area networks
 Firewall -provides security to networks
 Router - helps direct messages as they travel across a network
 Wireless Router - a specific type of router often found in home networks
 Cloud - used to summarize a group of networking devices, the details of which may
be unimportant to the discussion at hand
 Serial Link - one form of WAN interconnection, represented by the lightning bolt-
shaped line

(4) Medium
For a network to function, the devices must be interconnected. Network connections can
be wired or wireless. In wired connections, the medium is either copper, which carries
electrical signals, or optical fiber, which carries light signals. In wireless connections, the
medium is the Earth's atmosphere, or space, and the signals are microwaves.

Copper medium includes cables, such as twisted pair telephone wire, coaxial cable, or
most commonly, what is known as Category 5 Unshielded Twisted Pair (UTP) cable.
Optical fibers, thin strands of glass or plastic that carry light signals, are another form of
networking media. Wireless media may include the home wireless connection between a
wireless router and a computer with a wireless network card, the terrestrial wireless
connection between two ground stations, or the communication between devices on earth

6|
12150G48A - Network Fundamentals | II Yr / IV Sem

and satellites. In a typical journey across the Internet, a message may travel across a
variety of media.

The Network Architecture


The term network architecture refers to both the technologies that support the
infrastructure and the programmed services and protocols that move the messages across
that infrastructure. There are four basic characteristics that the underlying architectures
need to address in order to meet user expectations:

 fault tolerance
 scalability
 quality of service
 security

(1) Fault Tolerance


A fault tolerant network is one that limits the impact of a hardware or software failure
and can recover quickly when such a failure occurs. These networks depend on redundant
links, or paths, between the source and destination of a message. If one link or path fails,
processes ensure that messages can be instantly routed over a different link transparent to
the users on either end.

Difference between Circuit Switched and Packet Switched network

Circuit Switched Network

A temporary path, or circuit, is created through the various switching locations to use for
the duration of the telephone call. If any link or device participating in the circuit fails,
the call is dropped. To reconnect, a new call must be made, and a new circuit created
between the source telephone set and the destination. This type of connection-oriented
network is called a circuit-switched network. Once a circuit is established, even if no
communication is occurring between the persons on either end of the call, the circuit
remains connected and resources reserved until one of the parties disconnects the call.

Packet Switched Connectionless Networks

Single message can be broken into multiple message blocks. Individual blocks containing
addressing information indicate both their origination point and their final destination.
Using this embedded information, these message blocks, called packets, can be sent
through the network along various paths, and can be reassembled into the original
message upon reaching their destination. Each packet is sent independently from one
switching location to another. At each location, a routing decision is made as to which
path to use to forward the packet towards its final destination. If a previously used path is
no longer available, the routing function can dynamically choose the next best available
path, because the messages are sent in pieces, rather than as a single complete message.

7|
12150G48A - Network Fundamentals | II Yr / IV Sem

(2) Scalability
A scalable network can expand quickly to support new users and applications without
impacting the performance of the service being delivered to existing users. Thousands of
new users and service providers connect to the Internet each week. The ability of the
network to support these new interconnections depends on a hierarchical layered design
for the underlying physical infrastructure and logical architecture.

Fig 1.3 Tier Architecture

(3) Quality of service


The Internet is currently providing an acceptable level of fault tolerance and scalability
for its users. But new applications available to users over internetworks create higher
expectations for the quality of the delivered services. Voice and live video transmissions
require a level of consistent quality and uninterrupted delivery that was not necessary for
traditional computer applications. Quality of these services is measured against the
quality of experiencing the same audio or video presentation in person.

QoS mechanisms enable the establishment of queue management strategies that enforce
priorities for different classifications of application data. Without properly designed and
implemented QoS mechanisms, data packets will be dropped without consideration of the
application characteristics or priority. Examples of priority decisions for an organization
might include:

8|
12150G48A - Network Fundamentals | II Yr / IV Sem

Fig 1.4 Queue Priority

1) Time-sensitive communication - increase priority for services like telephony or


video distribution.
2) Non time-sensitive communication - decrease priority for web page retrieval or
e-mail
3) High importance to organization - increase priority for production control or
business transaction data.
4) Undesirable communication - decrease priority or block unwanted activity, like
peer-to-peer files sharing or live entertainment.

The Quality of Service a network can offer is a vital issue, and in some situations, it is
crucial. Imagine the consequences of a dropped distress call to an emerge ncy response
center, or of a lost control signal to an automated piece of heavy machinery. A key
responsibility for the network managers in an organization is to establish a Quality of
Service policy and ensure that the mechanisms are in place to meet that goal.

(4) Security
Rapid expansion in communication areas that were not served by traditional data
networks is increasing the need to embed security into the network architecture. As a
result, much effort is being devoted to this area of research and development. In the
meantime, many tools and procedures are being implemented to combat inherent security
flaws in the network architecture.

9|
12150G48A - Network Fundamentals | II Yr / IV Sem

Consequences of a network security breach could include:

1) Network outage that prevents communications and transactions occurring, with


consequent loss of business
2) Misdirection and loss of personal or business funds
3) Company intellectual property (research ideas, patents or designs) that is stolen
and used by a competitor
4) Customer contract details that become known to competitors or made public,
resulting in a loss of market confidence in the business

Security measures taken in a network should:

 Prevent unauthorized disclosure or theft of information


 Prevent unauthorized modification of information
 Prevent Denial of Service

Means to achieve these goals include:

 Ensuring confidentiality
 Maintaining communication integrity
 Ensuring availability

The elements of communication


Communication begins with a message, or information, that must be sent from one individual or
device to another. People exchange ideas using many different communication methods. All of
these methods have three elements in common.

 Message source or sender


 The destination or receiver
 Channel or media

The first of these elements is the message source, or sender. Message sources are people, or
electronic devices, that need to send a message to other individuals or devices. The second
element of communication is the destination, or receiver, of the message. The destination
receives the message and interprets it. A third element, called a channel, consists of the media
that provides the pathway over which the message can travel from source to destination.

The components of a network

The path that a message takes from source to destination can be as simple as a single cable
connecting one computer to another or as complex as a network that literally spans the globe.
This network infrastructure is the platform that supports our human network. It provides the
stable and reliable channel over which our communications can occur.

10 |
12150G48A - Network Fundamentals | II Yr / IV Sem

The importance components are:

 Devices
 Media
 Services

Devices and media are the physical elements or hardware of the network. Hardware is often the
visible components of the network platform such as a laptop, a PC, a switch, or the cabling used
to connect the devices. Occasionally, some components may not be so visible. In the case of
wireless media, messages are transmitted through the air using invisible radio frequency or
infrared waves.

Services and processes are the communication programs, called software, that run on the
networked devices. A network service provides information in response to a request. Services
include many of the common network applications people use every day, like e- mail hosting
services and web hosting services.

1) End devices and their role in network

The network devices that people are most familiar with are called end devices. These devices
form the interface between the human network and the underlying communication network.
Some examples of end devices are:

 Computers (work stations, laptops, file servers, web servers)


 Network printers
 VoIP phones
 Security cameras
 Mobile handheld devices (such as wireless barcode scanners, PDAs)

2) Intermediary devices and their role in network

Networks rely on intermediary devices to provide connectivity and to work behind the
scenes to ensure that data flows across the network. These devices connect the individual
hosts to the network and can connect multiple individual networks to form an
internetwork. Examples of intermediary network devices are:

 Network Access Devices (Hubs, switches, and wireless access points)


 Internetworking Devices (routers)
 Communication Servers and Modems
 Security Devices (firewalls)

11 |
12150G48A - Network Fundamentals | II Yr / IV Sem

Processes running on the intermediary network devices perform these functions:

 Regenerate and retransmit data signals


 Maintain information about what pathways exist through the network and internetwork
 Notify other devices of errors and communication failures
 Direct data along alternate pathways when there is a link failure
 Classify and direct messages according to QoS priorities
 Permit or deny the flow of data, based on security settings

Network Media
Communication across a network is carried on a medium. The medium provides the channel over
which the message travels from source to destination. Modern networks primarily use three types
of media to interconnect devices and to provide the pathway over which data can be transmitted.
These media are:
 Metallic wires within cables
 Glass or plastic fibers (fiber optic cable)
 Wireless transmission

Different types of network media have different features and benefits. Not all network media has
the same characteristics and is appropriate for the same purpose. Criteria for choosing a network
media are:
 The distance the media can successfully carry a signal.
 The environment in which the media is to be installed.
 The amount of data and the speed at which it must be transmitted.
 The cost of the media and installation

12 |
12150G48A - Network Fundamentals | II Yr / IV Sem

Fig 1.5 Network Media


LANs, WANs and Internetworks
LAN (Local Area Network)

An individual network usually spans a single geographical area, providing services and
applications to people within a common organizational structure, such as a single business,
campus or region. This type of network is called a Local Area Network (LAN). A LAN is
usually administered by a single organization. The administrative control that governs the
security and access control policies are enforced on the network level.

Fig 1.6 Local Area Network

WAN (Wide Area Network)

When a company or organization has locations that are separated by large geographical
distances, it may be necessary to use a telecommunications service provider (TSP) to
interconnect the LANs at the different locations. Telecommunications service providers operate
large regional networks that can span long distances. Traditionally, TSPs transported voice and
data communications on separate networks. Increasingly, these providers are offering converged
information network services to their subscribers.

13 |
12150G48A - Network Fundamentals | II Yr / IV Sem

Fig 1.7 Wide Area Network


The Internet
The Internet is created by the interconnection of networks belonging to Internet Service
Providers (ISPs). These ISP networks connect to each other to provide access for millions of
users all over the world. Ensuring effective communication across this diverse infrastructure
requires the application of consistent and commonly recognized technologies and protocols as
well as the cooperation of many network administration agencies.

Intranet
The term intranet is often used to refer to a private connection of LANs and WANs that belongs
to an organization, and is designed to be accessible only by the organization's members,
employees, or others with authorization.

Fig 1.8 Intranet

14 |
12150G48A - Network Fundamentals | II Yr / IV Sem

Network Representations
When conveying complex information such as the network connectivity and operation of a large
internetwork, it is helpful to use visual representations and graphics. Like any other language, the
language of networking uses a common set of symbols to represent the different end devices,
network devices and media.

In addition to these representations, specialized terminology is used when discussing how each
of these devices and media connect to each other. Important terms to remember are:

Network Interface Card - A NIC, or LAN adapter, provides the physical connection to the
network at the PC or other host device. The media connecting the PC to the networking device
plugs directly into the NIC.

Physical Port - A connector or outlet on a networking device where the media is connected to a
host or other networking device.

Interface - Specialized ports on an internetworking device that connect to individual networks.


Because routers are used to interconnect networks, the ports on a router are referred to network
interfaces.

Protocols – Rules that govern Communication

All communication, whether face-to-face or over a network, is governed by predetermined rules


called protocols. These protocols are specific to the characteristics of the conversation.

Successful communication between hosts on a network requires the interaction of many different
protocols. A group of inter-related protocols that are necessary to perform a communication
function is called a protocol suite. These protocols are implemented in software and hardware
that is loaded on each host and network device.

Network Protocols

Networking protocols suites describe processes such as:

 The format or structure of the message


 The process by which networking devices share information about pathways with other
networks
 How and when error and system messages are passed between devices
 The setup and termination of data transfer sessions

15 |
12150G48A - Network Fundamentals | II Yr / IV Sem

The benefits of using laye red model

To visualize the interaction between various protocols, it is common to use a layered model. A
layered model depicts the operation of the protocols occurring within each layer, as well as the
interaction with the layers above and below it.

There are benefits to using a layered model to describe network protocols and operations. Using
a layered model:

 Assists in protocol design, because protocols that operate at a specific layer have defined
information that they act upon and a defined interface to the layers above and below.
 Fosters competition because products from different vendors can work together.
 Prevents technology or capability changes in one layer from affecting other layers above
and below.
 Provides a common language to describe networking functions and capabilities.

Protocol and reference models

There are two basic types of networking models: protocol models and reference models.

A protocol model provides a model that closely matches the structure of a particular protocol
suite. The hierarchical set of related protocols in a suite typically represents all the functionality
required to interface the human network with the data network. The TCP/IP model is a protocol
model because it describes the functions that occur at each layer of protocols within the TCP/IP
suite.

A reference model provides a common reference for maintaining consistency within all types of
network protocols and services. A reference model is not intended to be an implementation
specification or to provide a sufficient level of detail to define precisely the services of the
network architecture. The primary purpose of a reference model is to aid in clearer understanding
of the functions and process involved.

16 |
12150G48A - Network Fundamentals | II Yr / IV Sem

Fig 1.9 Networking Model

The TCP/IP model

The first layered protocol model for internetwork communications was created in the early 1970s
and is referred to as the Internet model. It defines four categories of functions that must occur for
communications to be successful. The architecture of the TCP/IP protocol suite follows the
structure of this model. Because of this, the Internet model is commonly referred to as the
TCP/IP model.

17 |
12150G48A - Network Fundamentals | II Yr / IV Sem

Fig 1.10 TCP/IP Model

The Communication Process


A complete communication process includes these steps:

1. Creation of data at the application layer of the originating source end device

2. Segmentation and encapsulation of data as it passes down the protocol stack in the source end
device

3. Generation of the data onto the media at the network access layer of the stack

4. Transportation of the data through the internetwork, which consists of media a nd any
intermediary devices

5. Reception of the data at the network access layer of the destination end device

6. Decapsulation and reassembly of the data as it passes up the stack in the destination device

7. Passing this data to the destination application at the Application layer of the destination end
device

18 |
12150G48A - Network Fundamentals | II Yr / IV Sem

Protocol data units and encapsulation

The form that a piece of data takes at any layer is called a Protocol Data Unit (PDU). During
encapsulation, each succeeding layer encapsulates the PDU that it receives from the layer above
in accordance with the protocol being used. At each stage of the process, a PDU has a different
name to reflect its new appearance.
Although there is no universal naming convention for PDUs, in this course, the PDUs are named
according to the protocols of the TCP/IP suite.

Data - The general term for the PDU used at the Application layer
Segment - Transport Layer PDU
Packet - Internetwork Layer PDU
Frame - Network Access Layer PDU
Bits - A PDU used when physically transmitting data over the medium

Fig 1.11 Encapsulation

Sending and receiving process

When sending messages on a network, the protocol stack on a host operates from top to bottom.

The Application layer protocol, HTTP, begins the process by delivering the HTML formatted
web page data to the Transport layer. There the application data is broken into TCP segments.
Each TCP segment is given a label, called a header, containing information about which process
running on the destination computer should receive the message. It also contains the information
to enable the destination process to reassemble the data back to its original format.

19 |
12150G48A - Network Fundamentals | II Yr / IV Sem

The Transport layer encapsulates the web page HTML data within the segment and sends it to
the Internet layer, where the IP protocol is implemented. Here the entire TCP segment is
encapsulated within an IP packet, which adds another label, called the IP header. The IP header
contains source and destination host IP addresses, as well as information necessary to deliver the
packet to its corresponding destination process.

Next, the IP packet is sent to the Network Access layer Ethernet protocol where it is
encapsulated within a frame header and trailer. Each frame header contains a source and
destination physical address. The physical address uniquely identifies the devices on the local
network. The trailer contains error checking information. Finally the bits are encoded onto the
Ethernet media by the server NIC.

The OSI Model

Initially the OSI model was designed by the International Organization for Standardization (ISO)
to provide a framework on which to build a suite of open systems protocols.

Fig 1.12 OSI Model

20 |
12150G48A - Network Fundamentals | II Yr / IV Sem

Comparing OSI with TCP/IP model

Fig 1.13 Comparison of OSI & TCP/IP

Addressing in the Network

There are various types of addresses that must be included to successfully deliver the data from a
source application running on one host to the correct destination application running on another.
Using the OSI model as a guide, we can see the different addresses and identifiers that are
necessary at each layer.

21 |
12150G48A - Network Fundamentals | II Yr / IV Sem

Fig 1.14 Network Addressing

Getting data to the end device

The first identifier, the host physical address, is contained in the header of the Layer 2 PDU,
called a frame. Layer 2 is concerned with the delivery of messages on a single local network.
The Layer 2 address is unique on the local network and represents the address of the end device
on the physical media. In a LAN using Ethernet, this address is called the Media Access Control
(MAC) address. When two end devices communicate on the local Ethernet network, the frames
that are exchanged between them contain the destination and source MAC addresses. Once a
frame is successfully received by the destination host, the Layer 2 address information is
removed as the data is decapsulated and moved up the protocol stack to Layer 3.

Getting the data through the inte rnetwork

Layer 3 protocols are primarily designed to move data from one local network to another local
network within an internetwork. Whereas Layer 2 addresses are only used to communicate
between devices on a single local network, Layer 3 addresses must include identifiers that enable
intermediary network devices to locate hosts on different networks. In the TCP/IP protocol suite,
every IP host address contains information about the network where the host is located.

At the boundary of each local network, an intermediary network device, usually a router,
decapsulates the frame to read the destination host address contained in the header of the packet,
the Layer 3 PDU. Routers use the network identifier portion of this address to determine which
path to use to reach the destination host. Once the path is determined, the router encapsulates the
packet in a new frame and sends it on its way toward the destination end device. When the frame
reaches its final destination, the frame and packet headers are removed and the data moved up to
Layer 4.

Getting the data to the right application

Each application or service is represented at Layer 4 by a port number. A unique dialogue


between devices is identified with a pair of Layer 4 source and destination port numbers that are
representative of the two communicating applications. When the data is received at the host, the
port number is examined to determine which application or process is the correct destination for
the data.

22 |
12150G48A - Network Fundamentals | II Yr / IV Sem

UNIT – II APPLICATION AND TRANSPORT LAYER

APPLICATION LAYER FUNCTIONALITY AND PROTOCOLS

The Application layer, Layer seven, is the top layer of both the OSI and TCP/IP models. It is the
layer that provides the interface between the applications we use to communicate and the
underlying network over which our messages are transmitted. Application layer protocols are
used to exchange data between programs running on the source and destination hosts. There are
many Application layer protocols and new protocols are always being developed.

Fig 2.1 Application Layer

The most widely-known TCP/IP Application layer protocols are those that provide for the
exchange of user information. These protocols specify the format and control information
necessary for many of the common Internet communication functions. Among these TCP/IP
protocols are:
 Domain Name Service Protocol (DNS) is used to resolve Internet names to IP addresses.
 Hypertext Transfer Protocol (HTTP) is used to transfer files that make up the Web pages
of the World Wide Web.
 Simple Mail Transfer Protocol (SMTP) is used for the transfer of mail messages and
attachments.
 Telnet, a terminal emulation protocol, is used to provide remote access to servers and
networking devices.
 File Transfer Protocol (FTP) is used for interactive file transfer between systems.

23 |
12150G48A - Network Fundamentals | II Yr / IV Sem

Types of Servers
 DNS Server – Service that provides the IP address of a website or domain name so a host
can connect to it.
 Telnet Server – Service that allows administrators to login to a host from a remote
location and control the host as though they were logged in locally.
 E-Mail Server – Used to send e- mails messages from client to servers over the internet
 DHCP Server – Service that assign the IP address subnet mask default gateway and other
information to clients.
 Web Server – Used to transfer information between web clients and web servers.
 FTP Server – Service that allows for the download and upload of files between a client
and server.
Application layer protocol functions
 Define process on either end of the communication
 Define the type of messages
 Define the syntax of messages
 Define the meaning of any informational fields
 Define how messages are sent and the expected response
 Define interaction with the next lower layer.
The Client-Server model
In the client/server model, the device requesting the information is called a client and the device
responding to the request is called a server. Client and server processes are considered to be in
the Application layer. The client begins the exchange by requesting data from the server, which
responds by sending one or more streams of data to the client. Application layer protocols
describe the format of the requests and responses between clients and servers. In addition to the
actual data transfer, this exchange may also require control information, such as user
authentication and the identification of a data file to be transferred.

Fig 2.2 C/S Model

24 |
12150G48A - Network Fundamentals | II Yr / IV Sem

Peer-to-Peer Networking and Applications (P2P)


In a peer-to-peer network, two or more computers are connected via a network and can share
resources (such as printers and files) without having a dedicated server. Every connected end
device (known as a peer) can function as either a server or a client. One computer might assume
the role of server for one transaction while simultaneously serving as a client for another. The
roles of client and server are set on a per request basis.
A simple home network with two connected computers sharing a printer is an example of
a peer-to-peer network. Each person can set his or her computer to share files, enable networked
games, or share an Internet connection.

Fig 2.3 Peer to Peer Networking


Peer-to-Peer application
A peer-to-peer application (P2P), unlike a peer-to-peer network, allows a device to act as both a
client and a server within the same communication. In this model, every client is a server and
every server a client. Both can initiate a communication and are considered equal in the
communication process. However, peer-to-peer applications require that each end device provide
a user interface and run a background service. When you launch a specific peer-to-peer
application it invokes the required user interface and background services. After that the devices
can communicate directly.
Some P2P applications use a hybrid system where resource sharing is decentralized but the
indexes that point to resource locations are stored in a centralized directory. In a hybrid system,
each peer accesses an index server to get the location of a resource stored on another peer. The
index server can also help connect two peers, but once connected, the communication takes place
between the two peers without additional communication to the index server.
Peer-to-peer applications can be used on peer-to-peer networks, client/server networks, and
across the Internet.

25 |
12150G48A - Network Fundamentals | II Yr / IV Sem

Fig 2.4 Peer to Peer Application


DNS services and protocol
On the Internet these domain names, such as www.cisco.com , are much easier for people to
remember than 198.132.219.25, which is the actual numeric address for this server. Also, if
Cisco decides to change the numeric address, it is transparent to the user, since the domain name
will remain www.cisco.com . The new address will simply be linked to the existing domain
name and connectivity is maintained.

Fig 2.5 DNS Services & Protocols


The Domain Name System (DNS) was created for domain name to address resolution for these
networks. DNS uses a distributed set of servers to resolve the names associated with these
numbered addresses. The DNS protocol defines an automated service that matches resource
names with the required numeric network address.
The DNS server stores different types of resource records used to resolve names. These records
contain the name, address, and type of record.
Some of these record types are:

26 |
12150G48A - Network Fundamentals | II Yr / IV Sem

 A - an end device address


 NS - an authoritative name server
 CNAME - the canonical name (or Fully Qualified Domain Name) for an alias; used when
multiple services have the single network address but each service has its own entry in
DNS
 MX - mail exchange record; maps a domain name to a list of mail exchange servers for
that domain
When a client makes a query, the server's "named" process first looks at its own records to see if
it can resolve the name. If it is unable to resolve the name using its stored records, it contacts
The different top- level domains represent the either the type of organization or the country or
origin. Examples of top- level domains are:
 .au - Australia
 .co - Colombia
 .com - a business or industry
 .jp - Japan
 .org - a non-profit organization
After top- level domains are second- level domain names, and below them are other lower level
domains.

Fig 2.6 DNS Server Hierarchy

27 |
12150G48A - Network Fundamentals | II Yr / IV Sem

WWW services and HTTP


When a web address (or URL) is typed into a web browser, the web browser establishes a
connection to the web service running on the server using the HTTP protocol. URLs (or Uniform
Resource Locator) and URIs (Uniform Resource Identifier) are the names most people associate
with web addresses. In order to access the content, web clients make connections to the server
and request the desired resources. The server replies with the resources and, upon receipt, the
browser interprets the data and presents it to the user.

Fig 2.7 HTTP

First, the browser interprets the three parts of the URL:


1. http (the protocol or scheme)
2. www.cisco.com(the server name)
3. web-server.htm (the specific file name requested).

The browser then checks with a name server to convert www.cisco.com


<http://www.cisco.com > into a numeric address, which it uses to connect to the server. Using
the HTTP protocol requirements, the browser sends a GET request to the server and asks for the
file web-server.htm. The server in turn sends the HTML code for this web page to the browser.
Finally, the browser deciphers the HTML code and formats the page for the browser window.
HTTP protocol defines the message types the client uses to request the web page and also the
message types the server uses to respond. The three common message types are GET, POST, and
PUT.
GET is a client request for data. A web browser sends the GET message to request pages from a
web server. As shown in the figure, once the server receives the GET request, it responds with a
status line, such as HTTP/1.1 200 OK, and a message of its own, the body of which may be the
requested file, an error message, or some other information.

28 |
12150G48A - Network Fundamentals | II Yr / IV Sem

POST and PUT are used to send messages that upload data to the web server. For example, when
the user enters data into a form embedded in a web page, POST includes the data in the message
sent to the server. PUT uploads resources or content to the web server.

E-Mail services and SMTP/POP Protocols

When people compose e- mail messages, they typically use an application called a Mail User
Agent (MUA), or e- mail client. The MUA allows messages to be sent and places received
messages into the client's mailbox, both of which are distinct processes.
In order to receive e-mail messages from an e-mail server, the e-mail client can use POP.
Sending e- mail from either a client or a server uses message formats and command strings
defined by the SMTP protocol. Usually an e-mail client provides the functionality of both
protocols within one application.

The e- mail server operates two separate processes:


 Mail Transfer Agent (MTA)
 Mail Delivery Agent (MDA)

The Mail Transfer Agent (MTA) process is used to forward e- mail. As shown in the figure, the
MTA receives messages from the MUA or from another MTA on another e- mail server. Based
on the message header, it determines how a message has to be forwarded to reach its destination.
If the mail is addressed to a user whose mailbox is on the local server, the mail is passed to the
MDA. If the mail is for a user not on the local server, the MTA routes the e- mail to the MTA on
the appropriate server.

Fig 2.8 E-Mail Server

29 |
12150G48A - Network Fundamentals | II Yr / IV Sem

In the figure, we see that the Mail Delivery Agent (MDA) accepts a piece of e- mail from a Mail
Transfer Agent (MTA) and performs the actual delivery. The MDA receives all the inbound mail
from the MTA and places it into the appropriate users' mailboxes. The MDA can also resolve
final delivery issues, such as virus scanning, spam filtering, and return-receipt handling. Most e-
mail communications use the MUA, MTA, and MDA applications. However, there are other
alternatives for e-mail delivery.
Some of the commands specified in the SMTP protocol are:
 HELO - identifies the SMTP client process to the SMTP server process
 EHLO - Is a newer version of HELO, which includes services extensions
 MAIL FROM - Identifies the sender
 RCPT TO - Identifies the recipient
 DATA - Identifies the body of the message

FTP (File Transfer Protocol)

The File Transfer Protocol (FTP) is another commonly used Application layer protocol. FTP was
developed to allow for file transfers between a client and a server. An FTP client is an
application that runs on a computer that is used to push and pull files from a server running the
FTP daemon (FTPd).
To successfully transfer files, FTP requires two connections between the client and the server:
one for commands and replies, the other for the actual file transfer. The client establishes the first
connection to the server on TCP port 21. This connection is used for control traffic, consisting of
client commands and server replies. The client establishes the second connection to the server
over TCP port 20. This connection is for the actual file transfer and is created every time there is
a file transferred.

Fig 2.9 FTP process

30 |
12150G48A - Network Fundamentals | II Yr / IV Sem

DHCP(Dynamic Host Confirmation Protocol)


The Dynamic Host Confirmation Protocol (DHCP) service enables devices on a network to
obtain IP addresses and other information from a DHCP server. This service automates the
assignment of IP addresses, subnet masks, gateway and other IP networking parameters.
DHCP distributed addresses are not permanently assigned to hosts but are only leased for a
period of time. If the host is powered down or taken off the network, the address is returned to
the pool for reuse. This is especially helpful with mobile users that come and go on a network.
Users can freely move from location to location and re-establish network connections. The host
can obtain an IP address once the hardware connection is made, either via a wired or wireless
LAN.

Fig 2.10 DHCP Server


The client may receive multiple DHCP OFFER packets if there is more than one DHCP server
on the local network, so it must choose between them, and broadcast a DHCP REQUEST packet
that identifies the explicit server and lease offer that the client is accepting. A client may choose
to request an address that it had previously been allocated by the server.
Assuming that the IP address requested by the client, or offered by the server, is still valid, the
server would return a DHCP ACK message that acknowledges to the client the lease is finalized.

Fig 2.11 DHCP C/S

31 |
12150G48A - Network Fundamentals | II Yr / IV Sem

Files sharing services and SMB protocol


The Server Message Block (SMB) is a client/server file sharing protocol. IBM developed Server
Message Block (SMB) in the late 1980s to describe the structure of shared network resources,
such as directories, files, printers, and serial ports. It is a reque st-response protocol . Unlike the
file sharing supported by FTP, clients establish a long term connection to servers. Once the
connection is established, the user of the client can access the resources on the server as if the
resource is local to the client host.

Fig 2.12 File Sharing

The SMB protocol describes file system access and how clients can make requests for files. It
also describes the SMB protocol inter-process communication. All SMB messages share a
common format. This format uses a fixed-sized header followed by a variable-sized parameter
and data component.
SMB messages can:
 Start, authenticate, and terminate sessions
 Control file and printer access
 Allow an application to send or receive messages to or from another device

P2P services and Gnutella protocol


Many P2P applications do not use a central database to record all the files available on the peers.
Instead, the devices on the network each tell the other what files are available when queried and
use the Gnutella protocol and services to support locating resources. See the figure.
When a user is connected to a Gnutella service, the client applications will search for other
Gnutella nodes to connect to. These nodes handle queries for resource locations and replies to
those requests. They also govern control messages, which help the service discover other nodes.
The actual file transfers usually rely on HTTP services.

32 |
12150G48A - Network Fundamentals | II Yr / IV Sem

The Gnutella protocol defines five different packet types:


 ping - for device discovery
 pong - as a reply to a ping
 query - for file location
 query hit - as a reply to a query
 push - as a download request

Telnet services and Protocol


Telnet provides a standard method of emulating text-based terminal devices over the data
network. Both the protocol itself and the client software that implements the protocol are
commonly referred to as Telnet.
Appropriately enough, a connection using Telnet is called a Virtual Terminal (VTY) session, or
connection. Rather than using a physical device to connect to the server, Telnet uses software to
create a virtual device that provides the same features of a terminal session with access to the
server command line interface (CLI).
To support Telnet client connections, the server runs a service called the Telnet daemon. A
virtual terminal connection is established from an end device using a Telnet client application.
Once a Telnet connection is established, users can perform any authorized function on the server,
just as if they were using a command line session on the server itself.

Fig 2.13 Telnet


Some sample Telnet protocol commands include:
Are You There (AYT) - Lets the user request that something appear on the terminal screen to
indicate that the VTY session is active.
Erase Line (EL) - Deletes all text from the current line.
Interrupt Process (IP) - Suspends, interrupts, aborts, or terminates the process to which the
Virtual Terminal is connected.

33 |
12150G48A - Network Fundamentals | II Yr / IV Sem

TRANSPORT LAYER
The Transport layer encompasses these functions:
 Enables multiple applications to communicate over the network at the sa me time on a
single device
 Ensures that, if required, all the data is received reliably and in order by the correct
application
 Employs error handling mechanisms

Fig 2.14 OSI Transport Layer


The Transport layer provides for the segmentation of data and the control necessary to
reassemble these pieces into the various communication streams. Its primary responsibilities to
accomplish this are:
 Tracking the individual communication between applications on the source and
destination hosts
 Segmenting data and managing each piece
 Reassembling the segments into streams of application data
 Identifying the different applications

Purpose of Transport Laye r

Separating Multiple Communications


Consider a computer connected to a network that is simultaneously receiving and sending e-mail
and instant messages, viewing websites, and conducting a VoIP phone call. Each of these
applications is sending and receiving data over the network at the same time. However, data
from the phone call is not directed to the web browser, and text from an instant message does not
appear in an e- mail.

34 |
12150G48A - Network Fundamentals | II Yr / IV Sem

Segmentation of the data, in accordance with Transport layer protocols, provides the means to
both send and receive data when running multiple applications concurrently on a computer.
Without segmentation, only one application, the streaming video for example, would be able to
receive data. You could not receive e- mails, chat on instant messenger, or view web pages while
also viewing the video.

Controlling the Conversation


The primary functions specified by all Transport layer protocols include:
Segmentation and Reassembly - Most networks have a limitation on the amount of data that can
be included in a single PDU. The Transport layer divides application data into blocks of data that
are an appropriate size. At the destination, the Transport layer reassembles the data before
sending it to the destination application or service.
Conversation Multiplexing - There may be many applications or services running on each host in
the network. Each of these applications or services is assigned an address known as a port so that
the Transport layer can determine with which application or service the data is identified.
In addition to using the information contained in the headers, for the basic functions of data
segmentation and reassembly, some protocols at the Transport layer provide:
 Connection-oriented conversations
 Reliable delivery
 Ordered data reconstruction
 Flow control

Fig 2.15 Transport Layer Services

35 |
12150G48A - Network Fundamentals | II Yr / IV Sem

Supporting Reliable communication


A Transport layer protocol can implement is a method to ensure reliable delivery of the data. In
networking terms, reliability means ensuring that each piece of data that the source sends arrives
at the destination. At the Transport layer the three basic operations of reliability are:
 tracking transmitted data
 acknowledging received data
 retransmitting any unacknowledged data

Fig 2.16 Transport Layer Protocols

Roles of the Transport layers


TCP & UDP
The two most common Transport layer protocols of TCP/IP protocol suite are Transmission
Control Protocol (TCP) and User Datagram Protocol (UDP). Both protocols manage the
communication of multiple applications. The differences between the two are the specific
functions that each protocol implements.
User Datagram Protocol (UDP)
UDP is a simple, connectionless protocol, described in RFC 768. It has the advantage of
providing for low overhead data delivery. The pieces of communication in UDP are called
datagrams. These datagrams are sent as "best effort" by this Transport layer protocol.
Applications that use UDP include:
 Domain Name System (DNS)
 Video Streaming
 Voice over IP (VoIP)

36 |
12150G48A - Network Fundamentals | II Yr / IV Sem

Transmission Control Protocol (TCP)


TCP is a connection-oriented protocol, described in RFC 793. TCP incurs additional overhead to
gain functions. Additional functions specified by TCP are the same order delivery, reliable
delivery, and flow control. Each TCP segment has 20 bytes of overhead in the header
encapsulating the Application layer data, whereas each UDP segment only has 8 byt es of
overhead. See the figure for a comparison.
Applications that use TCP are:
 Web Browsers
 E- mail
 File Transfers

Fig 2.17 TCP & UDP Headers

Port Addressing
The TCP and UDP based services keep track of the various applications that are communicating.
To differentiate the segments and datagrams for each application, both TCP and UDP have
header fields that can uniquely identify these applications. These unique identifiers are the port
numbers,
In the header of each segment or datagram, there is a source and destination port. The source port
number is the number for this communication associated with the originating application on the
local host. The destination port number is the number for this communication associated with the
destination application on the remote host.

37 |
12150G48A - Network Fundamentals | II Yr / IV Sem

Fig 2.18 Port Addressing

The Internet Assigned Numbers Authority (IANA) assigns port numbers. IANA is a standards
body that is responsible for assigning various addressing standards.
There are different types of port numbers:

Fig 2.19 Port Number Types

Segmentation and Reassembly

In TCP, each segment header contains a sequence number. This sequence number allows the
Transport layer functions on the destination host to reassemble segments in the order in which
they were transmitted. This ensures that the destination application has the data in the exact form
the sender intended.

38 |
12150G48A - Network Fundamentals | II Yr / IV Sem

Fig 2.20 Transport Layer Functions


TCP – Making Conversation Reliable
The reliability of TCP communication is performed using connection-oriented sessions. Before a
host using TCP sends data to another host, the Transport layer initiates a process to create a
connection with the destination. This connection enables the tracking of a session, or
communication stream between the hosts. This process ensures that each host is aware of and
prepared for the communication. A complete TCP conversation requires the establishment of a
session between the hosts in both directions.
After a session has been established, the destination sends acknowledgements to the source for
the segments that it receives. These acknowledgements form the basis of reliability within the
TCP session. As the source receives an acknowledgement, it knows that the data has been
successfully delivered and can quit tracking that data. If the source does not receive an
acknowledgement within a predetermined amount of time, it retransmits that data to the
destination.

Fig 2.21 TCP Header

39 |
12150G48A - Network Fundamentals | II Yr / IV Sem

TCP Server Process


Each application process running on the server is configured to use a port number, either by
default or manually by a system administrator. When an active server application is assigned to a
specific port, that port is considered to be "open" on the server. This means that the Transport
layer accepts and processes segments addressed to that port. Any incoming client request
addressed to the correct socket is accepted and the data is passed to the server application. There
can be many simultaneous ports open on a server, one for each active server application. It is
common for a server to provide more than one service, such as a web server and an FTP server,
at the same time.

Fig 2.22 TCP Request

TCP Connection Establishme nt & Termination


When two hosts communicate using TCP, a connection is established before data can be
exchanged. After the communication is completed, the sessions are closed and the connection is
terminated. The connection and session mechanisms enable TCP's reliability function.
The three-way handshake:
1. Establishes that the destination device is present on the network
2. Verifies that the destination device has an active service and is accepting requests on the
destination port number that the initiating client intends to use for the session
3. Informs the destination device that the source client intends to establish a communication
session on that port number

40 |
12150G48A - Network Fundamentals | II Yr / IV Sem

Fig 2.23 TCP Handshake


In TCP connections, the host serving as a client initiates the session to the server. The three steps
in TCP connection establishment are:

1. The initiating client sends a segment containing an initial sequence value, which serves as a
request to the server to begin a communications session.
2. The server responds with a segment containing an acknowledge ment value equal to the
received sequence value plus 1, plus its own synchronizing sequence value. The value is one
greater than the sequence number because there is no data contained to be acknowledged. This
acknowledgement value enables the client to tie the response back to the original segment that it
sent to the server.
3. Initiating client responds with an acknowledgement value equal to the sequence value it
received plus one. This completes the process of establishing the connection.

To understand the three-way handshake process, it is important to look at the various values that
the two hosts exchange. Within the TCP segment header, there are six 1-bit fields that contain
control information used to manage the TCP processes.
Those fields are:
 URG - Urgent pointer field significant
 ACK - Acknowledgement field significant
 PSH - Push function
 RST - Reset the connection
 SYN - Synchronize sequence numbers
 FIN- No more data from sender

41 |
12150G48A - Network Fundamentals | II Yr / IV Sem

TCP Session Termination


Termination process can be initiated by any two hosts that complete the session:
1. When the client has no more data to send in the stream, it sends a segment with the FIN flag
set.
2. The server sends an ACK to acknowledge the receipt of the FIN to terminate the session from
client to server.
3. The server sends a FIN to the client, to terminate the server to client session.
4. The client responds with an ACK to acknowledge the FIN from the server.

TCP Segment Reassembly

When services send data using TCP, segments may arrive at their destination out of order. For
the original message to be understood by the recipient, the data in these segments is reassembled
into the original order. Sequence numbers are assigned in the header of each packet to achieve
this goal.

Fig 2.24 TCP Segment

During session setup, an initial sequence number (ISN) is set. This initial sequence number
represents the starting value for the bytes for this session that will be transmitted to the receiving
application. As data is transmitted during the session, the sequence number is incremented by the
number of bytes that have been transmitted. This tracking of data byte enables each segment to
be uniquely identified and acknowledged. Missing segments can be identified.
TCP Acknowle dgement with windowing
The segment header sequence number and acknowledgement number are used together to
confirm receipt of the bytes of data contained in the segments. The sequence number indicates
the relative number of bytes that have been transmitted in this session including the bytes in the

42 |
12150G48A - Network Fundamentals | II Yr / IV Sem

current segment. TCP uses the acknowledgement number in segments sent back to the source to
indicate the next byte in this session that the receiver expects to receive. This is called
expectational acknowledgement.

TCP Retrans mission


No matter how well designed a network is, data loss will occasionally occur. Therefore, TCP
provides methods of managing these segment losses. Among these is a mechanism to retransmit
segments with unacknowledged data. A destination host service using TCP usually only
acknowledges data for contiguous sequence bytes. If one or more segments are missing, only the
data in the segments that complete the stream are acknowledged. For example, if segments with
sequence numbers 1500 to 3000 and 3400 to 3500 were received, the acknowledgement number
would be 3001. This is because there are segments with the sequence numbers 3001 to 3399 that
have not been received.

TCP Congestion control – Minimizing Segment loss


Flow Control
TCP also provides mechanisms for flow control. Flow control assists the reliability of TCP
transmission by adjusting the effective rate of data flow between the two services in the session.
When the source is informed that the specified amount of data in the segments is received, it can
continue sending more data for this session.
This Window Size field in the TCP header specifies the amount of data that can be transmitted
before an acknowledgement must be received. The initial window size is determined during the
session startup via the three-way handshake.
TCP feedback mechanism adjusts the effective rate of data transmission to the maximum flow
that the network and destination device can support without loss. TCP attempts to manage the
rate of transmission so that all data will be received and retransmissio ns will be minimized.

43 |
12150G48A - Network Fundamentals | II Yr / IV Sem

Fig 2.25 TCP ACK


Reducing window size
Another way to control the data flow is to use dynamic window sizes. When network resources
are constrained, TCP can reduce the window size to require that received segments be
acknowledged more frequently. This effectively slows down the rate of transmission because the
source waits for data to be acknowledged more frequently.
The TCP receiving host sends the window size value to the sending TCP to indicate the number
of bytes that it is prepared to receive as a part of this session. If the destination needs to slow
down the rate of communication because of limited buffer memory, it can send a smaller window
size value to the source as part of an acknowledgement.

Fig 2.26 Congestion & Flow Control

UDP – Low overhead vs. Reliability

UDP is a simple protocol that provides the basic Transport layer functions. It much lower
overhead than TCP, since it is not connection-oriented and does not provide the sophisticated
retransmission, sequencing, and flow control mechanisms.
Application layer protocols that use UDP include:
 Domain Name System (DNS)
 Simple Network Management Protocol (SNMP)
 Dynamic Host Configuration Protocol (DHCP)
 Routing Information Protocol (RIP)
 Trivial File Transfer Protocol (TFTP)
 Online games

44 |
12150G48A - Network Fundamentals | II Yr / IV Sem

UDP Datagram Reassembly

Because UDP is connectionless, sessions are not established before communication takes place
as they are with TCP. UDP is said to be transaction-based. In other words, when an application
has data to send, it simply sends the data. The UDP PDU is referred to as a datagram, although
the terms segment and datagram are sometimes used interchangeably to describe a Transport
layer PDU. When multiple datagrams are sent to a destination, they may take different paths a nd
arrive in the wrong order.
UDP does not keep track of sequence numbers the way TCP does. UDP has no way to reorder
the datagrams into their transmission order. UDP simply reassembles the data in the order that it
was received and forwards it to the application.

UDP server process

Like TCP-based applications, UDP-based server applications are assigned Well Known or
Registered port numbers. When these applications or processes are running, they will accept the
data matched with the assigned port number. When UDP receives a datagram destined for one of
these ports, it forwards the application data to the appropriate application based on its port
number.

Fig 2.27 UDP Server Process

45 |
12150G48A - Network Fundamentals | II Yr / IV Sem

UDP Client Process

The UDP client process randomly selects a port number from the dynamic range of port numbers
and uses this as the source port for the conversation. The destination port will usually be the Well
Known or Registered port number assigned to the server process.
Because there is no session to be created with UDP, as soon as the data is ready to be sent and
the ports identified, UDP can form the datagram and pass it to the Network layer to be addressed
and sent on the network.

Fig 2.27 UDP Client Process

46 |
12150G48A - Network Fundamentals | II Yr / IV Sem

UNIT –III NETWORK LAYER AND ADDRESSING


1. Network Layer

The Network layer, or OSI Layer 3, provides services to exchange the individual pieces of data
over the network between identified end devices. To accomplish this end-to-end transport, Layer
3 uses four basic processes:
 Addressing
 Encapsulation
 Routing
 Decapsulation
1.1 Addressing
First, the Network layer must provide a mechanism for addressing these end devices. If
individual pieces of data are to be directed to an end device, that device must have a unique
address. In an IPv4 network, when this address is added to a device, the device is then referred to
as a host.

1.2 Encapsulation
During the encapsulation process, Layer 3 receives the Layer 4 PDU and adds a Layer 3 header,
or label, to create the Layer 3 PDU. When referring to the Network layer, we call this PDU a
packet. When a packet is created, the header must contain, among other information, the address
of the host to which it is being sent. This address is referred to as the destination address. The
Layer 3 header also contains the address of the originating host. This address is called the source
address.

1.3 Routing
Next, the Network layer must provide services to direct these packets to their destination host.
Intermediary devices that connect the networks are called routers. The role of the router is to
select paths for and direct packets toward their destination. This process is known as routing.

1.4 Decapsulation
Finally, the packet arrives at the destination host and is processed at Layer 3. The host examines
the destination address to verify that the packet was addressed to this device. If the address is
correct, the packet is decapsulated by the Network layer and the Layer 4 PDU contained in the
packet is passed up to the appropriate service at Transport layer.

47 |
12150G48A - Network Fundamentals | II Yr / IV Sem

2 Network Layer Protocols

Protocols implemented at the Network layer that carry user data include:
 Internet Protocol version 4 (IPv4)
 Internet Protocol version 6 (IPv6)
 Novell Internetwork Packet Exchange (IPX)
 AppleTalk
 Connectionless Network Service (CLNS/DECNet)

2.1 The IPv4 protocol

he Internet Protocol was designed as a protocol with low overhead. It provides only the functions
that are necessary to deliver a packet from a source to a destination over an interconnected
system of networks. The protocol was not designed to track and manage the flow of packets.
These functions are performed by other protocols in other layers.

IPv4 basic characteristics:

 Connectionless - No connection is established before sending data packets.


 Best Effort (unreliable) - No overhead is used to guarantee packet delivery.
 Media Independent - Operates independently of the medium carrying the data.

2.1.1 Connectionless Service

An example of connectionless communication is sending a letter to someone without notifying


the recipient in advance. As shown in the figure, the postal service still takes the letter and
delivers it to the recipient. Connectionless data communications works on the same principle. IP
packets are sent without notifying the end host that they are coming.

48 |
12150G48A - Network Fundamentals | II Yr / IV Sem

Best Effort Service (unreliable)

The IP protocol does not burden the IP service with providing reliability. Compared to a reliable
protocol, the IP header is smaller. Transporting these smaller headers requires less overhead.
Less overhead means less delay in delivery. This characteristic is desirable for a Layer 3
protocol.

Unreliable means simply that IP does not have the capability to manage, and recover from,
undelivered or corrupt packets.

Since protocols at other layers can manage reliability, IP is allowed to function very efficiently at
the Network layer.

2.1.2 Media Independent

The Network layer is also not burdened with the characteristics of the media on which packets
will be transported. IPv4 and IPv6 operate independently of the media that carry the data at
lower layers of the protocol stack. As shown in the figure, any individual IP packet can be
communicated electrically over cable, as optical signals over fiber, or wirelessly as radio signals.

2.2 IPv4 Packer Heade r


IPv4 protocol defines many different fields in the packet header. These fields contain binary
values that the IPv4 services reference as they forward packets across the network.

IP Destination Address

The IP Destination Address field contains a 32-bit binary value that represents the packet
destination Network layer host address.

49 |
12150G48A - Network Fundamentals | II Yr / IV Sem

IP Source Address

The IP Source Address field contains a 32-bit binary value that represents the packet source
Network layer host address.

The Time-to-Live (TTL)

The Time-to-Live(TTL) is an 8-bit binary value that indicates the remaining "life" of the packet.
The TTL value is decreased by at least one each time the packet is processed by a router (that is,
each hop). When the value becomes zero, the router discards or drops the packet and it is
removed from the network data flow. This mechanism prevents packets that cannot reach their
destination from being forwarded indefinitely between routers in a routing loop

Protocol
This 8-bit binary value indicates the data payload type that the packet is carrying. The Protocol
field enables the Network layer to pass the data to the appropriate upper- layer protocol.

Type-of-Service
The Type-of-Service field contains an 8-bit binary value that is used to determine the priority of
each packet. This value enables a Quality-of-Service (QoS) mechanism to be applied to high
priority packets, such as those carrying telephony voice data. The router processing the packets
can be configured to decide which packet it is to forward first based on the Type-of-Service
value.

Fragment Offset
A router may have to fragment a packet when forwarding it from one medium to another
medium that has a smaller MTU. When fragmentation occurs, the IPv4 packet uses the Fragment
Offset field and the MF flag in the IP header to reconstruct the packet when it arrives at the
destination host. The fragment offset field identifies the order in which to place the packet
fragment in the reconstruction.

Version - Contains the IP version number (4)

Header Length (IHL) - Specifies the size of the packet header.

Packet Length - This field gives the entire packet size, including header and data, in bytes.

Identification - This field is primarily used for uniquely identifying fragments of an original IP
packet

Header Checksum - The checksum field is used for error checking the packet header.

Options - There is provision for additional fields in the IPv4 header to provide other services but
these are rarely used.

50 |
12150G48A - Network Fundamentals | II Yr / IV Sem

3 Networks – Separating hosts into common groups

One of the major roles of the Network layer is to provide a mechanism for addressing hosts. As
the number of hosts on the network grows, more planning is required to manage and address the
network.

3.1 Dividing Networks


Rather than having all hosts everywhere connected to one vast global network, it is more
practical and manageable to group hosts into specific networks. networks can be grouped based
on factors that include:
 Geographic location
 Purpose
 Ownership

The Reason for dividing the hosts into separate groups includes:-
 Improving Performance
 Security
 Address Management

4 Routing – How the packets are handled

The role of the Network layer is to transfer data from the host that originates the data to the host
that uses it. During encapsulation at the source host, an IP packet is constructed Layer 3 to
transport the Layer 4 PDU. If the destination host is in the same network as the source host, the
packet is delivered between the two hosts on the local media without the need for a router.

If communication is between hosts in different networks, the local network delivers the packet
from the source to its gateway router. The router examines the network portion of the packet
destination address and forwards the packet to the appropriate interface. If the destina tion
network is directly connected to this router, the packet is forwarded directly to that host. If the
destination network is not directly connected, the packet is forwarded on to a second router that
is the next-hop router.

51 |
12150G48A - Network Fundamentals | II Yr / IV Sem

4.1 Gateway

The gateway, also known as the default gateway, is needed to send a packet out of the local
network. If the network portion of the destination address of the packet is different from the
network of the originating host, the packet has to be routed outside the original network. To do
this, the packet is sent to the gateway. This gateway is a router interface connected to the local
network. The gateway interface has a Network layer address that matches the network address of
the hosts. The hosts are configured to recognize that address as the gateway.

No packet can be forwarded without a route. Whether the packet is originating in a host or being
forwarded by an intermediary device, the device must have a route to identify where to forward
the packet.

A host must either forward a packet to the host on the local network or to the gateway, as
appropriate. To forward the packets, the host must have routes that represent these destinations.

4.2 Route

Like end devices, routers also add routes for the connected networks to their routing table. When
a router interface is configured with an IP address and subnet mask, the interface becomes part of
that network. The routing table now includes that network as a directly connected network. All
other routes, however, must be configured or acquired via a routing protocol. To forward a
packet the router must know where to send it. This information is available as routes in a routing
table.
Routes in a routing table have three main features:
 Destination network
 Next-hop
 Metric

The router matches the destination address in the packet header with the destination network of a
route in the routing table and forwards the packet to the next- hop router specified by that route. If
there are two or more possible routes to the same destination, the metric is used to decide which
route appears on the routing table.

4.3 The Next HOP

A next- hop is the address of the device that will process the packet next. For a host on a network,
the address of the default gateway (router interface) is the next-hop for all packets destined for
another network.

In the routing table of a router, each route lists a next hop for each destination address that is
encompassed by the route. As each packet arrives at a router, the destination network address is
examined and compared to the routes in the routing table. When a matching route is determined,
the next hop address for that route is used to forward of the packet toward its destination. The
router then forwards the packet out the interface to which the next-hop router is connected. The
next-hop router is the gateway to networks beyond that intermediate destination.

52 |
12150G48A - Network Fundamentals | II Yr / IV Sem

4.4 Packet Forwarding

Routing is done packet-by-packet and hop-by- hop. Each packet is treated independently in each
router along the path. At each hop, the router examines the destination IP address for each packet
and then checks the routing table for forwarding information.

The router will do one of three things with the packet:


 Forward it to the next-hop router
 Forward it to the destination host
 Drop it

4.4.1 Packet Examination

As an intermediary device, a router processes the packet at the Network layer. However, packets
that arrive at a router's interfaces are encapsulated as a Data Link layer (Layer 2) PDU. As show
in the figure, the router first discards the Layer 2 encapsulation so that the packet can be
examined.

4.4.2 Next Hop Selection

In the router, the destination address in a packet header is examined. If a matching route in the
routing table shows that the destination network is directly connected to the router, the packet is
forwarded to the interface to which that network is connected. In this case, there is no next-hop.
To be placed onto the connected network, the packet has to be first re-encapsulated by the Layer
2 protocol and then forwarded out the interface.

53 |
12150G48A - Network Fundamentals | II Yr / IV Sem

4.4.3 Using the Default Route

As shown in the figure, if the routing table does not contain a more specific route entry for an
arriving packet, the packet is forwarded to the interface indicated by a default route, if one exists.
At this interface, the packet is encapsulated by the Layer 2 protocol and sent to the next-hop
router. The default route is also known as the Gateway of Last Resort.

This process may occur number of times until the packet reaches its destination network. The
router at each hop knows only the address of the next- hop; it does not know the details of the
pathway to the remote destination host.

5 Routing Protocols – Sharing routes

Routing requires that every hop, or router, along the path to a packet's destination have a route to
forward the packet. Otherwise, the packet is dropped at that hop. Each router in a path does not
need a route to all networks. It only needs to know the next hop on the path to the packet's
destination network.

The routing table contains the information that a router uses in its packet forwarding decisions.
For the routing decisions, the routing table needs to represent the most accurate state of network
pathways that the router can access. Out-of-date routing information means that packets may not
be forwarded to the most appropriate next- hop, causing delays or packet loss.

5.1 Static Routing

Routes to remote networks with the associated next hops can be manually configured on the
router. This is known as static routing. A default route can also be statically configured.

If the router is connected to a number of other routers, knowledge of the internetworking


structure is required. To ensure that the packets are routed to use the best possible next hops,
each known destination network needs to either have a route or a default route configured.
Because packets are forwarded at every hop, every router must be configured with static routes
to next hops that reflect its location in the internetwork.

5.2 Dynamic Routing

Although it is essential for all routers in an internetwork to have up-to-date extensive route
knowledge, maintaining the routing table by manual static configuration is not always feasible.
Therefore, dynamic routing protocols are used. Routing p rotocols are the set of rules by which
routers dynamically share their routing information. As routers become aware of changes to the
networks for which they act as the gateway, or changes to links between routers, this information
is passed on to other routers. When a router receives information about new or changed routes, it
updates its own routing table and, in turn, passes the information to other routers.

54 |
12150G48A - Network Fundamentals | II Yr / IV Sem

Common routing protocols are:


Routing Information Protocol (RIP)
Enhanced Interior Gateway Protocol (EIGRP)
Open Shortest Path First (OSPF)

6 The Anatomy of IP address

Each device on a network must be uniquely defined. At the Network layer, the packets of the
communication need to be identified with the source and destination addresses of the two end
systems. With IPv4, this means that each packet has a 32-bit source address and a 32-bit
destination address in the Layer 3 header.

55 |
12150G48A - Network Fundamentals | II Yr / IV Sem

6.1 Network and Host Portions

For each IPv4 address, some portion of the high-order bits represents the network address. At
Layer 3, we define a network as a group of hosts that have identical bit patterns in the network
address portion of their addresses.

Although all 32 bits define the IPv4 host address, we have a variable number of bits that are
called the host portion of the address. The number of bits used in this host portion determines the
number of hosts that we can have within the network.

6.1 Types of Addresses

Network address - The address by which we refer to the network


Broadcast address - A special address used to send data to all hosts in the network
Host addresses - The addresses assigned to the end devices in the network

6.2 Types of Communication


In an IPv4 network, the hosts can communicate one of three different ways:

Unicast - the process of sending a packet from one host to an individual host

Broadcast - the process of sending a packet from one host to all hosts in the network

Multicast - the process of sending a packet from one host to a selected group of hosts

56 |
12150G48A - Network Fundamentals | II Yr / IV Sem

6.2.1 Unicast Traffic

Unicast communication is used for the normal host-to-host communication in both a client/server
and a peer-to-peer network. Unicast packets use the host address of the destination device as the
destination address and can be routed through an internetwork. Broadcast and multicast,
however, use special addresses as the destination address. Using these special addresses,
broadcasts are generally restricted to the local network. The scope of multicast traffic also may
be limited to the local network or routed through an internetwork.

6.2.2 Broadcast Transmission


Broadcast traffic is used to send packets to all hosts in the network, a packet uses a special
broadcast address. When a host receives a packet with the broadcast address as the destination, it
processes the packet as it would a packet to its unicast address.
Broadcast transmission is used for the location of special services/devices for which the address
is not known or when a host needs to provide information to all the hosts on the network.

Some examples for using broadcast transmission are:


 Mapping upper layer addresses to lower layer addresses
 Requesting an address
 Exchanging routing information by routing protocols

6.2.3 Multicast Transmission


Multicast transmission is designed to conserve the bandwidth of the IPv4 network. It reduces
traffic by allowing a host to send a single packet to a selected set of hosts. To reach multiple
destination hosts using unicast communication, a source host would need to send an individual
packet addressed to each host. With multicast, the source host can send a single packet that can
reach thousands of destination hosts.

Some examples of multicast transmission are:


 Video and audio broadcasts
 Routing information exchange by routing protocols
 Distribution of software
 News feeds

6.3 Public and Private addresses


Although most IPv4 host addresses are public addresses designated for use in networks that are
accessible on the Internet, there are blocks of addresses that are used in networks that require
limited or no Internet access. These addresses are called private addresses.

6.3.1 Private Addresses


The private address blocks are:
10.0.0.0 to 10.255.255.255 (10.0.0.0 /8)

172.16.0.0 to 172.31.255.255 (172.16.0.0 /12)

192.168.0.0 to 192.168.255.255 (192.168.0.0 /16)

57 |
12150G48A - Network Fundamentals | II Yr / IV Sem

6.4 Special IPv4 Addresses

6.4.1 Default Route

Also presented earlier, we represent the IPv4 default route as 0.0.0.0. The default route is used as
a "catch all" route when a more specific route is not available. The use of this address also
reserves all addresses in the 0.0.0.0 - 0.255.255.255 (0.0.0.0 /8) address block.

6.4.2 Loopback

One such reserved address is the IPv4 loopback address 127.0.0.1. The loopback is a special
address that hosts use to direct traffic to themselves. The loopback address creates a shortcut
method for TCP/IP applications and services that run on the same device to communicate with
one another. By using the loopback address instead of the assigned IPv4 host address, two
services on the same host can bypass the lower layers of the TCP/IP stack. You can also ping the
loopback address to test the configuration of TCP/IP on the local host.

6.4.3 Link-Local Addresses

IPv4 addresses in the address block 169.254.0.0 to 169.254.255.255 (169.254.0.0 /16) are
designated as link- local addresses. These addresses can be automatically assigned to the local
host by the operating system in environments where no IP configuration is available. These
might be used in a small peer-to-peer network or for a host that could not automatically obtain an
address from a Dynamic Host Configuration Protocol (DHCP) server.

7 Internet Assigned Numbe rs Authority (IANA) ( http://www.iana.net ) is the master holder


of the IP addresses. The IP multicast addresses and the IPv6 addresses are obtained directly from
IANA. Until the mid-1990s, all IPv4 address space was managed directly by the IANA. At that
time, the remaining IPv4 address space was allocated to various other registries to manage for
particular purposes or for regional areas

8 ISP2

8.1 The Role of the ISP

Most companies or organizations obtain their IPv4 address blocks from an ISP. An ISP will
generally supply a small number of usable IPv4 addresses (6 or 14) to their customers as a part of
their services. Larger blocks of addresses can be obtained based on justification of needs and for
additional service costs.

8.2 ISP Services

To get access to the services of the Internet, we have to connect our data network to the Internet
using an Internet Service Provider (ISP).

58 |
12150G48A - Network Fundamentals | II Yr / IV Sem

ISPs have their own set of internal data networks to manage Internet connectivity and to provide
related services. Among the other services that an ISP generally provides to its customers are
DNS services, e- mail services, and a website. Depending on the level of service required and
available, customers use different tiers of an ISP.

9 Overvie w of IPv6

In the early 1990s, the Internet Engineering Task Force (IETF) grew concerned about the
exhaustion of the IPv4 network addresses and began to look for a replacement for this protocol.
This activity led to the development of what is now known as IPv6.

Creating expanded addressing capabilities was the initial motivation for developing this new
protocol. Other issues were also considered during the development of IPv6, suc h as:
 Improved packet handling
 Increased scalability and longevity
 QoS mechanisms
 Integrated security

To provide these features, IPv6 offers:


 128-bit hierarchical addressing - to expand addressing capabilities
 Header format simplification - to improve packet handling
 Improved support for extensions and options - for increased
scalability/longevity and improved packet handling
 Flow labeling capability - as QoS mechanisms
 Authentication and privacy capabilities - to integrate security

10 Basic Subnetting

Subnetting allows for creating multiple logical networks from a single address block. Since we
use a router to connect these networks together, each interface on a router must have a unique
network ID. Every node on that link is on the same network.

59 |
12150G48A - Network Fundamentals | II Yr / IV Sem

We create the subnets by using one or more of the host bits as network bits. This is done by
extending the mask to borrow some of the bits from the host portion of the address to create
additional network bits. The more host bits used, the more subnets that can be defined.

11 Ping
Ping is a utility for testing IP connectivity between hosts. Ping sends out requests for responses
from a specified host address. Ping uses a Layer 3 protocol that is a part on the TCP/IP suite
called Internet Control Message Protocol (ICMP). Ping uses an ICMP Echo Request datagram.

You can also use ping to test the host ability to communicate on the local network. This is
generally done by pinging the IP address of the gateway of the host, as shown in the figure. A
ping to the gateway indicates that the host and the router's interface serving as that gateway are
both operational on the local network.

You can also use ping to test the ability of the local IP host to communicate across an
internetwork. The local host can ping an operational host of a remote network,

12 Traceroute

Ping is used to indicate the connectivity between two hosts. Traceroute (tracert) is a utility that
allows us to observe the path between these hosts. The trace generates a list of hops that were
successfully reached along the path.

This list can provide us with important verification and troubleshooting information. If the data
reaches the destination, then the trace lists the interface on every router in the path.

60 |
12150G48A - Network Fundamentals | II Yr / IV Sem

UNIT – IV DATA LINK AND PHYSICAL LAYER


1 The Data Link layer

The Data Link layer provides a means for exchanging data over a common local media.

The Data Link layer performs two basic services:


 Allows the upper layers to access the media using techniques such as framing
 Controls how data is placed onto the media and is received from the media using
techniques such as media access control and error detection

There are terms specific to this layer:

Frame - The Data Link layer PDU

Node - The Layer 2 notation for network devices connected to a common medium

Media/medium (physical) - The physical means for the transfer of information between two
nodes

Network (physical) - Two or more nodes connected to a common medium

The Data Link layer is responsible for the exchange of frames between nodes over the media of a
physical network.

61 |
12150G48A - Network Fundamentals | II Yr / IV Sem

1.1 Controlling Transfer Across Local Media

Layer 2 protocols specify the encapsulation of a packet into a frame and the techniques for
getting the encapsulated packet on and off each medium. The technique used for getting the
frame on and off media is called the media access control method. For the data to be transferred
across a number of different media, different media access control methods may be required
during the course of a single communication.

The media access control methods described by the Data Link layer protocols define the
processes by which network devices can access the network media and transmit frames in
diverse network environments.

1.2 Creating a Frame

The description of a frame is a key element of each Data Link layer protocol. Data Link layer
protocols require control information to enable the protocols to function. Control information
may tell:
Which nodes are in communication with each other
 When communication between individual nodes begins and when it ends
 Which errors occurred while the nodes communicated
 Which nodes will communicate next

The Data Link layer prepares a packet for transport across the local media by encapsulating it
with a header and a trailer to create a frame.

Unlike the other PDUs that have been discussed in this course, the Data Link layer frame
includes:
 Data - The packet from the Network layer
 Header - Contains control information, such addressing, and is located at the beginning of
the PDU
 Trailer - Contains control information added to the end of the PDU

62 |
12150G48A - Network Fundamentals | II Yr / IV Sem

1.3 Formatting data for Transmission

Framing breaks the stream into decipherable groupings, with control information inserted in the
header and trailer as values in different fields. This format gives the physical signals a structure
that can be received by nodes and decoded into packets at the destination.

Typical field types include:


 Start and stop indicator fields - The beginning and end limits of the frame
 Naming or addressing fields
 Type field - The type of PDU contained in the frame
 Quality - control fields
 A data field -The frame payload (Network layer packet)

Fields at the end of the frame form the trailer. These fields are used for error detection and mark
the end of the frame.

2 Data Link Sub layers

To support a wide variety of network functions, the Data Link layer is often divided into two
sublayers: an upper sublayer and an lower sublayer.
 The upper sublayer defines the software processes that provide services to the Network
layer protocols.
 The lower sublayer defines the media access processes performed by the hardware.
The two common LAN sublayers are:
2.1 Logical Link Control
Logical Link Control (LLC) places information in the frame that identifies which Network layer
protocol is being used for the frame. This information allows multiple Layer 3 protocols, such as
IP and IPX, to utilize the same network interface and media.

2.2 Media Access Control


Media Access Control (MAC) provides Data Link layer addressing and delimiting of data
according to the physical signaling requirements of the medium and the type of Data Link layer
protocol in use.

63 |
12150G48A - Network Fundamentals | II Yr / IV Sem

3 Standards

Data Link layer services and specifications are defined by multiple standards based on a variety
of technologies and media to which the protocols are applied. Some of these standards integrate
both Layer 2 and Layer 1 services.

Engineering organizations that define open standards and protocols that apply to the Data Link
layer include:
 International Organization for Standardization (ISO)
 Institute of Electrical and Electronics Engineers (IEEE)
 American National Standards Institute (ANSI)
 International Telecommunication Union (ITU)

4 Media Access Control Techniques(MAC)

Regulating the placement of data frames onto the media is known as media access control.
Among the different implementations of the Data Link layer protocols, there are different
methods of controlling access to the media. These media access control techniques define if and
how the nodes share the media.

4.1 Media Access Control for Shared Media

There are two basic media access control methods for shared media:
 Controlled - Each node has its own time to use the medium
 Contention-based - All nodes compete for the use of the medium

4.1.1 Controlled Access for Shared Media

When using the controlled access method, network devices take turns, in sequence, to access the
medium. This method is also known as scheduled access or deterministic. If a device does not
need to access the medium, the opportunity to use the medium passes to the next device in line.
When one device places a frame on the media, no other device can do so until the frame has
arrived at the destination and has been processed by the destination.

4.1.2 Contention-based Access for Shared Media

Also referred to as non-deterministic, contention-based methods allow any device to try to access
the medium whenever it has data to send. To prevent complete chaos on the media, these
methods use a Carrier Sense Multiple Access (CSMA) process to first detect if the media is
carrying a signal. If a carrier signal on the media from another node is detected, it means that
another device is transmitting. When the device attempting to transmit sees that the media is
busy, it will wait and try again after a short time period. If no carrier signal is detected, the
device transmits its data. Ethernet and wireless networks use contention-based media access
control.

64 |
12150G48A - Network Fundamentals | II Yr / IV Sem

4.2 Media Access Control for Non-Shared Media

Media access control protocols for non-shared media require little or no control before placing
frames onto the media. These protocols have simpler rules and procedures for media access
control. Such is the case for point-to-point topologies.

4.2.1 Full Duplex and Half Duplex

Half-duplex communication means that the devices can both transmit and receive on the media
but cannot do so simultaneously. Ethernet has established arbitration rules for resolving conflicts
arising from instances when more than one station attempts to transmit at the same time.

In full-duplex communication, both devices can transmit and receive on the media at the same
time. The Data Link layer assumes that the media is available for transmission for both nodes at
any time. Therefore, there is no media arbitration necessary in the Data Link layer.

4.2.2 Logical Topology Vs Physical Topology

The topology of a network is the arrangement or relationship of the network devices and the
interconnections between them. Network topologies can be viewed at the physical level and the
logical level.

The physical topology is an arrangement of the nodes and the physical connections between
them. The representation of how the media is used to interconnect the devices is the physical
topology. These will be covered in later chapters of this course.

A logical topology is the way a network transfers frames from one node to the next. This
arrangement consists of virtual connections between the nodes of a network independent of their
physical layout. These logical signal paths are defined by Data Link layer protocols. The Data
Link layer "sees" the logical topology of a network when controlling data access to the media. It
is the logical topology that influences the type of network framing and media access control
used.

Logical and physical topologies typically used in networks are:


 Point-to-Point
 Multi-Access
 Ring
Point-to-Point

A point-to-point topology connects two nodes directly together, as shown in the figure. In data
networks with point-to-point topologies, the media access control protocol can be very simple.
All frames on the media can only travel to or from the two nodes. The frames are placed on the
media by the node at one end and taken off the media by the node at the other end of the point-
to-point circuit.

65 |
12150G48A - Network Fundamentals | II Yr / IV Sem

Multi Access Topology


A logical multi-access topology enables a number of nodes to communicate by using the same
shared media. Data from only one node can be placed on the medium at any one time. Every
node sees all the frames that are on the medium, but only the node to which the frame is
addressed processes the contents of the frame.

The media access control methods used by logical multi-access topologies are typically
CSMA/CD or CSMA/CA. However, token passing methods can also be used.

66 |
12150G48A - Network Fundamentals | II Yr / IV Sem

Ring Topology

In a logical ring topology, each node in turn receives a frame. If the frame is not addressed to the
node, the node passes the frame to the next node. This allows a ring to use a controlled media
access control technique called token passing.

Nodes in a logical ring topology remove the frame from the ring, examine the address, and send
it on if it is not addressed for that node. In a ring, all nodes around the ring- between the source
and destination node examine the frame.

5 Data Link laye r protocols – The Frame


Frame type has three basic parts:

 Header
 Data
 Trailer

The structure of the frame and the fields contained in the header and trailer vary according to the
protocol.

The Data Link layer protocol describes the features required for the transport of packets across
different media. These features of the protocol are integrated into the encapsulation of the frame.
When the frame arrives at its destination and the Data Link protocol takes the frame off the
media, the framing information is read and discarded.

67 |
12150G48A - Network Fundamentals | II Yr / IV Sem

Typical frame header fields include:


 Start Frame field - Indicates the beginning of the frame
 Source and Destination address fields - Indicates the source and destination nodes on the
media
 Priority/Quality of Service field - Indicates a particular type of communication service for
processing
 Type field - Indicates the upper layer service contained in the frame
 Logical connection control field - Used to establish a logical connection between nodes
 Physical link control field - Used to establish the media link
 Flow control field - Used to start and stop traffic over the media
 Congestion control field - Indicates congestion in the media

The data Link layer provides addressing that is used in transporting the frame across the shared
local media. Device addresses at this layer are referred to as physical addresses. Data Link layer
addressing is contained within the frame header and specifies the frame destination node on the
local network. The frame header may also contain the source address of the frame.

Unlike Layer 3 logical addresses that are hierarchical, physical addresses do not indicate on what
network the device is located. If the device is moved to another network or subnet, it will still
function with the same Layer 2 physical address.

Frame Check Sequence

The Frame Check Sequence (FCS) field is used to determine if errors occurred in the
transmission and reception of the frame. Error detection is added at the Data Link layer because
this is where data is transferred across the media. The media is a potentially unsafe environment
for data. The signals on the media could be subject to interference, distortion, or loss that would
substantially change the bit values that those signals represent. The error detection mechanism
provided by the use of the FCS field discovers most errors caused on the media.

6 Data link layer protocols


Ethernet
Point-to-Point Protocol (PPP)
High-Level Data Link Control (HDLC)
Frame Relay
Asynchronous Transfer Mode (ATM)

68 |
12150G48A - Network Fundamentals | II Yr / IV Sem

Each protocol performs media access control for specified Layer 2 logical topologies. This
means that a number of different network devices can act as nodes that operate at the Data Link
layer when implementing these protocols. These devices include the network adapter or network
interface cards (NICs) on computers as well as the interfaces on routers and Layer 2 switches.

6.1 Ethernet Protocol for LANs

Ethernet is a family of networking technologies that are defined in the IEEE 802.2 and 802.3
standards. Ethernet standards define both the Layer 2 protocols and the Layer 1 technologies.
Ethernet is the most widely used LAN technology and supports data bandwidths of 10, 100,
1000, or 10,000 Mbps.

Ethernet provides unacknowledged connectionless service over a shared media using CSMA/CD
as the media access methods. Shared media requires that the Ethernet packet header use a Data
Link layer address to identify the source and destination nodes. As with most LAN protocols,
this address is referred to as the MAC address of the node. An Ethernet MAC address is 48 bits
and is generally represented in hexadecimal format.

6.2 Point-to-Point Protocol for WANs

Point-to-Point Protocol (PPP) is a protocol used to deliver frames between two nodes. Unlike
many Data Link layer protocols that are defined by electrica l engineering organizations, the PPP
standard is defined by RFCs. PPP was developed as a WAN protocol and remains the protocol of
choice to implement many serial WANs. PPP can be used on various physical media, including
twisted pair, fiber optic lines, and satellite transmission, as well as for virtual connections.

69 |
12150G48A - Network Fundamentals | II Yr / IV Sem

6.3 Wireless Protocol for LANs

802.11 is an extension of the IEEE 802 standards. It uses the same 802.2 LLC and 48-bit
addressing scheme as other 802 LANs, However there are many differences at the MAC
sublayer and Physical layer. In a wireless environment, the environment requires special
considerations. There is no definable physical connectivity; therefore, external factors may
interfere with data transfer and it is difficult to control access. To meet these challenges, wireless
standards have additional controls.

The Standard IEEE 802.11, commonly referred to as Wi-Fi, is a contention-based system using a
Carrier Sense Multiple Access/Collision Avoidance (CSMA/CA) media access process.
CSMA/CA specifies a random backoff procedure for all nodes that are waiting to transmit. The
most likely opportunity for medium contention is just after the medium becomes available.
Making the nodes back off for a random period greatly reduces the likelihood of a collision.

70 |
12150G48A - Network Fundamentals | II Yr / IV Sem

7 Physical Layer
The OSI Physical layer provides the means to transport across the network media the bits that
make up a Data Link layer frame. This layer accepts a complete frame from the Data Link layer
and encodes it as a series of signals that are transmitted onto the local media. The encoded bits
that comprise a frame are received by either an end device or an intermediate device.

The delivery of frames across the local media requires the following Physical layer elements:
 The physical media and associated connectors
 A representation of bits on the media
 Encoding of data and control information
 Transmitter and receiver circuitry on the network devices

The purpose of the Physical layer is to create the electrical, optical, or microwave signal that
represents the bits in each frame. These signals are then sent on the media one at a time.

71 |
12150G48A - Network Fundamentals | II Yr / IV Sem

7.1 Physical Operation

The media does not carry the frame as a single entity. The media carries signals, one at a time, to
represent the bits that make up the frame.

There are three basic forms of network media on which data is represented:
 Copper cable
 Fiber
 Wireless

7.1.1 Identifying a Frame

When the Physical layer encodes the bits into the signals for a particular medium, it must also
distinguish where one frame ends and the next frame begins. Otherwise, the devices on the
media would not recognize when a frame has been fully received. In that case, the destination
device would only receive a string of signals and would not be able to properly reconstruct the
frame. As described in the previous chapter, indicating the beginning of frame is often a function
of the Data Link layer. However, in many technologies, the Physical layer may add its own
signals to indicate the beginning and end of the frame.

7.2 Standards

The Physical layer technologies are defined by organizations such as:

The International Organization for Standardization (ISO)


The Institute of Electrical and Electronics Engineers (IEEE)
The American National Standards Institute (ANSI)
The International Telecommunication Union (ITU)
The Electronics Industry Alliance/Telecommunications Industry Association (EIA/TIA)
National telecommunications authorities such as the Federal Communication Commission
(FCC) in the USA.

8 Physical Layer Fundame ntal Principles

The three fundamental functions of the Physical layer are:

The physical components


Data encoding
Signaling

The physical elements are the electronic hardware devices, media and connectors other that
transmit and carry the signals to represent the bits.

72 |
12150G48A - Network Fundamentals | II Yr / IV Sem

8.1 Encoding

Encoding is a method of converting a stream of data bits into a predefined "code. Codes are
groupings of bits used to provide a predictable pattern that can be recognized by both the sender
and the received. Using predictable patterns helps to distinguish data bits from control bits and
provide better media error detection.

8.2 Signaling

The Physical layer must generate the electrical, optical, or wireless signals that represent the "1"
and "0" on the media. The method of representing the bits is called the signaling method. The
Physical layer standards must define what type of signal represents a "1" and a "0". This can be
as simple as a change in the level of an electrical signal or optical pulse or a mo re complex
signaling method.

9 Data Carrying Capacity


Different physical media support the transfer of bits at different speeds. Data transfer can be
measured in three ways:
Bandwidth
Throughput
Goodput

9.1 Bandwidth

The capacity of a medium to carry data is described as the raw data bandwidth of the media.
Digital bandwidth measures the amount of information that can flow from one place to another
in a given amount of time. Bandwidth is typically measured in kilobits per second (kbps) or
megabits per second (Mbps).

9.2 Throughput

Throughput is the measure of the transfer of bits across the media over a given period of time.
Due to a number of factors, throughput usually does not match the specified bandwidth in
Physical layer implementations such as Ethernet.

9.3 Goodput

A third measurement has been created to measure the transfer of usable data. That measure is
known as goodput. Goodput is the measure of usable data transferred over a given period of
time, and is therefore the measure that is of most interest to network users.
As shown in the figure, goodput measures the effective transfer of user data between Application
layer entities, such as between a source web server process and a destination web browser
device.

73 |
12150G48A - Network Fundamentals | II Yr / IV Sem

10 Types of Physical me dia

The Physical layer is concerned with network media and signaling. This layer produces the
representation and groupings of bits as voltages, radio frequencies, or light pulses. Various
standards organizations have contributed to the definition of the physica l, electrical, and
mechanical properties of the media available for different data communications. These
specifications guarantee that cables and connectors will function as anticipated with different
Data Link layer implementations.

As an example, standards for copper media are defined for the:


Type of copper cabling used
Bandwidth of the communication
Type of connectors used
Pinout and color codes of connections to the media
Maximum distance of the media

10.1 Coppe r media

The most commonly used media for data communications is cabling that uses copper wires to
signal data and control bits between network devices. Cabling used for data communications
usually consists of a series of individual copper wires that form circuits dedicated to specific
signaling purposes.

Other types of copper cabling, known as coaxial cable, have a single conductor that runs through
the center of the cable that is encased by, but insulated from, the other shield. The copper media
type chosen is specified by the Physical layer standard required to link the Data Link layers of
two or more network devices.

74 |
12150G48A - Network Fundamentals | II Yr / IV Sem

10.1.1 Unshielded twisted-pair (UTP) cable

Unshielded twisted-pair (UTP) cabling, as it is used in Ethernet LANs, consists of four pairs of
color-coded wires that have been twisted together and then encased in a flexible plastic sheath.
As seen in the figure, the color codes identify the individual pairs and wires in the pairs and aid
in cable termination.

The twisting has the effect of canceling unwanted signals. When two wires in an electrical circuit
are placed close together, external electromagnetic fields create the same interference in each
wire. The pairs are twisted to keep the wires in as close proximity as is physically possible.
When this common interference is present on the wires in a twisted pair, the receiver processes it
in equal yet opposite ways. As a result, the signals caused b y electromagnetic interference from
external sources are effectively cancelled.

10.1.2 UTP Cable Types


The following are main cable types that are obtained by using specific wiring conventions:
 Ethernet Straight-through
 Ethernet Crossover
 Rollover

75 |
12150G48A - Network Fundamentals | II Yr / IV Sem

Two other types of copper cable are used:

1. Coaxial
2. Shielded Twisted-Pair (STP)

10.1.3 Coaxial Cable


Coaxial cable consists of a copper conductor surrounded by a layer of flexible insulation, as
shown in the figure.

Over this insulating material is a woven copper braid, or metallic foil, that acts as the second
wire in the circuit and as a shield for the inner conductor. This second layer, or shield, also
reduces the amount of outside electromagnetic interference. Covering the shield is the cable
jacket.

76 |
12150G48A - Network Fundamentals | II Yr / IV Sem

10.1.4 Shielded Twisted-Pair (STP) Cable

Another type of cabling used in networking is shielded twisted-pair (STP). As shown in the
figure, STP uses two pairs of wires that are wrapped in an overall metallic braid or foil.
STP cable shields the entire bundle of wires within the cable as well as the individual wire pairs.
STP provides better noise protection than UTP cabling, however at a significantly higher price.

10.2 Fiber Media


Fiber-optic cabling uses either glass or plastic fibers to guide light impulses from source to
destination. The bits are encoded on the fiber as light impulses . Optical fiber cabling is capable
of very large raw data bandwidth rates. Most current transmission standards have yet to approach
the potential bandwidth of this media.

Optical fiber media implementation issues include:


 More expensive (usually) than copper media over the same distance (but for a higher
capacity)
 Different skills and equipment required to terminate and splice the cable infrastructure
 More careful handling than copper media

Generating and Detecting the Optical Signal

77 |
12150G48A - Network Fundamentals | II Yr / IV Sem

Either lasers or light emitting diodes (LEDs) generate the light pulses that are used to represent
the transmitted data as bits on the media. Electronic semi-conductor devices called photodiodes
detect the light pulses and convert them to voltages that can then be reconstructed into data
frames.

Single- mode optical fiber carries a single ray of light, usually emitted from a laser. Because the
laser light is uni-directional and travels down the center of the fiber, this type of fiber can
transmit optical pulses for very long distances.

Multimode fiber typically uses LED emitters that do not create a single coherent light wave.
Instead, light from an LED enters the multimode fiber at different angles. Because light entering
the fiber at different angles takes different amounts of time to travel down the fiber, long fiber
runs may result in the pulses becoming blurred on reception at the receiving end. This effect,
known as modal dispersion, limits the length of multimode fiber segments.

10.3 Wireless media

Wireless media carry electromagnetic signals at radio and microwave frequencies that represent
the binary digits of data communications. As a networking medium, wireless is not restricted to
conductors or pathways, as are copper and fiber media.

Wireless data communication technologies work well in open environments. However, certain
construction materials used in buildings and structures, and the local terrain, will limit the
effective coverage. In addition, wireless is susceptible to interference and ca n be disrupted by
such common devices as household cordless phones, some types of fluorescent lights,
microwave ovens, and other wireless communications.

10.3.1 Types of Wireless Networks

The IEEE and telecommunications industry standards for wireless da ta communications cover
both the Data Link and Physical layers. Four common data communications standards that apply
to wireless media are:
 Standard IEEE 802.11 - Commonly referred to as Wi-Fi, is a Wireless LAN (WLAN)
technology that uses a contention or non-deterministic system with a Carrier Sense
Multiple Access/Collision Avoidance (CSMA/CA) media access process.
 Standard IEEE 802.15 - Wireless Personal Area Network (WPAN) standard, commonly
known as "Bluetooth", uses a device pairing process to communicate over distances from
1 to 100 meters.
 Standard IEEE 802.16 - Commonly known as WiMAX (Worldwide Interoperability for
Microwave Access), uses a point-to-multipoint topology to provide wireless broadband
access.
 Global System for Mobile Communications (GSM) - Includes Physical layer
specifications that enable the implementation of the Layer 2 General Packet Radio
Service (GPRS) protocol to provide data transfer over mobile cellular telephony
networks.

78 |
12150G48A - Network Fundamentals | II Yr / IV Sem

10.4 The Wireless LAN

A common wireless data implementation is enabling devices to wirelessly connect via a LAN. In
general, a wireless LAN requires the following network devices:
 Wireless Access Point (AP) - Concentrates the wireless signals from users and connects,
usually through a copper cable, to the existing copper-based network infrastructure such
as Ethernet.
 Wireless NIC adapters - Provides wireless communication capability to each network
host.

11 Media Connectors

11.1 Common Copper Media Connectors

Different Physical layer standards specify the use of different connectors. These standards
specify the mechanical dimensions of the connectors and the acceptable electrical properties of
each type for the different implementations in which they are employed.

Although some connectors may look the same, they may be wired differently according to the
Physical layer specification for which they were designed. The ISO 8877 specified RJ-45
connector is used for a range of Physical layer specifications, one of which is Ethernet. Another
specification, EIA-TIA 568, describes the wire color codes to pin assignments (pinouts) for
Ethernet straight-through and crossover cables.

79 |
12150G48A - Network Fundamentals | II Yr / IV Sem

11.2 Common Optical Fiber Connectors

Fiber-optic connectors come in a variety of types. The figure shows some of the most common:

Straight-Tip (ST) (trademarked by AT &T) - a very common bayonet style connector widely
used with multimode fiber.
Subscriber Connector (SC) - a connector that uses a push-pull mechanism to ensure positive
insertion. This connector type is widely used with single- mode fiber.
Lucent Connector (LC) - A small connector becoming popular for use with single- mode fiber
and also supports multi- mode fiber.

80 |
12150G48A - Network Fundamentals | II Yr / IV Sem

UNIT –V ETHERNET, CABLING AND CONFIGURING


Planning and Cabling Networks

Objectives

– Identify the basic network media required to make a LAN connection.


– Identify the types of connections for intermediate and end device connections in a
LAN.
– Identify the pinout configurations for straight-through and crossover cables.
– Identify the different cabling types, standards, and ports used for WAN
connections.
– Define the role of device management connections when using Cisco equipment.
– Design an addressing scheme for an internetwork and assign ranges for hosts,
network devices, and the router interface.
– Compare and contrast the importance of network designs.

LANs - Making the Physical Connection


Choosing the Appropriate LAN Device

 Routers are the primary devices used to interconnect networks.


– Each port on a router connects to a different network and routes packets between
the networks.
– Routers have the ability to break up broadcast domains and collision domains.
– Routers are also used to interconnect networks that use different technologies.
– They can have both LAN and WAN interfaces.

 The router's LAN interfaces allow routers to connect to the LAN media. This is usually
UTP cabling, but modules can be added for using fiber-optics.
– Depending on the model of router, there can be multiple interface types for
connection of LAN and WAN cabling.

81 |
12150G48A - Network Fundamentals | II Yr / IV Sem

– Each LAN will have a router as its gateway connecting the LAN to other
networks. Inside the LAN will be one or more hubs or switches to connect the end
devices to the LAN.
– For this course, the choice of which router to deploy is determined by the Ethernet
interfaces that match the technology of the switches at the center of the LAN.

 Hub
– A hub receives a signal, regenerates it, and sends the signal over all ports.
– The use of hubs creates a logical bus.
– This means that the LAN uses multiaccess media.
– The ports use a shared bandwidth approach and often have reduced performance
in the LAN due to collisions and recovery.
– Multiple hubs can be interconnected, they remain a single collision domain.
– A hub is typically chosen as an intermediary device within a small LAN, in a
LAN that has low throughput requirements, or when finances are limited.

 Switch
– A switch receives a frame and regenerates each bit of the frame on to the
appropriate destination port.
– Switch is used to segment a network into multiple collision domains.
– Switch reduces the collisions on a LAN. Each port on the switch creates a
separate collision domain. This creates a point-to-point logical topology to the
device on each port.
– Switch provides dedicated bandwidth on each port.
– Switch can also be used to interconnect segments of different speeds.
– There is a range of switches available with a variety of features that enable the
interconnection of multiple computers in a typical enterprise LAN setting.

Device Selection Factors


 To meet user requirements, a LAN needs to be planned and designed.
– Planning ensures that all requirements, cost factors and deployment options are
given due consideration.

82 |
12150G48A - Network Fundamentals | II Yr / IV Sem


These factors include, but are not limited to:
– Cost
– Speed and Types of Ports/Interfaces
– Expandability
– Manageability
– Additional Features and Services
 The two topics will be explored further:
– cost
– interface characteristics.
Switch Selection Factors: Cost
 The cost of a switch is determined by its capacity and features.
– The switch capacity includes the number and types of ports available and the
switching speed.
– Other factors that impact the cost are its network management capabilities,
embedded security technologies, and optional advanced switching technologies.

 Using a simple "cost per port" calculation, it may appear initially that the best option is
to deploy one large switch at a central location.
– However, this apparent cost savings may be offset by the expense from the longer
cable lengths required to connect every device on the LAN to one switch.
– This option should be compared with the cost of deploying a number of smaller
switches connected by a few long cables to a central switch.

 Another cost consideration is how much to invest in re dundancy.


– We can provide a secondary central switch to operate concurrently with the
primary central switch.
– We can also provide additional cabling to provide multiple interconnections
between the switches.
– The goal of redundant systems is to allow the physical network to continue its
operation even if one device fails.

83 |
12150G48A - Network Fundamentals | II Yr / IV Sem

Switch Selection: Speed and Types of Ports/Interfaces


Newer computers with built- in 10/100/1000 Mbps NICs are available. Choosing Layer 2
devices that can accommodate increased speeds allows the network to evolve without
replacing the central devices.
 When selecting a switch, choosing the number and type of ports is a critical decisio n. Ask
yourself these questions: Would you purchase a switch with:
– Just enough ports for today's needs?
– A mixture of UTP speeds?
– Both UTP and fiber ports?
• Consider carefully how many UTP ports will be needed and how many
fiber ports will be needed.
• Consider how many ports will need 1 Gbps capability and how many ports
only require 10/100 Mbps bandwidths.
• Consider how soon more ports will be needed.
Router Selection Factors

 When selecting a router, we need to match:


– Cost
• Routers can be expensive based on interfaces and features.
– Interface types
• Additional module, such as fiber-optics, can increase the costs.
– Expandability
• Routers come in both fixed and modular configurations.
– Fixed configurations have a specific number and type of ports.
– Modular devices have expansion slots that provide the flexibility to
add new modules as requirements evolve. Most modular devices
come with a basic number of fixed ports as well as expansion slots.

84 |
12150G48A - Network Fundamentals | II Yr / IV Sem

– Media
• The media used to connect to the router should be supported without
needing to purchase additional modules.
– Operating System Features
• Depending on the version of the operating system, the router can support
certain features and services such as:
– Security
– Quality of Service (QoS)
– Voice over IP (VoIP)
– Routing multiple Layer 3 protocols
– Services such as NAT and DHCP

Device Interconnections
LAN and WAN - Getting Connected

 When planning the LAN cabling, there are 4 areas:


– Work area
• It is the locations for the end devices and individual users.
• It uses patch cables to connect individual devices to wall jacks.
• It has a maximum length of 5 meters.
• Straight-through cable is the most common patch cable used.
• When a hub or switch is placed in the work area, a crossover cable is
typically used to connect the device to the wall jack.
– Distribution cabling, also known as horizontal cabling
• Horizontal cabling refers to the cables connecting the telecommunication
rooms with the work areas.
• The maximum length for a cable from a termination point in the
telecommunication room to the termination at the work area outlet must
not exceed 90 meters.
• This 90 meter maximum cabling distance is the permanent link because it
is installed in the building structure.

85 |
12150G48A - Network Fundamentals | II Yr / IV Sem

 When planning the LAN cabling, there are 4 areas:


– Telecommunications room (distribution facility)
• The rooms contain - hubs, switches, routers, and data service units (DSUs)
- that tie the network together.
• These devices provide the transitions between the backbone cabling and
the horizontal cabling.
• The patch cord, with a length of up to 5 meters, is used to connect
equipment and patch panels in the telecommunications room.
• These rooms often serve dual purposes. In many organizations, the
telecommunications room also contains the servers.
– Backbone cabling (vertical cabling)
• Backbone cabling refers to the cabling used to connect telecommunication
rooms to the equipment rooms, where the servers are often located.
• Backbone cabling also interconnects multiple telecommunications rooms
throughout the facility.
• These cables are sometimes routed outside the building to the WAN
connection or ISP.
• Backbones cabling are used for aggregated traffic, such as traffic to and
from the Internet and access to corporate resources.
• Therefore, backbones typically require high bandwidth media such as
fiber-optic cabling.

Total Cable Length: 100 meters


 For UTP installations, the ANSI/TIA/EIA-568-B standard specifies that the total
combined length of cable spanning the 3 areas listed above is limited to a maximum
distance of 100 meters per channel.
– This standard specifies there can be up to 5 meters of patch cable for
interconnecting patch panels.
– There can be up to 5 meters of cable from the cable termination point on the wall
to the telephone or computer.
– 90 meters for the horizontal cable.
Types of Media
 Choosing the cables necessary to make a successful LAN or WAN connection requires
consideration of the different media types.
– UTP (Category 5, 5e, 6, and 7)
– Fiber-optics
– Wireless
 Each media type has its advantages and disadvantages:
– Cable length - Does the cable need to span across a room or from building to
building?
– Cost - Does the budget allow for using a more expensive med ia type?
– Bandwidth - Does the technology used with the media provide adequate
bandwidth?
– Ease of installation - Does the implementation team have the ability to install the
cable or is a vendor required?
– Susceptible to EMI/RFI - Is the local environment going to interfere with the
signal?

86 |
12150G48A - Network Fundamentals | II Yr / IV Sem

 Cable Length
– The total length of cable required to connect a device includes all cables from the
end devices to the intermediary device in the telecommunication room (usually a
switch).
 For example, when using UTP cabling for Ethernet, it has the
recommended maximum distance of 90 (100) meters.
 Fiber-optic cables may provide a greater cabling distance-up to 500 meters
to a few kilometers depending on the technology.
– Attenuation is reduction of the strength of a signal as it moves down a media.
 The longer the media, the more attenuation will affect the signal.
 Cabling distance is a significant factor in data signal performance.
 Cost
– Although fiber provides greater bandwidth than UTP, the material and installation
costs are significantly higher.
 Network designers must match the performance needs of the users with
the cost of the equipment and cabling to achieve the best cost/performance
ratio.
 Bandwidth
– A fiber cable may be a logical choice for a server connection.
 For example, a server generally has a need for more bandwidth than a
computer dedicated to a single user.
– Wireless is also supporting huge increases in bandwidth, but it has limitations in
distance and power consumption.
 Ease of Installation
– UTP cable is relatively lightweight and flexible and has a small diameter, which
allows it to fit into small spaces.
 The connectors, RJ-45 plugs, are easy to install and are a standard.
 A raceway is an enclosure or tube that encloses and protects the cable.
– Many fiber-optic cables contain a thin glass fiber. This creates issues for the bend
radius of the cable.
 Crimps or sharp bends can break the fiber. The termination of the cable
connectors (ST, SC, MT-RJ) are significantly more difficult to install.
– Wireless networks require cabling, at some point, to connect devices, such as
access points, to the wired LAN.
 However, a wireless LAN requires more careful planning and testing.
 There are many external factors, such as other radio frequency devices and
building construction, that can effect its operation.
 Electromagnetic Interference/Radio Frequency Interference
– Interference can be produced by electrical machines, lightning, and other
communications devices, including radio equipment.
– Interconnected devices in two separate buildings.
 Fiber cable is the best choice.
– Wireless is the medium most susceptible to RFI.
 Before using wireless technology, potential sources of interference must
be identified and, if possible, minimized.

87 |
12150G48A - Network Fundamentals | II Yr / IV Sem

Making LAN Connections

RJ-45 connector
 UTP cabling connections are specified by the Electronics Industry Alliance /
Telecommunications Industry Association (EIA/TIA).
 The RJ-45 connector is the male component crimped on the end of the cable.
– When viewed from the front, the pins are numbered from 8 to 1.
– When viewed from above with the opening gate facing you, the pins are
numbered 1 through 8, from left to right.

Straight-through UTP Cables

 A straight-through cable has connectors on each end that are terminated the same in
accordance with either the T568A or T568B standards.
– Identifying the cable standard used allows you to determine if you have the right
cable for the job.
– More importantly, it is a common practice to use the same color codes throughout
the LAN for consistency in documentation.

 Use straight-through cables for the following connections:


– Switch to a router Ethernet port
– Computer to switch
– Computer to hub

88 |
12150G48A - Network Fundamentals | II Yr / IV Sem

Crossover UTP Cables

 For two devices to communicate through a cable that is directly connected between the
two, the transmit terminal of one device needs to be connected to the receive terminal of
the other device.
– The cable must be terminated so the transmit pin, Tx, taking the signal from
device A at one end, is wired to the receive pin, Rx, on device B.
– Similarly, device B's Tx pin must be connected to device A's Rx pin.
 To achieve this type of connection with a UTP cable, one end must be terminated as
EIA/TIA T568A pinout, and the other end terminated with T568B pinout.
 Crossover cables directly connect the following devices on a LAN:
– Switch to switch
– Switch to hub
– Hub to hub
– Router to router Ethernet port connection
– Computer to computer
– Computer to a router Ethernet port

 On the figure, identify the cable type used based on the devices being connected.

89 |
12150G48A - Network Fundamentals | II Yr / IV Sem

 Use straight-through cables for connecting:


– Switch to router
– Computer to switch
– Computer to hub
 Use crossover cables for connecting:
– Switch to switch
– Switch to hub
– Hub to hub
– Router to router
– Computer to computer
– Computer to router

10.2.3 Making WAN Connections


 By definition, WAN links can span extremely long distances.
– These distances can range across the globe as they provide the communication
links.
 Wide area connections between networks take a number of forms, including:
– Telephone line RJ11 connectors for dialup or Digital Subscriber Line (DSL)
connections
– 60 pin Serial connections
 In the course labs, you may be using Cisco routers with one of two types of physical
serial cables.
– The first cable type has a male DB-60 connector on the Cisco end.

– The second type is a more compact version and has a Smart Serial connector on
the Cisco device end.
• Both cables use a large Winchester 15 Pin connector on the network end.
• This end of the cable is used as a V.35 connection to a Physical layer
device such as a CSU/DSU.

90 |
12150G48A - Network Fundamentals | II Yr / IV Sem

DCE and DTE

 The following terms describe the types of devices that maintain the link:
– Data Communications Equipment (DCE) –
• It supplies the clocking services to another device.
• It is at the WAN access provider end of the link.
• In most cases, the telco or ISP provides the clocking service that
synchronizes the transmitted signal.
• For example, if a device running at 1.544 Mbps, each receiving device
must use a clock, sending out a sample signal every 1/1,544,000th of a
second.
– Data Terminal Equipment (DTE) –
• It receives clocking services from another device and adjusts accordingly.
• It is at the WAN customer or user end of the link.
• If a serial connection is made directly to a service provider or to a device
that provides signal clocking such as a channel service unit/data service
unit (CSU/DSU), the router is DTE and will use a DTE serial cable.
 Be aware that there will be occasions, especially in our labs, when the local router is
required to provide the clock rate and will therefore use a DCE cable.
 When making WAN connections between two routers in a lab environment, connect two
routers with a serial cable to simulate a point-to-point WAN link.
– In this case, decide which router is going to be the one in control of clocking.
– Routers are DTE devices by default, but they can be configured to act as DCE
devices.

91 |
12150G48A - Network Fundamentals | II Yr / IV Sem

 The V35 compliant cables are available in DTE and DCE versions. To create a point-to-
point serial connection between two routers, join together a DTE and DCE cable.
– Each cable comes with a connector that mates with its complementary type.
– These connectors are configured so that you cannot join two DCE or two DTE
cables together by mistake.

Developing an Addressing Scheme


How Many Hosts in the Network?
 To develop an addressing scheme for a network, start with determining the total number
of hosts. (current and future )
– The end devices requiring an IP address include:
• User computers
• Administrator computers
• Servers
• Other end devices such as printers, IP phones, and IP cameras
– Network devices requiring an IP address include:
• Router LAN interfaces
• Router WAN (serial) interfaces
– Network devices requiring an IP address for management include:
• Switches
• Wireless Access Points
 Next, determine if all hosts will be part of the same network, or whether the network as a
whole will be divided into separate subnets.
– Recall that the number of hosts on one network or subnet is calculated using the
formula 2 to the nth power minus 2 (2^n - 2), where n is the number of bits
available as host bits.
– Recall also that we subtract two addresses - the network address and the network
broadcast address - cannot be assigned to hosts.
How Many Networks?
 There are many reasons to divide a network into subnets:
– Manage Broadcast Traffic - Broadcasts can be controlled because it is divided
into a number of smaller domains.
– Different Network Requirements - If different groups of users require specific
network, it is easier to manage these requirements if those users are all together
on one subnet.
– Security - Different levels of network security can be implemented based on
network addresses.
 Counting the Subnets
– Each subnet, as a physical network segment, requires a router interface as the
gateway for that subnet.
– Each connection between routers is a separate subnet.
– The number of subnets on one network is also calculated using the formula 2^n,
where n is the number of bits "borrowed" from the given IP network address.
 Subnet Masks
– The next step is to apply one subnet mask:
• A unique subnet and subnet mask for each physical segment
• A range of usable host addresses for each subnet

92 |
12150G48A - Network Fundamentals | II Yr / IV Sem

Designing the Address Standard for our Internetwork


For example, when allocating an IP address to a router interface that is the gateway for a
LAN, it is common practice to use the first (lowest) or last (highest) address within the
subnet range. This consistent approach aids in configuration and troubleshooting.
 Similarly, when assigning addresses to devices that manage other devices, using a
consistent pattern within a subnet makes these addresses easily recognizable. For
example, in the figure, addresses with 64 - 127 in the octets always represent the general
users.
 In addition, remember to document your IP addressing scheme on paper.
 Some of the different categories for hosts are:
 General users
 Special users
 Network resources
 Router LAN interfaces
 Router WAN links
 Management access
Calculating the Subnets
Calculating Addresses: Case 1
 The figure shows the network topology for this example:
 Student LAN
– Student Computers: 460
– Router (LAN Gateway): 1
– Switches (management): 20
– Total for student subnetwork: 481
 Instructor LAN
– Instructor Computers: 64
– Router (LAN Gateway): 1
– Switches (management): 4
– Total for instructor subnetwork: 69

93 |
12150G48A - Network Fundamentals | II Yr / IV Sem

 Administrator LAN
– Administrator Computers: 20
– Server: 1
– Router (LAN Gateway): 1
– Switch (management): 1
– Total for administration subnetwork: 23
 WAN
– Router - Router WAN: 2
– Total for WAN: 2
 There are two methods available for allocating addresses to an internetwork.
– We can use Variable Length Subnet Masking (VLSM), where we assign the
prefix and host bits to each network based on the number of hosts in that network.
– Or, we can use a non-VLSM approach, where all subnets use the same prefix
length and the same number of host bits.

Addresses-without VLSM
 When using the non-VLSM method of assigning addresses, all subnets have the same
number of addresses.
– We base the number of addresses for all networks on the addressing requirements
for the largest network.
 In Case 1, the Student LAN is the largest network, requiring 481 addresses.
 We use 9 as the value for n because 9 is the first power of 2 that is over 481.
– Borrowing 9 bits for the host portion yields this calculation:
– 2^9 = 512
– 512 - 2 = 510 usable host addresses
– This meets the current requirement for at least 481 addresses, with a small
allowance for growth. This also leaves 23 network bits (32 total bits - 9 host bits).
 Because there are four networks in our internetwork, we will need four blocks of 512
addresses each, for a total of 2048 addresses.
– We will use the address block 172.16.0.0 /23. This provides addresses in the
range from 172.16.0.0 to 172.16.7.255.

94 |
12150G48A - Network Fundamentals | II Yr / IV Sem

 For the Student network block, the values would be:


– The student network required 481 address
– The address block is 172.16.0.1 to 172.16.1.254.
– Only 29 address will go unused
 Instructor LAN
– The instructor network requires a total of 69 addresses.
– The address block is 172.16.2.1 to 172.16.3.254.
– The 441 addresses will go unused.
 Administrator LAN
– The administrator network requires a total of 23 addresses.
– The address block is 172.16.4.1 to 172.16.5.254.
– The 487 addresses will go unused.
 WAN
– The WAN network requires a total of 2 addresses.
– The address block is 172.16.6.1 to 172.16.7.254.
– The 508 addresses will go unused.
 We can use VLSM in this internetwork to save addressing, but using VLSM requires
more planning.

Addresses-with VLSM

 For the VLSM assignment, we can allocate a much smaller block of addresses to each
network, as appropriate.
 The address block 172.16.0.0/22 (subnet mask 255.255.252.0) has been assigned to this
internetwork.
– Ten bits will be used to define host and sub networks.
– It has a total of 1024 addresses from 172.16.0.0 to 172.16.3.0.
 Student LAN
– The largest subnet is the Student LAN requires 481 addresses.
– Using the formula usable hosts = 2^n - 2, borrowing 9 bits for the host portion
gives 512 - 2 = 510 usable host addresses.
– Using the lowest available address gives us of 172.16.0.0 /23.
– The IP host range would be 172.16.0.1 through 172.16.1.254.
 Instructor LAN
– The next largest network is the Instructor LAN. It requires at least 69 addresses.
– Using 6 in the power of 2 formula, 2^6 - 2, only provides 62 usable addresses.
– We must use an address block using 7 host bits. The calculation 2^7 -2 will yield
a block of 126 addresses.
– The next available block is the 172.16.2.0 /25 network.
– This provides an IP host range of 172.16.2.1 to 172.16.2.126.
 Administrator LAN
– For the Administrator LAN, we need to accommodate 23 hosts.
– This will require the use of 6 host bits: 2^6 - 2.
– The next available block of addresses that can accommodate these hosts is the
172.16.2.128 /26 block.
– This provides IP host range of 172.16.2.129 to 172.16.2.190.

95 |
12150G48A - Network Fundamentals | II Yr / IV Sem

 WAN
– The last segment is the WAN, requiring 2 host addresses.
– Only 2 host bits will accommodate the WAN links. 2^2 - 2 = 2.
– The next available address block is 172.16.2.192 /30.
– This gives an IP host range of 172.16.2.193 to 172.16.2.194.
 This completes the allocation of addresses using VLSM for Case 1. If an adjustment is
necessary to accommodate future growth, addresses in the range of 172.16.2.196 to
172.16.3.255 are still available.

10.4.2 Calculating Addresses: Case 2

 In Case 2, the challenge is to subnet this internetwork while limiting the number of
wasted hosts and subnets.
 The figure shows 5 different subnets, each with different host requirements. The given IP
address is 192.168.1.0/24.
 The host requirements are:
– NetworkA - 14 hosts
– NetworkB - 28 hosts
– NetworkC - 2 hosts
– NetworkD - 7 hosts
– NetworkE - 28 hosts
 As we did with Case 1, we begin the process by subnetting for the largest host
requirement first.
 In this case, the largest requirements are for NetworkB and NetworkE, each with 28
hosts.
– For networks B and E, 5 bits are borrowed from the host portion and the
calculation is 2^5 = 32 - 2.
– This allows 8 subnets with 30 hosts each.
– Network B will use Subnet 0: 192.168.1.0/27
– host address range 1 to 30
– Network E will use Subnet 1: 192.168.1.32/27
– host address range 33 to 62
 The next largest host is NetworkA, followed by NetworkD.
– Network A will use Subnet 0: 192.168.1.64/28
 host address range 65 to 78
– Network D will use Subnet 1: 192.168.1.80/28
 host address range 81 to 94
 NetworkC has only two hosts.
– Network C will use Subnet 1: 192.168.1.96/30
– host address range 97 to 98

96 |
12150G48A - Network Fundamentals | II Yr / IV Sem

 The host requirements are:


– NetworkA - 14 hosts
– NetworkB - 28 hosts
– NetworkC - 2 hosts
– NetworkD - 7 hosts
– NetworkE - 28 hosts

Device Interconnections

Device Interfaces

 It is important to understand that Cisco devices, routers, and switches have several types
of interfaces.
 LAN Interfaces - Ethernet
– The Ethernet interface is used for connecting cables that terminate with LAN
devices such as computers and switches.
– Several conventions for naming Ethernet interfaces, including AUI (older Cisco
devices), Ethernet, FastEthernet and Fa 0/0.
– The name used depends on the type and model of the device.
 WAN Interfaces - Serial
– Serial interfaces are used for connecting WAN devices to the CSU/DSU.
– For lab, we will make a back-to-back connection between two routers, and set a
clock rate on one of the interfaces.
– To establish communication with a router via a console on a remote WAN, a
WAN interface is assigned a IPv4 address.
 Console Interface
– The console interface is the interface for initial configuration.
– Physical security of network devices is extremely impo rtant.
 Auxiliary (AUX) Interface
– This interface is used for remote management of the router.
– Typically, a modem is connected to the AUX interface for dial- in access.

97 |
12150G48A - Network Fundamentals | II Yr / IV Sem

Making the Device Management Connection

 Typically, networking devices do not have their own displays, keyboards, or input
devices such as trackballs and mice. Accessing a network device for configuration,
verification, or troubleshooting is made via a connection between the device and a
computer.
 To enable this connection, the computer runs a program called a terminal emulator.
– A terminal emulator is a software program that allows one computer to access the
functions on another device. It allows a person to use the display and keyboard on
one computer to operate another device, as if the keyboard and display were
directly connected to the other device.
– The cable connection between the computer running the terminal emulation
program and the device is often made via the serial interface.
 To connect to a router or switch for device management using terminal emulation, follow
these steps:
 Step 1:
– Connect a computer to the console port using console cable.
– The console cable, has a DB-9 connector on one end and an RJ-45 connector on
the other end.
– Many newer computers do not have an serial interface. You can use a USB-to-
serial cable to access the console port.
 Step 2:
– For the purpose of this course, we will usually use HyperTerminal. This program
can be found under All Programs > Accessories > Communications. Select
HyperTerminal.
– Open HyperTerminal, configure the port with these settings:
 Bits per second: 9600 bps
 Data bits: 8
 Parity: None
 Stop bits: 1
 Flow control: None
 Step 3:
– Log in to the router using the terminal emulator software.
– You can access the router by pressing the Enter key.

98 |

You might also like