0% found this document useful (0 votes)
32 views476 pages

المنهج الكامل لمادة اسس الشبكات

The document provides an overview of computer networking fundamentals, including definitions, advantages, disadvantages, classifications of networks (LAN, WAN, MAN), and the roles of client and server computers. It also discusses network topologies such as bus, star, ring, and mesh, along with hardware and software components like NICs, repeaters, hubs, bridges, routers, and switches. The content aims to familiarize readers with essential networking concepts and components necessary for understanding and managing networks.

Uploaded by

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

المنهج الكامل لمادة اسس الشبكات

The document provides an overview of computer networking fundamentals, including definitions, advantages, disadvantages, classifications of networks (LAN, WAN, MAN), and the roles of client and server computers. It also discusses network topologies such as bus, star, ring, and mesh, along with hardware and software components like NICs, repeaters, hubs, bridges, routers, and switches. The content aims to familiarize readers with essential networking concepts and components necessary for understanding and managing networks.

Uploaded by

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

Dr.

Yasir Dawood

COMPUTER NETWORKING FUNDAMENTALS


INTRODUCTION TO COMPUTER NETWORKING
Objective:
To be acquainted with:
• The definitions of networking
• Network topology
• Hardware, Software and Networks devices
• Components of Communication System
• Networking models
• IP address
• MAC address
DEFINITIONS
Network Definition
A network can be defined as two or more computers connected together
in such a way that they can share resources.

The purpose of a network is to share resources.


DEFINITIONS (CONT..)
A resource may be:
A file
A folder
A printer
A disk drive
Or just about anything else that exists on a computer.
DEFINITIONS (CONT..)
A network is simply a collection of computers or
other hardware devices that are connected together,
either physically or logically, using special hardware
and software, to allow them to exchange information
and cooperate. Networking is the term that describes
the processes involved in designing, implementing,
upgrading, managing and otherwise working with
networks and network technologies.
ADVANTAGES OF NETWORKING
Connectivity and Communication
Data Sharing
Hardware Sharing
Internet Access
Internet Access Sharing
Data Security and Management
Performance Enhancement and Balancing
Entertainment
THE DISADVANTAGES (COSTS) OF
NETWORKING
Network Hardware, Software and Setup Costs
Hardware and Software Management and Administration Costs
Undesirable Sharing
Illegal or Undesirable Behavior
Data Security Concerns
FUNDAMENTAL NETWORK
CLASSIFICATIONS
Local Area Networks (LANs):
A local area network (LAN) is a computer network covering a small geographic
area, like a home, office, or group of buildings

Wide Area Networks (WANs):


Wide Area Network (WAN) is a computer network that covers a broad area (i.e.,
any network whose communications links cross metropolitan, regional, or national
boundaries). Or, less formally, a network that uses routers and public communications
links
The largest and most well-known example of a WAN is the Internet.
WANs are used to connect LANs and other types of networks together, so that users
and computers in one location can communicate with users and computers in other
locations
FUNDAMENTAL NETWORK
CLASSIFICATIONS (CONT)
Metropolitan Area Network (MAN):
oA metropolitan area network (MAN) is a network that interconnects users with
computer resources in a geographic area or region larger than that covered
by even a large local area network (LAN) but smaller than the area covered
by a wide area network (WAN). The term is applied to the interconnection of
networks in a city into a single larger network (which may then also offer
efficient connection to a wide area network). It is also used to mean the
interconnection of several local area networks by bridging them with
backbone lines. The latter usage is also sometimes referred to as a campus
network.
FUNDAMENTAL NETWORK
CLASSIFICATIONS (CONT)
The Local Network (LAN)

Client Client

Client Client

Client Client
FUNDAMENTAL
NETWORK
CLASSIFICATIONS
(CONT)
Wide Area Network
Fundamental Network
Classifications (cont)

METROPOLITAN AREA
NETWORK (MAN)
INTRANET AND INTERNET SPECIFICATIONS
Intranet: An intranet is a private network that is contained within an enterprise.
It may consist of many interlinked local area networks and also use leased
lines in the wide area network.
An intranet uses TCP/IP, HTTP, and other Internet protocols and in general looks
like a private version of the Internet. With tunneling, companies can send
private messages through the public network, using the public network with
special encryption/decryption and other security safeguards to connect one
part of their intranet to another.
Internet: is a worldwide system of computer networks - a network of networks
in which users at any one computer can, if they have permission, get
information from any other computer (and sometimes talk directly to users at
other computers).
CLIENT AND SERVER COMPUTER ROLE IN
NETWORKING
Server computer is a core component of the network, providing a link to the
resources necessary to perform any task.
A server computer provides a link to the resources necessary to perform any
task.
The link it provides could be to a resource existing on the server itself or a
resource on a client computer.
Client computers normally request and receive information over the network
client. Client computers also depends primarily on the central server for
processing activities
PEER-TO PEER NETWORK
A peer-to-peer network is a network where the computers act as both
workstations and servers.
great for small, simple, and inexpensive networks.
In a strict peer-to-peer networking setup, every computer is an equal, a
peer in the network.
Each machine can have resources that are shared with any other
machine.
There is no assigned role for any particular device, and each of the
devices usually runs similar software. Any device can and will send
requests to any other.
PEER-TO PEER NETWORK
(CONT..)
CLIENT/SERVER NETWORKING
In this design, a small number of computers are
designated as centralized servers and given the task
of providing services to a larger number of user
machines called clients
CLIENT/SERVER
NETWORKING (CONT..)
NETWORK TOPOLOGY
A topology is a way of “laying out” the network.
Topologies can be either physical or logical.
Physical topologies describe how the cables are run.
Logical topologies describe how the network
messages travel
NETWORK TOPOLOGY (CONT.)

Bus (can be both logical and physical)


Star (physical only)
Ring (can be both logical and physical)
Mesh (can be both logical and physical)
NETWORK TOPOLOGY (CONT.)
Bus
A bus is the simplest physical topology. It consists of a single cable that
runs to every workstation
This topology uses the least amount of cabling, but also covers the
shortest amount of distance.
Each computer shares the same data and address path. With a logical
bus topology, messages pass through the trunk, and each workstation
checks to see if the message is addressed to itself. If the address of the
message matches the workstation’s address, the network adapter copies
the message to the card’s on-board memory.
NETWORK TOPOLOGY (CONT.)
it is difficult to add a workstation
have to completely reroute the cable and possibly
run two additional lengths of it.
if any one of the cables breaks, the entire network
is disrupted. Therefore, it is very expensive to
maintain.
NETWORK TOPOLOGY (CONT.)
Bus topology
NETWORK TOPOLOGY (CONT.)
Star Topology
A physical star topology branches each network device off a central
device called a hub, making it very easy to add a new workstation.
Also, if any workstation goes down it does not affect the entire network.
(But, as you might expect, if the central device goes down, the entire
network goes down.)
Some types of Ethernet and ARCNet use a physical star topology. Figure
8.7 gives an example of the organization of the star network.
NETWORK TOPOLOGY (CONT.)
Star topologies are easy to install. A cable is run
from each workstation to the hub. The hub is placed
in a central location in the office.
Star topologies are more expensive to install than
bus networks, because there are several more
cables that need to be installed, plus the cost of the
hubs that are needed.
NETWORK TOPOLOGY (CONT.)
Star Topology
NETWORK TOPOLOGY (CONT.)
Ring
Each computer connects to two other computers,
joining them in a circle creating a unidirectional path
where messages move workstation to workstation.
Each entity participating in the ring reads a
message, then regenerates it and hands it to its
neighbor on a different network cable.
NETWORK TOPOLOGY (CONT.)
The ring makes it difficult to add new computers.
Unlike a star topology network, the ring topology
network will go down if one entity is removed from
the ring.
Physical ring topology systems don’t exist much
anymore, mainly because the hardware involved
was fairly expensive and the fault tolerance was
very low.
NETWORK TOPOLOGY (CONT.)
Ring Topology
NETWORK TOPOLOGY (CONT.)
Mesh
The mesh topology is the simplest logical topology in terms of data flow, but it is the
most complex in terms of physical design.
In this physical topology, each device is connected to every other device
This topology is rarely found in LANs, mainly because of the complexity of the
cabling.
If there are x computers, there will be (x × (x–1)) ÷ 2 cables in the network. For
example, if you have five computers in a mesh network, it will use 5 × (5 – 1) ÷ 2,
which equals 10 cables. This complexity is compounded when you add another
workstation.
For example, your five-computer, 10-cable network will jump to 15 cables just by
adding one more computer. Imagine how the person doing the cabling would feel if
you told them you had to cable 50 computers in a mesh network—they’d have to
come up with 50 × (50 – 1) ÷ 2 = 1225 cables!
NETWORK TOPOLOGY (CONT.)
Because of its design, the physical mesh topology is very expensive to install
and maintain.
Cables must be run from each device to every other device. The advantage
you gain from it is its high fault tolerance.
With a logical mesh topology, however, there will always be a way of getting
the data from source to destination.
It may not be able to take the direct route, but it can take an alternate,
indirect route. It is for this reason that the mesh topology is still found in WANs
to connect multiple sites across WAN links. It uses devices called routers to
search multiple routes through the mesh and determine the best path.
However, the mesh topology does become inefficient with five or more entities.
NETWORK TOPOLOGY (CONT.)
Mesh Topology
NETWORK TOPOLOGY (CONT.)

Advantages and
Disadvantages of Network
Topologies
HARDWARE, SOFTWARE AND NETWORKS DEVICES

Network Interface Card (NIC)


Repeater
Hub
Bridge
Routers
Switch
HARDWARE, SOFTWARE AND NETWORKS PERIPHERALS (CONT.)

Network Interface Card (NIC)


NIC provides the physical interface between computer and cabling.
It prepares data, sends data, and controls the flow of data. It can also receive and
translate data into bytes for the CPU to understand.
The following factors should be taken into consideration when choosing a NIC:
1. - Preparing data
2. - Sending and controlling data
3. - Configuration
4. - Drivers
5. - Compatibility
6. - Performance
HARDWARE, SOFTWARE AND NETWORKS PERIPHERALS (CONT.)
PREPARING DATA

In the computer, data moves along buses in parallel, as on a four-lane


interstate highway. But on a network cable, data travels in a single stream, as
on a one lane highway. This difference can cause problems transmitting and
receiving data, because the paths traveled are not the same.
It is the NIC’s job to translate the data from the computer into signals that can
flow easily along the cable.
It does this by translating digital signals into electrical signals (and in the case
of fiber-optic NICs, to optical signals).
HARDWARE, SOFTWARE AND NETWORKS PERIPHERALS (CONT.)
SENDING AND CONTROLLING DATA

For two computers to send and receive data, the cards must agree on several things.
These include the following:
- The maximum size of the data frames
- The amount of data sent before giving confirmation
- The time needed between transmissions
- The amount of time needed to wait before sending confirmation
- The amount of data a card can hold
- The speed at which data transmits
In order to successfully send data on the network, you need to make sure the network
cards are of the same type and they are connected to the same piece of cable.
HARDWARE, SOFTWARE AND NETWORKS PERIPHERALS (CONT.)
CONFIGURATION

The NIC’s configuration includes things like a manufacturer’s


hardware address, IRQ address, Base I/O port address, and base
memory address. Some may also use DMA channels to offer better
performance.
Each card must have a unique hardware address. If two cards
have the same hardware addresses, neither one of them will be
able to communicate.
HARDWARE, SOFTWARE AND NETWORKS PERIPHERALS (CONT.)
DRIVERS

For the computer to use the network interface card,


it is very important to install the proper device
drivers.
These drivers communicate directly with the network
redirector and adapter. They operate in the Media
Access Control sublayer of the Data Link layer of
the OSI model.
HARDWARE, SOFTWARE AND NETWORKS PERIPHERALS (CONT.)
COMPATIBILITY

When choosing a NIC, use one that fits the bus type of
your PC. If you have more than one type of bus in your PC
(for example, a combination ISA/PCI), use an NIC that fits
into the fastest type (the PCI, in this case).
This is especially important in servers, as the NIC can very
quickly become a bottleneck if this guideline isn’t followed.
HARDWARE, SOFTWARE AND NETWORKS PERIPHERALS (CONT.)
PERFORMANCE

The most important goal of the network adapter


card is to optimize network performance and
minimize the amount of time needed to transfer
data packets across the network.
There are several ways of doing this, including
assigning a DMA channel, use of a shared memory
adapter, and deciding to allow bus mastering.
HARDWARE, SOFTWARE AND NETWORKS PERIPHERALS (CONT.)
REPEATERS

Repeaters are very simple devices. They allow a cabling system to extend beyond its
maximum allowed length by amplifying the network voltages so they travel farther.
Repeaters are nothing more than amplifiers and, as such, are very inexpensive.
Repeaters can only be used to regenerate signals between similar network segments.
For example, we can extend an Ethernet 10Base2 network to 400 meters with a
repeater. But can’t connect an Ethernet and Token Ring network together with one.
The main disadvantage to repeaters is that they just amplify signals. These signals not
only include the network signals, but any noise on the wire as well.
Eventually, if you use enough repeaters, you could possibly drown out the signal with
the amplified noise. For this reason, repeaters are used only as a temporary fix.
HARDWARE, SOFTWARE AND NETWORKS PERIPHERALS (CONT.)
REPEATERS
HARDWARE, SOFTWARE AND NETWORKS PERIPHERALS (CONT.)
HUBS

Hubs are devices used to link several computers together.


They repeat any signal that comes in on one port and copy it to the other
ports (a process that is also called broadcasting).
There are two types of hubs: active and passive.
Passive hubs simply connect all ports together electrically and are usually not
powered.
Active hubs use electronics to amplify and clean up the signal before it is
broadcast to the other ports.
In the category of active hubs, there is also a class called “intelligent” hubs,
which are hubs that can be remotely managed on the network.
HARDWARE, SOFTWARE AND NETWORKS PERIPHERALS (CONT.)
HUBS
HARDWARE, SOFTWARE AND NETWORKS PERIPHERALS (CONT.)
BRIDGES

They join similar topologies and are used to divide network segments.
For example, with 200 people on one Ethernet segment, the performance will be
ordinary, because of the design of Ethernet and the number of workstations that are
fighting to transmit. If you divide the segment into two segments of 100 workstations
each, the traffic will be much lower on either side and performance will increase.
If it is aware of the destination address, it is able to forward packets; otherwise a
bridge will forward the packets to all segments. They are more intelligent than
repeaters but are unable to move data across multiple networks at once.
Unlike repeaters, bridges can filter out noise.
The main disadvantage to bridges is that they can’t connect different network types
or perform intelligent path selection. For that function, we would need a router.
HARDWARE, SOFTWARE AND NETWORKS PERIPHERALS (CONT.)
BRIDGES
HARDWARE, SOFTWARE AND NETWORKS PERIPHERALS (CONT.)
ROUTERS

Routers are highly intelligent devices that connect multiple network types and
determine the best path for sending data.
The advantage of using a router over a bridge is that routers can determine the best
path that data can take to get to its destination.
Like bridges, they can segment large networks and can filter out noise.
However, they are slower than bridges because they are more intelligent devices; as
such, they analyze every packet, causing packet-forwarding delays. Because of this
intelligence, they are also more expensive.
Routers are normally used to connect one LAN to another.
Typically, when a WAN is set up, there will be at least two routers used.
HARDWARE, SOFTWARE AND NETWORKS PERIPHERALS (CONT.)
ROUTERS
HARDWARE, SOFTWARE AND NETWORKS PERIPHERALS (CONT.)
SWITCH

A network switch is a computer networking device that connects network segments.


Low-end network switches appear nearly identical to network hubs, but a switch contains more "intelligence" (and a
slightly higher price tag) than a network hub.
Network switches are capable of checking data packets as they are received, determining the source and destination
device of that packet, and forwarding it correctly.
By delivering each message only to the connected device it was intended for, a network switch protects network
bandwidth and offers generally better performance than a hub.
A vital difference between a hub and a switch is that all the nodes connected to a hub share the bandwidth among
themselves, while a device connected to a switch port has the full bandwidth all to itself.
For example, if 10 nodes are communicating using a hub on a 10-Mbps network, then each node may only get a
portion of the 10 Mbps if other nodes on the hub want to communicate as well. .
But with a switch, each node could possibly communicate at the full 10 Mbps.
HARDWARE, SOFTWARE AND NETWORKS PERIPHERALS (CONT.)
SWITCH
CLASSIFY THE COMPUTER NETWORK
Data communications are the exchange of data between two
devices via some form of transmission medium such as a wire cable.
Characteristics Data communications system depends on:
1 Delivery
2 Accuracy
3 Timeliness
4 Jitter

52
CLASSIFY THE COMPUTER NETWORK

1- Delivery. The system must deliver data to the correct destination. Data must be
received by the intended device or user and only by that device or user.

