0% found this document useful (0 votes)
19 views47 pages

Networking

networking 1 prep

Uploaded by

ayesha153mohd
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)
19 views47 pages

Networking

networking 1 prep

Uploaded by

ayesha153mohd
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/ 47

Networking 1

* You have to refer to the official material in


Moodle (slides + labs) and don’t only depend on
this notebook.
Good luck in your studies!

* Notes were written by: Sayed Ali Alawi


* Organized by: PASS leader Fatema Habib

Special Thanks to:


Mr. Mahmoud Alhamad
Living in a Network-centric
world
* Network as a Platform:
All networks have four basie elements in common:
1. The devices.
2. The Messages.
3. The Medium (link) that connects the devices.
4. The Rules (protocols) to govern the handling of the
messages.

* Converged Network:
- Traditional telephone, radio, television and computer
data networks each have their own individual versions of
the four basic network elements.
- Technology advances are enabling us to consolidate
these disparate networks onto one platform, known as
converged network.
Living in a Network-centric world

* The Architecture of the Network:


- It’s the technologies that supports the infrastructure
and the programmed services and protocols that move
the message across that infrastructure.

* The four basic characteristics for networks:


1. Fault tolerance
2. Scalability
3. Quality of Service (QoS)
4. Security

* Fault Tolerance:
- Is the kind of mechanism that make sure the network
is still active in case there is a fault in one of the
devices in the network.
- Redundant connections allow for alternative paths.

* Scalability:
- Additional providers can be added relatively easily
with no disruption of current services.
Living in a Network-centric world

* Quality of services:
- Managed by the router, ensures that priorities are
matched with the type of communication and its
importance to the user/organization.

* Priorities given in the QoS:


1. Real-time traffic (voice over IP, videoconference).
2. Transactional traffic (order processing, accounting).
3. Web content (Browsing, chopping).
4. Streaming traffic (video on demand, movies).
5. Bulk traffic (Email, data backups, Print files).

* Security:
- Involves a lot of devices and Technologies.
- Protects the confidentiality, integrity and availability
of data.
- Prevents unauthorizes access to the network.
Communicating over the
Network
* Communication methods have three things in
common:
Source (Sender) — channel (Medium ) — destination (Receiver)

* Switching Techniques:
- Switching in computer network help in deciding the
best route for data transmission if there are multiple
paths in a larges network.
- Examples: Circuit switching, Message switching, Packet
switching.

* Circuit Switching:
- A dedicated path is establishes between the sender
and receiver before data transfer.
- Example: Telephone network.

- No other device would be able to send or receive


messages on the same network.
——>
Communicating over the Network

——>
- Disadvantages of Circuit Switching:
1. Significant delays.
2. Inefficient use of the channel.
3. A lost message needs to be transmitted entirely.
* Packet Switching:
- The internet is a packet switched network.
- In this type of technique, the message is broken into
individual chunks called packets.
- Each packet is sent individually.
- Each packet will have source and destination IP
address with Sequence number.
- Sequence numbers will help the receiver to:
1. Reorder the packets
2. Detect missing packets and send acknowledgments.
- Benefits:
1. Multiplexing. 2. Reliability.
3. Alternate paths can be used.
4. Only the missing parts of the message are
retransmitted, not the entire message.
- Disadvantages:
1. Complexity.
Communicating over the Network

* End Devices:
- An end device is any device that allows us to
interface with the network.
- Workstations, servers, laptops, and printers are some
examples.
- It can be either the source or the destination of a
message.
- A host can be a client, a server or both. Depends on
the software installs on the device
- Servers: software that enables them to provide
information and services to other hosts on the
networks.
- Client: software installed that enables them to
request and display the information obtained from the
server.
Communicating over the Network

* Intermediary Devices:
- Any device that provides connectivity to the network,
connectivity to other networks or links between network
segments.
- Routers, switches, and hubs are some examples.
- It manages data as it flows through the network
- Some of their functions:
1. Direct data along alternate pathways when there is
a link failure.
2. Permit or deny the flow of data based on security
settings.
3. Notify other devices of errors and communication
failures.
Communicating over the Network

* Media:
- The medium provides the channel over which the
messages travel from source to destination.
- Examples:
1. Copper: for short distances, cheap, uses electricity.
2. Fiber Optics: for long distances, expensive, uses light.
3. Wireless.

