ip routing & switching basics module - 1
TRANSCRIPT
-
8/8/2019 IP Routing & Switching Basics Module - 1
1/55
IP Routing & SwitchingBasicsModule - 1
By: Muhammad AhsanKhan
-
8/8/2019 IP Routing & Switching Basics Module - 1
2/55
Session Details:
Theory :
TCP/IP Concepts
IP Addressing
Sub-netting
NAT/PATIP Routing concepts (Static , Dynamic)
RIP
GRE/IPSec
-
8/8/2019 IP Routing & Switching Basics Module - 1
3/55
TCP/IP Concepts
-
8/8/2019 IP Routing & Switching Basics Module - 1
4/55
OSI
Open Systems Interconnection
Developed by the International
Organization for Standardization (ISO)Seven layers
A theoretical system
TCP/IP is the de facto standard
-
8/8/2019 IP Routing & Switching Basics Module - 1
5/55
OSI - The Model
A layer model
Each layer performs a subset of the
required communication functionsEach layer relies on the next lower layer toperform more primitive functions
Each layer provides services to the nexthigher layer
Changes in one layer should not requirechanges in other layers
-
8/8/2019 IP Routing & Switching Basics Module - 1
6/55
66
OSI Layers
It is use to guide productimplementers so that theirproducts will consistently workwith other products.
-
8/8/2019 IP Routing & Switching Basics Module - 1
7/55
The OSI Environment
-
8/8/2019 IP Routing & Switching Basics Module - 1
8/55
TCP/IP ProtocolArchitecture
Developed by the US DefenseAdvanced Research Project Agency
(DARPA) for its packet switchednetwork (ARPANET)
Used by the global Internet
No official model but a working one.Application layer
Host to host or transport layer
-
8/8/2019 IP Routing & Switching Basics Module - 1
9/55
Physical Layer
Physical interface between datatransmission device (e.g. computer)
and transmission medium or networkCharacteristics of transmissionmedium
Signal levelsData rates
etc.
-
8/8/2019 IP Routing & Switching Basics Module - 1
10/55
Network Access Layer
Exchange of data between end systemand network
Destination address provisionInvoking services like priority
-
8/8/2019 IP Routing & Switching Basics Module - 1
11/55
Internet Layer (IP)
Systems may be attached to differentnetworks
Routing functions across multiplenetworks
Implemented in end systems and
routers
-
8/8/2019 IP Routing & Switching Basics Module - 1
12/55
Transport Layer (TCP)
Reliable delivery of data
Ordering of delivery
-
8/8/2019 IP Routing & Switching Basics Module - 1
13/55
Application Layer
Support for user applications
e.g. http, SMPT
-
8/8/2019 IP Routing & Switching Basics Module - 1
14/55
OSI v TCP/IP
-
8/8/2019 IP Routing & Switching Basics Module - 1
15/55
TCP
Usual transport layer is Transmission Control Protocol
Reliable connection
Connection
Temporary logical association between entities in different systems
TCP PDU
Called TCP segment
Includes source and destination port (c.f. SAP)
Identify respective users (applications)
Connection refers to pair of ports
TCP tracks segments between entities on each connection
-
8/8/2019 IP Routing & Switching Basics Module - 1
16/55
UDP
Alternative to TCP is User DatagramProtocol
Not guaranteed deliveryNo preservation of sequence
No protection against duplication
Minimum overhead
Adds port addressing to IP
-
8/8/2019 IP Routing & Switching Basics Module - 1
17/55
TCP and UDP Headers
-
8/8/2019 IP Routing & Switching Basics Module - 1
18/55
IP and IPv6
IP (v4) header minimum 20 octets (160bits)
32-bit source and destinationaddresses
Checksum applies to header to avoidincorrect delivery
Protocol field shows if TCP, UDP etc.carried
Flags and fragmentation offset used infragmentation
-
8/8/2019 IP Routing & Switching Basics Module - 1
19/55
IPv4 Header
-
8/8/2019 IP Routing & Switching Basics Module - 1
20/55
TCP/IP Concepts
-
8/8/2019 IP Routing & Switching Basics Module - 1
21/55
2121
Action of
Sender
-
8/8/2019 IP Routing & Switching Basics Module - 1
22/55
Action of Router
-
8/8/2019 IP Routing & Switching Basics Module - 1
23/55
2323
Action ofReceiver
-
8/8/2019 IP Routing & Switching Basics Module - 1
24/55
IP Addressing
-
8/8/2019 IP Routing & Switching Basics Module - 1
25/55
An IP (Internet Protocol) address is aunique identifier for a node or hostconnection on an IP network.
An IP address is a 32 bit binary numberusually represented as 4 decimal values,
each representing 8 bits, in the range 0 to255 (known as octets) separated bydecimal points. This is known as "dotteddecimal notation.
-
8/8/2019 IP Routing & Switching Basics Module - 1
26/55
Address Classes
There are 5 different address classes.You can determine which class any IPaddress is in by examining
the first 4 bits of the IP address.
Class A addresses begin with0xxx, or 1 to 126 decimal.
Class B addresses begin with10xx, or 128 to 191 decimal.
-
8/8/2019 IP Routing & Switching Basics Module - 1
27/55
-
8/8/2019 IP Routing & Switching Basics Module - 1
28/55
Subnetting
Subnetting an IP Network can be donefor a variety of reasons, includingorganization, use of different
physical media (such as Ethernet,FDDI, WAN, etc.), preservation ofaddress space, and security. The
most common reason is to controlnetwork traffic. In an Ethernetnetwork, all nodes on a segment seeall
-
8/8/2019 IP Routing & Switching Basics Module - 1
29/55
Subnet Masking
Applying a subnet mask to an IPaddress allows you to identify thenetwork and node parts of the address.Performing a bitwise logical ANDoperation between the IP address andthe subnet mask results in the Network
Address or Number.
For example, using our test IP addressand the default Class B subnet mask,
we get:
-
8/8/2019 IP Routing & Switching Basics Module - 1
30/55
NAT/PAT
-
8/8/2019 IP Routing & Switching Basics Module - 1
31/55
Network AddressTranslation (NAT)In computer networking, network address translation (NAT) isthe process of modifying network address information in datagram(IP) packet headers while in transit across a traffic routing devicefor the purpose of remapping one IP address space into another.
Most often today, NAT is used in conjunction with networkmasquerading (or IP masquerading) which is a technique thathides an entire IP address space, usually consisting ofprivatenetwork IP addresses (RFC 1918), behind a single IP address inanother, often public address space. This mechanism isimplemented in a routing device that uses shameful translation
tables to map the "hidden" addresses into a single IP address andthen readdresses the outgoing Internet Protocol (IP) packets on exitso that they appear to originate from the router. In the reversecommunications path, responses are mapped back to theoriginating IP address using the rules ("state") stored in thetranslation tables. The translation table rules established in this
fashion are flushed after a short period without new trafficrefreshing their state.
-
8/8/2019 IP Routing & Switching Basics Module - 1
32/55
Basic NAT and PAT
There are two levels of network addresstranslation.
Basic NAT: This involves IP addresstranslation only, not port mapping.
PAT (Port Address Translation). Alsocalled simply "NAT" or "Network Address
Port Translation, NAPT". This involves thetranslation of both IP addresses and portnumbers.
All Internet packets have a source IP
-
8/8/2019 IP Routing & Switching Basics Module - 1
33/55
Benefits
The primary benefit ofIP-masquerading NAT is thatit has been a practical solution to the impendingexhaustion of IPv4 address space. Even largenetworks can be connected to the Internet with as
little as a single IP address. The more commonarrangement is having machines that require end-to-end connectivity supplied with a routable IP address,while having machines that do not provide services tooutside users behind NAT with only a few IP addressesused to enable Internet access.
Some[have also called this exact benefit a majordrawback, since it delays the need for theimplementation of IPv6, quote:
"
-
8/8/2019 IP Routing & Switching Basics Module - 1
34/55
IP Routing
-
8/8/2019 IP Routing & Switching Basics Module - 1
35/55
Why Routing?
-
8/8/2019 IP Routing & Switching Basics Module - 1
36/55
Routed vs Routing
Routed Protocol:
IP, IPX.
Routing Protocol:
RIP, EIGRP, OSPF, BGP.
-
8/8/2019 IP Routing & Switching Basics Module - 1
37/55
Static/Dynamic Routing
Static
Simple
Doesnt provide optimal routing andfast convergence (*IP SLA)
Dynamic
More Complex
Provide optimal routing and fast
convergence dynamically
l f l d l l
-
8/8/2019 IP Routing & Switching Basics Module - 1
38/55
Classful and Classless
Classful:
Follows bit boundaries of Class A,BandC
Routing Protocols:
RIP, EIGRP
Example: If we configured 10.10.100.0/24, it would
advertise it as a CLASS A (10.0.0.0/8) address.
Classless:
d i i i i
-
8/8/2019 IP Routing & Switching Basics Module - 1
39/55
Administrative Distance(AD)
Used to determine which routing protocolwould inject best route in the Routing Table.
Lowest Administrative Distance between two
routing protocols would WIN.
Protocol AD:
If EIGRP & OSPF both learning 10.10.100.0/24,
preference would be given to?
T f D i
-
8/8/2019 IP Routing & Switching Basics Module - 1
40/55
Types of DynamicRouting
Distance Vector
Advertise full routing table, no
neighbor or topology table.Example: Appletalk RTMP, IPX RIP, IPRIP , IGRP
Link State
Maintain neighbor and topology table
Advertise routing table
-
8/8/2019 IP Routing & Switching Basics Module - 1
41/55
Routing InformationProtocol (RIP)
R ti I f ti
-
8/8/2019 IP Routing & Switching Basics Module - 1
42/55
Routing InformationProtocol (RIP)
The Routing Information Protocol(RIP) is a dynamic routing protocolused in local and wide area networks.
Interior Gateway Protocol (IGP)
RIP Version 1 - RFC 1058 (1988)
RIP Version 2 (RFC 2453)
RIP v1 / RIP v2 (Classful/Classless)
RIP has also been adapted for use in
T h i l D t il
-
8/8/2019 IP Routing & Switching Basics Module - 1
43/55
Technical Details
Routing Type: Distance Vector
Algorithm : Bellman Ford
Metric: HOPS (hop count as a routing metric)
Hop Limits: 15
Updates: Send full updates after every 30 seconds.
Administrative Distance: 120
Other: Routing Table Symbol (R)
T h i l D t il
-
8/8/2019 IP Routing & Switching Basics Module - 1
44/55
Technical Details(contd)
The maximum number of hops allowedfor RIP is 15. This hop limit, however,also limits the size of networks that RIPcan support
A hop count of 16 is considered aninfinite distance and used to deprecateinaccessible, inoperable, or otherwiseundesirable routes in the selectionprocess.
RIP im lements the s lit horizon
S lit H i
-
8/8/2019 IP Routing & Switching Basics Module - 1
45/55
Split Horizon
split-horizon route advertisementis a method of preventing routing loopsin distance-vector routing protocols byprohibiting a router from advertising aroute back onto the interface fromwhich it was learned.
C fi i RIP
-
8/8/2019 IP Routing & Switching Basics Module - 1
46/55
Configuring RIP
RIP Detailed configuration will becovered in LAB, some basiccommands:
RIP F t S
-
8/8/2019 IP Routing & Switching Basics Module - 1
47/55
RIP Feature Summary
-
8/8/2019 IP Routing & Switching Basics Module - 1
48/55
Generic RoutingEncapsulation (GRE)
-
8/8/2019 IP Routing & Switching Basics Module - 1
49/55
St t f GRE
-
8/8/2019 IP Routing & Switching Basics Module - 1
50/55
Structure of a GREEncapsulated Packet
GRE Header
-
8/8/2019 IP Routing & Switching Basics Module - 1
51/55
GRE Header
Checksum Present (bit 0)If the Checksum Present bit is set to one, then the Checksum and the
Reserved1 fields are present and the Checksum field contains validinformation. Note that a compliant implementation MUST accept andprocess this field.Reserved0 (bits 1-12)A receiver MUST discard a packet where any of bits 1-5 are non-zero,unless that receiver implements RFC 1701. Bits 6-12 are reserved for
future use. These bits MUST be sent as zero and MUST be ignored onreceipt.Version Number (bits 13-15)The Version Number field MUST contain the value zero.Protocol Type (2 octets)The Protocol Type field contains the protocol type of the payload packet.
These Protocol Types are defined in [RFC1700] as "ETHER TYPES" and inETYPES . An im lementation receivin a acket containin a Protocol
-
8/8/2019 IP Routing & Switching Basics Module - 1
52/55
Checksum (2 octets)The Checksum field contains the IP (one's complement) checksum sum ofthe all the 16 bit words in the GRE header and the payload packet. Forpurposes of computing the checksum, the value of the checksum field iszero. This field is present only if the Checksum Present bit is set to one.Reserved1 (2 octets)The Reserved1 field is reserved for future use, and if present, MUST betransmitted as zero. The Reserved1 field is present only when theChecksum field is present (that is, Checksum Present bit is set to one).IPv4 as a PayloadWhen IPv4 is being carried as the GRE payload, the Protocol Type fieldMUST be set to 0x800.
Why GRE?
-
8/8/2019 IP Routing & Switching Basics Module - 1
53/55
Why GRE?
Configuring GRE
-
8/8/2019 IP Routing & Switching Basics Module - 1
54/55
Configuring GRE
Will be covered in LAB session
Topics will be covered in
-
8/8/2019 IP Routing & Switching Basics Module - 1
55/55
Topics will be covered inModule - 2
VLAN
Trunking
Switching in CYBERNET