2.Accuracy. The system must deliver the data accurately. Data that have been altered
in transmission and left uncorrected are unusable.

3.Timeliness. The system must deliver data in a timely manner. Data delivered late are
useless. In the case of video and audio, the Delivery called real-time transmission.

4. Jitter. Jitter refers to the variation in the packet arrival time. It is the uneven delay
in the delivery of audio or video packets.
3
COMPONENTS OF COMMUNICATION SYSTEM
1. Message. The message is the information (data) to be communicated. Popular
forms of information include text, numbers, pictures, audio, and video..

54
COMPONENTS OF COMMUNICATION SYSTEM
2. Sender. The sender is the device that sends the data message. It can be a computer,
workstation, telephone handset, video camera, and so on.
3. Receiver. The receiver is the device that receives the message. It can be a computer,
workstation, telephone handset, television, and so on.
4. Transmission medium. The transmission medium is the physical path by which a
message travels from sender to receiver.
5. Protocol. A protocol is a set of rules that govern data communications. It
represents an agreement between the communicating devices.

55
DATA REPRESENTATION:

Information comes in different forms such as text, numbers, images, audio, and
video.
1. Text: In data communications, text is represented as a bit pattern, a sequence of
bits (0s or 1s). Different sets of bit patterns have been designed to represent text
symbols. Each set is called a code, and the process of representing symbols is
called coding (ASCII).
2. Numbers: Numbers are also represented by bit patterns. However, a code such as
ASCII is not used to represent numbers.
3. Images: Images are also represented by bit patterns. In its simplest form, an image
is composed of a matrix of pixels (picture elements), where each pixel is a small
dot.
6
INTRODUCTION AND CLASSIFY THE COMPUTER NETWORK

4. Audio: Audio refers to the recording or broadcasting of sound or music. Audio is


by nature different from text, numbers, or images. It is continuous, not discrete.

5. Video: Video refers to the recording or broadcasting of a picture or movie. Video


can either be produced as a continuous entity (e.g., by a TV camera), or it can be a
combination of images, each a discrete entity, arranged to convey the idea of
motion.

57
TRANSMISSION TECHNOLOGY OR DATA FLOW

Communication between two devices can be simplex, half-duplex, or full-duplex.


Simplex : In simplex mode, the communication is unidirectional, as on a one-way street.
Only one of the two devices on a link can transmit; the other can only receive.
Half-Duplex : In half-duplex mode, each station can both transmit and receive, but not
at the same time. When one device is sending, the other can only receive, and vice
versa.
Full-Duplex : In full-duplex mode (also called duplex), both stations can transmit and
receive simultaneously.

58
TRANSMISSION TECHNOLOGY OR DATA FLOW

Communication between two devices can be simplex, half-duplex, or full-duplex.

59
NETWORK CRITERIA

A network must be able to meet a certain number of criteria. The most important
of these are:
1. Performance; 2. Reliability; 3. Security.
1. Performance: Performance can be measured in many ways, including transit
time and response time.
Transit time is the amount of time required for a message to travel from one
device to another.
Response time is the elapsed time between an inquiry and a response.

11
NETWORK CRITERIA

The performance of a network depends on a number of factors


which are:
The number of users
The type of transmission medium
The connected hardware
The efficiency of the software
.
12
NETWORK CRITERIA

2.Reliability
In addition to accuracy of delivery, network reliability is measured by the
frequency of failure, the time it takes a link to recover from a failure, and
the network’s robustness in a catastrophe.
3.Security
Network security issues include protecting data from unauthorized access,
protecting data from damage and development.

13
PHYSICAL STRUCTURES
Type of Connection
A network is two or more devices connected through links. A link is a communications
pathway that transfers data from one device to another.
Point-to-Point: A point-to-point connection provides a dedicated link between two
devices. The entire capacity of the link is reserved for transmission between those two
devices.
Multipoint: A multipoint (also called multidrop) connection is one in which more than
two specific devices share a single link. In a multipoint environment, the capacity of
the channel is shared, either spatially or temporally.

14
PHYSICAL STRUCTURES

Types of connections: point-to-point and multipoint

15
NETWORKING MODELS
A networking model, sometimes also called either a networking
architecture or networking blueprint, refers to a comprehensive set of
documents. Individually, each document describes one small function
required for a network; collectively, these documents define everything
that should happen for a computer network to work.
Some documents define a protocol, which is a set of logical rules that
devices must follow to communicate. Other documents define some
physical requirements for networking. For example, a document could
define the voltage and current levels used on a particular cable when
transmitting data.
OSI MODEL
The Open Systems Interconnection (OSI) model defines a networking
framework to implement protocols in layers, with control passed from
one layer to the next. It is primarily used today as a teaching tool. It
conceptually divides computer network architecture into 7 layers in a
logical progression.
The lower layers deal with electrical signals, chunks of binary data, and
routing of these data across networks. Higher levels cover network
requests and responses, representation of data, and network protocols
as seen from a user's point of view. The OSI model is divided into 7
layers which starts from the physical layer that represents the first and
ending with the seventh layer which is the application layer
THE SEVEN LAYERS IN OSI MODEL
- The seventh layer / Application layer supplies network services to
end-user applications.
- The sixth layer / presentation layer handles syntax processing of
message data such as format conversions and encryption / decryption
needed to support the Application layer above it.
- The fifth layer / Session Layer manages the sequence and flow of
events that initiate and tear down network connections.
- The fourth layer / Transport Layer delivers data across network
connections. The transport layer decides on the type of whether it was
reliable or unreliable type of communication. Transport layer provides
error checking, data recovery and provides port numbers for services.
THE SEVEN LAYERS IN OSI MODEL (CONT.)
- The third layer / Network layer maintains logical addresses such as IP
addresses for devices on the network. The Network layer also
manages the mapping between these logical addresses and physical
addresses.
- The second layer / Data Link layer checks for physical transmission
errors and packages bits into data "frames". The Data Link layer also
manages physical addressing schemes such as MAC addresses for
Ethernet networks, controlling access of any various network devices to
the physical medium.
- The first layer / Physical layer of the OSI model is responsible for
ultimate transmission of digital data bits from the source to the
destination. At the Physical layer, data are transmitted using the type
of signals are supported by the physical medium: electric voltages,
radio frequencies, or pulses of infrared or ordinary light.
OSI MODEL
TCP/IP MODEL
TCP/IP stands for Transmission Control Protocol and Internet Protocol was
developed by Department of Defence's Project Research Agency as a
part of a research project of network interconnection to connect remote
machines. The features that stood out during the research, which led to
making the TCP/IP reference model were:
• Support for a flexible architecture. Adding more machines to a
network was easy.
• The network was robust, and connections remained intact until the
source and destination machines were functioning.
The overall idea was to allow one application on one computer to talk
(send data packets) to another application running on different computer.
TCP/IP MODEL
DATA ENCAPSULATION
The term encapsulation refers to the process of putting headers
(and sometimes trailers) around some data.
The process by which a TCP/IP host sends data can be viewed as a
five-step process.
The first four steps relate to the encapsulation performed by the
four TCP/IP layers, and the last step is the actual physical
transmission of the data by the host. In fact, if you use the five-
layer TCP/IP model, one step corresponds to the role of each
layer.
DATA ENCAPSULATION
NETWORK ADDRESS
Network address serves as a unique identifier for a computer
(or other devices) on a network. When set up correctly, computers
can determine the addresses of other computers on the network
and use these addresses to send messages to each other.
NETWORK ADDRESS
Most network devices have several different addresses. Physical
addresses belong to individual network interfaces attached to a
device. For example, the Wi-Fi radio and the Bluetooth radio of a
mobile device will each possess their own physical network
addresses.
Separately, logical addresses can be assigned to devices
according to the kind of network they are attached to. The logical
addresses of a mobile device, for example, change as it migrates
from one network to another (while their physical addresses remain
fixed).
IP ADDRESSES
The most popular type of virtual network addressing is the Internet
Protocol (IP) address. A traditional IP address (IP version 4, IPv4)
consists of four bytes (32 bits) that uniquely identify connected
devices.
Much of the IPv4 address space (the numeric range of address
numbers from lowest to highest) is allocated to Internet service
providers and other large organizations to assign to their customers
and to Internet servers – these are called public IP addresses.
IP ADDRESSES (CONT.)
Certain private IP address ranges have also been established
to support internal networks (like home networks) with devices
that do not need to be directly connected to the Internet.

There are more than one class of IP addresses, the common


three classes in IP addresses are:
- Class A
- Class B
- Class C
IP ADDRESSES CLASSES
- Class A addresses are assigned to networks with a very large number of hosts. The
high-order bit in a class A address is always set to zero. The next seven bits
(completing the first octet) complete the network ID. The remaining 24 bits (the last
three octets) represent the host ID. This allows for 126 networks and 16,777,214 hosts
per network.
- Class B addresses are assigned to medium-sized to large-sized networks. The two
high-order bits in a class B address are always set to binary 1 0. The next 14 bits
(completing the first two octets) complete the network ID. The remaining 16 bits (last
two octets) represent the host ID. This allows for 16,384 networks and 65,534 hosts
per network.
- Class C addresses are used for small networks. The three high-order bits in a class C
address are always set to binary 1 1 0. The next 21 bits (completing the first three
octets) complete the network ID. The remaining 8 bits (last octet) represent the host ID.
This allows for 2,097,152 networks and 254 hosts per network.
IP ADDRESSES CLASSES (CONT.)

Note: The class A address 127.x.y.z is reserved for loopback testing and inter-process
communication on the local computer.
MAC ADDRESS
A well-known form of physical addressing us based on Media Access
Control (MAC) technology. MAC addresses (also known as “physical
addresses”) are six bytes (48 bits) that manufacturers of network
adapters embed in their products to uniquely identify them. IP and other
protocols rely on physical addresses to identify devices on a network.
The Media Access Control (MAC) address is a used to uniquely identify
computer network adapters. These numbers (sometimes called
"hardware addresses" or "physical addresses") are embedded into the
network hardware during the manufacturing process, or stored in
firmware, and designed to not be modified.
MAC ADDRESS (CONT.)
Traditional MAC addresses are 12-digit (6 bytes or 48
bits) hexadecimal numbers. By convention, they are usually
written in one of the following three formats:
- MM:MM:MM:SS:SS:SS
- MM-MM-MM-SS-SS-SS
- MMM.MMM.SSS.SSS
MAC ADDRESS (CONT.)
The leftmost 6 digits (24 bits) called a "prefix" is associated with the
adapter manufacturer. Each vendor registers and obtains MAC prefixes
as assigned by the IEEE. Vendors often possess many prefix numbers
associated with their different products. For example, the prefixes
00:13:10, 00:25:9C and 68:7F:74 (plus many others) all belong to
Linksys (Cisco Systems).
The rightmost digits of a MAC address represent an identification
number for the specific device. Among all devices manufactured with the
same vendor prefix, each is given their own unique 24-bit number. Note
that hardware from different vendors may happen to share the same
device portion of the address.
MAC ADDRESS (CONT.)
TCP/IP networks based on IPv6 also implement a different approach to
communicating MAC addresses compared to mainstream IPv4. Instead of
64-bit hardware addresses, though, IPv6 automatically translates 48-bit
MAC address to a 64-bit address by inserting a fixed (hardcoded) 16-
bit value FFFE in between the vendor prefix and the device identifier.
IPv6 calls these numbers "identifiers" to distinguish them from true 64-bit
hardware addresses. For example, a 48-bit MAC address
00:25:96:12:34:56 appears on an IPv6 network as (commonly written in
either of these two forms):
- 00:25:96:FF:FE:12:34:56
- 0025:96FF:FE12:3456
MAC ADDRESS FORMAT
Dr. Yasir Dawood

COMPUTER NETWORKING FUNDAMENTALS


NETWORK CABLE TYPES AND SPECIFICATIONS
To connect two or more computers or networking
devices in a network, network cables are used.
There are three types of network cables
• Coaxial
• twisted-pair
• fiber-optic.
COAXIAL CABLE
This cable contains a conductor, insulator, braiding, and sheath. The sheath covers the
braiding, braiding covers the insulation, and the insulation covers the conductor.
COMPONENTS OF COAXIAL CABLE
Sheath
This is the outer layer of the coaxial cable. It protects the cable from physical damage.

Braided-shield
This shield protects signals from external interference and noise. This shield is built from the same metal that is used to
build the core.

Insulation
Insulation protects the core. It also keeps the core separate from the braided-shield. Since both the core and the braided-
shield use the same metal, without this layer, they will touch each other and create a short- circuit in the wire.

Conductor
The conductor carries electromagnetic signals. Based on conductor a coaxial cable can be categorized into two types;
single-core coaxial cable and multi-core coaxial cable.
A single-core coaxial cable uses a single central metal (usually copper) conductor,
while a multi-core coaxial cable uses multiple thin strands of metal wires.
TWISTED-PAIR CABLES
Usually, there are four pairs. Each pair has one solid color and one stripped color
wire. Solid colors are blue, brown, green and orange. In stripped color, the solid
color is mixed with the white color.
Based on how pairs are stripped in the plastic sheath, there are two types of twisted-
pair cable; UTP and STP.
In the UTP (Unshielded twisted-pair) cable, all pairs are wrapped in a single plastic
sheath.
In the STP (Shielded twisted-pair) cable, each pair is wrapped with an additional
metal shield, then all pairs are wrapped in a single outer plastic sheath.
SIMILARITIES AND DIFFERENCES BETWEEN STP
AND UTP CABLES
STP UTP

can transmit data at 10Mbps, 100Mbps, 1Gbps, and can transmit data at 10Mbps, 100Mbps, 1Gbps, and
10Gbps. 10Gbps.

the STP cable contains more materials, the UTP cable contains less materials,

it is more expensive than the UTP cable it is less expensive than the STP cable

Both cables use the same RJ-45 (registered jack) Both cables use the same RJ-45 (registered jack)
modular connectors. modular connectors
The STP provides more noise and EMI resistant than The UTP provides less noise and EMI resistant than the
the UTP cable. STP cable.
The maximum segment length for both cables is 100 The maximum segment length for both cables is 100
meters or 328 feet. meters or 328 feet.
Both cables can accommodate a maximum of 1024 Both cables can accommodate a maximum of 1024
nodes in each segment. nodes in each segment.
CABLES
FIBER OPTIC CABLE
This cable consists of core, cladding, buffer, and jacket. The core is made from the thin strands
of glass or plastic that can carry data over the long distance. The core is wrapped in the
cladding; the cladding is wrapped in the buffer, and the buffer is wrapped in the jacket.
Core carries the data signals in the form of the light. Cladding reflects light back to the core.
Buffer protects the light from leaking. The jacket protects the cable from physical damage.
Fiber optic cable is completely immune to EMI and RFI. This cable can transmit data over a
long distance at the highest speed. It can transmit data up to 40 kilometres at the speed of
100Gbps.
Fiber optic uses light to send data. It reflects light from one endpoint to another. Based on how
many beams of light is transmitted at a given time, there are two types of fiber optical cable;
SMF and MMF.
STRAIGHT THROUGH AND CROSSOVER CABLE
Ethernet cables can be wired as straight through or crossover.
The straight through is the most common type and is used to connect computers
to hubs or switches. They are most likely what you will find when you go to
your local computer store and buy a patch cable.
Crossover Ethernet cable is more commonly used to connect a computer to a
computer and may be a little harder to find since they aren’t used nearly as
much as straight through Ethernet cable.
T568A AND T568B WIRING STANDARD BASIS
WHAT IS STRAIGHT THROUGH CABLE?
A straight through cable is a type of twisted pair cable that is used in local
area networks to connect a computer to a network hub such as a router. This
type of cable is also sometimes called a patch cable and is an alternative to
wireless connections where one or more computers access a router through
wireless signal.
On a straight through cable, the wired pins match. Straight through cable use
one wiring standard: both ends use T568A wiring standard or both ends use
T568B wiring standard.
WHAT IS CROSSOVER CABLE?
A crossover Ethernet cable is a type of Ethernet cable used to
connect computing devices together directly.
Unlike straight through cable, the RJ45 crossover cable uses two
different wiring standards: one end uses the T568A wiring
standard and the other end uses the T568B wiring standard.
The internal wiring of Ethernet crossover cables reverses the
transmit and receive signals. It is most often used to connect two
devices of the same type: e.g. two computers or two switches to
each other.
STRAIGHT THROUGH VS CROSSOVER CABLE,
WHICH TO CHOOSE?
Straight through vs crossover cable, which one should I choose? Usually, straight through cables are
primarily used for connecting unlike devices. And crossover cables are use for connecting alike devices.
Use straight through Ethernet cable for the following cabling:
Switch to router

Switch to PC or server

Hub to PC or server

Use crossover cables for the following cabling:


Switch to switch

Switch to hub

Hub to hub Router to router

Router Ethernet port to PC NIC