* Local Area Network (LAN):


- An individual network usually spans a single
geographical area, providing services and applications to
people within a common organizational structure.
- Example: campus, single business.

* Wide Area Network (WAN):


- Networks that connect LANs in geographically
separated locations.
Communicating over the Network

* Internet Service Providers:


- Internet service providers (ISPs) connect their
customers to the internet through their network
infrastructures.
- The internet is a collection of ISPs co-operating with
each other to form one large converged internetwork.

* Network Representations:
- Network interface card (NIC): provides the physical
connection to the network at the PC or other host
device.
- Physical Port: a connector or outlet on a networking
device where the media is connected to a hast or other
networking device.
- Interface: specialized ports an an inter-networking
device that connect to individual networks.
Communicating over the Network

* Protocols:
- Protocols are the rules that govern communications.
1. The structure of the message.
2. The method by which networking devices share
information.
3. How and when error and system messages are passed
between devices.
4. The setup and termination of data transfer sessions.

* The OSI Model:


- The International organization for standardization
(ISO) releases the Open System Interconnection (OSI)
model.
- Breaks network communication into smaller, more
manageable parts.
- It is a descriptive scheme.
Communicating over the Network
Application Layer
Functionally and Protocols
* Application Layer:
- The applications are the interfaces between us and
networks.
- It is the top layer of the OSI and TCP/IP models.
- It is the first step for getting data an to the network.
- Application software: the program used to
communicate over the network, e.g. Microsoft Edge.

* Presentation Layer Functionality:


- Coding and conversion of application layer data.
- Compression.
- Encryption.

* Session Layer Functionality:


- Create and maintain dialogs between source and
destination application.
- Handles the exchange of information to initiate dialogs,
keep them active and restart sessions.
- Incorporated by most application.
Application Layer Functionally and Protocols

* The Applications:
- DNS (Domain Name System): translates domain names
to IP address.
- Telnet: access te servers and network devices.
- SMTP (Simple Mail Transfer Protocol): transfer of mail
messages and attachments.
- DHCP (Dynamic Host Configuration Protocol): assigns IP
addresses to the devices connected to the network.
- HTTP (Hypertext Transfer Protocol): transfer files that
make up web pages.
- FTP (File Transfer Protocol): interactive file transfer
between systems.

- Within the application layer, these are two forms of


software programs/process that provide access to the
network:
1. Applications
2. Services
- The application layer uses protocols that are
implemented within applications and services, protocols
provide the rules and formats that govern how data is
treated.
Application Layer Functionally and Protocols

* Communication Models:
- Three methods:
1. client/server model.
2. Application Layer services and protocols.
3. Peer-to-peer (P2P) networking and applications.

- The biggest disadvantage of client/server model is


the centralization of resources.
- Peer to Peer (P2P) model: two ar more computers are
connects via a network and can share resources,without
having dedicated server.
- End devices (peers) can function as either a server or a
client, depending upon the required service.
- Disadvantages:
1. It decentralizes the services.
2. Security and access policies.
3. Every server is a client and every client is a server.
Application Layer Functionally and Protocols

* Port Numbers:
- The OSI Model Transport Layer uses an addressing
scheme called a port number.
- Port numbers identify applications.
- Server programs generally use predefined port
numbers that are commonly known by clients.

* Email Services and SMTP/PoP Protocols:


- Mail User Agent (MUA) is used to compose messages.
- Also Known as an email client.
- MUA allows messages to be sent and received.
- Messages placed in the client mail box.
- Mail Transfer Agent (MTA) used to forward email.
- Mail Delivery Agent (MDA) accepts emails from the
MTA.
Application Layer Functionally and Protocols

* Telnet:
- Allows a user to remotely access another device (Host,
router, switch).
- A connection using Telnet is called a Virtual Terminal
(VTY) session of connection.
- Supports user authentication but does not encrypt
data.
- SSH protocol offers a secure method for server
access.
OSI Transport Layer
* Purpose of the Transport Layer:
- The layer 4 data stream is a logical connection
between the endpoints of a network (Applications and
network access).
- It provides transport services from host to a
destination, this service is sometimes referred to as an
end-to-end service.
- Provides two protocols:
1. TCP (Transmission Control Protocol).
2. UDP (User Datagram Protocol).