PC to PC
TWISTED-PAIR (STP AND UTP) NETWORK CABLE
CRIMPING TOOLS
NETWORK CABLE TESTING AND TROUBLESHOOTING
TOOLS
A network cable testing and troubleshooting tool is used for the
following purposes.
To measure the length of a segment or network cable.
To detect loose connectors.
To identify an un-labeled network cable from all network cables.
To find a break in the network cable.
To certify the cable installation.
CABLE CERTIFIER TIME DOMAIN REFLECTOMETER
BASIC CABLE TESTER
Dr. Yasir Dawood

COMPUTER NETWORKING FUNDAMENTALS


IP ADDRESSING & SUBNETTING

IP Addressing

Subnetting

IPv4 vs IPvs6
IP ADDRESSES
 An IP address is an address used to uniquely identify a device on
an IP network.
 The address is made up of 32 binary bits which can be divisible
into a network portion and host portion with the help of a subnet
mask.
 32 binary bits are broken into four octets (1 octet = 8 bits)
 Dotted decimal format (for example, 137.45.104.172)
DOTTED DECIMAL VS BINARY
137.45.104.172
10001001001011010110100010101100
CONVERSION BETWEEN DECIMAL & BINARY
128 X 1 = 128
64 X 0 = 0
32 X 0 = 0
16 X 0 = 0
8 X 1 = 8
4 X 0 = 0
2 X 0 = 0
1 X 1 = 1
137
CONVERSION BETWEEN DECIMAL & BINARY
128 1 128 0 0 0 0 1 128
64 0 0 0 0 1 64 0 0
32 0 0 1 32 1 32 1 32
16 0 0 0 0 0 0 0 0
8 1 8 1 8 1 8 1 8
4 0 0 1 4 0 0 1 4
2 0 0 0 0 0 0 0 0
1 1 1 1 1 0 0 0 0
137 45 104 172
IP ADDRESS CLASSES
ADDRESS CLASSES (CONTINUED)
Determining which part of the IP address belongs to the network (N)and
which part belongs to the host(h).
Class A – NNNNNNNN.hhhhhhhh.hhhhhhhh.hhhhhhhh
Class B – NNNNNNNN.NNNNNNNN.hhhhhhhh.hhhhhhhh
Class C – NNNNNNNN.NNNNNNNN.NNNNNNNN.hhhhhhhh
140.179.220.200 is a Class B so the first 2 octets identify the
network address 140.179.0.0
If the address was then set to 140.179.255.255 this would be a
broadcast address for that network and all nodes would receive
communication
PRIVATE SUBNETS
There are 3 network address ranges reserved for private networks.
These are internal IP networks that sit behind a proxy server or external
router interface.
Routers on the internet by default will not forward packets coming from
these addresses

 10.0.0.0 to 10.255.255.255
 172.16.0.0 to 172.31.255.255
 192.168.0.0 to 192.168.255.255
SUBNET MASKING
Applying a subnet mask to an IP address enables identification of network
part and the host parts of the address

The network bits are represented by 1’s and the host bits represented by 0’s

Default Subnet Masks


 Class A – 255.0.0.0 – 11111111.00000000.00000000.00000000 (/8)

 Class B – 255.255.0.0 – 11111111.11111111.00000000.00000000 (/16)

 Class C – 255.255.255.0 – 11111111.111111111.11111111.00000000 (/24)


SUBNET MASK FOR CLASS C

137.45.104.172
255.255.255.0
“ANDING” A BINARY SUBNET MASK
10001001001011010110100010101100
11111111111111111111111100000000

10001001001011010110100000000000

subnet ID = (137.45.104.0)
IP ADDRESS CLASSES
Class A: The first octet is the network portion. Octets 2, 3, and 4
are for subnets/hosts
Reserved for governments and large corporations throughout the
world

Class B: The first two octets are the network portion. Octets 3 and
4 are for subnets/hosts
Addresses are assigned to large- and medium-sized companies
IP CLASSES (CONTINUED)
IP CLASSES (CONTINUED)
• Class C
The first three octets are the network portion. Octet 4 is for subnets/hosts
– Addresses are assigned to groups that do not meet the qualifications to
obtain Class A or B addresses
• Class D
– Addresses (also known as multicast addresses) are reserved for
multicasting
– Multicasting is the sending of a stream of data (usually audio and
video) to multiple computers at the same time
IP CLASSES (CONTINUED)
IP CLASSES (CONTINUED)
Class E
 Addresses are reserved for research, testing, and experimentation
 The Class E range starts where Class D leaves off
Private IP ranges
 Many companies use private IP addresses for their internal networks
 Will not be routable on the Internet
 Gateway devices have network interface connections to the internal
network and the Internet
 Route packets between them
IP CLASSES (CONTINUED)
SUBNETTING
 Creates multiple logical networks that exist within a single Class
A, B, or C network.

 If you do not subnet, you will only be able to use one network
from your Class A, B, or C network, which is unrealistic.

 Each data link on a network must have a unique network ID, with
every node on that link being a member of the same network
BENEFITS OF SUBNETTING

1) Reduced network traffic

2) Optimized network performance

3) Simplified management

4) Facilitated spanning of large geographical distances


SUBNET MASKING
When network administrators create subnets
 They borrow bits from the original host field to make a set of subnetworks
 The number of borrowed bits determines how many subnetworks and hosts
will be available
Class C addresses also can be subdivided
 Not as many options or available masks exist because only the last octet can
be manipulated with this class
HOW TO CREATE SUBNETS
 Determine the number of required network IDs:
 One for each subnet
 One for each wide area network connection
 Determine the number of required host IDs per subnet:
 One for each TCP/IP host
 One for each router interface
 Based on the above requirements, create the following:
 One subnet mask for your entire network
 A unique subnet ID for each physical segment
 A range of host IDs for each subnet
SUBNETTING FORMULAS
Consider memorizing the following two formulas:

2y = # of usable subnets (where y is the number of bits borrowed)

2x – 2 = # of usable hosts per subnet (where x is the number of bits remaining in the
host field after borrowing)
SUBNETTING FORMULAS (CONTINUED)
SUBNETTING FORMULAS (CONTINUED)
LEARNING TO SUBNET (CONTINUED)
SUBNETTING A CLASS A/B/C ADDRESS

How many subnets does the chosen subnet mask produce?

How many valid hosts per subnet are available?

What are the valid subnets?

What’s the broadcast address of each subnet?

What are the valid hosts in each subnet?


PRACTICE EXAMPLE #1C: 255.255.255.128 (/25)
NETWORK 192.168.10.0
 How many subnets? Since 128 is 1 bit on (10000000), the answer would be 21= 2.
 How many hosts per subnet? We have 7 host bits off (10000000), so the equation would
be 27– 2 = 126 hosts.
 What are the valid subnets? 256 – 128 = 128. Remember, we’ll start at zero and count
in our block size, so our subnets are 0, 128.
 What’s the broadcast address for each subnet? The number right before the value of the
next subnet is all host bits turned on and equals the broadcast address. For the zero
subnet, the next subnet is 128, so the broadcast of the 0 subnet is 127.
 What are the valid hosts? These are the numbers between the subnet and broadcast
address
PRACTICE EXAMPLE #1C: 255.255.255.128 (/25)
NETWORK 192.168.10.0
Class c:
Subnet 0 128
129.168.10.20/25 Address
255.255.255.128
11111111. 11111111. 11111111. 10000000 First Host 1 129

Last Host 126 254


255 255 255 128
Broadcast 127 255
128 64 32 16 8 4 2 1 Address
1 0 0 0 0 0 0 0
PRACTICE EXAMPLE #2C: 255.255.255.224 (/27)
NETWORK 192.168.10.0

 How many subnets? 224 is 11100000, so our equation would be 23 = 8.


 How many hosts? 25– 2 = 30.
 What are the valid subnets? 256 – 224 = 32. We just start at zero and count to the
subnet mask value in blocks (increments) of 32: 0, 32, 64, 96, 128, 160, 192, and 224.
 What’s the broadcast address for each subnet (always the number right before the
next subnet)?
 What are the valid hosts (the numbers between the subnet number and the broadcast
address)?
PRACTICE EXAMPLE #2C: 255.255.255.224 (/27)
NETWORK 192.168.10.0

Subnet 0 32 …………. 192 224


Address

First Host 1 33 193 225

Last Host 30 62 222 254

Broadcast 31 63 223 255


Address
PRACTICE EXAMPLE #1B: 255.255.128.0 (/17)
NETWORK 172.16.0.0

 Subnets? 21 = 2
 Hosts? 215– 2 = 32,766 (7 bits in the third octet, and 8 in the fourth)
 Valid subnets? 256 – 128 = 128. (0, 128). Remember that subnetting is performed
in the third octet, so the subnet numbers are really 0.0 and 128.0, as shown in the
next table
 Broadcast address for each subnet?
 Valid hosts?
PRACTICE EXAMPLE #1B: 255.255.128.0 (/17)
NETWORK 172.16.0.0

Subnet 0.0 128.0

First Host 0.1 128.1

Last Host 127.254 255.254

Broadcast 127.255 255.255


PRACTICE EXAMPLE #2B: 255.255.240.0 (/20)
NETWORK 172.16.0.0

Subnets? 24= 16.


Hosts? 212 – 2 = 4094.
Valid subnets? 256 – 240 = 16 (0, 16, 32, 48, etc., up to 240).
Broadcast address for each subnet?
Valid hosts?
PRACTICE EXAMPLE #2B: 255.255.240.0 (/20)
NETWORK 172.16.0.0

Subnet 0.0 16.0 ……….. 240.0

First Host 0.1 16.1 240.1

Last Host 15.254 31.254 255.254

Broadcast 15.255 31.255 255.255


IPV4 VERSUS IPV6
IP version 4 (IPv4)
 The version of IP currently deployed on most systems today

IP version 6 (IPv6)
 Originally designed to address the eventual depletion of IPv4 addresses

Classless inter-domain routing (CIDR) has slowed the exhaustion of IPv4 address

space and made the move to IPv6 less urgent


 However, CIDR is destined to become obsolete because it is based on IPv4
IPV4 VERSUS IPV6 (CONTINUED)
Network address translation (NAT)
 Another technique developed in part to slow the running down of IPv4
addresses
 Allows a single IP address to provide connectivity for many hosts
However:
• NAT is CPU intensive and expensive
• Some protocols do not work well with NAT, such as the IP Security Protocol (IPSec)

IPv4 does not provide security in itself


 Has led to security issues with DNS and ARP
IPV4 VERSUS IPV6 (CONTINUED)
Security concerns were factored into the design of IPv6
IPv4 networks rely on broadcasting
Inefficient because many hosts unnecessarily see and partially process
traffic not ultimately destined for them
IPv6 does away completely with broadcasting and replaces it with
multicasting
IPv6 addresses are 128 bits compared with IPv4’s 32-bit structure
IPV4 VERSUS IPV6 (CONTINUED)
IPv6 addresses are expressed as hexadecimal numbers
 Example: 3FFE:0501:0008:0000:0260:97FF:FE40:EFAB
IPv6 can be subnetted
 CIDR notation is also used with IPv6
 Example: 2001:702:21:: /48

Organizations requesting an IPv6 address may be assigned a /64


start
 Minimum subnet with space for over a billion hosts
TRANSITIONING TO IPV6
Dual stack
 Involves enabling IPv6 on all routers, switches, and end nodes but not disabling IPv4
 Both version 4 and version 6 stacks run at the same time
Tunneling
 Encapsulates IPv6 traffic inside IPv4 packets
 Done when portions of a network are running IPv6 and other network areas have not
been upgraded yet
 Greatest concern: security
COMPUTER NETWORKING
FUNDAMENTALS
Dr. Yasir Dawood
Analog and Digital
ANALOG AND DIGITAL
o Data must be transformed to electromagnetic signals to be transmitted.

o One of the major functions of the physical layer is to move data in the form of
electromagnetic signals across a transmission medium.

o It is responsible for movements of individual bits from one node to next node

o Both data and the signals can be either analog or digital

o Transmission media work by conducting energy along a physical path which


can be wired or wireless
ANALOG AND DIGITAL
Data can be analog or digital.
 Analog Data: refers to information that is continuous. (an analog clock)
Analog data, such as the sounds made by a human voice, take on continuous values.

 Digital Data: refers to information that has discrete states. (a digital clock)
Digital data take on discrete values. For example, data are stored in computer
memory in the form of 0s and 1s.
ANALOG AND DIGITAL
Signals can be analog or digital.
 An analog signal has infinitely many levels of intensity over a period of time.
 A digital signal, can have only a limited number of defined values.
ANALOG AND DIGITAL
Digital Signal
 Information can also be represented by a digital signal
 For example, a 1 can be encoded as a positive voltage and a 0 as zero voltage.
A digital signal can have more than two levels. In this case, we can send more than
1 bit for each level.

If a signal has L levels, each level needs ( log𝟐𝟐 L )bits.


For this reason, we can send log2 4 = 2 bits such as in figure part b.
ANALOG AND DIGITAL
 Bit Rate

• Most digital signals are non-periodic, and thus period and (frequency are not
appropriate characteristics).

• Another term - bit rate (instead of frequency)- is used to describe digital


signals.
 The bit rate is the number of bits sent in 1s, expressed in bits per second
(bps).
o next Figure shows the bit rate for two signals.
ANALOG AND DIGITAL/ DIGITAL SIGNAL
• We send 1 bit
per level in
part a of the
figure

• And 2 bits per


level in part b
of the figure.
ANALOG AND DIGITAL/ DIGITAL SIGNAL
Example 1
A digital signal has eight levels. How many bits are needed per level?
We calculate the number of bits from the following formula.

Number of bits per level  log2 8 = 3


Each signal level is represented by 3 bits.
ANALOG AND DIGITAL/ DIGITAL SIGNAL
Example 2
A digital signal has nine levels. How many bits are needed per
level? We calculate the number of bits by using the formula.

 Number of bits per level  log2 9 = 3.17


 Each signal level is represented by 3.17 bits. However, this answer is
not realistic.
The number of bits sent per level needs to be an integer as well as a power of 2.
In this example, 4 bits can represent one level.
ANALOG AND DIGITAL
Example 3
Assume we need to download text documents at the rate of 100 pages per second.
What is the required bit rate of the channel? Assume each page has 24 lines with
80 byte in each line.
Solution
If we assume that one character requires 8 bits (ascii), the bit rate is:

100 * 24 * 80 * 8 = 1,536,000 bps = 1.536 Mbps


ANALOG AND DIGITAL
Example 4
A digitized voice channel is made by digitizing a 4-kHz bandwidth analog
voice signal. We need to sample the signal at twice the highest frequency (two
samples per hertz). We assume that each sample requires 8 bits. What is the
required bit rate?

Solution
The bit rate can be calculated as
ANALOG AND DIGITAL
Example 5
What is the bit rate for high-definition TV (HDTV)?

Solution
HDTV uses digital signals to broadcast high quality video signals. The HDTV screen
is normally a ratio of 16 : 9. There are 1920 by 1080 pixels per screen, and the screen
is renewed 30 times per second. Twenty-four bits represents one color pixel.

The TV stations reduce this rate to 20 to 40 Mbps through compression.


BANDWIDTH
In networking, we use the term bandwidth in two contexts.

The first, bandwidth in hertz, refers to the range of frequencies in a composite signal
or the range of frequencies that a channel can pass.

The second, bandwidth in bits per second, refers to the speed of bit transmission in
a channel or link. Often referred to as Capacity.

In data transmission, network throughput is the amount of data moved successfully


from one place to another in a given time period, and typically measured in bits per
second (bps), as in megabits per second (Mbps) or gigabits per second (Gbps).
BANDWIDTH
A network with bandwidth of 10 Mbps can pass only an average of 12,000
frames per minute with each frame carrying an average of 10,000 bits.
What is the throughput of this network?

Solution
We can calculate the throughput as

The throughput is almost one-fifth of the bandwidth in this case.


PROPAGATION & TRANSMISSION SPEED
 Propagation speed - speed at which a bit travels though the medium
from source to destination.

 Transmission speed - the speed at which all the bits in a message


arrive at the destination. (difference in arrival time of first and last bit)
PROPAGATION & TRANSMISSION DELAY
 Propagation Delay = Distance/Propagation speed

 Transmission Delay = Message size/bandwidth bps

 Latency = Propagation delay + Transmission delay + Queueing time +


Processing time
EXAMPLE 1
What is the propagation time if the distance between the two points is
12,000 km? Assume the propagation speed to be 2.4 × 108 m/s in cable.

Solution
We can calculate the propagation time as

The example shows that a bit can go over the Atlantic Ocean in only 50
ms if there is a direct cable between the source and the destination.
EXAMPLE 2
What are the propagation time and the transmission time for a 2.5-kbyte
message (an e-mail) if the bandwidth of the network is 1 Gbps? Assume
that the distance between the sender and the receiver is 12,000 km and that
light travels at 2.4 × 108 m/s.

Solution
We can calculate the propagation and transmission time as shown on the
next slide:
EXAMPLE 2 (CONTINUED)

Note that in this case, because the message is short and the bandwidth is high,
the dominant factor is the propagation time, not the transmission time. The
transmission time can be ignored.
EXAMPLE 3
What are the propagation time and the transmission time for a 5-Mbyte
message (an image) if the bandwidth of the network is 1 Mbps? Assume
that the distance between the sender and the receiver is 12,000 km and that
light travels at 2.4 × 108 m/s.

Solution
We can calculate the propagation and transmission times as shown on the
next slide.
EXAMPLE 3 (CONTINUED)

Note that in this case, because the message is very long and the bandwidth is
not very high, the dominant factor is the transmission time, not the
propagation time. The propagation time can be ignored.
FILLING THE LINK WITH BITS FOR CASE 1
EXAMPLE 4
We can think about the link between two points as a pipe. The cross
section of the pipe represents the bandwidth, and the length of the pipe
represents the delay. We can say the volume of the pipe defines the
bandwidth-delay product, as shown in Figure 3.7.

The bandwidth-delay product defines the


number of bits that can fill the link.
FILLING THE LINK WITH BITS IN CASE 2
EXAMPLE 5
Anetwork link is transferring a data file in two minutes period. The figure shown

below shows the throughput vs. time. Use this figure to calculate the following:

1) Average data transfer rate for this whole time. P Kbps

500
2) Amount of data transferred between second 70 and second 120 ?

Solution 30 70 120 t sec

Size of data=0.5*30*500+40*500+0.5*50*500= 40000 KB

1) Average data transfer =S/T=40000/120= 333.3333 Kbps

2) Amount of data transferred =0.5*50*500= 12500 bit


TRANSMISSION IMPAIRMENT
Signals travel through transmission media, which are not perfect.
The signal at the beginning of the medium is not the same as the signal at the end
of the medium.
Three causes of impairment are attenuation, distortion, and noise
ATTENUATION
 Attenuation means a loss of energy. When a signal, simple or composite, travels
through a medium, it loses some of its energy in overcoming the resistance of the
medium.

 That is why a wire carrying electric signals gets warm, if not hot, after a while
some of the electrical energy in the signal is converted to heat.

 To compensate for this loss, amplifiers are used to amplify the signal.
ATTENUATION
Figure shows the effect of attenuation and amplification.
DECIBEL
 To show that a signal has lost or gained strength, engineers use the unit of the
decibel.

 The decibel (dB) measures the relative strengths of two signals or one signal at
two different points.

Note that the decibel is negative if a signal is attenuated and positive if a signal is
amplified.
dB = 10 log10 P2/P1
EXAMPLE 1
Suppose a signal travels through a transmission medium and its power is reduced to
one-half.
This means that P2 = ½ P1. In this case, the attenuation (loss of power) can be
calculated as

A loss of 3 dB (−3 dB) is equivalent to losing one-half the power.


EXAMPLE 2
A signal travels through an amplifier, and its power is increased 10 times.

This means that P2 = 10 P1. In this case, the amplification (gain of power) can be
calculated as
EXAMPLE 3
One reason that engineers use the decibel to measure the changes in the strength of
a signal is that decibel numbers can be added (or subtracted) when we are
measuring several points (cascading) instead of just two. In the figure a signal travels
from point 1 to point 4. In this case, the decibel value can be calculated as
DISTORTION
 Distortion means that the signal changes its shape.

 Distortion can occur in a composite signal made of different frequencies.

 Signal components at the receiver have phases different from what they had
at the sender.
DISTORTION
NOISE
Several types of noise, may corrupt the signal.
• Thermal noise: is the random motion of electrons in a wire, which creates an
extra signal not originally sent by the transmitter.
• Induced noise: comes from sources such as motors and appliances. These devices
act as a sending antenna, and the transmission medium acts as the receiving
antenna.
• Crosstalk: is the effect of one wire on the other. One wire acts as a sending
antenna and the other as the receiving antenna.
• Impulse noise: is a spike (a signal with high energy in a very short time) that
comes from power lines, lightning, and so on.
NOISE
SIGNAL-TO-NOISE RATIO (SNR):
To find the theoretical bit rate limit, we need to know the ratio of the signal power
to the noise power.
The signal-to-noise ratio is defined as:
SNR = (average signal power) / (average noise power)

A high SNR means the signal is less corrupted by noise;


A low SNR means the signal is more corrupted by noise.
ANALOG AND DIGITAL / SIGNAL-TO-NOISE RATIO (SNR):

Because SNR is the ratio of


two powers, it is often described
in decibel units, SNRdB, defined
as:
SNRdB = 10 log10 SNR
EXAMPLE 3
The power of a signal is 10 mW and the power of the noise is 1 μW; what are the
values of SNR? and SNRdB?
Solution
SNR = (signal power) / (noise power)

The values of SNR and SNRdB can be calculated as follows:


10 𝑚𝑚𝑊𝑊
SNR= 1  SNR = (10000 mw) / (1 mw) = 10000
𝑚𝑚
1000

SNRdB = 10 log10 10000 = 10 log10 104 = 40


COMPUTER NETWORKING
FUNDAMENTALS
Dr. Yasir Dawood
Satellite Communication
OVERVIEW
Satellite is a microwave repeater in the space.
Satellite technology has progressed extremely over the last 50 years.
Today, satellite systems can provide a variety of services including broadband
communications, audio/video distribution networks, marine navigation, worldwide
customer service and support as well as military command and control.
There are about 2,666 satellites in Space, of which 1,918 in low Earth orbit (LEO),
most of them are used for communication.
They are:
 Covering a wide area of the earth’s surface.
 Transmission delay is about 0.3 sec.
 Transmission cost is independent of distance.
SATELLITE SIGNALS
Used to transmit signals and data over long distances
 Weather forecasting

 Television broadcasting

 Internet communication

 Global Positioning Systems


MOTIVATION TO USE SATELLITES
HOW DO SATELLITES WORK
Two Stations on Earth want to communicate through radio broadcast but are
too far away to use conventional means.
The two stations can use a satellite as a relay station for their communication
One Earth Station sends a transmission to the satellite. This is called a Uplink.
The satellite Transponder converts the signal and sends it down to the second
earth station. This is called a Downlink.
SATELLITE UPLINK AND DOWNLINK
Downlink
 The link from a satellite down to one or more ground stations or receivers
Uplink
 The link from a ground station up to a satellite.
Some companies sell uplink and downlink services to
 television stations, corporations, and to other telecommunication carriers.
 A company can specialize in providing uplinks, downlinks, or both.
SATELLITE COMMUNICATION
•When using a satellite for long distance
communications, the satellite acts as a
repeater.
•An earth station transmits the signal up to
the satellite (uplink), which in turn
retransmits it to the receiving earth station
(downlink).
•Different frequencies are used for
uplink/downlink.
SATELLITE TRANSMISSION BANDS
Satellite up links and down links can operate in different frequency bands:

Band Up-Link Down-link ISSUES


(Ghz) (Ghz)
C 4 6 Interference with ground links.
Ku 11 14 Attenuation due to rain

Ka 20 30 High Equipment cost

The up-link is a highly directional, point to point link


The down-link can have a footprint providing coverage for a substantial area "spot beam“.
ADVANTAGES OF SATELLITE COMMUNICATION
The advantages of satellite communication over terrestrial
communication are:
The coverage area of a satellite greatly exceeds that of a terrestrial system.
Transmission cost of a satellite is independent of the distance from the center
of the coverage area.
Satellite to Satellite communication is very precise.
Higher Bandwidths are available for use.
DISADVANTAGES OF SATELLITE COMMUNICATION
The disadvantages of satellite communication:
Launching satellites into orbit is costly.

Satellite bandwidth is gradually becoming used up.

There is a larger propagation delay in satellite communication than in

terrestrial communication.
FACTORS IN SATELLITE COMMUNICATION

Elevation Angle: The angle of the horizontal of the earth surface


to the center line of the satellite transmission beam.
This effects the satellites coverage area. Ideally, you want a elevation angle
of 0 degrees, so the transmission beam reaches the horizon visible to the
satellite in all directions.
However, because of environmental factors like objects blocking the
transmission, atmospheric attenuation, and the earth electrical background
noise, there is a minimum elevation angle of earth stations.
FACTORS IN SATELLITE COMMUNICATION (CONT.)

Other impairments to satellite communication:


The distance between an earth station and a satellite (free space loss).
Satellite Footprint: The satellite transmission’s strength is strongest in the
center of the transmission, and decreases farther from the center as free
space loss increases.
Atmospheric Attenuation caused by air and water can impair the
transmission. It is particularly bad during rain and fog.
EXAMPLE
What is the period of the Moon, according to Kepler’s law?

Here C is a constant approximately equal to 1/100. The period is in seconds


and the distance in kilometers.
EXAMPLE (CONT.)
Solution
The Moon is located approximately 384,000 km above the Earth. The radius
of the Earth is 6378 km. Applying the formula, we get.
EXAMPLE 2
According to Kepler’s law, what is the period of a satellite that is located at an
orbit approximately 35,786 km above the Earth?
Solution
Applying the formula, we get

This means that a satellite located at 35,786 km has a period of 24 h, which is


the same as the rotation period of the Earth. A satellite like this is said to be
stationary to the Earth. The orbit, as we will see, is called a geosynchronous
orbit.
SATELLITE ORBITS

•Geosynchronous Orbit (GEO): 36,000 km


above Earth, includes commercial and military
communications satellites, satellites providing
early warning of ballistic missile launch.
•Medium Earth Orbit (MEO): from 5000 to
15000 km, they include navigation satellites
(GPS, Galileo, Glonass).
•Low Earth Orbit (LEO): from 500 to 1000 km
above Earth, includes military intelligence
satellites, weather satellites.
•High Altitude Platform (HAP) around 20 km
above Earth.
SATELLITE ORBITS
GEOSTATIONARY EARTH ORBIT (GEO)
These satellites are in orbit 35,863 km above the earth’s surface along the equator.
Objects in Geostationary orbit revolve around the earth at the same speed as the
earth rotates. This means GEO satellites remain in the same position relative to the
surface of earth.
GEO ADVANTAGES
Advantages
 A GEO satellite’s distance from earth gives it a large coverage area, almost a fourth of the earth’s
surface.
 GEO satellites have a 24 hour view of a particular area.
 These factors make it ideal for satellite broadcast and other multipoint applications.
GEO DISADVANTAGES

Disadvantages
A GEO satellite’s distance also cause it to have both a comparatively weak
signal and a time delay in the signal, which is bad for point to point
communication.
GEO satellites, centered above the equator, have difficulty broadcasting
signals to near polar regions
LOW EARTH ORBIT (LEO)
LEO satellites are much closer to the earth than GEO satellites, ranging from 500 to
1,500 km above the surface.
LEO satellites don’t stay in fixed position relative to the surface, and are only visible
for 15 to 20 minutes each pass.
A network of LEO satellites is necessary for LEO satellites to be useful
LEO ADVANTAGES

Advantages
A LEO satellite’s proximity to earth compared to a GEO satellite
gives it a better signal strength and less of a time delay, which
makes it better for point to point communication.
A LEO satellite’s smaller area of coverage is less of a waste of
bandwidth.
LEO DISADVANTAGES

Disadvantages
A network of LEO satellites is needed, which can be costly
LEO satellites have to compensate for Doppler shifts cause by
their relative movement.
Atmospheric drag effects LEO satellites, causing gradual orbital
deterioration.
MEDIUM EARTH ORBIT (MEO)

A MEO satellite is in orbit somewhere between 8,000 km and 18,000 km


above the earth’s surface.
MEO satellites are similar to LEO satellites in functionality.
MEO satellites are visible for much longer periods of time than LEO satellites,
usually between 2 to 8 hours.
MEO satellites have a larger coverage area than LEO satellites.
MEO (CONT.)

Advantage
A MEO satellite’s longer duration of visibility and wider footprint means
fewer satellites are needed in a MEO network than a LEO network.
Disadvantage
A MEO satellite’s distance gives it a longer time delay and weaker signal
than a LEO satellite, though not as bad as a GEO satellite.
OTHER ORBITS

Molniya Orbit Satellites


Used by Russia for decades.
Molniya Orbit is an elliptical orbit. The satellite remains in a nearly fixed
position relative to earth for eight hours.
A series of three Molniya satellites can act like a GEO satellite.
Useful in near polar regions.
OTHER ORBITS (CONT.)

High Altitude Platform (HAP)


One of the newest ideas in satellite communication.
A blimp or plane around 20 km above the earth’s surface is used as a
satellite.
HAPs would have very small coverage area, but would have a comparatively
strong signal.
Cheaper to put in position, but would require a lot of them in a network.
SATELLITE ORBITS
WHY SATELLITES REMAIN IN ORBITS?
THE GLOBAL POSITIONING SYSTEM
GPS is funded and controlled by the Department of Defense (DOD).
Although there are many thousands of civil users of GPS worldwide, the system was
originally designed for the U. S. military
GPS provides special satellite signals that can be processed in a GPS receiver,
enabling the receiver to compute position and velocity
Four GPS satellite signals are used to compute positions in three dimensions and the
time offset in the receiver
For around $100, you can get a hand held gadget that will tell you exactly what
point you are on the earth
GPS
The orbital period of the GPS satellites is around 12 hours
The satellites move with respect to the receivers on the earth, but at a slower speed compared
to LEO’s
Typical civilian accuracy is around 100 ft, with occasional errors of up to 300 ft
For applications requiring higher accuracy such as aircraft landing etc., enhancements in the
systems are made that can reduce the error to around 1 cm
Some applications of GPS include:
 Aircraft navigation
 Marine navigation
 Driving
 Surveying
 Farming
CAPACITY ALLOCATION
FDMA
 FAMA-FDMA
 DAMA-FDMA

TDMA
 Advantages over FDMA
FDMA
Satellite frequency is already broken into bands, and is broken in to smaller channels
in Frequency Division Multiple Access (FDMA).
Overall bandwidth within a frequency band is increased due to frequency reuse (a
frequency is used by two carriers with orthogonal polarization).
FDMA (CONT.)
The number of sub-channels is limited by three factors:
 Thermal noise (too weak a signal will be effected by background noise).
 Intermodulation noise (too strong a signal will cause noise).
 Crosstalk (cause by excessive frequency reusing).
FDMA (CONT.)
FDMA can be performed in two ways:
 Fixed-assignment multiple access (FAMA): The sub-channel assignments are of a fixed allotment.
Ideal for broadcast satellite communication.
 Demand-assignment multiple access (DAMA): The sub-channel allotment changes based on demand.
Ideal for point to point communication.
TDMA
TDMA (Time Division Multiple Access) breaks a transmission into multiple time slots,
each one dedicated to a different transmitter.
TDMA is increasingly becoming more widespread in satellite communication.
TDMA uses the same techniques (FAMA and DAMA) as FDMA does.
TDMA (CONT.)

Advantages of TDMA over FDMA.


Digital equipment used in time division multiplexing is increasingly becoming
cheaper.
There are advantages in digital transmission techniques.
Ex: error correction.
Lack of intermodulation noise means increased efficiency.
COMPUTER NETWORKING
FUNDAMENTALS
Dr. Yasir Dawood
Configure a Network Operating System
CISCO IOS
 Cisco Internetwork Operating System (IOS) is a
family of network operating systems used on
many Cisco Systems routers and current Cisco
network switches
 Operating Systems
PC OS allows users to interact with the
computer
User-computer interaction in PC OSs are
often done via mouse, keyboard and monitor
CISCO IOS
 Cisco IOS is also an Operating
System
 Cisco IOS allows users to interact with
Cisco devices.
 Cisco IOS enables a technician to:
 Use a keyboard to run CLI-based (Command
Line Interface) network programs.
 Use a keyboard to enter text and
text-based commands.
 View output on a monitor.
CISCO IOS ACCESS
 Access Methods
 Console
 Aux port
 Virtual Terminal (Telnet / SSH)
CISCO IOS ACCESS
 Console port
• Console port is used to connect a computer
directly to a router or switch and manage the
router or switch.
• The console port must be used for the initial
configuration of devices, because in this case
there is no network connection for remote
configuration of devices
CISCO IOS ACCESS
• Console port

• Roll over cable is used to connect the Serial/COM


port of the computer to the router or switch console
port.
CISCO IOS ACCESS
• AUX Port
• An other way to establish a CLI session remotely is via a telephone
dialup connection using a modem connected to the auxiliary (AUX)
port of a router.
• The Auxiliary Port (AUX Port) which allows an administrator from a
remote location to access the router like a console port.
CISCO IOS ACCESS
 Access Methods
• Virtual Terminal (Telnet / SSH)

• Telnet is a method for remotely establishing a CLI session of a device, through a