* Segmentation and Reassembly:


- The transport layer segments the data in multiple
segments.
- It provides a header to each segment, containing the
sequence number and other info about the data.
OSI Transport Layer

* Tracking Individual conversation:


- Any host can have multiple applications running
simultaneously.
- Transport layer maintains these separate data streams,
For example, it makes sure that Instant Messaging data
does not appear on the E-mail application.

* Segmentation of Data:
- A Transport layer breaks large data into smart pieces
called Segments.
- Multiplexing allows multiple concurrent applications to
run simultaneously.
- Segment/sequence numbers allow reassembly of the
data in the proper order.
- Then, the port number is used to pass the dats to the
correct application.
——>
OSI Transport Layer

——>
- Each segment is assigned a unique application
identifier (port number).
- Regulating the amount of data that can be transmitted
or received is Flow control.
- It is possible for a piece of data to become corrupted
or lost, the transport layer protocols can request a
retransmission.
- Transport layer establishes the connection before data
transfer, this is called connection oriented.

* Port Addressing:
- TCP header is 20 bytes and the UDP header is 8
bytes.
- Both TCP and UDP use port numbers to pass
information to the upper layers.
- These ports are actually termed sockets.
- A socket: the combination of the device's IP address
and the source destination port for the data, separated
by a color: 207.134.65.2:80.
- Port numbers usually distinguish the data by the type
of service.
OSI Transport Layer

* Port Addressing Types and Tools:


- Some ports are reserved in both TCP and UDP,
although applications might not be written to support
them.

* TCP and UDP:


- Different application have different requirements,
different protocols have been developed to meet them.
- Some applications may use both TCP and UDP, for
example the law overhead in UDP enables DNS to serve
many client requests very quickly.
- The key difference between TCP and UDP is the
reliability.
- TCP uses connection - oriented sessions.
OSI Transport Layer

* TCP Three way Handshake:


- Sequence numbers are used to track the order of
segments and to ensure that no segments are lost.
——> SEQ=1000 CTL=SXN ——>
SIN-Sent <—— SEQ=750 ACK=1000 <—— SYN-receives
Established ——> SEQ=1001 ACK=751 ——> Established

- The Flag fields are used to identify the type of


segment.
OSI Transport Layer

* UDP - Communicating with Low overhead:


- Connectionless, "Best Effort" delivery, low overhead,
no three-way handshake.
- Example Applications:
1. DNS 2. online Games
3. Voice overIP
4. DHCP 5. TFTP
- Connectionless: no connection establishment.
- Unreliable or "Best effort" delivery:
- No error checking.
- No flow control.
- No congestion control.
- No sequence numbers.
- UDP is said to be transaction - based, it simply sends
the data.
- The UDP protocol data unit (PDU) is referred to as a
datagram.
- If datagrams take multiple paths, they will sometimes
arrive in the wrong order since UDP does not sequence
the datagrams.
- Re-sequencing datagram and handling missing data is
up to the application.
Addressing the Network
(IPv4)
- Network is in layer 3 in the OSI model.
* Types of Addresses in IPv4:
- Network: a special address that gives the network
a name.
- Broadcast: a special address used to send data to
all hosts in a network.
- Host: the unique address assigned to each host in a
network.
- Network and Broadcast addresses cannot be assigned
to host.
* Network Address:
- Standard way to reference a network (lowest
address).
- All hosts in the network will have the same network
bits.
- Cannot be assigned to a device.
- Each host bit in this address will be 0.
Example: 192. 168 - 10 . 0
Binary: 11000000.10101000.00001010.00000000
Addressing the Network (IPv4)

* Broadcast Address:
- The destination address of a single packet used to
communicate to all hosts in a network (highest address).
- Cannot be assigned to a device.
- Each host bit in this address will be 1.
Example: 192.168.10.255
Binary: 11000000.10101000.00001010.11111111

* Host Address:
- The unique address assigned do each device on the
network.
- Assign any address between the network address
(192.168.10.0) and the broadcast address
(192.168.10.255)
Addresses: 192.168.10.1 to 192.169.10.254

- For a host to communicate directly with another host