virtual interface, over a network.
• Unlike the console connection, Telnet sessions require active networking services
on the device.
• SSH
• The Secure Shell (SSH) protocol provides a remote login similar to Telnet, except
that it uses more secure network services.
• SSH provides stronger password authentication than Telnet and uses encryption
when transporting session data.
CISCO IOS ACCESS
• Terminal emulation programs available for connecting to a networking
device either by a serial connection over a console port or by a Telnet/SSH
connection.
• Some of these include:
• PuTTY
• Tera Term
• SecureCRT
• HyperTerminal
NAVIGATE THE IOS
Cisco IOS Modes of
Operation
• Initial configuration must be done
via console connection
• Configuration is then done via
various CLI command modes.
NAVIGATE THE IOS
 Primary Command Modes
• User EXEC Mode
• Privileged EXEC Mode

 Configuration Command Modes


• The Configure Terminal command enters the Global Configuration Mode.
• Sub-configuration modes are accessible from the Privileged EXEC Mode.
• Examples are: swtich(config-line)# and switch(config-if)#
NAVIGATE THE IOS
NAVIGATE THE IOS
NAVIGATE THE IOS
THE COMMAND STRUCTURE
 Basic IOS Command Structure
• The general syntax for a command is the command followed by any appropriate keywords and arguments.
• Keyword - a specific parameter defined in the operating system
• Argument - not predefined; a value or variable defined by the user
HOT KEYS AND SHORTCUTS
 Commands and keywords can be shortened to the minimum number of
characters that identify a unique selection.

 For example, the configure command can be shortened to conf because


configure is the only command that begins with conf.
• An even shorter version of con will not work because more than one
command begins with con.
• Keywords can also be shortened.
VIDEO DEMONSTRATION - HOTKEYS AND SHORTCUTS
The IOS CLI support the following hotkeys:
 Down Arrow – Allows the user to scroll through command history.

 Up Arrow - Allows the user to scroll backward through commands.

 Tab - Completes the remainder of a partially entered command.

 Ctrl-A - Moves to the beginning of the line.

 Ctrl-E – Moves to the end of the line.

 Ctrl-R – Redisplays a line.

 Ctrl-Z – Exits the configuration mode and returns to user EXEC.

 Ctrl-C – Exits the configuration mode or aborts the current command.

 Ctrl-Shift-6 – Allows the user to interrupt an IOS process (e.g., ping).


HOSTNAMES
 Device Names
• Hostnames allow devices to be identified by network administrators over a network or
the Internet.
• Very important and should also be displayed in the topology.

 Configure Hostnames
• IOS hostnames should:
• Start with a letter
• Contain no spaces
• End with letter or digit
• Use only letters, digits or dashes
• Be less than 64 characters in length
HOSTNAMES
LIMIT ACCESS TO DEVICE CONFIGURATIONS
 Secure Device Access
• Secure privileged EXEC and user EXEC
access with a password.
• Secure virtual terminal lines with a
password.

 Configure Passwords
• Use strong passwords.
• Avoid re-using passwords

 Encrypt Passwords
• Cisco IOS displays passwords in plain text
by default.
• Passwords should be encrypted.
LIMIT ACCESS TO DEVICE CONFIGURATIONS
 Secure Device Access
 To secure privileged EXEC access, use the enable secret password command.
 An older, less secure variation of this command is the enable password password command.
 The enable secret command provides greater security because the password is encrypted.
LIMIT ACCESS TO DEVICE CONFIGURATIONS
 The console port of network devices must be secured by requiring
the user to supply a strong password.
 This reduces the chance of unauthorized person physically plugging
a cable into the device and gaining device access.
 The following commands are used in global configuration mode to
set a password for the console line:

Switch(config)# line console 0


Switch(config-line)# password cisco
Switch(config-line)# login
LIMIT ACCESS TO DEVICE CONFIGURATIONS
VTY Password
 The vty lines allow access to a Cisco device via Telnet.
 By default, many Cisco switches support up to 16 vty lines
that are numbered 0 to 15.
 The same password can be set for all connections.

 The following commands are used in global configuration


mode to set a password for the vty lines:

Switch(config)# line vty 0 15


Switch(config-line)# password cisco
Switch(config-line)# login
IP ADDRESSES
 IP Addresses
• Each end device on a network must be configured with an IP address.
• Enable devices to establish end-to-end communication on
the Internet.
• IPv6 is the most recent version of IP and the replacement for the more
common IPv4.
VERIFYING CONNECTIVITY
 End-To-End Connectivity Test
The ping command can be used to
test connectivity to another device on
the network or a website on the
Internet.
Basic Configuration Commands
Command Purpose
enable Logs you into enable mode, which is also known as user exec mode or
privileged mode
configure terminal Logs you into configuration mode
interface fastethernet/number Enters interface configuration mode for the specified fast ethernet
interface
hostname name Sets a host name to the current Cisco network device
write erase An enable mode command that deletes the startup config
erase startup-config
ip address ip-address mask Assigns an IP address and a subnet mask
shutdown Used in interface configuration mode. “Shutdown” shuts down the
no shutdown interface, while “no shutdown” brings up the interface.

ip default-gateway ip_address Sets the default gateway on a Cisco device


show running-config An enable mode command that displays the current configuration

description name-string A config interface command to describe or name an interface


show running-config interface interface An enable mode command to display the running configuration for a
slot/number specific interface
show ip interface [type number] Displays the usability status of interfaces that are configured for IP

ip name-server serverip-1 serverip-2 A configure mode command that sets the IP addresses of DNS servers
Troubleshooting Commands
ping {hostname | system-address} [source source- Used in enable mode to diagnose basic network connectivity
address]

speed {10 | 100 | 1000 | auto} An interface mode command that manually sets the speed to the specified
value or negotiates it automatically

duplex {auto | full | half} An interface mode command that manually sets duplex to half, full or auto

show mac address-table Displays the MAC address table

show interfaces Displays detailed information about interface status, settings and counters

show interface status Displays the interface line status

show interfaces switchport Displays a large variety of configuration settings and current operational
status, including VLAN trunking details.
Extra
ip route network-number network-mask {ip-address | Sets a static route in the IP routing table
interface}
password pass-value Lists the password that is required if the login command (with no other
parameters) is configured
username name password pass-value A global command that defines one of possibly multiple user names and
associated passwords used for user authentication. It is used when the login
local line configuration command has been used.

enable password pass-value A configuration mode command that defines the password required when
using the enable command
enable secret pass-value A configuration mode command that sets this Cisco device password that is
required for any user to enter enable mode
ip domain-name name Configures a DNS domain name
logging ip-address Configures the IP address of the host that will receive the system logging
(syslog) messages
terminal monitor An enable mode command that tells Cisco IOS to send a copy of all syslog
messages, including debug messages, to the Telnet or SSH user who issues
this command
COMPUTER NETWORKING
FUNDAMENTALS
Dr. Yasir Dawood
The Physical Layer
THE PHYSICAL LAYER
•Theoretical Basis for Data Communications
•Guided Transmission Media
•Wireless Transmission
•Communication Satellites
•Digital Modulation and Multiplexing
•Public Switched Telephone Network
•Mobile Telephone System
•Cable Television
THEORETICAL BASIS FOR DATA TRANSMISSION
There are physical limits to what can be sent over a channel.
Three types of transmission media- each with different properties and performance
capabilities:
 Guided (copper wire and fiber)
 Wireless (radio frequency)
 Satellite

Digital modulation - how analog signals are converted into digital bits and back
again.
Multiplexing to put multiple conversation on the same transmission medium without
interfering with one another.
3 examples of communication systems: telephone, mobile phone and cable TV.
THE PHYSICAL LAYER
Foundation on which other layers build
 Properties of wires, fiber, wireless limit what the network can do Application
Transport
Key problem is to send (digital) bits using only (analog) signals Network
 This is called modulation Link
Physical
THEORETICAL BASIS FOR DATA COMMUNICATION
Communication rates have fundamental limits
Fourier analysis »
Bandwidth-limited signals »
Maximum data rate of a channel »
FOURIER ANALYSIS
A time-varying signal can be equivalently represented as a series of frequency
components (harmonics) or the sum of sines and cosines:

a, b weights of harmonics
Signal over time
FOURIER ANALYSIS
No transmission facility can transmit signal with losing some power in process.
If all Fourier components were equally diminish, the resulting signal would be
reduced in amplitude, but not distorted. Unfortunately all transmission facilities
diminish different Fourier components by different amount, thus introducing
distortion.
The width of this frequency range is called the bandwidth.
 Baseband run from 0 to some max frequency
 Passband- shifted to occupy higher frequencies such as wireless
BANDWIDTH
Bandwidth is a physical property of the transmission medium such
as the construction, thickness and length of the wire or fiber.
Limiting the bandwidth, limits the data rate.
Goal for digital transmission is to receive a signal with enough
fidelity to reconstruct the sequence of bits that was sent.
BANDWIDTH-LIMITED SIGNALS
8 harmonics
Having less bandwidth (harmonics) degrades the signal
Lost!

Bandwidth

4 harmonics
Lost!

2 harmonics

Lost!
MAXIMUM DATA RATE OF A CHANNEL
Nyquist’s theorem relates the data rate to the bandwidth (B) and number of signal levels (V):

Max. data rate = 2B log2V bits/sec

Shannon's theorem relates the data rate to the bandwidth (B) and signal strength (S) relative to
the noise (N):

Max. data rate = B log2(1 + S/N) bits/sec

How fast signal How many levels


can change can be seen
THEOREMS OF NYQUIST AND SHANNON
•According to Nyquist max. data rate = 2B log2V bits/sec so a
3kHz channel can not transmit at a rate faster than 6000bps:
D = 2(3000) * log2 2 = 6000 * 1 bps ( for a binary 2 level signal)
Shannons’ result gives the maximum capacity of the channel:
Voice (analog) phone line B= 3 kHz= 103 and S/N = 30 dB = 30/10 -> 103
max. data rate = B log2 (1 + S/N) bits/sec
C = 3*103 * log2 ( 1+ 1000) = 3 *103 * 10= 3000 *10 = 30,000bps
(This is the maximum amount of data over a phone line or 30Kbps)
CONSEQUENCES OF NYQUIST AND SHANNON
What doe this mean?

Nyquist – encourages us to find more ways to encode bits on a signal because a


better encoding will allow for more bits to be transmitted in a unit of time

Shannon reminds us that there is a fundamental limit to the number of bits pre second
that can be transmitted in a real communication system ( due to the laws of Physics).
GUIDED TRANSMISSION (WIRES & FIBER)
Media have different properties, hence performance
Reality check
Storage media »
Wires:
Twisted pairs »
Coaxial cable »
Power lines »
Fiber cables »
SOME USEFUL TERMS
Different media have different properties such as bandwidth, delay, cost and ease of
installation.
Delay or latency is the time needed to transfer data across a network, usually from one point
to another, like cars on a highway going from point A to point B
Throughput or capacity is the amount of data that can be transmitted in a unit of time, usually
bps.
Bandwidth is the difference between the highest and lowest frequency or the number of signal
changes. In computing, bandwidth refers to the capacity of the channel, or the rate of data
transfer in bps.
SOME TYPICAL 56 kbit/s
1.5 Mbit/s
Modem / Dialup
ADSL Lite

BANDWIDTHS 1.544 Mbit/s


2.048 Mbit/s
T1/DS1
E1 / E-carrier
10 Mbit/s Ethernet
11 Mbit/s Wireless 802.11b
44.736 Mbit/s T3/DS3
54 Mbit/s Wireless 802.11g
100 Mbit/s Fast Ethernet
155 Mbit/s OC3
600 Mbit/s Wireless 802.11n
622 Mbit/s OC12
1 Gbit/s Gigabit Ethernet
2.5 Gbit/s OC48
9.6 Gbit/s OC192
10 Gbit/s 10 Gigabit Ethernet
100 Gbit/s 100 Gigabit Ethernet
REALITY CHECK: STORAGE MEDIA
Magnetic media – data can be stored on tape or DVD and
shipped or driven to its destination:
Send data on tape / disk / DVD for a high bandwidth link
Mail one box with 1000 800GB tapes
 1000* 800 GB * 8 b/B =(6400 Tbit) (where T=103 * 1G)
Takes one day to send (86,400 secs) (delay)
Data rate is 6400 * 103 Gb / 86,400 secs = 74 Gbps.
Data rate is faster than long-distance networks!
But, the message delay is very poor.
WIRELESS TRANSMISSION
Electromagnetic Spectrum »
Radio Transmission »
Microwave Transmission »
Light Transmission »
Wireless vs. Wires/Fiber »
ELECTROMAGNETIC SPECTRUM (1)
Different bands have different uses:
 Radio: wide-area broadcast; Infrared/Light: line-of-sight Networking focus
 Microwave: LANs and 3G/4G;

Microwave
ELECTROMAGNETIC SPECTRUM (2)
To manage interference, spectrum is carefully divided, and its use regulated and licensed,
e.g., sold at auction.

300 MHz 3 GHz

WiFi (ISM bands)


3 GHz Source: NTIA Office of Spectrum Management, 2003 30 GHz

Part of the US frequency allocations


CN5E BY TANENBAUM & WETHERALL, © PEARSON EDUCATION-PRENTICE HALL AND D. WETHERALL, 2011, MODIFIED BY SJF 2014 20
ELECTROMAGNETIC SPECTRUM (3)
Fortunately, there are also unlicensed (“ISM”) bands:
 Free for use at low power; devices manage interference
 Widely used for networking; WiFi, Bluetooth, Zigbee, etc.

802.11 802.11a/g/n
b/g/n
RADIO TRANSMISSION
Radio signals penetrate buildings well and propagate for long distances with path loss

In the VLF, LF, and MF bands, radio waves follow the In the HF band, radio waves bounce off the
curvature of the earth ionosphere.
MICROWAVE TRANSMISSION
Microwaves have much bandwidth and are widely used indoors (WiFi) and outdoors (3G, 4G
satellites)
 Signal is attenuated/reflected by everyday objects
 Strength varies with mobility due multipath fading, etc.
LIGHT TRANSMISSION
Line-of-sight light (no fiber) can be used for links
 Light is highly directional, has much bandwidth
 Use of LEDs/cameras and lasers/photodetectors
WIRELESS VS. WIRES/FIBER
Wireless:
+ Easy and inexpensive to deploy
+ Naturally supports mobility
+ Naturally supports broadcast
− Transmissions interfere and must be managed
− Signal strengths hence data rates vary greatly

Wires/Fiber:
+ Easy to engineer a fixed data rate over point-to-point links
− Can be expensive to deploy, esp. over distances
− Doesn’t readily support mobility or broadcast
SATELLITE VS. FIBER
Satellite:
+Can rapidly set up anywhere/anytime communications (after satellites have
been launched)
+Can broadcast to large regions
- Limited bandwidth and interference to manage
Fiber:
+Enormous bandwidth over long distances
- Installation can be more expensive/difficult
MULTIPLEXING
 A physical channel in a transmission medium may provide bandwidth greater
than required for a data stream
 To efficiently utilize the capacity of the channel, several channel access
schemes are applied
 Multiple transceivers share a transmission medium

 Three types of channel access methods: circuit-mode, packet-mode, and


duplexing
 Multiplexing is one of the circuit-mode methods used in the physical layer

 The channel access methods in the link layer are packet-mode methods
that are based on multiple access protocols in the media access control
(MAC) sublayer
 The duplexing methods are used to separate the uplink and downlink
channels
27
 A multiplexing system with multiplexer (MUX) and demultiplexer
(DEMUX) is shown as follows
 Data streams from multiple data sources multiplexed and
transmitted over a shared physical channel
MULTIPLEXING TECHNIQUES
 Time-Division Multiplexing (TDM)
 Frequency-Division Multiplexing (FDM)
 Wavelength-Division Multiplexing (WDM)
 Code Division Multiple (CDM)
The mapping of channel access scheme and multiplexing
TIME-DIVISION MULTIPLEXING (TDM)
Remember that a WAN connection normally uses a provider’s network.

The internal path is shared by several conversations or WAN connections.

Time Division Multiplexing (TDM) is used to give each conversation a share of the
connection in turn.
 TDM assures that a fixed capacity connection is made available to the subscriber.
TIME-DIVISION MULTIPLEXING (TDM)
 TDM is a technique to combine multiple digital signals from low-rate
channels into a high-rate channel shared alternately in time slots
 A simplified scheme of TDM is shown as follows, where data
streams from different sources are interleaved in a stream of time
slots

32
 TDM divides a time domain into several recurrent time slots of certain time
length
 Each time slot is considered part of a sub-channel or logical channel

 Each sub-channel is used to transmit a data stream

 The interleaved time slots require synchronization at a demultiplexer

 It can be implemented by adding one or more synchronization bits at the


beginning of each transmitted frame
 This is called synchronous TDM, compared to statistical TDM, which can
dynamically allocate time slots to sub-channels without assigning time slots to
empty input lines
 If the input data rates are different, several techniques can be used
 Multilevel multiplexing

 Multi-slot allocation

 Pulse stuffing (or bit stuffing, bit padding).

 The telephony industry uses T lines to implement the digital signal


service
 T lines are categorized from T1 to T5 with different service data rates
 TDM can be extended to the time-division multiple access
(TDMA) scheme
 TDMA policy at the link layer is enforced through TDM at the
physical layer that actually does the job
 GSM telephone system is one of its applications
FREQUENCY-DIVISION MULTIPLEXING (FDM)
 FDM divides a frequency domain into several non-overlapping
frequency ranges, each becoming a sub-channel used by a
sub-carrier
 At a transmitter
 The multiplexing process combines all waveforms derived from data
streams
 A sub-channel uses a sub-carrier, and results in a composite signal
that is transmitted over a physical channel
 At the receiver
 Several bandpass filters are used to extract messages for sub-
channels from a received composite signal
 FDM is only applied to analog signals
 A digital signal can be converted into an analog signal by
modulation, and then FDM can be applied

37
 FDM application
 The radio broadcasting of AM and FM signals
 For example, the bandwidth from 530 kHz to 1700 kHz is assigned
to AM radio
 This is the bandwidth of a physical channel medium and is shared
by several radio stations
 Frequency-Division Multiple Access (FDMA)
 An access method extended from FDM
 Variants of FDMA
 Orthogonal Frequency-Division Multiple Access (OFDMA) based
on Orthogonal Frequency-Division Multiplexing (OFDM)
 Single Carrier FDMA (SC-FDMA) based on Single-Carrier
Frequency Domain Equalization (SC-FDE)
 Wavelength-Division Multiple Access (WDMA) based on
wavelength-division multiplexing (WDM)

39
WAVELENGTH-DIVISION MULTIPLEXING (WDM)
 WDM is equivalent to frequency-division multiplexing, but WDM is
often used in fiber-optic communications where wavelength is the
common term to describe the carrier modulated by optical signals
 WDM uses different wavelengths of laser light to carry different
signals, and each wavelength is specified as a sub-channel in a
single optical fiber
 Because the data rate of the optical fibers is much higher than that
of twisted pair cables, WDM is normally used to aggregate the data
from multiple users
 WDM application: SONET (Synchronous Optical Networking)

40
CODE DIVISION MULTIPLE ACCESS (CDM)

oAll terminals send on the same frequency probably at the same time and can use the whole
bandwidth of the transmission channel
oSo, how the receivers identify the data/signals for them?
oEach sender has a unique random number (code), the sender XORs the signal with this random
number
oDifferent senders use different codes
oThe codes separate the signals from different senders
oThe encoded signals are concatenated together for sending, i.e., as a signal stream of signals
oThe receiver “tunes” into this signal stream if it knows the virtual random number. Tuning is
done via a correlation function
oThe received decodes the signal stream using the known code to identify the data for it
oDifferent receivers received different data as they use different codes
MOBILE TELEPHONE SYSTEM
Mobile telephone service (MTS) connects mobile radio
telephones with other networks like public switched
telephone networks (PSTN), other mobile telephones and
communication systems like Internet.
GENERATIONS OF MOBILE TELEPHONE SYSTEMS
1G, analog voice
 AMPS (Advanced Mobile Phone System) is example, deployed from 1980s. Modulation based on FM (as in radio).

2G, analog voice and digital data


 GSM (Global System for Mobile communications) is example, deployed from 1990s. Modulation based on QPSK.

3G, digital voice and data


 UMTS (Universal Mobile Telecommunications System) is example, deployed from 2000s. Modulation based on CDMA

4G, digital data including voice


 LTE (Long Term Evolution) is example, deployed from 2010s. Modulation based on OFDM
MOBILE NETWORK EVOLUTION
1G 2G 3G 4G
AMPS, NMT GSM/GPRS/ WCDMA/HSPA+ LTE
TACS EDGE CDMA2000/EVDO LTE-A
cdmaOne TD-SCDMA
1G 2G 3G 4G 5G
Mid 1980s 1990s 2000s 2010s 2020s
analog Digital voice Mobile Mobile Internet
voice + Simple data broadband More & faster
CELLULAR MOBILE PHONE SYSTEMS
All based on notion of spatial regions called cells
 Each mobile uses a frequency in a cell; moves cause handoff
 Frequencies are reused across non-adjacent cells
 To support more mobiles, smaller cells can be used

Cellular reuse pattern Smaller cells for dense mobiles


GSM – GLOBAL SYSTEM FOR MOBILE COMMUNICATIONS (1)
 Mobile is divided into handset and SIM card (Subscriber Identity Module) with credentials
 Mobiles tell their HLR (Home Location Register) their current whereabouts for incoming calls
 Cells keep track of visiting mobiles (in the Visitor LR)
GSM – GLOBAL SYSTEM FOR MOBILE COMMUNICATIONS (2)
Air interface is based on FDM channels of 200 KHz divided in an eight-slot TDM frame
every 4.615 ms
 Mobile is assigned up- and down-stream slots to use
 Each slot is 148 bits long, gives rate of 27.4 kbps
UMTS – UNIVERSAL MOBILE TELECOMMUNICATIONS SYSTEM (1)
Architecture is an evolution of GSM; terminology differs
Packets goes to/from the Internet via SGSN/GGSN

Internet
UMTS – UNIVERSAL MOBILE TELECOMMUNICATIONS SYSTEM (2)
Air interface based on CDMA over 5 MHz channels
 Rates over users <14.4 Mbps (HSPDA) per 5 MHz
 CDMA allows frequency reuse over all cells
 CDMA permits soft handoff (connected to both cells)

Soft
handoff
WHAT IS LTE?
•LTE stands for “Long Term Evolution”
•Fourth-generation (4G) cellular technology from 3GPP
•Deployed worldwide
•4G LTE: First global standard
–Increased speed
–IP-based network (All circuits are gone/fried!)
–New air interface: OFDMA (Orthogonal Frequency-Division Multiple Access),
MIMO (multiple antennas)
• Also includes duplexing, timing, carrier spacing, coding...
–New service paradigm (e.g., VoLTE)
WHAT IS LTE?
•LTE is always evolving and 3GPP often has new “releases”
–First release: Rel-8
–Current: Rel-11, Rel-12
–Toward LTE-Advanced (4.5G)
NETWORK ARCHITECTURE EVOLUTION

2G 3G 4G

• Circuit- • Circuit-switching • Packet-


switching for voice switching for
for voice • Packet-switching everything
for data • IP-based
Telecomm
IP-based Internet
Infrastructure
CABLE TELEVISION
Internet over cable »
Spectrum allocation »
Cable modems »
ADSL vs. cable »
INTERNET OVER CABLE
Internet over cable reuses the cable television plant
 Data is sent on the shared cable tree from the head-end, not on a dedicated line per subscriber (DSL)

ISP
(Internet)
SPECTRUM ALLOCATION
Upstream and downstream data are allocated to frequency channels not used for TV
channels:
CABLE MODEMS
Cable modems at customer premises implement the physical layer of the DOCSIS standard
 QPSK/QAM is used in timeslots on frequencies that are assigned for upstream/downstream data
CABLE VS. ADSL
Cable:
+Uses coaxial cable to customers (good bandwidth)
Data is broadcast to all customers (less secure)
Bandwidth is shared over customers so may vary
ADSL:
+Bandwidth is dedicated for each customer
+Point-to-point link does not broadcast data
Uses twisted pair to customers (lower bandwidth)
COMPUTER NETWORKING
FUNDAMENTALS
Dr. Yasir Dawood
Circuit Switching and Packet Switching
CIRCUIT SWITCHING AND PACKET SWITCHING
Packet-switched networks move data in separate, small blocks “packets” based on
the destination address in each packet. When received, packets are reassembled in
the proper sequence to make up the message. Circuit-switched networks require
dedicated point-to-point connections during calls.
Circuit-switched networks and packet-switched networks have traditionally occupied
different spaces within corporations. Circuit-switched networks were used for phone
calls and packet-switched networks handled data. But because of the reach of
phone lines and the efficiency and low cost of data networks, the two technologies
have shared chores for years.
SWITCHING NETWORKS
Long distance transmission is typically done over a network of switched nodes
Nodes not concerned with content of data
End devices are stations
 Computer, terminal, phone, etc.

A collection of nodes and connections is a communications network


Data routed by being switched from node to node
NODES
Nodes may connect to other nodes only, or to stations and other nodes
Node to node links usually multiplexed
Network is usually partially connected
 Some redundant connections are desirable for reliability

Two different switching technologies


 Circuit switching
 Packet switching
SIMPLE SWITCHED NETWORK
CIRCUIT SWITCHING
Dedicated communication path between two stations
Three phases: Establish, Transfer, & Disconnect
Must have switching capacity and channel capacity to establish connection
Must have intelligence to work out routing
Inefficient
 Channel capacity dedicated for duration of connection
 If no data, capacity wasted

Set up (connection) takes time


Once connected, transfer is transparent
Developed for voice traffic (phone)
CIRCUIT SWITCH ELEMENTS
Digital Switch
 Provide transparent signal path
between devices

Network Interface
Control Unit
 Establish connections
 Generally on demand
 Handle and acknowledge requests
 Determine if destination is free
 construct path
 Maintain connection
 Disconnect
PUBLIC CIRCUIT SWITCHED NETWORK
TELECOMS COMPONENTS
Subscriber
 Devices attached to network
Subscriber line
 Local Loop
 Subscriber loop
 Connection to network
 Few km up to few tens of km
Exchange
 Switching centers
 End office - supports subscribers
Trunks
 Branches between exchanges
 Multiplexed
CIRCUIT
ESTABLISHMENT
CIRCUIT SWITCHING CONCEPTS
Blocking or Non-blocking
 Blocking
 A network is unable to connect stations because all paths are in use
 Used on voice systems since we have Short duration calls
 Non-blocking
 Permits all stations to connect (in pairs) at once
 Used for some data connections

Two types of switches:


 Space Division Switching
 Time Division Switching
SPACE DIVISION SWITCHING
Developed for analog environment
Separate physical paths
Switching is instantaneous
Crossbar switch
 Number of crosspoints grows as square of number of stations
 Loss of crosspoint prevents connection
 Inefficient use of crosspoints
 All stations connected, only a few crosspoints in use.
 Statistically, only 25% of the Crosspoint's are used at any time.
 Non-blocking

Multistage Switch
 Reduced number of crosspoints
 More than one path through network
 Increased reliability
 More complex control
 May be blocking
TIME DIVISION SWITCHING
Modern digital systems rely on intelligent control of space and time division elements
Use digital time division techniques to set up and maintain virtual circuits
Partition low speed bit stream into pieces that share higher speed stream
CONTROL SIGNALING FUNCTIONS
Audible communication with subscriber
Transmission of dialed number
Call can not be completed indication
Call ended indication
Signal to ring phone
Billing info
Equipment and trunk status info
Diagnostic info
Control of specialist equipment
CONTROL SIGNAL SEQUENCE
Both phones on hook
Subscriber lifts receiver (off hook)
End office switch signaled
Switch responds with dial tone
Caller dials number
If target not busy, send ringer signal to target subscriber
Feedback to caller
 Ringing tone, engaged tone, unobtainable

Target accepts call by lifting receiver


Switch terminates ringing signal and ringing tone
Switch establishes connection
Connection release when Source subscriber hangs up
SWITCH TO SWITCH SIGNALING
Subscribers connected to different switches
Originating switch seizes interswitch trunk
Send off hook signal on trunk, requesting digit register at target switch (for address)
Terminating switch sends off hook followed by on hook (wink) to show register ready
Originating switch sends address
LOCATION OF SIGNALING
Subscriber to network
 Depends on subscriber device and switch

Within network
 Management of subscriber calls and network
 ore complex
IN CHANNEL SIGNALING
Use same channel for signaling and call
 Requires no additional transmission facilities
Inband
 Uses same frequencies as voice signal
 Can go anywhere a voice signal can
 Impossible to set up a call on a faulty speech path
Out of band
 Voice signals do not use full 4kHz bandwidth
 Narrow signal band within 4kHz used for control
 Can be sent whether or not voice signals are present
 Need extra electronics
 Slower signal rate (narrow bandwidth)
DRAWBACKS OF IN CHANNEL SIGNALING
Limited transfer rate
Delay between entering address (dialing) and connection
Overcome by use of common channel signaling
COMMON CHANNEL SIGNALING
Control signals carried over paths independent of voice channel
One control signal channel can carry signals for a number of subscriber
channels
Common control channel for these subscriber lines:
Associated Mode
 Common channel closely tracks Interswitch trunks

Disassociated Mode
 Additional nodes (signal transfer points)
 Effectively two separate networks
COMMON V. IN CHANNEL SIGNALING
COMMON
CHANNEL
SIGNALING
MODES
Advantages of circuit switching over packet switching:
•Decreases the delay the user experiences before and during a call
•The call will be done with a steady bandwidth, dedicated channel, and consistent
data rate
•Packets are always delivered in the correct order
Disadvantages of circuit switching:
•Great for only voice communication
•Doesn’t use resources efficiently
•Dedicated channels for circuit switching are unavailable for any other use
•There is a higher cost to dedicate one channel per use
Advantages of packet switching over circuit switching:
•More efficient than circuit switching
•Data packets are able to find the destination without the use of a dedicated channel
•Reduces lost data packets because packet switching allows for resending of packets
•More cost-effective since there is no need for a dedicated channel for voice or data
traffic
Disadvantages of packet switching:
•Not ideal for applications that are in constant use, such as high volume voice calls
•High-volume networks can lose data packets during high-traffic times; those data
packets cannot be recovered or resent during transmission
•There is a lack of security protocols for data packets during transmission
CIRCUIT-SWITCHED VS. PACKET SWITCHED NETWORKS
SIGNALING SYSTEM NUMBER 7 (SS7)
Signaling System No. 7 is a set of telephony signaling
protocols developed in 1975, which is used to set up and
tear down telephone calls in most parts of the world-wide
public switched telephone network.
SS7 SIGNALING NETWORK ELEMENTS
Signaling point (SP)
 Any point in the network capable of handling SS7 control message

Signal transfer point (STP)


 A signaling point capable of routing control messages

Control plane
 Responsible for establishing and managing connections

Information plane
 Once a connection is set up, info is transferred in the information plane
TRANSFER
POINTS
SIGNALING NETWORK STRUCTURES
STP capacities
 Number of signaling links that can be handled
 Message transfer time
 Throughput capacity

Network performance
 Number of SPs
 Signaling delays

Availability and reliability


 Ability of network to provide services in the face of STP failures
SOFTSWITCH ARCHITECTURE
General purpose computer running software to make it a smart phone switch
Lower costs
Greater functionality
 Packetizing of digitized voice data
 Allowing voice over IP
Most complex part of telephone network switch is software controlling call process
 Call routing
 Call processing logic
 Typically running on proprietary processor
Separate call processing from hardware function of switch
Physical switching done by media gateway
Call processing done by media gateway controller
TRADITIONAL CIRCUIT SWITCHING
SOFTSWITCH
PACKET SWITCHING PRINCIPLES
Circuit switching designed for voice
 Resources dedicated to a particular call
 Much of the time a data connection is idle
 Data rate is fixed
 Both ends must operate at the same rate
BASIC OPERATION
Data transmitted in small packets
 Typically 1000 octets
 Longer messages split into series of packets
 Each packet contains a portion of user data plus some control info

Control info
 Routing (addressing) info

Packets are received, stored briefly (buffered) and past on to the next node
 Store and forward
USE OF PACKETS
ADVANTAGES
Line efficiency
 Single node to node link can be shared by many packets over time
 Packets queued and transmitted as fast as possible

Data rate conversion


 Each station connects to the local node at its own speed
 Nodes buffer data if required to equalize rates

Packets are accepted even when network is busy


 Delivery may slow down

Priorities can be used


SWITCHING TECHNIQUE
Station breaks long message into packets
Packets sent one at a time to the network
Packets handled in two ways
 Datagram
 Virtual circuit
DATAGRAM
Each packet treated independently
Packets can take any practical route
Packets may arrive out of order
Packets may go missing
Up to receiver to re-order packets and recover from missing packets
DATAGRAM
DIAGRAM
VIRTUAL CIRCUIT
Preplanned route established before any packets sent
Call request and call accept packets establish connection (handshake)
Each packet contains a virtual circuit identifier instead of destination address
No routing decisions required for each packet
Clear request to drop circuit
Not a dedicated path
VIRTUAL
CIRCUIT
DIAGRAM
VIRTUAL CIRCUITS V DATAGRAM
Virtual circuits
 Network can provide sequencing and error control
 Packets are forwarded more quickly
 No routing decisions to make
 Less reliable
 Loss of a node looses all circuits through that node