on the same network, they must have the same network
portion.
- For every IP address range that we assign to a
network segment, we automatically lose two addresses:
1. One for the network address
2. One for the broadcast address
Addressing the Network (IPv4)

* IPv4 Classful Addressing:


First Octet Network Default No. of Host per
Class Range bits Subnet Mask Networks Network

A 0 - 127 8 255.0.0.0 128 16,777,12

B 128 - 191 16 255.255.0.0 16,384 65,539

C 192 - 223 24 255.255.255.0 2,097,152 256

* Calculating Addresses:
- To work with an IPv4 network:
- Find the network address for the host.
- Find the broadcast address for the network.
- Find the host addresses available in the network.
- Divide a larger network into smaller network.

* Basic Subnetting:
- Organizations use owned addresses (or public address)
to avaid waste of using private IP addresses.
- The large networks are broken down into smaller
networks that are more manageable segment.
- Each Segment becomes physically smaller and each
must have their own unique, logical, layer 3 network
address.
Addressing the Network (IPv4)

* Dividing networks into the right size:


- Variable Length Subnet Masking (VLSM) enables a
network number to be configured with different subnet
masks an different interfaces:
- Subnet an already subnetted network address.
- Conserves IP Addresses.
- More efficient use of available address space.

* Note: Solve all exercise on IP Addressing and Subnetting


Workbook + VLSM exercises.
• I could provide you with some solutions explained in
recorded videos.
OSI Network Layer
* Communicating from host to host:
- Devices use the transport layer to connect sessions.
- The networking layer enables devices to reach each
other.
- Routers find the best path.
- The network layer addresses packets with an IP
address.
- Routes the packet to the destination.

* Network Layre protocols:


- IPv4 (Internet Protocol version 4).
- IPv6 (Internet Protocol version 6).

* IPv4 characteristics:
- Connectionless.
- Media independent.
- "Best effort" Delivery (Unreliable):
- Means simply that IP does not have the capability
to manage and recover from undelivered or corrupt
packets.
OSI Network Layer

* Dividing Hosts Into Groups:


- As networks grow, they became too hard to manage
as an large LAN.
- The solution is to divide the large network into several
more manageable sub-networks.
- The advantages (how to do so):
1. Performance.
2. Security.
3. Address Management.

* Address Types:
1. MAC Address:
- Physical address of the host.
- Burnt in to the Network Interface card (NIC).
- Layer 2 address.

2. Network Address:
- Logical address of the host.
- Assigned by network admin.
- Layer 3 address.

——>
OSI Network Layer

——>

* Each host, two addresses, physical and logical:


- Physical:
1. Uniquely identifies the host from all other hosts on
all other networks at layer 2.
2. It is absolutely necessary to get the information
into the host.
- Logical: Uniquely identities the host and the network
to which it belongs at layer 3.

* Gateway:
- Its the way out of the local network.
- A router makes a forwarding decision for each packet
that arrives at the gateway interface.
- The destination may be one or more hops away
- Usually is the first assignable IP address in the subnet,
and it is given to the router.
OSI Network Layer

* Static Routing:
- Manually configured.
- Must know network structure.
- Every router between each source and destination
must have routes.
- Changes to the topology require static route changes.

* Dynamic Routing:
- Routing information is exchanged among the routers
using a routing protocol.
- Route always up-to-date with little administration but
creates overhead.

* Routing Protocols:
- Routing Information Protocol (RIP).
- Enhances Interior Gateway Protocol (ElGRP).
- Open shortest Path First (OSPF).
Internet Protocol
Version 6 (IPv6)
* IPv6 Addressing:

Characteristics IPv4 IPv6

x.x.x.x x:x:x:x:x:x:x:x
Format 4, 8 bits fields 8, 16 bits fields
separated by dots separated by colons

Groups of 4 Hex
Field decimal
Decimal format
representation digits, case sensitive
for A, B, 6, D, E and F

Leading zeros Omitted Optional

Successive Can be reprented by “::”


zero fields Must be included once in an address
Internet Protocol Version 6 (IPv6)

* IPv6 Representation - Rule 1:


- The leading zeroes in any 16 bits segment do not have
to be written.
Example: 2031:0000:130F:0000:0000:09C0:876A:130B
2031:0:130F:0:0:9C0:876A:130B