Datagram
 No call setup phase
 Better if few packets
 More flexible
 Routing can be used to avoid congested parts of the network
PACKET SIZE
EVENT TIMING
X.25
1976
Interface between host and packet switched network
Almost universal on packet switched networks and packet switching in ISDN
Defines three layers
 Physical
 Link
 Packet
X.25 - PHYSICAL
Interface between attached station and link to node
Data terminal equipment DTE (user equipment)
Data circuit terminating equipment DCE (node)
Uses physical layer specification X.21
Reliable transfer across physical link
Sequence of frames
X.25 - LINK
Link Access Protocol Balanced (LAPB)
 Subset of HDLC
 see chapter 7
X.25 - PACKET
External virtual circuits
Logical connections (virtual circuits) between subscribers
X.25 USE OF VIRTUAL CIRCUITS
VIRTUAL CIRCUIT SERVICE
Logical connection between two stations
 External virtual circuit

Specific preplanned route through network


 Internal virtual circuit

Typically one to one relationship between external and internal virtual circuits
Can employ X.25 with datagram style network
External virtual circuits require logical channel
 All data considered part of stream
X.25 LEVELS
User data passes to X.25 level 3
X.25 appends control information
 Header
 Identifies virtual circuit
 Provides sequence numbers for flow and error control

X.25 packet passed down to LAPB entity


LAPB appends further control information
USER DATA AND X.25 PROTOCOL CONTROL
INFORMATION
FRAME RELAY
Designed to be more efficient than X.25
Developed before ATM
Larger installed base than ATM
ATM now of more interest on high speed networks
FRAME RELAY BACKGROUND - X.25
Call control packets, in band signaling
Multiplexing of virtual circuits at layer 3
Layer 2 and 3 include flow and error control
Considerable overhead
Not appropriate for modern digital systems with high reliability
FRAME RELAY - DIFFERENCES
Call control carried in separate logical connection
Multiplexing and switching at layer 2
 Eliminates one layer of processing

No hop by hop error or flow control


End to end flow and error control (if used) are done by higher layer
Single user data frame sent from source to destination and ACK (from higher layer)
sent back
ADVANTAGES AND DISADVANTAGES
Lost link by link error and flow control
 Increased reliability makes this less of a problem

Streamlined communications process


 Lower delay
 Higher throughput

ITU-T recommend frame relay above 2Mbps


PROTOCOL ARCHITECTURE
CONTROL PLANE
Between subscriber and network
Separate logical channel used
 Similar to common channel signaling for circuit switching services

Data link layer


 LAPD (Q.921)
 Reliable data link control
 Error and flow control
 Between user (TE) and network (NT)
 Used for exchange of Q.933 control signal messages
USER PLANE
End to end functionality
Transfer of info between ends
LAPF (Link Access Procedure for Frame Mode Bearer Services) Q.922
 Frame delimiting, alignment and transparency
 Frame mux and demux using addressing field
 Ensure frame is integral number of octets (zero bit insertion/extraction)
 Ensure frame is neither too long nor short
 Detection of transmission errors
 Congestion control functions
USER DATA TRANSFER
One frame type
 User data
 No control frame

No inband signaling
No sequence numbers
 No flow nor error control
COMPUTER NETWORKING
FUNDAMENTALS
Dr. Yasir Dawood
Error Detection and Correction
DATA LINK LAYER
INTRODUCTION
Networks must be able to transfer data from one device to another with
complete accuracy. A system that cannot guarantee that the data received
by one device are identical to the data transmitted by another device is
essentially useless. Yet any time data are transmitted from source to
destination, they can become corrupted in passage. In fact, it is more likely
that some part of a message will be altered in transit than that the entire
contents will arrive intact. Many factors, including line noise, can alter or
wipe out one or more bits of a given data unit. Reliable systems must have
a mechanism for detection, and correcting such errors.
TYPES OF ERRORS
Whenever an electromagnetic signal flows from one point to another, it is subject to
unpredictable interference from heat, magnetism, and other forms of electricity. This
interference can change the shape or timing of the signal.
Such changes can alter the meaning of the data. Changing 0 to 1 or 1 to 0. Bits can
be changed singly or in clumps. So, it is important to understand three types of errors.
These types are usually referred to as single-bit, multiple-bit, and burst errors. Of the
three, a single-bit, error is the most likely to occur and a burst error the least likely.
Errors can be of three types, namely single bit errors, multiple bit errors, and burst
errors.
SINGLE BIT ERROR
Single bit error − In the received frame, only one bit has been
corrupted, i.e., either changed from 0 to 1 or from 1 to 0. Single bit
errors type of errors in serial data transmission because the noise must
have a very short duration which is very rare.
MULTIPLE-BIT ERROR
Multiple bits error − In the received frame, more than
one bit is corrupted.
BURST ERROR
Burst error − In the received frame, more than one consecutive bit is corrupted. means
that two or more bits in the data unit have changed from 1 to 0 or from 0 to 1.
EXAMPLE 1
The number of bits affected depends on the data rate and duration of noise.

𝐍𝐍𝐍𝐍𝐍𝐍𝐍𝐍𝐍𝐍𝐍𝐍 𝐨𝐨𝐨𝐨 𝐛𝐛𝐛𝐛𝐛𝐛 𝐜𝐜𝐜𝐜𝐜𝐜 𝐛𝐛𝐛𝐛 𝐞𝐞𝐞𝐞𝐞𝐞𝐞𝐞𝐜𝐜𝐜𝐜𝐜𝐜𝐜𝐜 = 𝐍𝐍𝐍𝐍𝐍𝐍𝐍𝐍𝐍𝐍 × 𝐛𝐛𝐛𝐛𝐛𝐛 𝐫𝐫𝐫𝐫𝐫𝐫𝐫𝐫


𝒃𝒃𝒃𝒃𝒃𝒃
= 𝐬𝐬𝐬𝐬𝐬𝐬 × = 𝒃𝒃𝒃𝒃𝒃𝒃 (𝐚𝐚𝐚𝐚𝐚𝐚𝐚𝐚𝐚𝐚𝐚𝐚𝐚𝐚𝐚𝐚)
𝒔𝒔𝒔𝒔𝒔𝒔

Example1/ Describe briefly the burst error and mention how many bits can be affected by noise if data
is sent at rate 1Kbps then a noise of 0.01 sec.
Answer :

Burst error: means that two or more bits in the data unit have changed from 1 to 0 or from 0 to 1.
Number of bits can be affected = Noise × bit rate = (0.01) × (1 × 103) = 10 𝑏𝑏𝑖𝑖𝑡𝑡𝑠𝑠
EXAMPLE 2
How many bits can be affected by noise if data is sent at rate 1Mbps
then a noise of 0.01 sec.
Answer:

Number of bits can be affected = Noise × bit rate = (0.01) × (1 × 106)


= 10000 𝑏𝑏𝑖𝑖𝑡𝑡𝑠𝑠
ERROR CONTROL
Error control can be done in two ways:

Error detection − Error detection involves checking whether any error has occurred or not. The
number of error bits and the type of error does not matter.
Error detection uses the concept of redundancy, which means adding extra bits for detecting errors at the
destination.

Error correction − Error correction involves ascertaining the exact number of bits that has been
corrupted and the location of the corrupted bits.

For both error detection and error correction, the sender needs to send some additional bits along with
the data bits. The receiver performs necessary checks based upon the additional redundant bits. If it
finds that the data is free from errors, it removes the redundant bits before passing the message to the
upper layers.
ERROR DETECTION
Error detection uses the concept of redundancy, which means adding extra bits for detecting errors at the
destination.

Redundancy
** Redundancy: send some extra bits with data.
These bits are added by sender and deleted by
the receiver. These bits are used for error
detection and correction.
THE STRUCTURE OF ENCODER AND DECODER
TYPES OF REDUNDANCY CHECKS
Four types of redundancy checks are used in data communications:

1. Vertical Redundancy Check (VRC) (also called parity check).


2. Longitudinal Redundancy Check (LRC).
3. Cyclical Redundancy Check (CRC).
4. Checksum.

The first three, VRC, LRC, and CRC, are implemented in the physical layer for use in the data link layer. The fourth, checksum, is used
primarily by networks, including the Internet, and is implemented in the transport layer.
VERTICAL REDUNDANCY CHECK (VRC)
The most common and least expensive mechanism for error detection is the vertical
redundancy check (VRC), often called a parity check.
(One Dimension Parity Checks)
Parity checks: Parity checking at the receiver can detect the presence of an error if
the parity of the receiver signal is different from the expected parity.
• There are two types VRC.

1. Even parity
2. Odd Parity.
CON.
The parity check is done by adding an extra bit, called parity bit to the data to make a number of 1s either even in
case of even parity or odd in case of odd parity. There are two types of parity bits:
Even parity bit:
In the case of even parity, for a given set of bits, the number of 1’s is counted. If that count is odd, the parity bit
value is set to 1, making the total count of occurrences of 1’s an even number. If the total number of 1’s in a given
set of bits is already even, the parity bit’s value is 0.
Odd Parity bit:
In the case of odd parity, for a given set of bits, the number of 1’s is counted. If that count is even, the parity bit
value is set to 1, making the total count of occurrences of 1’s an odd number. If the total number of 1’s in a given set
of bits is already odd, the parity bit’s value is 0.
***In Single error parity check cannot detect even number of errors
THE STRUCTURE OF ENCODER AND DECODER
EXAMPLE 3
Suppose that a sender wants to send (1000101, 1000001, 1000011, and 1110001) with one dimensional
EVEN PARITY, find the parity bit need to be added to the message and then check received data at
receiver side as shown in the table below
Data Parity Sender Data Received Data at Result
Bit Receiver
1000101 10001011
1000001 10000010
1000011 11100111
1110001 11100000

Answer:

Data Parity Sender Data Received Data at Result


Bit Receiver
1000101 1 10001011 10001011 Accept (Even)
1000001 0 10000010 10000010 Accept (Even)
1000011 1 10000111 11100111 Accept (Even)
1110001 0 11100010 11100000 Error (Odd)
EXAMPLE 4
Suppose that a sender wants to send (1000101, 1001001, 1100011, 1111001, and
1010101) with one dimensional ODD PARITY, find the parity bit need to be added to the
message and then check received data at receiver side as shown in the table below.
Data Parity Sender Data Received Data at Result
Bit Receiver
1000101 10001110
1001001 10000010
1100011 11010111
1111001 11110010
1010101 10101011

Answer:
Data Parity Sender Data Received Data at Result
Bit Receiver
1000101 0 10001010 10001110 Error (Even)
1001001 0 10010010 10000010 Error (Even)
1100011 1 11000111 11010111 Error (Even)
1111001 0 11110010 11110010 Accept (Odd)
1010101 1 10101011 10101011 Accept (Odd)
LONGITUDINAL REDUNDANCY CHECK (LRC)
In this error detection method, a block of bits is organized in a table with rows and
columns. Then the parity bit for each column is calculated and a new row of eight bits,
which are the parity bits for the whole block, is created. After that the new calculated
parity bits are attached to the original data and sends to the receiver.

LRC fields consist of one byte containing an eight-bit binary value. LRC values are
calculated by transmitting devices, which append LRC to messages. The device at the
receiving end recalculates the LRC on receipt of the message and compares the
calculated value to the actual value received in the LRC field. If the values are equal,
the transmission was successful; if the values are not equal, this indicates an error.
EXAMPLE 5 Answer:

Using LRC find the message to be send if you


have the following data message stream
(10110011 10101011 01011010 11010101).
EXAMPLE 6
Using Longitudinal Redundancy Check (LRC) find the message to be send if you
have the following data message stream (11100111 11011101 00111001
10101001).

11100111
11011101
00111001
10101001
10101010
HOW LRC FAIL TO DETECT THE BURST NOISE
However, if two bits in one data unit are damaged and two bits in exactly the same positions in another data unit
are also damaged, the LRC checker will not detect an error.

Notice that although the 5th bit and the 7th bit for 3rd and 4th data unit have been changed but the LRC
calculated by receiver is still the same as the LRC received. Thus, the receiver checker cannot detect this burst
error.
COMPUTER NETWORKING
FUNDAMENTALS
Dr. Yasir Dawood
Error Detection and Correction
CYCLICAL REDUNDANCY CHECK (CRC)
The most powerful redundancy technique, unlike the VRC and LRC,
CRC is based on binary division. The redundancy bits used by CRC
are derived by dividing the data unit by the predetermined divisor
(The CRC generator uses modulo-2 division).and appends it to the
end of the data string so that the resulting bit sequence must be
exactly divisible by the divisor.
This process can be described as a step at the source and we call it
the encoder, the other step is performed at the receiver and we
call it the decoder.
CRC STEPS
In the encoder (see the figure below), the dataword has k bits (4
here); the predetermined divisor (normally called the generator
polynomial or simply the generator) has m bits (4 here).
The resulting codeword from the binary division would have n bits
calculated as k + (m -1) (7 here). The size of the dataword is
augmented by adding (m – 1) (3 here) 0s to the right-hand side of
the word. The result is fed into the generator.
THE STRUCTURE OF ENCODER AND DECODER
CON
The generator circuit divides the augmented dataword by the divisor (modulo-2
division). The quotient of the division is discarded; the remainder (r2 ,r1and r0) is
appended to the dataword to create the codeword.

At the receiver (decoder) this operation is repeated with the same divisor. The
analyzer has a simple function. If the syndrome bits are all 0s (remaineder), the 4
leftmost bits of the codeword are accepted as the dataword (interpreted as no
error); otherwise, the 4 bits are discarded (error).
CRC
CRC or Cyclic Redundancy Check is a method of detecting accidental changes/errors in
communication channel. CRC uses Generator Polynomial which is available on both sender and
receiver side.

k : datawor d
m: divisor (normally called the gener ator polynomial or simply the generator)
n : The resulting codeword (augmented datawor d ), n = k + (m-1)
remainder =m -1
n
codeword

k m-1
dataword remainder
EXAMPLE
Let the data word be 1001 The Generator 1011
A) Find the codeword that would be sent from the sender
B) Perform the checking operation at the receiver if the
received codeword was
1- 1001110
2- 1000110

Solution:
A: The sender side
EXAMPLE CON.
B) Receiver Side both
cases 1 and 2
CRC GENERATOR FUNCTION AS POLYNOMIAL
The CRC generator is most often represented as an algebraic polynomial. This is useful because the
code is short and can be easily mathematically understood. For example:

X7+X5+X2+X+1 Gives the binary: 10100111

See another example below


EXAMPLE
Assume you have a generator function of G = 11011.
The data frame to be sent is 11100101.
1. Find the CRC value
2. The final data frame sent with CRC
3. Check at the receiver
side that there are no
problems solution:

1. CRC value = 0100


2. Final data frame = 11100101 0100
3. Check at the receiver side that there are no problems Note:
Remainder must be 00000

Reliability
CRC will detect all possible errors except those that change the bit value of a
block of code by exactly the value of the divisor.
EXAMPLE

Define CRC and determine the message to be sent T(x)


for a given Generator
𝑮𝑮(𝒙𝒙) = 𝒙𝒙𝟑𝟑 + 𝒙𝒙 and a Message 𝑴𝑴(𝒙𝒙) = 𝒙𝒙𝟓𝟓
+ 𝒙𝒙𝟑𝟑 + 𝒙𝒙𝟐𝟐 + 𝒙𝒙 . (Using binary division).
Answer:
Cyclic Redundancy Check (CRC): is error detector for a
message. Consist of : G(x),P(x) Generator & M(x) Message
Based on binary addition and division.
𝑮𝑮(𝒙𝒙) = 𝒙𝒙𝟑𝟑 + 𝒙𝒙 = 𝟏𝟏𝟎𝟎𝟏𝟏𝟎𝟎

𝑴𝑴(𝒙𝒙) = 𝒙𝒙𝟓𝟓 + 𝒙𝒙𝟑𝟑 + 𝒙𝒙𝟐𝟐 + 𝒙𝒙 = 𝟏𝟏𝟎𝟎𝟏𝟏𝟏𝟏𝟏𝟏𝟎𝟎


CON.
The CRC code is = 110

And the message to be sent is:

Dataword CRC

101110 110

Codeword
CHECKSUM
The last error detection method we discuss here is called the checksum. The checksum
is used in the Internet by several protocols although not at the data link layer. However,
we briefly discuss it here to complete our discussion on error checking

In the receiver, the coming data is subdivided into data and checksum. The total value
of the data unit and the checksum must be zero for errorless transmission.

Checksum in networking is an error detection method. Checksum method involves


calculating a value called as checksum to check whether error occurred in the data
during the transmission or not.
DETAILED STEPS OF CHECKSUM
1- Add the 16-bit values up. Each time a carry-out (17th bit) is produced,
swing that bit around and add it back into the LSb (one’s digit). This is
somewhat erroneously referred to as "one's complement addition."

2- Once all the values are added in this manner, invert all the bits in the result.
A binary value that has all the bits of another binary value inverted is called
its "one's complement," or simply its “complement."

Checksum: Detected all errors


EXAMPLE
Suppose the blocks of 5 binary digits 0111, 1011, 1100, 0000, 0110, to be sent using checksum, calculate
the checksum at the sender and check the sent message at the receiver side.
Answer:
EXAMPLE
Define Checksum and detect the error on the following message

10101. 10110. 01110


Answer:
Checksum: Is an error detection method. Checksum method involves calculating a value called as checksum to
check whether error occurred in the data during the transmission or not.

10101 First 5-bit value


+ 10110 Second 5-bit value

1 01011 Produced a carry-out, which gets added


+ \-----> 1 add carry

01100
+ 01110 Third 5-bit value

11010 Our sum


00101 Complement

So, the checksum stored in the header would be 00101


EXAMPLE 1) First, we add the 16-bit values 2 at a time:
Sender needs to send four data items 1001, 1010,
0101, 1100 1001 First 4-bit value
+ 1010 Second 4-bit value
1) Find the checksum at the sender site.
2) Find the checksum at the receiver site if the second 1 0011 Produced a carry-out, which gets added
item from the left changed to 1000 + \-----> 1 add carry

Answer: 0100
+ 0101 Third 4-bit value

1001 No carry to swing around


+ 1100 Fourth 8-bit value

1 0101
+ \------> 1 add carry

0110 Our sum


1001 Complement

So, the checksum stored in the header would be 1001


CON. 1001 First 4-bit value
2) The checksum at the receiver site if the + 1000 Second 4-bit value
second item from the left changed to 1000
1 0001 Produced a carry-out, which gets added
1001, 1000, 0101, 1100, 1001 + \-----> 1 add carry

0010
+ 0101 Third 4-bit value

0111 No carry to swing around


+ 1100 Fourth 4-bit value

1 0011
+ \------> 1 add carry

0100
+ 1001 Fifth 4-bit value

1101 Our sum


0010 Complement the pattern is corrupted
Discarded the message
COMPUTER NETWORKING
FUNDAMENTALS
Dr. Yasir Dawood
Television Systems
TELEVISION SYSTEMS
• Television systems are the combination of equipment, protocols and
transmission lines that are used to obtain media from content
providers and distribute the media or programs to content viewers.
• Some of the key types of television systems include :
• cable TV,
• satellite TV,
• broadcast TV,
• mobile TV,
• IPTV, and Internet TV.

2
CABLE TELEVISION
• Cable television - generally, any system that distributes
television signals by a network of coaxial or fiber-optic
cables.
• It typically have 50 or more video channels.
• In the late 1990's, many cable systems started converting
to digital transmission using fiber optic cable and digital
signal compression.

3
CABLE TELEVISION
Analog Cable
• An analog cable system distributes television (and other information
services) via a cable television distribution system in analog modulated
form. (ex. CATV)

Digital Cable
• A digital cable system distributes television (and other information services)
via a cable television distribution system in digital modulated form.
• Digital cable systems may include high-speed data and two-way
interactive services.

4
A SAMPLE CATV SYSTEM

5
• The CATV system gathers content from a variety of sources including network feeds, stored
media, communication links and live studio sources.

• The headend converts the media sources into a form that can be managed and distributed.

• The asset management system stores, moves and sends out (playout) the media at scheduled
times.

• The distribution system simultaneously transfers multiple channels to users who are
connected to the CATV system.

• Users view CATV programming on televisions that are directly connected to the cable line
(cable ready TVs) or through an adapter box (set top box).

6
SATELLITE TELEVISION
• Satellite television is the broadcasting of television signals through
satellites to viewers who have viewing devices that can receive
satellite signals.
• Satellite viewing devices can range from televisions that are
connected to a satellite receiver to mobile telephones that have built
in satellite receivers.

7
A SATELLITE TV SYSTEM

8
A SATELLITE TV SYSTEM
• A satellite TV system is a wide area media distribution system.
• All the TV channels and media programs are sent on an uplink radio
channel to a satellite that retransmits the signal back toward Earth.
• The satellite is located approximately 22,300 miles above the Earth
which allows it to travel at the same rotational speed of the Earth so
it appears stationary to the antennas that are receiving its signal.

9
BROADCAST TELEVISION
• Broadcast television is the sending of video and audio signals to
devices (such as television sets) that can receive broadcast signals.
• Analog Broadcast TV
• Digital Terrestrial Television – DTT
• Enhanced TV
• Hybrid Broadcast Broadband Television - HBBTV

10
BROADCAST TELEVISION
Analog Broadcast TV - broadcasting is the sending of video
information in an analog form.
Digital Terrestrial Television - DTT- are land based broadcast high
speed digital signals that can contain a mix of digital television
channels and other digital media
Enhanced TV - is the sending of additional data or signals along with
broadcast media that can enhance the viewing experience.

11
DIGITAL TERRESTRIAL TELEVISION SYSTEM

12
DIGITAL TERRESTRIAL TELEVISION SYSTEM
• A DTT system uses a single wide digital radio channel that is divided
into multiple digital television channels.
• Television broadcasters are linked to the DTT system by a digital
channel and they are assigned (mapped) to a specific portion (logical
channel) on the digital radio channel.
• The DTT system combines (multiplexes) the incoming channels to form
one digital transmission channel.
• DTT receivers receive and decode a DTT frequency, separate out
(demultiplexes) the specific digital (logical) channel and converts the
digital channel back into its original television (video and audio) form.

13
MOBILE TELEVISION
Mobile television is the transferring of signals that carry
moving picture information to mobile devices.
Mobile TV services may be provided using cellular
systems, mobile broadcast systems, or mobile satellite
systems.

14
IPTV
• Internet protocol television - IPTV is a process of providing television
(video and/or audio) services through the use Internet protocol - IP
networks.
• These IP networks initiate, process, and receive voice or multimedia
communications using Internet protocol.
• These IP systems may be public IP systems (e.g. the Internet), private
data systems (e.g. LAN based), or a hybrid of public and private
systems.

15
MULTICAST VS UNICAST
TV Servers support two types of streaming: unicast
and multicast streaming.
Unicast is a form of network communication where the
stream is sent multiple times directly to each receiver:
CON.
Multicast is a stream that is sent once but can be
received by multiple receivers:

The internet is almost entirely unicast: a browser connects to a server and packets flow
along a direct connection between the server and the receiver. Multicast is more similar to
a radio station, broadcasting a single stream that is received by more than one receiver.
COMPUTER NETWORKING
FUNDAMENTALS
Dr. Yasir Dawood
WWW and HTTP
ARCHITECTURE
The World Wide Web (WWW) today is a distributed client/server service, in
which a client using a browser can access a service using a server. However,
the service provided is distributed over many locations called sites.
Topics discussed in this section:
Server
Client (Browser)
Uniform Resource Locator (URL)
Cookies

27.2
Figure 1 Architecture of WWW
Figure 2 Browser
Figure 3 URL

http:// 80 by default
https://
ftp://
Cookies

HTTP cookies, or internet cookies, are built specifically for Internet web
browsers to track, personalize, and save information about each user's
session. A “session” just refers to the time you spend on a site. Cookies are
created to identify you when you visit a new website.
Cookies are needed for extending functionalities of the Web, such as:
 To remember past client in order to show a customized webpage.
 Save login session to keep the user always logged in.
 For advertiser to show what the customer might need
Cookies: Creation and stor age

When a server receives a request from a client, it stores information about


the client in a file or a string.
The server includes the cookie in the response that it sends to the client.
When the client receives the response, the browser stores the cookie in the
cookie directory.
WEB DOCUMENTS
The documents in the WWW can be grouped into three broad categories:
static, dynamic, and active. The category is based on the time at which the
contents of the document are determined.
Topics discussed in this section:
Static Documents
Dynamic Documents
Active Documents

27.8
Figure 4 Static document

 Uses the Hypertext Markup Language (HTML)


 The HTML is the standard markup language for documents designed to be displayed
in a web browser. It can be assisted by technologies such as Cascading Style Sheets
(CSS) and scripting languages such as JavaScript.
Figure 5 Boldface tags
Figure 7 Beginning and ending tags

Example:
 <a href=“index.html">Home Page</a>
 <img src="../images/logo.gif" width="200" border="0" height=“150">
Figure 8 Dynamic document using Common Gateway Inter face (CGI)

The Common Gateway Interface (CGI) is a technology that creates and handles dynamic
documents. CGI is a set of standards that defines how a dynamic document is written, how data
are input to the program, and how the output result is used.
Figure 9 Dynamic document using ser ver-site scr ipt

A few technologies have been involved in creating dynamic documents using scripts. Among the most common
are Hypertext Preprocessor (pHP), which uses the Perl language; Java Server Pages (JSP), which uses the
Java language for scripting; Active Server Pages (ASP), a Microsoft product which uses Visual Basic
language for scripting; and ColdFusion, which embeds SQL database queries in the HTML document.
Figure 10 Active document using J ava applet

An applet is a program written in Java on the server. It is compiled and ready to be


run. The document is in byte-code (binary) format. The client process (browser) creates
an instance of this applet and runs it.
Figure 11 Active document using client-site scr ipt

The idea of scripts in dynamic documents can also be used for active documents. If the active part
of the document is small, it can be written in a scripting language; then it can be interpreted and
run by the client at the same time.
HTTP
The Hypertext Transfer Protocol (HTTP) is a protocol used mainly to access
data on the World Wide Web.
Topics discussed in this section:
HTTP Transaction
Persistent vs Nonpersistent Connection
Figure 12 HTTP tr ansaction

HTTP uses the services of TCP on well-


known port 80.
Figure 13 Request and response messages (all in Plain Text)
Figure 15 Header for mat

General header The general header gives general information about the message and
can be present in both a request and a response. Next table lists some general headers
with their descriptions
Table Gener al Header for mat
PERSISTENT VS NONPERSISTENT CONNECTION
HTTP can use both nonpersistent connections and persistent connections.
A nonpersistent connection is the one that is closed after the server sends the
requested object to the client. In other words, the connection is used exactly for one
request and one response.
With persistent connections, the server leaves the TCP connection open after
sending responses and hence the subsequent requests and responses between the
same client and server can be sent. The server closes the connection only when it is
not used for a certain configurable amount of time.
With persistent connections, the performance is improved by 20%
COMPUTER NETWORKING
FUNDAMENTALS
Dr. Yasir Dawood
Domain Name System
INTRODUCTION
There are several applications in the application layer of the
Internet model that follow the client/server paradigm.
The client/server programs can be divided into two categories:
those that can be directly used by the user, such as e-mail, and
those that support other application programs.
The Domain Name System (DNS) is a supporting program that is
used by other programs such as e-mail.
EXAMPLE OF USING THE DNS SERVICE
NAME SPACE
To be clear, the names assigned to machines must be carefully selected from a name
space with complete control over the binding between the names and IP addresses.
A name space that maps each address to a unique name can be organized in two ways:
flat or hierarchical.

In a Flat Name Space a name is assigned to an address. A name in this space is a


sequence of characters without structure.

In a Hierarchical Name Space, each name is made of several parts. The first part can
define the nature of the organization, the second part can define the name of an
organization, the third part can define departments in the organization, and so on.
DOMAIN NAME SPACE
To have a hierarchical name space, a domain name space was designed. In this design
the names are defined in an inverted-tree structure with the root at the top. The tree can
have only 128 levels: level 0 (root) to level 127..
DOMAIN NAMES AND LABELS
FQDN AND PQDN
DOMAINS
A domain is a subtree of the
domain name space. The name
of the domain is the domain
name of the node at the top of
the subtree. Note that a domain
may itself be divided into
domains.
DISTRIBUTION OF NAME SPACE
The information contained in the domain name space must be stored. However, it is very
inefficient and also unreliable to have just one computer store such a huge amount of
information.

It is inefficient because responding to requests from all over the world places a heavy load
on the system. It is not unreliable because any failure makes the data inaccessible.
HIERARCHY OF NAME SERVERS
ZONES AND DOMAINS
Since the complete domain name
hierarchy cannot be stored on a single
server, it is divided among many
servers. What a server is responsible
for or has authority over is called a
zone. We can define a zone as a
contiguous part of the entire tree. If a
server accepts responsibility for a
domain and does not divide the domain
into smaller domains, the domain and
the zone refer to the same thing.
DNS IN THE INTERNET
DNS is a protocol that can be used in different platfor ms. In the
Inter net, the domain name space (tree) is divided into three different
sections: gener ic domains, countr y domains, and the inver se domain.

Topics discussed in this


section:
Generic Domains
Country Domains
Inverse Domain
DNS IN THE INTERNET
GENERIC DOMAINS

The generic domains define


registered hosts according to
their generic behavior. Each
node in the tree defines a
domain, which is an index to the
domain name space database
GENERIC DOMAIN LABELS
Looking at the tree before , we see
that the first level in the generic
domains section allows 14 possible
labels. These labels describe the
organization types as listed
COUNTRY DOMAINS
The country domains section uses two-character
country abbreviations (e.g., us for United States).
Second labels can be organizational, or they can
be more specific, national designations. Iraq, for
example, uses iq (e.g., duc.edu.iq).
INVERSE DOMAIN
The inverse domain is used to map an
address to a name. This may happen, for
example, when a server has received a
request from a client to do a task. Although
the server has a file that contains a list of
authorized clients, only the IP address of
the client (extracted from the received IP
packet) is listed. The server asks its resolver
to send a query to the DNS server to map
an address to a name to determine if the
client is on the authorized list.
RESOLUTION
Mapping a name to an address or an address to a name is called
name-address resolution.

Topics discussed in this section:


Resolver
Mapping Names to Addresses
Mapping Addresses to Names
Recursive Resolution
Caching
RECURSIVE RESOLUTION
The client (resolver) can ask for a recursive answer
from a name server. This means that the resolver
expects the server to supply the final answer. If the
server is the authority for the domain name, it
checks its database and responds. If the server is
not the authority, it sends the request to another
server (the parent usually) and waits for the
response. If the parent is the authority, it responds;
otherwise, it sends the query to yet another server.
When the query is finally resolved,
the response travels back
until it finally reaches the
requesting client.
ITERATIVE RESOLUTION
If the client does not ask for a recursive answer,
the mapping can be done iteratively. If the server
is an authority for the name, it sends the answer. If
it is not, it returns (to the client) the IP address of
the server that it thinks can resolve the query. The
client is responsible for repeating the query to this
second server. If the newly addressed server can
resolve the problem, it answers the query with the
IP address; otherwise, it returns the IP address of
a new server to the client. Now the client must
repeat the query to the third server. This process is
called iterative resolution because the client
repeats the same query to multiple servers
DNS MESSAGES
DNS has two types of messages: query and response.
Both types have the same format.

The query message consists of a header and question records; the


response message consists of a header, question records, answer records,
authoritative records, and additional records.
QUERY AND RESPONSE MESSAGES
HEADER FORMAT
Both query and response messages have the same header format with some
fields set to zero for the query messages. The header is 12 bytes.
HEADER FORMAT
There are two types of records are used in DNS. The question records
are used in the question section of the query and response messages. The
resource records are used in the answer, authoritative, and additional
information sections of the response message.

Topics discussed in this section:


Question Record
Resource Record
REGISTRARS
How are new domains added to DNS? This is done through a registrar, a
commercial entity accredited by ICANN.. registrar first verifies that the
requested domain name is unique and then enters it into the DNS database.
A fee is charged.

To register, the organization needs to give the name of its server and the IP
address of the server. For example, a new commercial organization named
wonderful with a server named ws and IP address 200.200.200.5 needs to
give the following information to one of the registrars:

Domain name: WS.wonderful.com


IP address: 200.200.200.5
DYNAMIC DOMAIN NAME SYSTEM (DDNS)
The DNS master file must be updated dynamically. The Dynamic Domain
Name System (DDNS) therefore was devised to respond to this need.. In
DDNS, when a binding between a name and an address is determined,
the information is sent, usually by DHCP to a primary DNS server. The
primary server updates the zone.. The secondary servers are notified
either actively or passively.
ENCAPSULATION
DNS can use either UDP or TCP. In both cases the well-known port used by the server is
port 53. UDP is used when the size of the response message is less than 512 bytes
because most UDP packages have a 512-byte packet size limit. If the size of the response
message is more than 512 bytes, a TCP connection is used. In that case, one of two
scenarios can occur:
• If the resolver has prior knowledge that the size of the response message is more than
512 bytes, it uses the TCP connection. For example, if a secondary name server
(acting as a client) needs a zone transfer from a primary server, it uses the TCP
connection because the size of the information being transferred usually exceeds 512
bytes.
• If the resolver does not know the size of the response message, it can use the UDP
port. However, if the size of the response message is more than 512 bytes, the server
truncates the message and turns on the TC bit. The resolver now opens a TCP
connection and repeats the request to get a full response from the server.

You might also like