* IPv6 Representation - Rule 2:


- Any single, contiguous string of one or more 16 bit
segments consisting of all zeroes can be represented
once with a double colon.
Example: FE80:ACAD:0000:0197:0000:0000:0000:FF0l
FE80:ACAD:0000:197::FF0l

* IPv6 Representation:
- Prefix:
- IPv4 prefix (the network portion of the address) can
be dotted decimal or bit count:
198.10.0.0/16
- IPv6 prefix is always represented by bit count:
3ef8:ca62:12:cc::2/64
Internet Protocol Version 6 (IPv6)

* IPv6 Address Types:


- Unicast:
- Global Unicast Address.
- Link Local Unicast.
- Unique Local Unicast.
- Multicast.
- Any cast.
- Unlike IPv4, there is no broadcast address.

* Unicast Addressing:
- A unicast address is an address that identifies a
single device.
- A global unicast address is a unicast address that is
globally unique.

* Global Unicast Address:


- The host portion of the address is called the
Interface ID, can contain:
1. The interface's 48-bit MAC Address.
2. An identifier derived from the EUL-64 Address.
3. A manually configured address.
——>
Internet Protocol Version 6 (IPv6)

——>
- The address more correctly identifies an interface on
a host than a host itself.
- A single interface can have multiple IPv6 addresses,
and can have an IPv4 addsess in addition.
- Making the subnet ID a part of the network portion
creates a clear separation oF functions.
- The netwark portion provides the location of a
device down to the specific data link.
- The host portion provides the identity of the device
on the data link.

* Global Routing Prefix:


1. ICANN (Internet Corporation far Assigned Names and
Numbers):
- Manages the DNS Root zone.
- Coordinates the global IP and AS number space and
assigns them to the RIRs.

2. RIR (Regional Internet Registry):


- Overseas allocation and registration of internet
number resources within a particular region of the
world.
Internet Protocol Version 6 (IPv6)

3. LIR (Local Internet Registry):


- Usually large internet service providers.
- Received an IP address allocation from a RIR.
- May assign parts of this allocation to its own
customer or smaller ISPs.

4. ISP (Internet Service Provider):


- A company that offers its customers access to the
internet.

5. Site:
- The end-customer of an ISP.
- Can be individuals or corporation requiring internet
access.

- The ICANN and RIRs assign IPv6 prefixes (normally 23)


to the LIRs.
- The LIRs and ISPs then allocates longer prefixes to
their customers (normally 48).
Planning and cabling
Networks
* Choosing the appropriate LAN Device:
- Routers are the primary internetwork devices used
to interconnect LANs.

* Hub:
- Regenerates all signals over all ports except the
incoming port.
- All devices share bandwidth.
- Single collision domain.
- Less expensive than switches and less performance.
- Can extend the length of a cable run.

* Switch:
- Sends the frame to the correct destination port.
- Dedicated bandwidth on all ports.
- Segments a network into multiple collision domains.
- More expensive, enhanced reliability and
performance.
Planning and cabling Networks

* Device Selection Factors:


1. Cost
2. Ports
3. Speed
4. Expandable
5. Manageable
- Each type have their own advantages and disadvantages:
Cable length, cost, bandwidth, ease of installation and
susceptible to EMI or RFI.

* Cable length:
- Attenuation: The reduction of the strength of the
signal as it moves down a medium. The langer the
medium the more affect attenuation has on the signal

* Cost:
- Can vary from media type to media type.
- Match the performance needs of the users with the
cost of the equipment.
Planning and cabling Networks

* Ease of installation:
- Varies according to cable types and building
architecture (cat5 UTP, optical fiber).

* EMI /RFI:
- Electromagnetic interference (EMI) and Radio
Frequency interference (RFI) must be taken into
consideration when choosing a media type for a LAN.
- It can significantly impact data transfer, electrical
machines, lightning and power cables.

* Making LAN Connections:


- When connecting a different types of devices, use a
straight through cable.
- When connecting the same type of device, use a
crossover cable.

* Making WAN Connections:


- Data Communication Equipment (DCE): a device that
supplies the clocking (timing) services to another device.
- Data Terminal Equipment (DTE): a device that receives
clocking (timing) services from another device and
adjusts accordingly.
Planning and cabling Networks

* Device Interface:
- Cisco devices (routers and switches) have several types
of interfaces associated with them,
ethernet, serial, console, auxiliary.
- To access a network device for configuration,
troubleshooting, this can be done by connecting the
console port between the PC and the network device.

* LAN Connections:
- Devices use one of two types of UTP interfaces:
1. Media-Dependent Interface (MDI):
Transmit: Pin 1 and 2
Receive: Pins 3 and 6
(computers, servers, routers)
2. Media-Dependent Interface crossover (MDIX):
- Switch the transmit and receive pairs internally.
- Allows use of a straight through cable.
- Hubs and switches.
- Many devices will now automatically detect the cable
type and with configure the interfaces accordingly.
Introduction to Routing
and Packet Forwarding
* Router as a computer:
- Router components:
1. CPU: executes OS instructions.
2. RAM: contains the running copy of configuration
file.
3. ROM (Read-only Memory): holds diagnostic
software.
4. Non-volatile RAM (NVRAM): stores startup
configuration.
5. Flash Memory: contains the operating system (OS).
6. Interfaces: such as ethernet/FastEthernet, serial
and management interfaces.

* Router Interfaces:
- It’s a physical connector that enables a router to send
or receive packets.
- Each interface connects to a separate network.
- Examples: ethernet, FastEthernet, serial, DSL, ISDN,
cable. ——>
Introduction to Routing and Packet Forwarding

——>
- Two major groups of router interfaces:
1. LAN interfaces:
- Used to connect router to LAN network.
- Has a layer 2 MAC address.
- Can be assigned a Layer 3 IP address.
- usually consist of an Rj-45 jack.
2. WAN Interfaces:
- Used to connect routers to external networks that
interconnect LANs.
- A layer 2 address may be used.
- Uses a layer 3 IP address.

* Static Route:
- Static routes are added by the administrator of the
network.
- The more routers are there, the more static routes
need to be created.
- When to use?
1. When a network only consist of a few routers.
2. Network is connected to internet only through one
ISP.
Introduction to Routing and Packet Forwarding

* Dynamic Route:
- Used to add remote networks to routing tables.
- Used to discover networks.
- Used to up date and maintain routing tables.
- Routers are able to discover new networks by sharing
routing table information.
ElGRP Summary
- EIGRP (Enhanced Interior Gateway Routing Protocol)
- Exclusive only on Cisco devices.
- Metric: Delay, bandwidth, reliability, and load using the
Distrusting Update Algarithm (DUAL).
- Weakness: Not an internet standard, all routers must
be from Cisco Systems.

* Autonomous System (AS):


- An autonomous system is a collection of networks under
the administrative control of a single entity. Used by 1SPs,
Internet Backbone Providers, Large institution.
- All routers in an ElGRP routing domain must use the
same autonomous system number.

* Note: all commands will be on a separate sheet.


Open Shortest Path
First (OSPF)
* Introduction to OSPF:
- OSPF V2, where v1 was never implemented.
- Type of protocol: Link-state.
- Metric: calculates the cost to traverse router links to
get to the destination, taking the bandwidth of the links
into accounts.
- Origin: based on RFC 2328.
- Ideal topology: any network, either small or large.
- Strengths:
1. Converges quickly.
2. Scales very well to large networks.
3. Supports VLSM or CIDR.
- Weakness:
1. More complex to configure and understand.

* Administrative Distance (AD):


- It is the trustworthiness of the route source.
- The lowest AD is used first (The less the better).
Open Shortest Path First (OSPF)

* Verifying OSPF:
- Two routers may not form an OSPF, if:
1. The subnet masks does not match.
2. OSPF Hello or Dead timers do not match.
3. OSPF network types does nat match.
4. Missing or incorrect OSPF network command.

* How Does OSPF Work?


- It’s a link-state routing protocol, which makes the
routing decisions based on the state of the links that
connect source and destination devices.
- OSPF routers generates routing updates only when a
change occurs in the network topology.
- OSPFv2 is used to advertise IPv4 routes, and OSPFv3
is used to advertise IPv6 routes.

* Note: all commands will be on a separate sheet.


Wish you all the best in your
studies!
Fatema Habib
[email protected]

You might also like