View
141
Download
0
Category
Tags:
Preview:
Citation preview
CCNA
SUBMITTED IN PARTIAL FULFILLMENT OF THE REQUIREMENT FOR
Six Week/Month Industrial Training
at
Chandigarh
from 11 July to 25 August
Submitted by
Name-Minakshi Chaudhary Roll no. – 5508023
S.D.D.GLOBAL INSTITUTE OF ENGG. & TECHNOLOGY
BARWALA(PANCHKULA), INDIA
CERTIFICATE
I hereby certify that “…………….” Roll No. ……………..of ……………
Institute of Engg. and Techonlogy……city……., has undergone six
month industrial training from……………. at our organization to fulfill
the requirements for the award of degree of B.Tech. (Branch).He/She
works on networking project during the training under the supervision
of Mr. Sumit Malhotra. During his tenure with us we found him sincere
and hard working. We wish him a great success in the future.
Acknowledgement_______________________________________________
I would like to thank the …………Principal, ………Institute of engg. and Technolody …..city…… for providing this opportunity to carry out the six month/week industrial training in ZCC Institute, Chandigarh.
The constant guidance and encouragement received from Mr. …….T&P, …city……. has been of great help in carrying out the project work and is acknowledged with reverential thanks.
I would like to express a deep sense of gratitude and thanks profusely to Mr. Balbir Singh centre head of Institute. Without the wise counsel and able guidance, it would have been impossible to complete the report in this manner.
I would like to thank the project coordinator Mr.Sumit Malhotra for providing all the material possible and encouraging throughout the course. It is great pleasure for me to acknowledge the assistance and contributions for his prompt and timely help in the official clearances and valuable suggestions during the development of this project
Last but not least, I express my heartiest gratitude to Almighty god, our Parents for their love and blessings to complete the project successfully.
About ZCC
SCO. 94-95, 4th FloorSec. 34 A Chandigarh,
Phone: 0172-2646400, 5087637Website. Zccindia.com, Email: info@zccindia.com
ZCC (Zealous Computer Centre) was established on 1st July 2001. It offers higher education in computer Hardware and Networking and also provides coaching in International certifications like A+, MCSE, CCNA, Linux Operating System.
ZCC also provides training of international standards. ZCC institute's own placement cell assures quality placement on local, national, and international level to good performer. ZCC Institute has 100% placement record in different companies like HCL, Targus, Wipro, Allegers and Tulip IT etc. Our primary focus is on providing quality education to our Students and provide better placement.
The vision of the ZCC Program is to provide students with knowledge and experience that adds value to computer education and Information Technologies through research, product development, and applicationof current tools to solving educational problems
Our philosophy is different from our competitors We don't believe in “watch me do this “training. - We believe in active learning. We make every minute of training relevent to the student. Classes are small, hence effective. Training is interactive. Instructors bring real-world experience to the classroom, using easy methods. Sometimes even humour is used to help students cut through foreign terms and get a full hands-on experience.
As a result, -- our classes simplify technical education; students learn faster and retain more.
AAIT
Auscan Academy of Information Technology Pvt. Ltd. is an ISO 9001:
2000 Certified Institute and also a unit of “ZCC Institute” Chandigarh-
INDIA. ZCC institute was established in 2001 to facilitate a common
computational resource centre for the academic programs. Auscan
Academy group is a distinctive, highly professional Computer
Educational organization, engaged in career counseling and providing
most authentic, prompt and highly reliable information to the students
in the IT. Auscan Academy has many franchisees in Himachal Pradesh
and running successfully. The main reason to open AAIT Institute at
different places is to provide education in remote areas where students
are unable to get good education like other advance places. AAIT has
its own placement cell which helps the students to provide them better
placement and secure their future.
CONTENTS
Description
Acknowledgement
Executive summary
Contents
Routing Protocol
Static Routing
Default Routing
Dynamic Routing
RIP
RIPv2
IGRP
EIGRP
OSPF
Switch
IP Addresses
Administrator model for networking Server software: - which software is used to giving services that are server software.Client software: - which gets services. Apache, Internet Explorer, IIS, Outlook Express,
Exchange 2003, Yahoo messenger, FTP Server, Cute FTP Send Mail
Server Software
Client Software
P R O T O C O L Stack
P R O T O C O L Stack
NIC NIC Media Media
TCP/IP, IPX/SPX, AppleTalk, Netbeui
If NIC are different then use bridge. If media is different then use Trans-Receive devices.
(i) Implementation and troubleshooting of network will be easy.
OSI Model
OSI model is the layer approach to design, develop and implement network. OSI provides following advantages: -
(ii) Designing of network will be standard base.(iii) Development of new technology will be faster.(iv) Devices from multiple vendors can communicate with each other.
Software
Application Layer
Presentation Layer
Session Layer
Transport Layer
Network Layer
Data Link Layer
Physical Layer
Protocol Stack
NIC
Media
(1)Application Layer: -Application layer accepts data and forward into the protocol stack. It creates user interface between application software and protocol stack.
(2)Presentation Layer: -This layer decides presentation format of the data. It also able to performs other function like compression/decompression and encryption/decryption.
(3)Session Layer: -This layer initiate, maintain and terminate sessions between different applications. Due to this layer multiple application software can be executed at the same time.
(4)Transport Layer: -Transport layer is responsible for connection oriented and connection less communication. Transport layer also performs other functions like
(i) Error checking(ii) Flow Control
BufferingWindowingMultiplexing
(iii) Sequencing(iv) Positive Acknowledgement
(v) Response
Connection Oriented Communication
Request for synchronize VirtualConnection NegotiationOrHandshaking Acknowledgement
Send
Send
Data AcknowledgementTransfer
Send
Acknowledgement
TerminateOr
Connection less Communication
Send
(i) Error checkingTransport layer generates cyclic redundancy check (CRC) and forward the CRC value to destination along with data. The other end will generate CRC according to data and match the CRC value with received value. If both are same, then data is accepted otherwise discard.
(ii) Flow ControlFlow control is used to control the flow of data during communication. For this purpose following methods are used: -(a) Buffer
Buffer is the temporary storage area. All the data is stored in the buffer memory and when communication ability is available the data is forward to another.
(b) Windowing
Sender Receiver
Sender Receiver
Windowing is the maximum amounts of the data that can be send to destination without receiving Acknowledgement. It is limit for buffer to send data without getting Acknowledgement.
(c) MultiplexingMultiplexing means combining small data segment, which has same destination IP and same destination service.
(iii) SequencingTransport layer add sequence number to data, so that out of sequence data can be detected and rearranged in proper manner.
(iv) Positive Acknowledgement and ResponseWhen data is send to destination, the destination will reply with Acknowledgement to indicate the positive reception of data. If Acknowledgement is not received within a specified time then the data is resend from buffer memory.
(5)Network LayerThis layer performs function like logical addressing and path determination. Each networking device has a physical address that is MAC address. But logical addressing is easier to communicate on large size network.
Logical addressing defines network address and host address. This type of addressing is used to simplify implementation of large network. Some examples of logical addressing are: - IP addresses, IPX addresses etc. Path determinationNetwork layer has different routing protocols like RIP, EIGRP, BGP, and ARP etc. to perform the path determination for different routing protocol.
Network layer also perform other responsibilities like defining quality of service, fragmentation and protocol identification.
(6)Data Link LayerThe functions of Data Link layer are divided into two sub layers
(i) Logical Link Control(ii) Media Access Control
(i) Logical Link Control defines the encapsulation that will be used by the NIC to delivered data to destination. Some examples of Logical Link Control are ARPA (Ethernet), 802.11 wi-fi.
(ii) Media Access Control defines methods to access the shared media and establish the identity with the help of MAC address. Some examples of Media Access Control are CSMA/CD, Token Passing.
(7)Physical Layer
Physical Layer is responsible to communicate bits over the media this layer deals with the standard defined for media and signals. This layer may also perform modulation and demodulation as required.
Data EncapsulationData
Application Layer Data*Physical Layer Data**Session Layer Data***Transport Layer Transport Header | Data = SegmentNetwork Layer Network Header | Segment = PacketData Link Layer Header | Packet | Trailer = FramePhysical Layer 1 0 = Bits
Data => Segment => Packet => Frames => Bits
Devices at different Layers
Physical Layer DevicesHub, Modem, Media, DCE (Data comm. Equipment), CSU/DSU, Repeater, Media converter
DCE CSU | DSU
DTE
Channel Service Unit Data Service Unit
Data Terminal Equipment
Data Link LayerNIC, Switch, Bridge
R
Network Layer DeviceRouter, Layer 3 Switch
All Layers DevicePC, Firewall
DCE: - DCE convert the bits into signal & send them on media.FDDI – Fiber Distributed Data InterfaceSwitch forwards frames on the base of MAC address.Router forwards packets on the base of IP address.
LAN Technologies
10 – 10000 mbps 4 – 16 mbps 4 – 16 mbps 1 – 108 mbps100 m 100m up to 2 km up to 40 km
Ethernet Ethernet is the most popular LAN technology. It can support verity of media like copper (UTP, Coaxial, fiber optic). This technology supports wide range of speed from 10mbps to 10000 mbps.
Ethernet at Logical Link ControlTo create logical link control Ethernet uses ARPA protocol also called IEEE802.3. Ethernet adds source MAC, destination MAC, error checking information and some other information to data. Ethernet encapsulation explain as follows
1010101010..10 10101011
Ethernet at Media Access ControlEthernet at Media Access Control layer uses CSMA/CD protocol to access the shared media.
LAN
Ethernet Token Ring FDDI Wi-Fi
Preamble start frame Destination Source MAC Length Data up to Frame 64 Delimiter 8 MAC 48 16 1500 bytes Check
48 Sequence49 16
In these days, we use Ethernet with switches and in switches the technology is made CSMA/CA (Collision Avoidance). So this reason Ethernet is best compare with Token Ring, FDDI & Wi-Fi.
Yes
No
No
Yes
Back off AlgorithmThis algorithm runs when a collision created.
Sense the carrier
Is carrier busy?
Do we have any data to communicate?
Send data over media
Receive data
Detect the Collision
Stop transmitting receiving data
Generate a random Number
Try to communicate after delay X r.no.
Ethernet Family
Speed Base band10 Base 2 200-meter Coaxial cable10 Base 5 500-meter Thick Coaxial cable10 Base T 100 meter Twisted Pair (UTP)10/100(present) Base TX 100 meter UTP100 Base T4 100 meter UTP 4 Pairs used100 Base FX up to 4 kms Fiber Optic1000(Server) Base TX 100 meter UTP1000 Base FX up to 10 kms Fiber Optic10000 Base FX Fiber Optic
Ethernet framePreamble An alternating 1,0 pattern provides a 5MHz clock at the start of each packet, which allows the receiving devices to lock the incoming bit stream.
Start Frame Delimiter (SFD)/Synch The preamble is seven octets and the SFD is one octet (synch). The SFD is 10101011, where the last pair of 1s allows the receiver to come into the alternating 1,0 pattern somewhere in the middle and still sync up and detect the beginning of the data.
Length or type 802.3 uses a length field, but the Ethernet frame uses a type field to identify the network layer protocol. 802.3 cannot identify the upper-layer protocol and must be used with a proprietary LAN-IPX, for example
Ethernet Cabling
Coaxial cablingRequirement: -T connector, Terminator, BNC connector, Coaxial cable, 10 base2 lan cards
T Connector BNC
Terminator LAN card
This is used by BUS topology with 10 mbs Base 2 and Base 5. it is not used currently.
UTP CablingIn the UTP, we have used different topology to create the network.
(1)
PC PC
In any Ethernet UTP topology we have to use one of the two types of cables(1) Straight cable(2) Cross cable
TXRX
Structure CablingRequirement: -Rack, patch panel, Switch/ Hub( Rack Mounable), patch cord, I/O connector, I/O box, UTP cableTool: - Punching tool
Problems of Ethernet technology(3) In Ethernet only one pc is able to send data at a time, due to this the bandwidth of
Ethernet will be shared.(4) Not an equal access technology.(5) One pc will send data, which will be received by the all devices of network. Due
to this data communication will not be secured.(6) Collision will occur in the network and collision will lead to other problems like
latency, delay and reduce throughput.Latency – time duration to send packet from start to end.Throughput – speed to send data (output)
(7) All PCs will have single broadcast domain. Due to this the bandwidth will be reduced.
EMI – Electro Magnetic Indication
Hub / Switch
LAN Segmentation of Ethernet Network
There are three methods to perform LAN segmentation (1) LAN segmentation using bridge.(2) LAN segmentation using switches.(3) LAN segmentation using Routers.
LAN segmentation using bridge.Existing
New
Port1 Port3
Port2
1st collision domain 2nd collision domain 3rd collision domain
1 broadcast domain
Working of Bridge: -Working of Bridge explains in following steps: -
(i) Bridge can receives a frame in the buffer memory.(ii) The source MAC address of frame this stored to the bridging table.
Port number MAC address123
(iii) According to the destination MAC address the frame will be forwarded or drop
Hub Hub Hub
Bridge
Hub Hub Hub
(a) If destination MAC address of the frame is known then frame is forwarded to the particular port.
(b) If destination MAC address is unknown by bridging table then frame is forwarded to the all port except receiving port.
(c) If destination MAC address is broadcast MAC address ff.ff.ff.ff.ff.ff.(d) If destination MAC address exists on the same port from which port
received then frame is dropped.
Collision domainA group of pc, in which collision can occur, is called a collision domain.
Broadcast domainA group of pc in which broadcast message is delivered is called broadcast domain.
LAN segmentation using SwitchesDue to perform Lan segmentation using switches. We have to remove hubs from the network and replace hub with switches the working of switches. The working of switch is exactly like a bridge. A multiport bridge can be used as a bridge.
1 broadcast domainCollision domain = micro segmentation
Switch’s working is same like bridgeAdvantages: -
(1) Bandwidth will not be shared and overall throughput will depend on wire speed of the switch. Wire speed is also called switching capacity measured in mbps or gbps.
Minimum port on switches = 4Maximum port on switches = 48
(2) Any time access technology.(3) One to one communication so that network will be more secures.(4) Switches will perform micro segmentation and no collision will occur in
network.
Lan segmentation using routerIf we are facing high concession in the n/w due to the large number of broadcast then we can divide broadcast domain of network. So that number of broadcast message will be reduced.Exist: -
Switch Switch Switch
New: -
1st Broadcast Domain 2nd Broadcast Domain 3rd Broadcast DomainRouter is unicast.We have to install router between multiple switches to divide the broadcast domain. Each broadcast domain has to used different network address and router will provide inter network communication between them.
Router operation When a pc has to send data to a different network address, then data will be forwarded to the router. It will analysis IP address of the data and obtain a route from the routing table. According to the route data will be dropped, If route not available.
Pc Architecture
Switch | Hub Switch | Hub Switch | Hub
Switch | Hub Switch | Hub Switch | Hub
I/OController
K/BController
Keyboard
DisplayCard
V.D.U
SerialParallelUSB
SoundCard
Processor
RAM
Memory controller
BIOSROM
CMOSRAM
HDD FD CDD
Router Architecture
Incomplete IOS
IOS
Startup Configuration
Non-Volatile RAM
(1) ProcessorSpeed: - 20 MHz to 1GHzArchitecture: - RISC
Reduce Instruction set computerManufacturers: - Motorola, IBM, Power PC, Texas, Dallis, Intel.
(2) Flash RAMFlash Ram is the permanent read/write memory. This memory is used to store one or more copies of router o/s. Router o/s is also called IOS (Internetwork Operating System).
Processor
Memory Controller
BIOS ROM
NVRAM
RAM
Flash RAM O/S
I/O Controller
LAN
WAN
Ports
Flash Ram stores the only o/s.The size of flash ram in the router is 4mb to 128mb. The flash ram may be available in one of the following three packages: -SLMM Flash: - Single Line Memory ModulePCMCIA Flash: - Personal Computer Memory Card Interface ArchitectureCompact Flash: - (Small Memory)
(3) NVRAMNVRAM is a “Non Volatile Random Access Memory”. It is used to store the configuration of the Router. The size of NVRAM is 8 KB to 512 KB.
(4) RAMRam of the router is divided into two logical parts.
(i) Primary RAM(ii) Shared RAM
Primary RAMPrimary RAM is used for: -(a) Running copy of IOS.(b) Running configuration(c) Routing table(d) ARP table (IP address to MAC address)(e) Processor & other data structure
Shared RAMShared RAM is used as a buffer memory to shared the data received from different interfaces. Size of ram in a router may vary from 2 mb to 512 mb. The types of memory that may be present in a ram are: -(a) DRAM -> Dynamic RAM(b) EDORAM -> Extended Data Out Ram(c) SDRAM -> Synchronous Dynamic Ram
(5) BIOS ROMThe BIOS ROM is the permanent ROM. This memory is used to store following program & Routines: -
(i) Boot strap loader (doing booting)(ii) Power on self test routines(iii) Incomplete IOS(iv) ROM Monitor (ROM-MON)
Booting difference between router & PcRouter PC
ROM-MON CMOS Setup
Incomplete IOS Bootable Floppy/CDFLASH O/S from HDD
Router Interfaces & Ports
Interface is used to connect LAN networks or wan networks to the router. Interface will use protocol stacks to send/receive data. Ports are used for the configuration of routers. Ports are not used to connect different n/ws. The primary purpose of port is the management of router.
Router InterfacesInterface Connector color Speed UseEthernet RJ45 yellow 10 mbps to connect Ethernet LAN
Using UTP mediaAUI DB15 yellow 10 mbps to connect Ethernet LAN
Using Trans-Receiver Fast Ethernet RJ45 yellow 100 mbps to connect Ethernet LANSerial DB60 blue E1-2 mbps to connect WAN
T1-1.5 mbps Technology like Leased Lines, Radio link, Frame Relay, X.25, ATM
Smart Serial SS blue “ “BRI ISDN RJ45 orange 192 kbps to connect ISDN Basic Rate InterfaceVOIP RJ11 white - to connect Phones, Fax,
EPABX
AUI – Attachment Unit InterfaceEPABX – Electronic Private Automatic BranchPSTN – Public Services Telephone Network
Router PortsPort Connector Color Speed DetailsConsole RJ45 sky blue 9600bps used for configuration
Using PCAuxiliary RJ45 black depend on to connect remote Modem router using PSTN lineVirtual terminal - - - to connect remote router Vty with telnet protocol via interface
Types of routers:-(1) Fixed configuration router(2) Modular router(3) Chassis based router
Other interfaces:-(1) Token Ring RJ45 Violet 4/16 mbps
To connect Token Ring network.(2) E1/T1 controller RJ45 White E1-2048 kbps
T1-1544 kbps(3) ADSL RJ11 - up-640 kbps (Asynchronous Digital Subscriber Line) Down-8 mbps
Router Access ModesWhen we access router command prompt the router will display different modes. According to the modes, privileges and rights are assigned to the user.
User modeIn this mode, we can display basic parameter and status of the router we can test connectivity and perform telnet to other devices. In this mode we are not enable to manage & configure router.
Privileged modeIn this mode, we can display all information, configuration, perform administration task, debugging, testing and connectivity with other devices. We are not able to perform here configuration editing of the router.
The command to enter in this mode is ‘enable’. We have to enter enable password or enable secret password to enter in this mode. Enable secret has more priority than enable password. If both passwords are configured then only enable secret will work.
Global configurationThis mode is used for the configuration of global parameters in the router. Global parameters applied to the entire router.For e.g: - router hostname or access list of routerThe command enter in this mode is ‘configure terminal’.
Line configuration modeThis mode is used to configure lines like console, vty and auxiliary. There are main types of line that are configured.
(i) Console Router (config)#line console 0
(ii) Auxiliary Router (config)#line aux 0
(iii) Telnet or vty Router (config)#line vty 0 4
Interface configuration modeThis mode is used to configure router interfaces. For e.g:- Ethernet, Serial, BRI etc. Router(config)#interface <type> <number>
Router(config)#interface serial 1
Routing configuration modeThis mode is used to configure routing protocol like RIP, EIGRP, OSPF etc.
Router(config)#router <protocol> [<option>]
Router(config)#router ripRouter(config)#router eigrp 10
Configuring PasswordThere are five types of password available in a router
(1) Console Password router#configure terminal router(config)#line console 0 router(config-line)#password <word> router(config-line)#login router(config-line)#exit
to erase password do all steps with no command.
(2) Vty Passwordrouter>enablerouter#configure terminalrouter(config)#line vty 0 4router(config-line)#password <word>router(config-line)#loginrouter(config-line)#exit
(3) Auxiliary Password
router#configure terminalrouter(config)#line Aux 0router(config-line)#password <word>router(config-line)#loginrouter(config-line)#exit
(4) Enable Passwordrouter>enablerouter#configure terminalrouter(config)#enable password <word>router(config)#exit
(5) Enable Secret PasswordEnable Password is the clear text password. It is stored as clear text in configuration where as enable secret password is the encrypted password with MD5 (Media Digest 5) algorithm.
Router>enableRouter#configure terminalRouter(config)#enable secret <word>Router(config)#exit
Encryption all passwordsAll passwords other than enable secret password are clear text password. We can encrypt all passwords using level 7 algorithm. The command to encrypt all passwords is
Router#configure terminalRouter(config)#service password-encryption
Managing ConfigurationThere are two types of configuration present in a router(1) Startup Configuration(2) Running Configuration
(1) Startup configuration is stored in the NVRAM. Startup configuration is used to save settings in a router. Startup configuration is loaded at the time of booting in to the Primary RAM.
(2) Running Configuration is present in the Primary RAM wherever we run a command for configuration; this command is written in the running configuration.
To save configurationRouter#copy running-configuration startup-configuration
OrRouter#write
To abort configurationRouter#copy startup-configuration running-configuration
To display running-configurationRouter#show running-configuration
To display startup configurationRouter#show startup-configuration
To erase old configurationRouter#erase startup-configurationRouter#reload Save[y/n]:n
Access Router using console
Com/Port--------DB9------------------------Console Cisco Console RJ45 Router
In windowsClick start=> program=> accessories=> comm.(communication)=> HyperTerminalType any nameSelect com portSet settings
Speed 9600 stop bit 1Data bits 8Parity no
Click ok
Press shift+home to default prompt
CISCO command line shortcutsTab – to auto complete command? – To take helpCtrl+P – to recall previous commandCtrl+N – next commandCtrl+Z – alternate to ‘end’ commandCtrl+C – to abortQ – to quitCtrl+Shift+6 – to break connection
Command line editing shortcutsCtrl+A – to move cursor at start of lineCtrl+E – to move cursor at end of lineCtrl+ B – to move cursor one character backCtrl+F – to move cursor one character forwardCtrl+W – to delete word one by one word backCtrl+D – to delete one characterCtrl+U – to delete one lineEsc+B – to take cursor one word backConfiguring HostName
Router#configure terminalRouter#hostname <name><name>#exit or end or /\z
Configuration InterfacesInterfaces configuration is one of the most important part of the router configuration. By default, all interfaces of Cisco router are in disabled mode. We have to use different commands as our requirement to enable and configure the interface.
Configuring IP, Mask and Enabling the InterfaceRouter#configure terminalRouter(config)#interface <type> <no>Router(config-if)#ip address <ip> <mask>Router(config-if)#no shutdownRouter(config-if)#exit
Interface NumbersInterface numbers start from 0 for each type of interface some routers will directly used interface number while other router will use slot no/port no addressing technique.
Eth 0 Slot 1 Slot 0Serial 0 Serial 1/0 Serial 0/0Serial 1 Serial 1/1
To configure Interface descriptionRouter#configure terminalRouter(config)#interface <type> <no>Router(config-if)#description <line>
Configuring optional parameter on LAN interfaceRouter#configure terminalRouter(config)#interface <type> <no>Router(config-if)#duplex <half|full|auto>Router(config-if)#speed <10|100|auto>Router(config-if)#end
Configuring optional parameter on WAN interfaceRouter#configure terminalRouter(config)#interfac <type> <no>Router(config-if)#encapsulation <protocol>Router(config-if)#clock rate <value>Router(config-if)#end
To display interface statusRouter#show interfaces (to show all interfaces)Router#show interface <type> <no>
This command will display following parameters about an interface1) Status2) Mac address 3) IP address4) Subnet mask5) Hardware type / manufacturer6) Bandwidth7) Reliability8) Delay9) Load ( Tx load
Rx load)10) Encapsulation11) ARP type (if applicable)12) Keep alive13) Queuing strategy14) Input queue details
Output queue details 15) Traffic rate
(In packet per second, bit per second)
16) Input packet details 17) Output packet details 18) Modem signals (wan interface only) 19) M.T.U maximum transmission rate (mostly 1500 bytes)
Configuring sub interfaceSub interface are required in different scenario. For e.g:- in Ethernet we need sub interface for Vlan communication and in frame relay we need sub interface for multipoint connectivity. Sub interface means creating a logical interface from physical interface.
Router#config terRouter(config)#interface <type> <no> <subint no>Router(config-subif)#
Router(config-subif)#end
Router(config)#interface serial 0.2
Configuring secondary IPRouter#config terminalRouter(config)#interface <type> <no>Router(config-if)#IP address 192.168.10.5 255.255.255.0Router(config-if)#IP address 192.168.10.18 255.255.255.0 secondaryRouter(config-if)#no shutdown (to enable the interface because they always shutdown)Router(config-if)#exit
Router#show run (to display secondary IP)
Managing Command Line HistoryWe can use CTRL+P & CTRL+N shortcuts to display command history. By default router will up to 10 commands. In the command line history, we can use following commands to edit this setting
To display commands present in historyRouter#show history
To display history sizeRouter#show terminal
To change history sizeRouter#config terminalRouter(config)#line console 0Router(config-if)#history size <value(0-256)>Router(config-if)#exit
Configuring BannersBanners are just a message that can appear at different prompts according to the type. Different banners are: -
Message of the day (motd)This banner appear at every access method
LoginAppear before login prompt
ExecAppear after we enter to the execution mode
IncomingAppear for incoming connections
Syntax:-Router#config terminalRouter(config)#banner <type> <delimation char>Text Massage<delimation char>Router(config)#Example:-Router#config terminalRouter(config)#banner motd $This router is distribution 3600 router connected to Reliance$Router(config)#
Configure LoginRouter generates the log message, which has stored in the router internal buffer and also displayed on the console.
To display log bufferRouter#show logging
To send log messages to sys log serverRouter#config terRouter(config)#logging <IP address>Router(config)#exit
To configure synchronous logging on consoleRouter#config terminalRouter(config)#line console 0Router(config)#logging synchronousRouter(config)#exit
syslog server windows->search on Google to install syslog server on our pc which creates a file in which we store logging buffer memory on the pc.
Configuring Router ClockWe can configure router clock with the help of two methods.(1) Configure clock locally(2) Configure clock on NTP server (Network Time Protocol)
Router does not have battery to save the clock setting. So that clock will reset to the default on reboot.
To display clockRouter#show clock
To configure clockRouter#clock set hh:mm:ss day month year 00-23: 00-59:00-59 1-31 JAN-DEC 1993-2035
To configure clock from NTP serverRouter#config terminalRouter(config)#ntp server <IP address>Router(config)#exit
C:\>ping pool.ntp.orgTo get ntp server ip from internet
C:\>route print
Status message of InterfacesWhen we use “Show Interfaces” command on router. The first two lines will display the status message. It will display one of the following four messages.
Interface is administratively down, line protocol is down.This message means that the interface is shutdown by the administrator using “shutdown” command. We can change this status with help of “no shutdown” command.
Interface is up, line protocol is up.This message will appear when everything working fine and interface is able to communicate with other devices. In case of Ethernet, this message will display when interface is connected and enabled. In case of serial, this message will display when end to end connectivity is established.
Interface is down, line protocol is downThis message will appear when interface is not receiving clock rate. This message will never appear in case of Ethernet. In case of serial, this message may appear due to following reasons.R x-----x--------m x---------------x-------------x m--------------R Fault
Interface is up, line protocol is downThis message will appear due to the encapsulation failure. In case of Ethernet, this message may appear when interface is not connected properly. In case of serial, this message may appear due to followingR ----------M----------------M------x------x R
Fault
e.g:-router#show Interface serial 0
router#show Interface eth 0
Router Booting Sources
A router can boot from various sources. By default, it will boot from the flash memory and we can control the sequence with the help of configuration system or commands. A router can boot from following sources: -
(1) First file in flash (2) Specific file in flash (3) Incomplete IOS(4) TFTP Server(5) Rom Monitor (from Bios)
The first to control boot sequence using configuration system register. We can modify configuration register value with the help of “config-register” command in global configuration mode. We can also modify register value from ROM monitor mode.
Configuration RegisterConfiguration Register is 16-bit value, which is stored in the NVRAM. At the time of booting the Bootstrap Loader reads the value of configuration Register and according to the value it configure its booting behavior.
0x2102 (IOS with Config)With this value the router will boot from first file present in the flash memory. This is the default value of configuration register. After loading IOS the router will also load startup-config into running-config.
0x2101 (Incomplete IOS with Config)The router will boot from incomplete IOS and then load the startup-config.
0x2100 (Rom Monitor)With this router will not boot. But enters to the Rom Monitor mode.
0x2142 (IOS without Config)The router will boot from first file in flash. But bypass the startup configuration
0x2141 (Incomplete IOS without Config)The router will boot from Incomplete IOS but bypass the startup-config.
To change Config-Register from global modeRouter#configure terminal
Router(config)#config-register <value>Router(config)#exitRouter#reload
Note: - this is the only value, which is configured in the configuration mode and does not need to be saved.
To change Config-Register using Rom Monitor Steps: -
(1) Power on the router(2) Press “ctrl+break” from console with in 60 sec.(3) The router will enter to the Rom Monitor. Type following commands
Rom Mon>confreg <value>Rom Mon>i
Note: - in 2500 series router “o/r” command should be used in place of “confreg” command.
Boot System commandsBoot system command is the second method to control sequence of router. These commands will be executed only when configuration register is set to 0x2102.Boot system commands are executed in global configuration mode. These commands are executed in the same sequence they are applied to the router. If one boot system command is successful then next boot system command is not executed in the router.
Router(config)#boot system flash <file name>To boot router from specific file in flash
Router(config)#boot system tftp <file name> <IP address>To boot router from TFTP server/network
Router(config)#boot system flashTo boot from first file in flash
Router(config)#boot system romTo boot from incomplete IOS
TFTP serverTFTP server is modified form of FTP. It is used to transfer file without performing authentication. TFTP has only home directory, in which subdirectories are not allowed. Directory browsing is not allowed in the home directory.
TFTP is the udp-based protocol, which works on port no 69. TFTP has following features in comparison to the FTP.
(1) Only get file and put file service is available.(2) Authentication is not supported.(3) Home directory may not have subdirectories
(4) Directory browsing is not allowed
Installation and Configuration of TFTP server In windows system, we have to execute following steps to use the pc as TFTP server.
(1) Download TFTP server software from Internet.(2) Install the TFTP server software on pc.(3) If software is not installed as the service then software should be running on
screen. Configure home directory of server or use default.
Functions to be perform with the help of TFTP server(1) To boot router from TFTP server(2) Backup IOS and configuration(3) Restore IOS and configuration(4) Upgrade IOS
(1) To boot from TFTP server i) Run the tftp server s/w on pc. And copy IOS image file in the Home directory of tftp server. ii) Test connectivity between router and tftp server. iii) On router use following commands:- Router#conf ter Router(config)#boot system tftp c1700-1s-mz.122.3.bin 10.0.0.18 Router(config)#exit Router#copy runn startReload the device. Make sure that configuration register set as 0x2102.
2) To backup IOS i) Test connectivity and make sure TFTP server is running. ii) Type command: - Router#show flash (note the IOS filename) Router#copy flash TFTP
Source filename =?Destination filename=?IP of TFTP server=?
To backup Configuration i) Test connectivity and make sure TFTP server is running. ii) Type commands: - Router#copy running-config tftp
Or Router#copy startup-config tftp
Remote IP: ________Destination Filename: ______________
3) To restore Configuration i) Test connectivity and make sure TFTP server is running. ii) Make sure configuration file is present in home directory and note the filename. iii) Type commands: - Router#copy tftp running-config
Remote IP: __________ Source Filename: _______________Destination Filename[running-config]: _______________
4) Restore/Upgrade IOSThere are four different conditions in which we can restore/upgrade ios.
Case 1: old ios is present and flash is in read/write mode.i) Copy ios image in tftp server’s home directory.
ii) Test connectivity and make sure tftp server is running. iii) On router use commands: -
Router# copy tftp flash Source file: -
Destination file: - IP address: -
Erase Flash [y/n]:
Case2: old ios is present but flash is in read only. i) In this case, we have to set config-register to 0x2101 to boot the router from incomplete ios. ii) After booting the flash will be read/write mode. Now use same command as in condition case 1. iii) When ios loading is complete reset config-register to 0x2102.
Case3: old ios is not present but incomplete ios is present in bios. The router will automatically boot from incomplete ios. And we have to execute
same commands as in case1 and case2.
Case4: complete ios and incomplete ios is not present in router. There are two methods to load ios with the help of Rom Monitor mode. Method1: loading ios using xmodem In this case we have to use xmodem command and the ios will be loaded with the
help of console cable. Tftp is not required in this case. i) Enter to the Rom Monitor and type following command.
Rom Mon 1>xmodem <filename>
ii) When router display a message “ Ready to receive file” then click on HyperTerminal then Transfer>> Send file>> use browse to select file>> select protocol xmodem>> send.
Method2: in this case we have to use tftp server in Rom Monitor. i) Connect the pc tftp server make sure tftp is running and ios image present in the home directory. ii) Enter to the Rom Monitor mode and type following command.
Rom Mon>IP_ADDRESS=10.0.0.2 TFTP_SERVER=10.0.0.1
TFTP_FILE=<filename> DEFAULT_GATEWAY=10.0.0.1 IP_SUBNET_MASK=255.0.0.0 >tftpdnld
When ios transfer is completed then type command.
Rom Mon>boot
Router#show versionTo view from where ios boot.
Router#show flash
Resolving Host Name
In router, we can communicate with the help of IP address as well as host name and domain name. There are two methods to resolve hostname into IP address.
1) Using local hostname database We can use local hostname database by using IP host command. We can use this command with following syntax: -Router#config terminalRouter(config)#IP host <name> <IP address>Router(config)#IP host abc 202.144.55.6Router(config)#exitRouter#show hostsRouter#ping abc
2) Using a DNS server
We can configure router to send DNS queries to DNS server. The DNS server will resolve hostname and then pc or router will try to communicate with destination. We can create maximum 6 IP.Router#config terminalRouter(config)#IP name-server <IP> [<IP2>]
Router(config)#IP name-server 202.56.230.6Router(config)#exit
Managing Telnet connectionOur router is able to telnet other devices as well as other devices can also perform telnet to our router.
To allow Telnet access to routerFor this purpose we have to configure IP address, vty password and enable secret password. IP must exist between client and router. When router will be able to perform telnet access. On telnet client we have to use following command: -Router#Telnet <IP of router>
To display connected usersRouter#show users
To disconnect a userRouter#clear line <no>(to view no use show users & show line commands)
To telnet a device from routerRouter#telnet <IP>OrRouter>telnet <IP>OrRouter><IP>
To exit from telnet sessionRouter#exit
To exit from a hanged telnet sessionCtrl+shft+6XRouter#disconnect
To display connected sessionRouter#show sessionsThis command shows those sessions, which are created or connected by us.
If we want anyone can telnet our router without password then on the line vty type command “No Login”.
TCP/IP MODEL
TCP/IP is the most popular protocol stack, which consist of large no of protocol. According to the OSI model TCP/IP consist of only four layers. TCP/IP model is modified form of DOD (Department of Defense) model.
A Http Smtp Dns Ftp Tftp Telnet Ntp Snmp Ssl Rdp & many more 80 25 53 20 69 23 123 443 3389 pop3 imapP Application
S
T TCP | UDP Transport(Host to Host)
Internet ProtocolN
ARP| RARP | ICMP | IGMP | RIP | OSPF | BGP Internet
DLAll common Lan/Wan Technologies Network
AccessPh
Application Layer
This layer contains a large no. of protocols. Each protocol is designed to act as server & client. Some of protocol will need connection oriented. TCP and others may need connection less UDP for data transfer.
Application layer use port no.s to identity each application at Transport layer. This layer performs most of functions, which are specified by the Application, Presentation, and Session layer of OSI model.
Transport Layer Two protocols are available on Transport layer1) Transmission Control Protocol2) User Datagram Protocol
1) Transmission Control Protocol
TCP performs connection-oriented communication. Its responsibilities are: - i) Error Checking ii) Acknowledgement iii) Sequencing iv) Flow Control v) Windowing
TCP Header (24 bytes)
Bytes 4 Source port 16 bits Destination port 16 bits ( Randomly generated) ( Fixed )
(1024) (80) Bytes 4 Sequence no. 32 bits
(100)
4 Acknowledgement no. 32 bits(500)
4 Header length Reserved Code bits Window 4 bits 6 bits 6 bits 16 bits
(512 bytes – onwards 1024)
4 Checksum 16 bits Urgent 16 bits
4 Options 0 or 32
Data (varies)
2) User Datagram Protocol UDP is connection less protocol, which is responsible for error checking and identifying applications using port numbers.
UDP Header (8 bytes)
Bytes 4 Source port 16 bits Destination port 16 bits
4 Length 16 bits Ckecksum 16 bits
Data
Internet LayerThe main function of Internet layer is routing and providing a single network interface to the upper layers protocols. Upper or lower protocols have not any functions relating to routing. To prevent this, IP provides one single network interface for the upper layer protocols. After that it is the job of IP and the various Network Access protocols to get along and work together. The main protocols are used in Internet layer:-1) Internet Protocol (IP)2) Internet Control Message Protocol (ICMP)3) Address Resolution Protocol (ARP)4) Reverse Address Resolution Protocol (RARP)5) Proxy ARP
Internet ProtocolThis protocol works at internet layer. It is responsible for logical addressing, defining type of service and fragmentation.
IP Header (20 – 24 bytes)
IP version (4bits) Header length (4) Type of service (8) Total length(16)
Identification no (16) Flag (3) Fragmentation offset (13)
Time to live (8) Protocol (8) Header checksum (16)
Source IP (32)
Destination IP (32)
Options (0 or 32 bits if any)
Segment data
IP SubnetIn TCP/IP by default three sizes of networks are available: -(1) Class A -224 PC -> 16777216(2) Class B - 216 PC-> 65536(3) Class C – 28 PC -> 256
In subneting, we will divide class A,B & C network into small size sub networks. This procedure is called subneting.
Subneting is performed with the help of subnet mask. There are two types of subneting that we performed: -
(1) FLSM Fixed Length Subnet Mask(2) VLSM Variable Length Subnet Mask
Why to Sub? (i) Default Class Network provide us large no. of PCs in comparison to the requirement of PCs in the network.(ii) It is practical never possible to create a class A or class B sized network.
To reduce the broadcast of network, we have to perform LAN segmentation of routers. In each sub network, we need different network addresses.
How to Subnet? In this formula, we will first modify our requirement according to the no. of subnet possible then we calculate new subnet mask and create IP range.Example 1 Class = CNo. of subnet =5
Step1No. of subnet possible is 2,4,8,16,32……Class= CNo. of subnets= 8
Step 2Calculate key value2? = No. of subnets2? = 823= 8
Step 3Calculate new subnet maskIn class CNet id Host id24+key 8-key24+3 8-327 5
11111111.11111111.11111111.11100000 255. 255. 255. 224
We add this address to make subnet mask
Step 4Range
No. of Pc/Subnet= Total Pc/ No. of Subnet = 256/8 =32
In Class Cx.x.x.0 – x.x.x.31 (1)- (30)x.x.x.32- x.x.x.63 64- 95 96- 127 128- 159 160- 191 192- 223x.x.x.224-x.x.x.255
The first IP of each subnet will be subnet id and last IP will be sub network broadcast address.
Example 2 Class= CNo. of subnet= 10
Step 1No. of subnet= 16
Step 224= 16
Step 3Net id Host id24+4 8-411111111.11111111.11111111.11110000
Subneting method 2Class=No. of Pc/Sub= 8Mask= ?Range= ?
In this case we have to calculate the key according to the no. of per subnet according to the key value the bits of subnet mask from right hand side are set to zero then range is calculated.
ExampleClass= CNo. of Pc/Sub=5
Step 1No. of Pc/Subnet possible 4,8,16,32,64….
New requirementClass= CNo. of Pc/Sub= 8
Step 22?= No. of Pc/Sub2?= 823= 8
key 3
11111111.11111111.11111111.11111000 255. 255. 255. 248
No. of Subnet= Total Pc/(Pc/Sub) = 256/8
Class C Sub Pc/Sub255.255.255.248 32 8
200.100.100.0 200.100.100.7 .8 .15 .16 .23 .24 .31 .
.
Example 2Class CNo. of Pc/Sub=50
Step 1Class= CNo. of Pc/Sub= 64
Step 226= 6411111111.11111111.11111111.11000000 255. 255. 255. 192
No. of subnet= 256/64= 4
Class C Sub Pc/Sub255.255.255.192 4 64
Method 3
No. of Pc/Sub= 50
New req.No. of Pc/Sub= 64
No. of Subnet= 256/64= 4
Class= CNo. of Sub= 422= 424+2 8-211111111.11111111.11111111.11000000 255. 255. 255. 192
Zero SubnetAccording to the rules of IP Addressing the first subnet and last subnet is not useable due to routing problem. In new Cisco router a command is present in default configuration. With this command, we are able to use first and last Subnet after Subneting.Command is Router#config terRouter(config)#ip subnet-zeroRouter(config)#exit
Example: - Check whether an address is valid IP, N/w address or Broadcast address. If IP is valid then calculate its N/w & Broadcast address.
200.100.100.197255.255.255.240
28 4
200.100.100.197200.100.100.1100 0101 Valid IP
200.100.100.192200.100.100.1100 0000 Network address
200.100.100.207200.100.100.1100 1111 Broadcast address
Example: -
Class= BNo. of subnet= 64
26= 6411111111.11111111.11111111.11000000 255. 255. 255. 192
No. of Pc/Sub= 65536/64= 1024
150.20.0.0 – 150.20.3.255150.20.4.0 – 150.20.7.255150.20.8.0 – 150.20.11.255
Prefix Notation of representing IP AddressIP address can be written as IP & Mask as well as IP/Prefix.
200.100.100.18255.255.255.248200.100.100.18/29
170.20.6.6255.255.255.224.0170.20.6.6/19
This method is representing IP address also called CIDR (Classless Inter Domain Routing) notation.
No Subneting
200.100.8.X 200.100.1.X
200.100.7.X 200.100.9.X
200.100.4.X 200.100.6.X200.100.5.X
200.100.3.X 200.100.2.X
FLSM
200.100.1.112-127/28 200.100.1.128-143/28
200.100.1.95-111/28
200.100.1.48-63/28
200.100.1.80-95/28
200.100.1.64-79/28 200.100.1.32-47/28
200.100.0-15/28200.100.1.16-31/28
Remaining Subnet144 – 159160 – 175176 – 191192 – 207208 – 223224 – 239240 – 255
Problem with FLSMIn FLSM, we have to create subnet of equal size. All N/w will be allotted constant size subnet instead of their IP addresses requirement. Due to this a N/w may be allotted more than required IP address and less than required IP addresses.
VLSM
/25 /26 /27 /28 /29255.255.255.128 255.255.255.192 255.255.255.224 255.255.255.240 255.255.255.248
Sub Pc/Sub Sub Pc/Sub Sub Pc/Sub Sub Pc/Sub Sub Pc/Sub 2 128 4 64 8 32 16 16 32 8
0 – 127 0 – 63 0 – 31 0 – 15 0 – 7128 – 255 64 – 127 32 – 63 16 – 31 8 – 15
128 – 191 64 – 95 32 – 47 16 – 23 192 – 255 96 – 127 48 – 63 24 - 31
64 –79 80 – 95
96 – 111
/30255.255.255.252
Sub Pc/Sub 64 4
0 – 3 4 – 7 8 – 11 20 30 12 – 15 32-63/30 64-95/27
2 IP 2 0-3/30
4-7/302 2
8-11/30 12-15/30
5 16-23/29
10 50 96-111/28 128-191/26
Remaining 24 – 31112 – 127
If we are using VLSM and Dynamic Routing then routing be compatible to VLSM. This will happen only if Subnet masks are also sends in the routing updates.
Super Netting Combining small N/w to create a large size N/w is called Super Network. Super netting is mostly used to define route summarizations in routing tables. It is not used for the implementation of large network.
170.10.0.0 170.00001010.00000000.00000000
170.11.0.0 170.00001011.00000000.00000000
IP RoutingWhen we want to connect two or more networks using different n/w addresses then we have to use IP Routing technique. The router will be used to perform routing between the networks. A router will perform following functions for routing.
(1) Path determination(2) Packet forwarding
(1) Path determination
The process of obtaining path in routing table is called path determination. There are three different methods to which router can learn path.i) Automatic detection of directly connected n/w.ii) Static & Default routingiii) Dynamic routing.
(2) Packet forwarding
It is a process that is by default enable in router. The router will perform packet forwarding only if route is available in the routing table.
Routing Process(i) The pc has a packet in which destination address is not same as the local n/w address.(ii) The pc will send an ARP request for default gateway. The router will reply to the ARP address and inform its Mac address to pc.(iii) The pc will encapsulate data, in which source IP is pc itself, destination IP is server, source Mac is pc’s LAN interface and destination Mac is router’s LAN interface.
R1
10.0.0.1
PC1 10.0.0.6 172.16.0.5
S. MAC D. MACPC1 R1
D. IP 172.16.0.5S. IP 10.0.0.6
The router will receive the frame, store it into the buffer. When obtain packet from the frame then forward data according to the destination IP of packet. The router will obtain a route from routing table according to which next hop IP and interface is selected (iv) According to the next hop, the packet will encapsulated with new frame and data is send to the output queue of the interface.
Static Routing
In this routing, we have to use IP route commands through which we can specify routes for different networks. The administrator will analyze whole internetwork topology and then specify the route for each n/w that is not directly connected to the router.
Steps to perform static routing
(1) Create a list of all n/w present in internetwork.(2) Remove the n/w address from list, which is directly connected to n/w.(3) Specify each route for each routing n/w by using IP route command.
Router(config)#ip route <destination n/w> <mask> <next hop ip>
Next hop IP it is the IP address of neighbor router that is directly connected our router.
Static Routing Example: -Router#conf terRouter(config)#ip route 10.0.0.0 255.0.0.0 192.168.10.2
Advantages of static routing(1) Fast and efficient.(2) More control over selected path.(3) Less overhead for router.(4) Bandwidth of interfaces is not consumed in routing updates.
Disadvantages of static routing(1) More overheads on administrator.(2) Load balancing is not easily possible.(3) In case of topology change routing table has to be change manually.
Alternate command to specify static routeStatic route can also specify in following syntax: -
Old Router(config)#ip route 172.16.0.0 255.255.0.0 172.25.0.2OrRouter(config)#ip route 172.16.0.0 255.255.0.0 serial 0
Backup route or loading static route
If more than one path are available from our router to destination then we can specify one route as primary and other route as backup route.
Administrator Distance is used to specify one route as primary and other route as backup. Router will select lower AD route to forward the traffic. By default static route has AD value of 1. With backup path, we will specify higher AD so that this route will be used if primary route is unavailable.
Protocols ADDirectly Connected 0Static 1BGP 20EIGRP 90IGRP 100OSPF 110RIP 120
Syntax: - To set backup pathRouter(config)#ip route <dest. n/w> <mask> <next hop> <AD>
Or<exit interface>
Example: -Router#conf terRouter(config)#ip route 150.10.0.0 255.255.0.0 150.20.0.5Router(config)#ip route 150.10.0.0 25.255.0.0 160.20.1.1 8 (below 20)Router(config)#exitDefault RoutingDefault routing means a route for any n/w. these routes are specify with the help of following syntax: -Router(config)#ip route 0.0.0.0 0.0.0.0 <next hop>
Or<exit interface>
This type of routing is used in following scenario.
Scenario 1: -Stub networkA n/w which has only one exit interface is called stub network.
If there is one next hop then we can use default routing.
Scenario 2Internet connectivityOn Internet, million of n/ws are present. So we have to specify default routing on our router. Default route is also called gateway of last resort. This route will be used when no other routing protocol is available.
200.100.100.11
172.16.0.5
R
ISP
R1 R2
10.0.0.0
Router(config)#ip route 10.0.0.0 255.0.0.0 172.16.0.5Router(config)#ip route 0.0.0.0 0.0.0.0 200.100.100.11
To display routing tableRouter#sh ip route
To display static routes onlyRouter#sh ip route static
To display connected n/ws onlyRouter#sh ip route connected
S 192.168.10.0/28 [1/0] via 172.16.0.5
To check all the interface of a routerRouter#sh interface brief
Dynamic Routing
In dynamic routing, we will enable a routing protocol on router. This protocol will send its routing information to the neighbor router. This protocol will send its routing information to the neighbor router. The neighbors will analyze the information and write new routes to the routing table.
The routers will pass routing information receive from one router to other router also. If there are more than one path available then routes are compared and best path is selected. Some examples of dynamic protocol are: -RIP, IGRP, EIGRP, OSPF
Types of Dynamic Routing Protocols
According to the working there are two types of Dynamic Routing Protocols.(1) Distance Vector(2) Link State
According to the type of area in which protocol is used there are again two types of protocol: -(1) Interior Routing Protocol(2) Exterior Routing Protocol
Autonomous system
Autonomous system is the group of contiguous routers and n/w, which will share their routing information directly with each other. If all routers are in single domain and they share their information directly with each other then the size of routing updates will depend on the no. of n/w present in the Internetwork. Update for each n/w may take 150 – 200 bytes information. For example: - if there are 1000 n/ws then size of update will be
200*1000 = 200000 bytesThe routing information is send periodically so it may consume a large amount of bandwidth in our n/w.
Domain
ProtocolsInterior Routing Exterior RoutingRIP BGPIGRP EXEIGRPEIGRPOSPF
Distance Vector Routing
The Routing, which is based on two parameters, that is distance and direction is called Distance Vector Routing. The example of Distance Vector Routing is RIP & IGRP.
Interior Routing
Exterior Routing
Border Routing
AS 200AS 400
AS 500
Operation: -(1) Each Router will send its directly connected information to the neighbor router. This information is send periodically to the neighbors.
(2) The neighbor will receive routing updates and process the route according to following conditions: - (i) If update of a new n/w is received then this information is stored in routing table. (ii) If update of a route is received which is already present in routing table then route will be refresh that is route times is reset to zero. (iii) If update is received for a route with lower metric then the route, which is already present in our routing table. The router will discard old route and write the new route in the routing table. (iv) If update is received with higher metric then the route that is already present in routing table, in this case the new update will be discard.
(3) A timer is associated with each route. The router will forward routing information on all interfaces and entire routing table is send to the neighbor. There are three types of timers associated with a route.
(i) Route update timer It is the time after which the router will send periodic update to the neighbor.
(ii) Route invalid timer It is the time after which the route is declared invalid, if there are no updates for the route. Invalid route are not forwarded to neighbor routers but it is still used to forward the traffic.
(iii) Route flush timer It is the time after which route is removed from the routing table, if there are no updates about the router.
Metric of Dynamic Routing
Metric are the measuring unit to calculate the distance of destination n/w. A protocol may use a one or more than one at a time to calculate the distance. Different types of metric are: -(1) Hop Count(2) Band Width(3) Load(4) Reliability(5) Delay(6) MTU
Hop CountIt is the no. of Hops (Routers) a packet has to travel for a destination n/w.
BandwidthBandwidth is the speed of link. The path with higher bandwidth is preferred to send the data.
LoadLoad is the amount of traffic present in the interface. Paths with lower load and high throughput are used to send data.
ReliabilityReliability is up time of interface over a period of time.
DelayDelay is the time period b/w a packet is sent and received by the destination.
MTU Maximum Transmission UnitIt is the maximum size of packet that can be sent in a frame mostly MTU is set to 1500.
Problems of Distance Vector
There are two main problems of distance vector routing(1) Bandwidth Consumption(2) Routing Loops
Bandwidth Consumption
The problem of accessive bandwidth consumption is solved out with the help of autonomous system. It exchanges b/w different routers. We can also perform route summarization to reduce the traffic.
Routing LoopsIt may occur b/w adjacent routers due to wrong routing information. Distance Vector routing is also called routing by Rumor. Due to this the packet may enter in the loop condition until their TTL is expired.
Method to solve routing loopsThere are five different methods to solve or reduce the problem of routing loop.
(1) Maximum Hop Count(2) Flash Updates/Triggered Updates(3) Split Horizon(4) Poison Reverse(5) Hold Down
Maximum Hop Count This method limits the maximum no. of hops a packet can travel. This method does not solve loop problem. But it reduce the loop size in the n/w. Due to this method the end to end size of a n/w is also limited.
Flash Updates/Triggered UpdatesIn this method a partial update is send to the all neighbors as soon as there is topology change. The router, which receives flash updates, will also send the flash updates to the neighbor routers.
Split HorizonSplit Horizon states a route that update receive from an interface can not be send back to same interface.
Poison ReverseThis method is the combination of split Horizon and Flash updates. It implements the rule that information received from the interface can not be sent back to the interface and in case of topology change flash updates will be send to the neighbor.
Hold DownIf a route changes frequently then the route is declared in Hold Down state and no updates are received until the Hold Down timer expires.
Routing Information ProtocolFeatures of RIP: -* Distance Vector* Open standard* Broadcast Updates
(255.255.255.255)* Metric
Hop Count*Timers
Update 30 secInvalid 180 secHold 180 secFlush 240 sec
* Loop ControlSplit HorizonTriggered UpdatesMaximum Hop CountHold Down
* Maximum Hop Count 15* Administrative Distance 120* Equal Path Cost Load Balancing* Maximum Load path 6
Default 4* Does not support VLSM* Does not support Autonomous system
Configuring RIPRouter#conf terRouter(config)#router ripRouter(config-router)#network <own net address>Router(config-router)#network <own net address>----------------------------Router(config-router)#exit
172.16.0.6
10.0.0.1 172.16.0.5 175.2.1.1
200.100.100.12
Router(config-router)#network 10.0.0.0Router(config-router)#network 172.16.0.0Router(config-router)#network 200.100.100.0
175.2.0.0 via 172.16.0.6
Display RIP RoutersRouter#sh ip route rip
R 192.168.75.0/24 [120/5] via 172.30.0.2 00:00:25 serial 1/0
RIP Dest. n/w mask AD Metric Next Hop Timer own Interface
RIP advanced configuration
Passive InterfacesAn interface, which is not able to send routing updates but able to receive routing update only is called Passive Interface. We can declare an interface as passive with following commands: -
Router#conf ter
R1
Router(config)#router ripRouter(config-router)#Passive-interface <type> <no>Router(config-router)#exit
Neighbor RIP
In RIP, by default routing updates are send to the address 255.255.255.255. In some scenarios, it may be required to send routing updates as a unicast from router to another. In this case, we have to configure neighbor RIP.For example: - in a Frame Relay n/w the broadcast update is discarded by the switches, so if we want to send RIP updates across the switches then we have to unicast updates using Neighbor RIP.
Unicast 10.0.0.2
255.255.255.255
10.0.0.1 10.0.0.2
R1 R2Router(config)#router rip Router(config)#router ripRouter(config-router)#neighbor 10.0.0.2 Router(config-router)#neighbor 10.0.0.1
Configuring TimersRouter(config)#router ripRouter(config-router)#timers basic <update> <invalid> <hold down> <flush>Router(config-router)#exit
Example: -Router(conf)#timer basic 50 200 210 300
Update 50 secInvalid 200 secHold 210 secFlush 300 sec
To change Administrative DistanceRouter(config)#router ripRouter(config-router)#distance <value>
R1 R2
Frame Relay Cloud
Router(config-router)#exit 95 or 100
To configure Load BalanceRIP is able to perform equal path cost Load Balancing. If multiple paths are available with equal Hop Count for the destination then RIP will balance load equally on all paths.
Load Balancing is enabled by default 4 paths. We can change the no. of paths. It can use simultaneously by following command: -Router(config)#router ripRouter(config-router)#maximum-path <1-6>
To display RIP parameters Router#sh ip protocolOrRouter#sh ip protocol RIP
This command display following parameters: -(i) RIP Timers(ii) RIP Version (iii) Route filtering(iv) Route redistribution(v) Interfaces on which update send(vi) And receive(vii) Advertise n/w(viii) Passive interface(ix) Neighbor RIP(x) Routing information sources(xi) Administrative Distance
RIP version 2
RIP version 2 supports following new features: -(1) Support VLSM (send mask in updates)(2) Multicast updates using address 224.0.0.9(3) Support authentication
Commands to enable RIP version 2We have to change RIP version 1 to RIP version 2. Rest all communication will remain same in RIP version 2.
Router(config)#Router RIPRouter(config-router)#version 2Router(config-router)#exit
To debug RIP routingRouter#debug ip rip
To disable debug routingRouter#no debug ip ripOrRouter#no debug allOrRouter#undebug all
Interior Gateway Routing ProtocolFeatures: -* Cisco proprietary * Distance vector* Timers
Update 90 secInvalid 270 secHold time 280 secFlush 630 sec
* Loop controlAll methods
* Max hop count100 upto 255
* Metric (24 bit composite)Bandwidth (default)Delay (default)Load ReliabilityMTU
* Broadcast updates to address 255.255.255.255* Unequal path cost load balancing* Automatic route summarization* Support AS* Does not support VLSM
Configuring IGRPRouter(config)#router igrp <as no>(1 – 65535)Router(config-router)#network <net address>Router(config-router)#network <net address>Router(config-router)#exit
Configuring Bandwidth on Interface for IGRP
By default the router will detect maximum speed of interface and use this value as the bandwidth metric for IGRP. But it may be possible that the interfaces and working at its maximum speed then we have to configure bandwidth on interface, so that IGRP is able to calculate correct method.
Router(config)#interface <type> <no>Router(config-if)#bandwidth <value in kbps>Router(config-if)#exit
Router(config)#interface serial 0Router(config-if)#bandwidth 256Router(config-if)#exit
Serial E1 modem Serial E1
2048 k 2048 k256 ksync
Configuring Unequal path cost load balancingTo configure load balancing, we have to set two parameters (1) Maximum path (by default 4)(2) Variance (default 1)
Maximum Path: - it is maximum no. of paths that can be used for load balancing simultaneously.Variance: - it is the multiplier value to the least metric for a destination n/w up to which the load can be balanced. Router(config)#Router igrp <as no>Router(config-router)#variance <value>Router(config-router)#exit
Configuring following options in IGRP as same as in case of RIP: -(1) Neighbor (2) Passive interface(3) Timer(4) Distance (AD)(5) Maximum path
Link State RoutingThis type of routing is based on link state. Its working is explain as under
(1) Each router will send Hello packets to all neighbors using all interfaces.(2) The router from which Hello reply receive are stored in the neighborship table. Hello packets are send periodically to maintain the neighbor table. (3) The router will send link state information to the all neighbors. Link state information from one neighbor is also forwarded to other neighbor.(4) Each router will maintain its link state database created from link state advertisement received from different routers.(5) The router will use best path algorithm to store the path in routing table.
Neighbor Topology Routing11.0.0.1 R1 11.0.0.0 dc 13.0.0.2 12.0.0.0 dc
13.0.0.0 dc
R2 11.0.0.0 10.0.0.0
R3 13.0.0.0 14.0.0.0 15.0.0.0 16.0.0.0
R4 16.0.0.0 17.0.0.0
R5 18.0.0.0 19.0.0.0 20.0.0.0 14.0.0.0
R6 20.0.0.0 19.0.0.0 21.0.0.0
20.0.0.0 18.0.0.0
21.0.0.0 14.0.0.0
15.0.0.0 13.0.0.0 11.0.0.0 10.0.0.0
R6
R5
R3
R1
R2
16.0.0.0 12.0.0.0
17.0.0.0
Problems of Link State Routing
The main problems of link state routing are: -(1) High bandwidth consumption.(2) More hardware resources required that is processor and memory (RAM)
The routing protocols, which use link state routing are: -(1) OSPF(2) EIGRP
Enhanced Interior Gateway Routing ProtocolFeatures: -* Cisco proprietary* Hybrid protocol
Link StateDistance Vector
* Multicast Updates usingAddress 224.0.0.10
* Support AS* Support VLSM* Automatic Route Summarization* Unequal path cost load balancing* Metric (32 bit composite)
BandwidthDelayLoadReliabilityMTU
* Neighbor Recovery* Partial updates* Triggered updates* Backup Route* Multi Protocol Routing
R4
EIGRP Protocols & Modules(1) Protocol depended module This module is used to perform multi protocol routing that is the router will maintain 3 routing table for TCP/IP, IPX/SPX and Appletalk.
TCP/IP
IPX/SPX
Appletalk
Reliable Transport Protocol (Quiet Protocol)
RTP is used to exchange routing updates with neighbor routers. It will also maintain neighbor relationship with the help of Hello packet. RTP has following features: -(1) Multicast updates (224.0.0.10)(2) Neighbor recovery If neighbor stops responding to the Hello packets then RTP will send unicast Hello packet for that neighbor.(3) Partial updates(4) No updates are send if there is no topology change.
Packet type?
IP Routing
IPX Routing
Appletalk Routing
Diffusing Update Algorithm (DUAL)
DUAL is responsible for calculating best path from the topology table. Dual has following features: -* Backup Path* VLSM* Route queries to neighbor for unknown n/w.
Configuring EIGRP
Router(config)#router eigrp <as no>Router(config-router)#network <net addr.>Router(config-router)#network <net addr.>Router(config-router)#exit
Advanced Configuration EIGRP
Configuring following options are same as configuring IGRP(1) Bandwidth on Interfaces(2) Neighbor(3) Load balancing
Max pathVariance
Configuring EIGRP MetricIf we want our router to use additional metric then we can use following command: -Router(config)#Router eigrp <as no>Router(config-router)#metric weights 0 <k1> <k2> <k3> <k4> <k5>
Type of service (default) 1 0 1 0 0Router(config-router)#exit
Metric K Default valueBandwidth K1 1Load K2 0Delay K3 1Reliability K4 0MTU K5 0
All routers exchanging update with each other must have same AS no. and same K value.
To up the Ethernet without connect wireRouter(config)#int eth0
Router(config-if)#no keepaliveRouter(config-if)#bandwidth 64
Router#clear ip route *Hush routing table and again make it.
Router#sh ip eigrp topologyIt shows topology database.P-> passive->stable A->active->under updation
Router#sh ip eigrp neighborIt shows neighbor table
Router#redistribute <protocol> ?Metric also need to be modified
Debug IGRPRouter#debug ip igrp eventsIts display info. On special event
Router#debug ip igrp transactionsIt shows every update
Debug EIGRPRouter#debug ip eigrpFor full debug
Router#debug ip eigrp summaryFor few debug
Open Shortest Path FirstFeatures: -* Link State* Open standard* Multicast updates
224.0.0.5224.0.0.6
* Support VLSM* Support Area similar to AS* Manual Route Summarization* Hierarchical model* Metric
Bandwidth* Equal path cost load balancing* Support authentication
* Unlimited hop count
OSPF TerminologyAlready known topics in this: -(1) Hello packets(2) LSA (Link State Advertisement)(3) Neighbor(4) Neighbor table(5) Topology table (LSA database)
Router IDRouter ID is the highest IP address of router interfaces. This id is used as the identity of the router. It maintaining stale databases. The first preference for selecting router ID is given to the Logical interfaces. If logical interface is not present then highest IP of physical interface is selected as router id.
Highest ip is router id of a router
50.0.0.6
11.0.0.2 13.0.0.1
AreaArea is the group of routers & n/ws, which can share their routing information directly with each other.
AdjacencyA router is called adjacency when neighbor relationship is established. We can also say adjacency relationship is formed between the routers.
OSPF Hierarchical Model Area 0
Area 20 Area 70 Area 90Area RouterA router, which has all interfaces member of single area, is called area router.Backbone AreaArea 0 is called backbone area. All other areas must connect to the backbone area for communication.
Backbone RouterA router, which has all interfaces members of area 0, is called backbone router.
Area Border RouterA router, which connects an area with area 0, is called area border router.
LSA Flooding in OSPFIf there are multiple OSPF routers on multi access n/w then there will be excessive no. of LSA generated by the router and they can choke bandwidth of the network.
br br br
abr abr abr
ar ar ar ar
ar ar ar
L K M N
A B C D
A B C DB A A A NeighborC C B BD D D CL K M N
This problem is solved with the help of electing a router as designated router and backup designated router.
Designated RouterA router with highest RID (router id) will be designated router for a particular interface. This router is responsible for receiving LSA from non-DR router and forward LSA to the all DR router.
Backup Designated RouterThis router will work as backup for the designated router. In BDR mode, it will receive all information but do not forward this information to other non-DR router.Commands to configure OSPFRouter#conf terRouter(config)#router ospf <process no>Router(config-router)#network <net address> <wild mask> area <area id>Router(config-router)#network <net address> <wild mask> area <area id>Router(config-router)#exit
Wild Mask – Complement of subnet mask
Example 255.255.0.0 0.0.255.255
255.255.255.255 - Subnet mask
Wild mask
255.255.255.255 - 255.255.192.0 subnet mask
0.0.63.255 wild mask
Area 20
200.100.100.2/24
215.1.13/24
Router(config)#router ospf 32Router(config-router)#network 200.100.100.0 0.0.0.255 area 20Router(config-router)#network 215.1.1.0 0.0.0.255 area 20Router(config-router)#exit
Area 0
200.100.100.33/30 200.100.100.34/30
200.100.100.66/27 200.100.100.160/26
R1
R2
R1Router(config)#router ospf 33Router(config-router)#network 200.100.100.32 0.0.0.3 area 0Router(config-router)#network 200.100.100.64 0.0.0.31 area 0Router(config-router)#exit
R2Router(config)#router ospf 2Router(config-router)#network 200.100.100.32 0.0.0.3 area 0Router(config-router)#network 200.100.100.128 0.0.0.63 area 0Router(config-router)#exit
200.100.100.5/30 200.100.100.17/30
200.100.100.6/30 200.100.100.18/30
200.100.100.230/27
200.100.100.38/28 200.100.100.161/28
R1Router(config-router)#network 200.100.100.4 0.0.0.3Router(config-router)#network 200.100.100.32 0.0.0.15
R2Router(config-router)#network 200.100.100.4 0.0.0.3Router(config-router)#network 200.100.100.160 0.0.0.15Router(config-router)#network 200.100.100.16 0.0.0.3
R3Router(config-router)#network 200.100.100.16 0.0.0.3Router(config-router)#network 200.100.100.224 0.0.0.31
Configuring bandwidth on interfaceIf the actual bandwidth of interface is not equal to the maximum speed of interface then we have to use bandwidth command to specify the actual bandwidth.
Router(config)#interface <type> <no>Router(config-if)#bandwidth <speed>
R1
R2
R3
Configuring logical interface for OSPFBy default the highest IP address of interface will be elected as Router id. If there is a change in status of interface then router will reelect some IP as Router id. So if we create logical interface, it will never go down and first preference give to the logical interface for RID.
Command: -Router(config)#interface loopback <no>Router(config-if)#ip address 200.100.100.1 255.255.255.0Router(config-if)#no shRouter(config-if)#exit
Command to display OSPF parameterRouter#show ip protocolRouter#show ip ospf
Router#show ip ospf neighborRouter#show ip ospf database (it shows RID of router)Router#show ip ospf interfaces
LAN Switching
Ethernet switches are used in LAN to create Ethernet n/ws. Switches forward the traffic on the basis of MAC address. Switches maintain a switching table in which mac addresses and port no.s are used to perform switching decision. Working of bridge and switch is similar to each other.
Classification of switchesSwitches are classified according to the following criteria: -Types of switches based on working(1) Store & Forward This switch receives entire frame then perform error checking and start forwarding data to the destination.
(2) Cut through This switch starts forwarding frame as soon as first six bytes of the frame are received.
(3) Fragment-free This switch receives 64 bytes of the frame, perform error checking and then start forwarding data.
(4) Adaptive cut-through It changes its mode according the condition. If it see there are errors in many frames then it changes to Store & Forward mode from Cut through or Fragment-free.
Types of switches based on management(1) Manageable switches(2) Non-Manageable switches(3) Semi-Manageable switches
Types of switches based on OSI layer (1) Layer 2 switches (only switching)(2) Layer 3 switches (switching & routing)
Types of switches based on command mode (only in Cisco)(1) IOS based(2) CLI based
Type of switches based on hierarchical model(1) Core layer switches(2) Distribution layer switches(3) Access layer switches
Qualities of switch- No. of ports- Speed of ports- Type of media- Switching or wire speed or throughput
Basic Switch AdministrationIOS based switches are similar to the routers. We can perform following function on switches in a similar manner as performed on router.(1) Access switch using console(2) Commands to enter & exit from different mode(3) Commands to configure passwords(4) Manage configuration(5) Backup IOS and configuration(6) Configuring and resolving hostnames(7) Managing telnet(8) Configuring CDP(9) Configuring time clock(10) Configuring Banners(11) Command line shortcuts and editing shortcuts(12) Managing history(13) Configure logging(14) Boot system commands
Following function and options are not similar in router and switch.(1) Default hostname is ‘Switch’(2) seiliary port is not present (3) VTY ports are mostly 0 to 15(4) By default interfaces are enabled(5) IP address cannot be assign to interfaces(6) Routing configuration mode is not present(7) Interface no. starts from 1(8) Web access is by default enabled(9) Configuration registry is not present in similar manner(10) Flash memory may contain multiple files and startup-configuration is also saved in flash
Configuring IP and Gateway on switch We can configure IP address on switch for web access or telnet IP address is required for the administration of the switch. If we have to access switch from remote n/w then we will configure default gateway in addition to IP address.
IP address is assigned to the logical interface of switch with following command:-Switch(config)#interface vlan 1Switch(config)#IP address <ip> <mask>Switch(config)#no shSwitch(config)#exit
Old SwitchesSwitch(config)#ip address <ip> <mask>Switch(config)#exit
Configuring GatewaySwitch(config)#ip default-gateway <ip>Switch(config)#exit
Breaking Switch Password(1) Power off switch press mode button present in front of switch then power on the switch.(2) Keep mode button press until ‘Switch:’ prompt appears on console.(3) In switch monitor mode, type following commands: - flash_init load_helper rename flash:config.text flash:<anyname> dir flash: boot(4) After booting switch will prompt to enter in initial configuration dialog. Enter ‘no’ here and type. Switch>enable Rename flash:<anyname> Flash:config.text Configure memory
Change password and save config. Then copy run strat_config.
Cisco Hierarchal Model
When we want to create a large sized LAN network then we may face following problems if we are going design the network in flat model.(1) High latency(2) Conjunction between switches between switches (3) Large broadcast domain
Cisco hierarchal model recommends three layer design of the network (i) Core layer (ii) Distribution layer (iii) Access layer
on each layer there are some rules which we have to follow
(1) Highest performance devices are connected on Core layer(2) Resources should be placed on Core layer(3) Polices should not be applied on core layer(4) On distribution layer, we can implement policies(5) Distribution and Core devices should be connected with high-speed links.(6) Access layer devices are basic devices and may be non manageable.
Server
1 GBps
100 MBps
(Hierarchal model)
After using hierarchal model the most of LAN problem will be solve but one problem still remain same that is all pc s will be in single broadcast domain. We have to implement following solution for this problem.(1) Physical Segmentation(2) Logical Segmentation
VLANTrunkingVTPInter VLANPruning
CORE
Distribution Distribution Distribution
Accesss Accesss Accesss Accesss Point
Logical Segmentation of NetworkTo perform logical segmentation, we have to create VLAN in the network. With the help of VLAN, we can logically divide the broadcast domain of the network.
VLAN (Virtual LAN)
VLAN provides Virtual Segmentation of Broadcast Domain in the network. The devices, which are member of same Vlan, are able to communicate with each other. The devices of different Vlan may communicate with each other with routing. So that different Vlan devices will use different n/w addresses. Vlan provides following advantages: -(1) Logical Segmentation of network(2) Enhance network security
Creating port based VlanIn port based Vlan, first we have to create a Vlan on manageable switch then we have to add ports to the Vlan.
Commands to create VlanSwitch#config terSwitch(config)#vlan <no> [name <word>]Switch(config)#exit optional
Or
Switch#vlan databaseSwitch(vlan)#vlan <no> [name <word>]Switch(vlan)#exit
Commands to configure ports for a Vlan
By default, all ports are member of single vlan that is Vlan1. we can change vlan membership according to our requirement.
Switch#conf terSwitch(config)#interface <type> <no>Switch(config-if)#switchport access vlan <no>Switch(config-if)#exit
Commands to configure multiple ports in a vlanSwitch#conf ter
Switch(config)#interface range <type> <slot/port no (space)–(space) port no>Switch(config-if)#switchport access vlan <no>Switch(config-if)#exit
Example: - Suppose we want to add interface fast Ethernet 0/10 to 0/18 in vlan5Switch#config terSwitch(config)#interface range fastethernet 0/10 – 18Switch(config-if)#switchport access vlan 5 Switchconfig-if#exit
In 1900 & Compatible switchesSwitch#config terSwitch(config)#interface <type> <no>Switch(config-if)#vlan-membership static <vlan no>Switch(config-if)#exit
To Disable web access in switchSwitch#config terSwitch(config)#no ip http server
To display mac address tableSwitch#sh mac-address-table
Vlan Mac address type ports20 00-08-a16-ab-6a-7b dynamic fa0/7
To Display Vlan and port membershipSwitch#sh vlan
Trunking
When there are multiple switches then we have to use trunk links to connect one switch with other. If we are not using trunk links then we have to connect one cable from each vlan to the corresponding vlan of the other switch.
Normal: -
Vlan 1 7 3 1 3 7
In Trunking: - Vlan 1,3,7
1 7 3 1 3 7
Trunk Trunk
Switches will perform trunking with the help of frame tagging. The trunk port will send data frames by adding a Vlan id information to the frame, at the receiving end vlan id information is removing from the end and according to the tag data is delivered to the corresponding vlan. There are two protocols to perform frame tagging.(1) Inter switch link (cisco prop)(2) IEEE 802.1 q
Configuring Trunking In cisco switches all switch ports may be configured in three modes(1) Trunk desirable (default)(2) Trunk on(3) Trunk off
Switch#conf terSwitch(config)#interface <type> <no>Switch(config-if)#switchport mode <trunk|access|auto>Switch(config-if)#exit on off desirable
To configure Vlans allowed on TrunkBy default all Vlans are allowed on Trunk port. We can add/remove a partucular Vlan from trunk port with following commandSwitch#config terSwitch(config)#interface <type> <no>Switch(config-if)#switchport trunk allowed vlan all
Remove <vlan> Add <vlan> Except <vlan>
To display trunk interfacesSwitch#sh interface trunkSwitch#sh interface <type> <no> trunk
Vlan Trunking Protocol (VTP)With the help of VTP, we can simplify the process of creating Vlan. In multiple switches, we can configure one switch as VTP server and all other switches will be configured as VTP client. We will create Vlans on VTP server switch. The server will send periodic updates to VTP client switches. The clients will create Vlans from the update received from the VTP server.
VTP serverVTP server is a switch in which we can create, delete or modify Vlans. The server will send periodic updates for VTP clients.
VTP clientOn VTP client, we are not able to create, modify or delete Vlans. The client will receive and forward vtp updates. The client will create same Vlans as defined in vtp update.
VTP TransparentTransparent is a switch, which will receive and forward VTP update. It is able to create, delete and modify Vlans locally. A transparent will not send its own VTP updates and will not learn any information from received vtp update.
VTP Domain VTP serverVTP password Vlan 1,3,5,10,20
Vlan Client Client Client Vlan 1,3,10,20,40,901,3,5,10,20
Client Client Client Client
VTP Transparent
CommandsSwitch#conf terSwitch(config)#vtp domain <name>Switch(config)#vtp password <word>Switch(config)#vtp mode <server|client|transparent>Switch(config)#exit
By default in cisco switches the VTP mode is set as VTP server with no domain and no password.
To display VTP statusSwitch#sh vtp status
VTP PruningPruning is the VTP feature through which a trunk link can be automatically disable, for a particular Vlan if neighbor switch does not contain ports in that Vlan. Vlan1 is not prun eligible.Command to configure VTP PruningWe have to use only one command on VTP server for VTP Pruning.Switch#conf terSwitch(config)#vtp pruningSwitch(config)#exit
ServerVlan 1,3,5,7
Client Client Client
Vlan 1 3 5 7 1 3 5 7 1 3 5 7
Inter Vlan Communication After creating Vlans, each Vlan has own broadcast domain. If we want communication from one Vlan to another Vlan then we need to perform routing. There are three methods for inter vlan communication.(1) Inter Vlan using multi-interface router(2) Inter Vlan using router on a stick method(3) Inter Vlan using layer 3 switch
1751, 2621 routers supports Vlan
(1) Inter Vlan using multi-interface router In this case, we have to connect one interface of router in each Vlan. This interface will act as gateway for the corresponding vlan. Each Vlan has to use different n/w addresses. Data from one Vlan to another Vlan will travel by router.
10.0.0.1 12.0.0.1
11.0.0.1
1, 3, 5
N/w 10.x.x.x 11.x.x.x 12.x.x.xGateway 10.0.0.1 11.0.0.1 12.0.0.1
(2) Inter Vlan using router on a stick method In this method a special router is used for Inter Vlan. In this router, we can create one interface for each Vlan. The physical interface of router will be connected on trunk port switch. This router will route traffic on the same interface by swapping vlan id information with the help of frame tagging protocol.
Fa 0/0.1 – 10.0.0.1 -> Vlan1Fa 0/0.2 – 11.0.0.1 -> Vlan3Fa 0/0.3 – 12.0.0.1 -> Vlan5
Router
E0 E2 E1
Vlan1 Vlan3 Vlan5 T T T
1 3 5 1 3 5 1 3 5
Router
Fa 0/0
Vlan 1, 3, 5
T T T
N/w 10.x.x.x 11.x.x.x 12.x.x.x Gateway 10.0.0.1 11.0.0.1 12.0.0.1
Configuration on RouterRouter#config terRouter(config)#interface fastethernet 0/0Router(config-if)#no ip addressRouter(config-if)#no shRouter(config-if)#exit
Router(config)#interface fastethernet 0/0.1Router(config-if)#encapsulation dot1q 1Router(config-if)#ip address 10.0.0.1 255.0.0.0Router(config-if)#no shRouter(config-if)#exit
Router(config)#interface fastethernet 0/0.2Router(config-if)#encapsulation dot1q 3Router(config-if)#ip address 11.0.0.1 255.0.0.0Router(config-if)#no shRouter(config-if)#exit
Router(config)#interface fastethernet 0/0.3Router(config-if)#encapsulation dot1q 5Router(config-if)#ip address 12.0.0.1 255.0.0.0Router(config-if)#no shRouter(config-if)#exit
Configuration on Core switch(1) Configure switch as VTP server(2) Create Vlans
Trunk T T T
1 3 5 1 3 5 1 3 5
(3) Configure interface connected to router as Trunk(4) Configure interfaces connected to other switches as trunk (if required)
Configuration on Distribution layer switches(1) Configure switch as VTP client(2) Configure required interface as Trunk (optional)(3) Add ports to Vlan
Configuration on PcConfigure IP and Gateway
Spanning Tree ProtocolWhen we connect multiple switches with each other and multiple paths exist from one switch to another switch then it may lead to the switching loop in the network. Multiple paths are used to create redundancy in the network. STP is only required when multiple path exist then there is possibility of loop in n/w.
Packets
Problems the occur with redundancy path(1) Multiple copies of the frame will be received by destination.(2) Frequent changes in the mac address table of switch.(3) A mac address may appear at multiple ports in a switch.(4) Packets may enter in the endless loop. Spanning Tree Protocol will solve this problem by blocking the redundancy interface. So that only one path will remain active in the switches. If the primary path goes down then disabled link will become enable and data will be transferred through that path.
Working of STPThe STP will create a topology database in which one switch will be elected as Route switch. Path cost is calculated on the basis of bandwidth. The lowest path cost link will be enable mode and another path will be disable.
1 Gb 1 Gb
Switch Switch Switch
Route Switch
Switch Switch
100 Mb 100 Mb
100 Mb
Lowest cost(Disable)
STP terminology (1) Bridge id It is the combination of bridge priority and base mac address. In Cisco switches default priority no. is 32768.
(2) Route Bridge The Bridge/Switch with lowest Bridge id will become the Route Bridge. Route Bridge is used as the center point for calculating path cost in topology.
(3) BPDU Bridging Protocol Data Units It is the STP information, which is exchange between the switches to create topology and path selection.
(4) STP port mode An STP is enabled a port may be in one of the following mode. (i) Listening: - in this mode a port will send/receive BPD. (ii) Learning: - a port will learn mac address table. (iii) Forwarding: - the port will forward data based on mac address table. (iv) Blocking: - the port is block to send/receive data by Spanning Tree Protocol. (v) Disable: - the port is administratively disabled.Path cost calculationThe links in switches will be enable or disabled on the basis of path cost. The path cost for each link is calculated according to following table.
Old IEEE New IEEESpeed Cost Cost10 Mb 100 100100 Mb 10 191 Gb 1 410 Gb 1 2
To configure ports for forwarding mode directlySwitch#config terSwitch(config)#interface <type> <no>Switch(config-if)#switchport host
Switch Switch
Configuring port securityIn manageable switches, we can restrict the no. of mac addresses that a port can learn. Even we can specify the mac address statically with a command. With port security, we can also specify the action to be perform if port security violation is detected.
Switch#conf terSwitch(config)#interface <type> <no>Switch(config-if)#switchport port-securitySwitch(config-if)#switchport port-security maximum <no. of mac>Switch(config-if)#switchport port-security violation <shutdown|restrict|reject>Switch(config-if)#switchport port-security mac-address stickySwitch(config-if)#switchport port-security mac-address sticky <mac address>Switch(config-if)#exit
Access Control ListACL are the basic security feature that is required in any network to control the flow of traffic. Most of time our network may have servers and clients for which traffic control is required.
We can also use ACL to classify the traffic. ACLs are used in features like QOS (Quality of Service), Prioritize traffic and interesting traffic for ISDN.
Classification Access Control List: -Types of ACL based on Protocol: -(1) IP Access Control List(2) IPX Access Control List(3) Appletalk Access Control List
Types of ACL based on Feature: -(1) Standard ACL(2) Extended ACLTypes of ACL based on Access mode: -(1) Numbered ACL(2) Named ACL
Types of ACL based on Order of rules: -(1) Deny, permit(2) Permit, deny
Types of ACL based on direction of implementation: -(1) Inbound ACL(2) Outbound ACL
Flow chart of Inbound ACL
No
Yes
No
Yes
Yes No
IP Standard ACL (Numbered)In Standard ACL, we are only able to specify source address for the filtering of packets. The syntax to create IP standard ACL are: -Router#conf terRouter(config)#access-list <no> <permit|deny> <source>Router(config)#exit
<source> Single pc host 192.168.10.5192.168.10.5192.168.10.5 0.0.0.0
N/w 200.100.100.0 0.0.0.255
Subnet 200.100.100.32 0.0.0.15
All any
A Packet is received
Is there any Access-list applied on interface in Inbound direction?
Is there any macthing rule in ACL from top-down order?
Is it permit?
The packet is dropped.
The packet is dropped.
The packet is passed to RE
The packet is passed to Routing Engine
Example: - 172.16.0.16 – 18 should not access Internet; rest of all other pc should access Internet.
Internet
172.16.0.1
172.16.x.x
Router#conf terRouter(config)#access-list 30 deny 172.16.0.16Router(config)#access-list 30 deny 172.16.0.17Router(config)#access-list 30 deny 172.16.0.18Router(config)#access-list 30 permit anyRouter(config)#exit
Applying ACL on interfaceRouter#conf terRouter(config)#interface <type> <no>Router(config-if)#ip access-group <ACL no.> <in|out>Router(config-if)#exit
Rule for applying ACL Only one ACL can be applied on each interface, in each direction for each protocol.
Example: - Suppose we want to allow Internet only for 192.168.10.32 – 70.
Internet
Router
Router
Router(config)#access-list 25 permit 192.168.10.32 0.0..31Router(config)#access-list 25 permit 192.168.10.64 0.0.0.3Router(config)#access-list 25 permit 192.168.10.68Router(config)#access-list 25 permit 192.168.10.69Router(config)#access-list 25 permit 192.168.10.70
Router(config)#interface serial 0Router(config-if)#ip access-group 25 out
IP Standard ACL (Named)In Numbered ACL editing feature is not available that is we are not able to delete single rule from the ACL. In Named ACL editing feature is available.
Router#config terRouter(config)#ip access-list standard <name>Router(config-std-nacl)#<deny|permit> <source>Router(config-std-nacl)#exit
Router#conf terRouter(config)#ip access-list standard abcRouter(config-std-nacl)#deny 172.16.0.16Router(config-std-nacl)#deny 172.16.0.17Router(config-std-nacl)#deny 172.16.0.18Router(config-std-nacl)#permit anyRouter(config-std-nacl)#exit
To modify the ACLRouter#conf terRouter(config)#ip access-list standard abcRouter(config-std-nacl)#no deny 172.16.0.17Router(config-std-nacl)#exit
To control Telnet access using ACLIf we want to control telnet with the help of ACL then we can create a standard ACL and apply this ACL on vty port. The ACL that we will create for vty will be permit – deny order.Example: - suppose we want to allow telnet to our router from 192.168.10.5 & 200.100.100.30 pc.Router#conf terRouter(config)#access-list 50 permit 192.168.10.5Router(config)#access-list 50 permit 192.168.10.30Router(config)#access-list 50 deny any
Router(config)#line vty 0 4Router(config-line)#access-class 50 inRouter(config)#exit
IP Extended ACL (Numbered)Extended ACL are advanced ACL. ACL, which can control traffic flow on the basis of five different parameters that are: -(i) Source address(ii) Destination address(iii) Source port(iv) Destination port(v) Protocol (layer 3/layer 4)
The syntax to create Extended ACLRouter#conf terRouter(config)#access-list <no> <deny|permit> <protocol> <source> [<s.port>]
<destination> [<d.port>]router(config)#exit
<no> -> 100 to 199<protocol> -> layer ¾
IPTCPUDPICMPIGRP
<Source port> no (1 to 65535) or<Destination port> telnet/www/ftp etc.<Source> Single pc<Destination> 192.168.10.4 0.0.0.0
host 192.168.10.4
N/w200.100.100.0 0.0.0.255
Subnet172.30.0.32 0.0.0.7
AllAny
Example rules of Extended ACLRouter(config)#access-list 140 deny ip 192.168.10.3 0.0.0.0 any(All tcp/ip data is denied from source 192.168.10.3 to any destination)
Router(config)#access-list 120 permit ip any any
(All tcp/ip data permit from any source to any destination)
Router(config)#access-list 145 deny tcp any host 200.100.100.5(All tcp data is denied from any source to host 200.100.100.5)
Router(config)#access-list 130 permit tcp any host 200.100.100.10 eq 80(All tcp based data from any source is allowed to access destination 200.100.100.10 on port no. 80 that is www(http) ) – web access
Router(config)#access-list 130 permit udp any host 200.100.100.10 eq 53(Any pc is able to access our DNS service running on port no. 53)
Router(config)#access-list 150 deny tcp any any eq 23 [or telnet](Telnet traffic is not allowed)
Router(config)#access-list 160 deny icmp any any(All icmp data from any source to any destination is denied)
To display ACLRouter#show access-lists orRouter#show access-list <no>
To display ACL applied on interfaceRouter#show ip interface
Router#show ip interface <type> <no>Router#show ip interface Ethernet 0
Example: - Extended ACLSuppose we want to control inbound traffic for our network. ACL should be designed according the following policy.
(1) Access to web server (200.100.100.3) is allowed from any source.(2) FTP server (200.100.100.4) should be accessible only from branch office n/w (200.100.175.0/24).(3) ICMP & Telnet should be allowed only from remote pc 200.100.175.80(4) Any pc can access DNS (200.100.100.8)
200.100.175.x
Router
Router
200.100.100.x
Router(config)#access-list 130 permit tcp any host 200.100.100.3 eq 80Router(config)#access-list 130 permit tcp 200.100.175.0 0.0.0.255 200.100.100.4 0.0.0.0
Eq 21Router(config)#access-list 130 permit icmp 200.100.175.80 0.0.0.0 anyRouter(config)#access-list 130 permit tcp 200.100.175.80 0.0.0.0 any eq 23Router(config)#access-list 130 permit udp any host 200.100.100.8 eq 53
Switch port ACL
You can only apply port ACLs to layer 2 interfaces on your switches because they are only supported on physical layer 2 interfaces. You can apply them as only inbound lists on your interfaces, and you can use only named lists as well.
Extended IP access lists use both source and destination addresses as well as optional protocol information and port number. There are also MAC extended access lists that use source and destination MAC addresses and optional protocol type information.
Switches scrutinize all inbound ACLs applied to a certain interface and decide to allow traffic through depending on whether the traffic is a good match to the ACL or not. ACLs can also be used to control traffic on VLANs. You just need to apply a port ACL to a trunk port.
Switch#conf terSwitch(config)#mac access-list extended abcSwitch(config-ext-mac)#deny any host 000d.29bd.4b85Switch(config-ext-mac)#permit any anySwitch(config-ext-mac)#do show access-list
Switch(config-ext-mac)#int f0/6Switch(config-if)#mac access-group abc in
Display CDP statusRouter#sh cdp
To display CDP enabled interfacesRouter#sh cdp interface
To display CDP neighborsRouter#sh cdp neighborOrRouter#sh cdp neighbor detail
To disable CDP from deviceRouter#conf terRouter(config)#no cdp run
To disable CDP on particular interfaceRouter#conf terRouter(config)#int <type> <no.>Router(config-if)#no cdp enableRouter(cobfig-if)#exit
To change CDP timersRouter#conf terRouter(config)#cdp timer <value> (by default 60 sec)Router(config)#cdp holdtime <value> (by default 180 sec)(Value in seconds)
Wide Area Network
The network that is design for long distance communication is called Wide Area Network. A WAN network uses WAN protocols, WAN interface card to communicate with remote network.
Leased line ISDN Frame Relay ATMMLLN PSTN X.25Radio LinkFor 2 locations Unlimited Maximum MaximumFactors to be considered while selecting a WAN technology(1) No. of locations(2) Hours of connectivity
WAN
Point-to-Point Circuit Switching Packet Switching Cell Switching
(3) Speed(4) Cost (Bandwidth + Distance)(5) Reliability
WAN EncapsulationWAN encapsulation is used to convert a packet into frame and transfer data to WAN links, Different type of encapsulation are designed for different WAN technologies. The general format of WAN encapsulation is: -
FH Packet FT
Common WAN Encapsulation
Point-to-Point High level data link control HDLCPoint-to-Point, Point-to-Point Protocol PPPCircuit SwitchFrame Relay Frame Relay CiscoFrame Relay Frame Relay IETF X.25 Link Access Procedure Based LAPBISDN Link Access Procedure Based for D channel LAPDATM ATM Adaptation layer 5 AAL5
Point-to-Point WAN technologies
These WAN technologies are used to connect two locations with each other. It is the 24-hour high speed and reliable connectivity. We can setup this WAN technology in three steps: -Step 1: - Connect the devices according to topology.Step 2: - Configure Modems.Step 3: - Configure Router.
Step 1Point-to-Point WAN Topology(a) Campus n/w or Drop wire n/w
V.35 Line LineRS 232
EIA/TIA 530 2 wire TP Or
4 wire TP
Flag Address Control Data FCS Flag
Modem
DB-60 Smart Serial
RJ-45* Distance depends on modems & mostly up to 10-15 kms.
(b) Leased line via Service Provided
G703G704
Line
Local Loop Local Loop
Line
V.35RS 232, EIA/TIA 530
SS, DB-60
(c) Managed Leased Line n/w (MLLN)
Serial
Router eth
Router
Modem
Modem
Modem
Modem
R R
ExchangeMux Mux
ExchangeMLLNMUX
MLLNMUX
MLLNModem
MLLNModem
(d) Radio Link
Antenna
V.35RS 232EIA 530
DB-60Smart Serial
(e) Radio Link using IDU & ODU
ODU ODU
UTP orCoaxial
IDU IDU
Router
Router
RadioModem
RadioModem
Router Router
RadioModem
RadioModem
RadioModem
RadioModemRoute
r
Router
ODU – Out Door UnitIDU – In Door Unit
Line
4 Wire 2 Wire1 ------- 12 ------- Loop 1 23 34 ------- Loop2 4 ------- Signal5 ------ - 5 -------6 67 78 8
Step 2 Configurations of ModemsWe have to configure various parameters in the modem. There are three different
methods to configure these parameters according to Modem.
Method1) Configuration of modem using Jumper setting/ Dip switches.2) Configuration of modem using LCD menu.3) Configuration of Modem using Console/ Terminal.
Step 3 Configuration of RouterTo configure Router for a Leased line scenario or Point-to-Point n/w, we have to
set following parameters: -1) IP addresses2) IP routing3) WAN encapsulation
172.16.0.1 172.16.0.2
192.168.5.1 10.0.0.1
In Point-to-Point WAN n/w any type of routing can be perform on routers.
WAN EncapsulationTwo routers interfaces in Point-to-Point WAN must required to have same WAN encapsulation. Two types of WAN encapsulation are supported in this type of network.(1) HDLC(2) PPP
HDLCPPP
Same Manufacturer
PPP
Different ManufacturerBy default, Cisco routers will use Cisco HDLC encapsulation. We can change encapsulation by following command: -
Router#conf terRouter(config)#interface <type> <no>Router(config-if)#encapsulation ppp|hdlc
HDLCHigh Level Data Link ControlHDLC is the modified form of SDLC (Synchronous Data Link Control). SDLC was developed by IBM for router to main frame communication. HDLC is modified for router-to-router communication. Most of manufacturer has developed their proprietary HDLC protocol. So HDLC from one manufacturer is not compatible for other.
HDLC encapsulation is designed for Point-to-Point router communication. In HDLC no addressing is required, but still all station address is used in encapsulation. HDLC provides only basic features and error checking for the frame.
PPP – Point-to-Point ProtocolPPP is an open standard WAN protocol that can be used in Point-to-Point and circuit switching networks. PPP provides various advantages as compared to HDLC. PPP has following special features: -(1) Authentication(2) Multi Link(3) Compression(4) Call Back
PPP at OSI layer
AP TCP/IPS IPX/SPXTN
Lan, Wan Protocols DL
P
NetworkDA NCPT -------------------A
LCP PPPL I --------------------
PPP
HDLC
LAPB
EE 8023 ARPA
NK HDLC
PhysicalRouter 1 Router 2
Router 1Router#config terRouter(config)#int serial 0Router(config-if)# encapsulation pppRouter(config-if)# ppp authentication chapRouter(config-if)#ip address 10.0.0.1 255.0.0.0Router(config-if)#no shRouter(config-if)#exitRouter(config)#hostname chdRouter(config)#username ldh password net123Router(config)#exit
Router 2Router#config terRouter(config)#int serial 1Router(config-if)#encapsulation pppRouter(config-if)#ppp authentication chapRouter(config-if)#ip address 10.0.0.2 255.0.0.0Router(config-if)#no shRouter(config-if)#exitRouter(config)#hostname ldhRouter(config)#username chd password net123Router(config)#exit
Configuring Compression in PPPIn PPP, one of the following three protocols can be used for compression(1) Stac(2) Predictor(3) Microsoft Point-to-Point Compression
Router#config terRouter(config)#interface <type> <no>Router(config-if)#encapsulation pppRouter(config-if)#compress <Stac|MPPC|Predictor>Router(config-if)#exit
S0
S1
To display CompressionRouter#show compress
Circuit Switching
In Circuit Switching, all users are connected to the Circuit Switching. Exchange cloud depending upon user request. A circuit is established between two locations and then data is transferred. A signaling protocol is used to establish the connectivity then data is transferred with the help of protocol used Point-to-Point WAN.Examples of Circuit Switching are: -ISDN (Integrated Services Digital Network)PSTN (Public Switched Telephone Network)
Integrated Services Digital NetworkISDN is the high-end circuit switching technology, which is designed for voice, data and video. ISDN is the time division multiplexing technology, in which multiple channels are used to transfer rate.
2 B Channels1 D Channel
ISDN
PRI BRI
E1 T1
30 B Channels 23 B Channels1 D Channel 1 D Channel
B Channel (Bearer Channel)This channel carries data using data encapsulation.
D Channel (Data Channel)This channel carries signal using signaling protocol.
Time Division Multiplexing in ISDN BRI
TB1 ------- 64 kbpsB2 ------- 64 kbpsD Ch ------- 16 kbpsS ------- 48 kbps
ISDN BRI Topology
S T U 2 wire
S
R
NT 1 Network Termination 1Send/Receive ISDN BRI Signals
NT 2 Network Termination 2Share ISDN between multiple users
TE 1 Terminal Equipment 1ISDN compatible device
TE 2 Terminal Equipment 2
B1 S1 B2 S D Ch S B1 S B2 S --
TE 1 NT 2 NT 1
TE 2 TA
ISDN Cloud
Non-ISDN device
TA Terminal AdapterConnects ISDN line with Non-ISDN device
Topology 1: - Voice
4 2 wire
4
Topology 2: - Voice
Topology 3: - Voice + Data
USB Serial
Install TA in Pc, similar to External modem installation. Use “Dialup Networking” to connect Remote location.
Topology 3: - Data
ISDN BRI S/T
ISDN Phone 1
ISDN Phone 2
NT 1 ISDN Cloud
Phone 1
Phone 1
TA NT 1 ISDN Cloud
PC TA NT 1
Ph 1 Ph 2
ISDN Cloud
Router
NT 1 ISDN Cloud
ISDNBRIU
Configuring ISDN BRIWe will configure ISDN BRI for following two scenarios: -
(1) ISDN Branch office to Branch office connectivity.(2) ISDN Branch office to ISP Connectivity.
Packet Switching
Packet Switching is the wan technology in which all devices are connected to the packet switching exchange. The devices will request packet switching exchange to create a virtual connection then data is transferred over the virtual connection. It is possible to create more than one virtual connection. Simuntasouly and transfer data over them one by one.
Example of Packet Switching Technology are: -
(1) X.25(2) Frame Relay
Frame RelayFrame Relay is the Packet switching technology in which virtual connections are established. The frame relay supports only permanent virtual connections. Frame used special addresses called DLCI to create common and virtual connections.
Frame Relay Topology
Router ISDN CloudNT 1
FRModem
FR SW
V.35 232
4 wire Tp 530 Line
Local loop Line
Frame Relay Encapsulation
Frame Relay use special type of Encapsulation, Which is specifically designed for this technology. There are two encapsulations are available: -(1) Frame Relay Cisco(2) Frame Relay IETF (Internet Engineering Task Force)
Cisco FRIETF FR
Cisco Cisco
IETF FR
Non Cisco ?
Frame Relay DLCI
DLCI stands for Data Link Control Identifier. It is used for addressing purpose. In frame
Relay Encapsulation, Virtual Circuits are established and data is transferred on the basis
of DLCI. DLCI addresses are different from general addressing scheme. One DLCI
address provided for each virtual circuit that we want to create.
DLCI range 16 - 1017
FRModem
R R
R R
Virtual Circuit
In packet switching technology there are two types of virtual circuits: -
(1) Switched Virtual Circuit (SVC)
(2) Permanent Virtual Circuit (PVC)
Only PVC is supported in Frame Relay technology.
Frame Relay (LMI) Local Management Interface
LMI are the keep alive signals, which are used to keep the virtual circuit up and running.
LMI are exchange between frame relay switch and router. We have to set same LMI on
router as specified by the service provider. There are three types of LMI that we can use
(1) CISCO(2) Q933a(3) ANSI
Configuring Frame Relay Point to Point connectivity
S0 S1 Cisco ANSI
300 for R2 400 for R1
encap: - Cisco FR
M M
M M
FRSW SW
192.168.10.1 192.168.10.2
172.16.0.1 172.30.0.1
R1
Router#config ter
Router(config)#int eth0
Router(config-if)#ip address 172.16.0.1 255.255.0.0
Router(config-if)#no sh
Router(config-if)#exit
Router(config)#ip route 172.30.0.0 255.255.0.0 192.168.10.2
Router(config)#int serial 0
Router(config-if)#encapsulation frame-relay
Router(config-if)#frame-relay lmi-type cisco
Router(config-if)#ip address 192.168.10.1 255.255.255.0
Router(config-if)#frame-relay interface-dlci 300
Router(config-dlci)#exit
Router(config-if)#frame-relay map ip 192.168.10.2 300
Router(config-if)#no sh
Router(config-if)#exit
R2
Router#config ter
Router(config)#int eth0
Router(config-if)#ip address 172.30.0.1 255.255.0.0
Router(config-if)#no sh
Router(config-if)#exit
R1 R2
Router(config)#ip route 172.16.0.0 255.255.0.0 192.168.10.1
Router(config)#int serial 0
Router(config-if)#encapsulation frame-relay
Router(config-if)#frame-relay lmi-type cisco
Router(config-if)#ip address 192.168.10.2 255.255.255.0
Router(config-if)#frame-relay interface-dlci 400
Router(config-dlci)#exit
Router(config-if)#frame-relay map ip 192.168.10.1 400
Router(config-if)#no sh
Router(config-if)#exit
Frame-relay Switch
Router(config)#hostname FR-SW
FR-SW(config)#frame-relay switching
FR-SW(config)#int serial0
FR-SW(config-if)#encapsulation frame-relay
FR-SW(config-if)#no ip address
FR-SW(config-if)#frame-relay intf-type dce
FR-SW(config-if)#frame-relay route 300 int serial 1 400
FR-SW(config-if)#clocka rate 64000
FR-SW(config-if)#no sh
FR-SW(config-if)#exit
FR-SW(config)#int serial1
FR-SW(config-if)#encapsulation frame-relay
FR-SW(config-if)#no ip address
FR-SW(config-if)#frame-relay intf-type dce
FR-SW(config-if)#frame-relay route 400 int serial 0 300
FR-SW(config-if)#clocka rate 64000
FR-SW(config-if)#no sh
FR-SW(config-if)#exit
Configuring Frame Relay point to multipoint when all routers are same subnet
192.168.10.2
400 for R1
ANSI 172.30.0.1
309 for R2 701 for R1
318 for R3
192.168.10.1 192.168.10.5
R1 R3
R2
M
M
M
M
M
MVC1
VC2S
10.0.0.1 172.20.0.1
Encapsulation = Frame-Relay IETF
On physical interface, we can assign only one DLCI address. But in this case, we have to
use two DLCI on single interface so we will create a frame relay sub interface
(multipoint), which is able to create multiple virtual circuit.
R1
Router#config ter
Router(config)#int eth 0
Router(config-if)#ip address 10.0.0.1 255.0.0.0
Router(config-if)#no sh
Router(config-if)#exit
Router(config)#ip route 172.30.0.0 255.255.0.0 192.168.10.2
Router(config)#ip route 172.20.0.0 255.255.0.0 192.168.10.5
Router(config)#int serial 0
Router(config-if)#encapsulation frame-relay ietf
Router(config-if)#frame-relay lmi-type ansi
Router(config-if)#no ip address
Router(config-if)#no sh
Router(config-if)#exit
Router(config)#interface serial 0.2 multipoint
Router(config-if)#ip address 192.168.10.1 255.255.255.0
Router(config-if)#frame-relay map ip 192.168.10.2 309
Router(config-if)#frame-relay map ip 192.168.10.5 318
Router(config-if)#no sh
Router(config-if)#exit
R2
Router#config ter
Router(config)#interface Ethernet 0
Router(config-if)#ip address 172.30.0.1 255.255.0.0
Router(config-if)#no sh
Router(config-if)#exit
Router(config)#ip route 10.0.0.0 255.0.0.0 192.168.10.1
Router(config)#interface serial 0
Router(config-if)#ip address 192.168.10.2 255.255.255.0
Router(config-if)#encapsulation frame-relay
Router(config-if)#frame-relay interface-dlci 400
Router(config-dlci)#exit
Router(config-if)#frame-relay lmi-type ansi
Router(config-if)#frame-relay map ip 192.168.10.1 400
Router(config-if)#no sh
Router(config-if)#exit
R3
Router#config ter
Router(config)#interface Ethernet 0
Router(config-if)#ip address 172.20.0.1 255.255.0.0
Router(config-if)#no sh
Router(config-if)#exit
Router(config)#ip route 10.0.0.0 255.0.0.0 192.168.10.1
Router(config)#interface serial 0
Router(config-if)#ip address 192.168.10.5 255.255.255.0
Router(config-if)#encapsulation frame-relay
Router(config-if)#frame-relay interface-dlci 701
Router(config-dlci)#exit
Router(config-if)#frame-relay lmi-type ansi
Router(config-if)#frame-relay map ip 192.168.10.1 701
Router(config-if)#no sh
Router(config-if)#exit
Frame-relay Switch
Router(config)#hostname FR-SW
FR-SW(config)#frame-relay switching
FR-SW(config)#int serial0
FR-SW(config-if)#encapsulation frame-relay
FR-SW(config-if)#no ip address
FR-SW(config-if)#frame-relay intf-type dce
FR-SW(config-if)#frame-relay route 309 int serial 1 400
FR-SW(config-if)#frame-relay route 318 int serial 2 701
FR-SW(config-if)#clocka rate 64000
FR-SW(config-if)#no sh
FR-SW(config-if)#exit
FR-SW(config)#int serial1
FR-SW(config-if)#encapsulation frame-relay
FR-SW(config-if)#no ip address
FR-SW(config-if)#frame-relay intf-type dce
FR-SW(config-if)#frame-relay route 400 int serial 0 309
FR-SW(config-if)#clocka rate 64000
FR-SW(config-if)#no sh
FR-SW(config-if)#exit
FR-SW(config)#int serial2
FR-SW(config-if)#encapsulation frame-relay
FR-SW(config-if)#no ip address
FR-SW(config-if)#frame-relay intf-type dce
FR-SW(config-if)#frame-relay route 701 int serial 0 318
FR-SW(config-if)#clocka rate 64000
FR-SW(config-if)#no sh
FR-SW(config-if)#exit
Frame Relay point to multipoint configuration when routers are in different
subnets.
192.168.10.6
400 for R1
CISCO 11.0.0.1
300 for R2 701 for R1
309 for R3
R1
M
M
M
M
MVC1
VC2S
192.168.10.5
172.16.0.2 172.16.0.1
10.0.0.1 12.0.0.1
Encapsulation = Frame-Relay IETF
R1
Router#config ter
Router(config)#int eth0
Router(config-if)#ip address 10.0.0.1 255.0.0.0
Router(config-if)#no sh
Router(config-if)#exit
Router(config)#ip route 11.0.0.0 255.0.0.0 192.168.10.6
Router(config)#ip route 12.0.0.0 255.0.0.0 172.16.0.1
Router(config)#interface serial 0
Router(config-if)#encapsulation frame-relay ietf
Router(config-if)#frame-relay lmi-type cisco
Router(config-if)#no ip address
Router(config-if)#no sh
Router(config-if)#exit
R1 R1
M
Router(config)#interface serial 0.20 point-to-point
Router(config-if)#ip address 192.168.10.5 255.255.255.0
Router(config-if)#frame-relay interface-dlci 300
Router(config-if)#exit
Router(config-if)#frame-relay map ip 192.168.10.6 300
Router(config-if)#no sh
Router(config-if)#exit
Router(config)#interface serial 0.30 point-to-point
Router(config-if)#ip address 172.16.0.2 255.255.0.0
Router(config-if)#frame-relay interface-dlci 309
Router(config-if)#exit
Router(config-if)#frame-relay map ip 172.16.0.1 309
Router(config-if)#no sh
Router(config-if)#exit
Frame Relay Show Command
Router#sh interface <type> <no>
It will be show additional
(i) Encapsulation
(ii) LMI send/receive
Router#sh frame-relay pvc
It will be show
(i) Active/inactive pvc
(ii) Data send/receive over each pvc
(iii) Frame-relay congestion control information
Router#sh frame-relay map
Display the IP to DLCI mapping and pvc status
Frame relay congestion control
Frame relay uses three types of information in frame relay encapsulation for congestion
control.
(1) Backward explicit congestion notice.
(2) Forward explicit congestion notice
(3) Discard eligibility
Network Address Translation
NAT is the feature that can be enable in a Router, Firewall or a Pc. With the help of
NAT, we are able to translate network layer addresses that are IP addresses of packets.
With the help of Port Address Translation, we are also able to translate port no.s present
in transport layer header.
Advantage of NAT
There are two reasons due to which we use NAT: -
(1) Conserve Live IP address
On Internet, there are limited no of IP addresses. If our Pc wants to communicate on
Internet then it should have a Live IP address assigned by our ISP. So that IP address
request will depend on no. of PCs that we want to connect on Internet. Due to this, there
will be a lot of wastage in IP addresses. To reduce wastage, we can share live IP
addresses between multiple PCs with the help of NAT.
(2) NAT enhances the network security by hiding PC & devices behind NAT.
Working of NAT & PAT
10.0.0.5
10.0.0.6 10.0.0.1 200.100.100.12
10.0.0.7
10.0.0.8
NAT
Internet
Switch
10.0.0.5200.100.100.12
1080
10.0.0.6200.100.100.12
1085
Port Translation
1100
Types of NAT
Static NAT
This NAT is used for servers in which one Live IP is directly mapped to one Local IP.
This NAT will forward on the traffic for the Live IP to the Local PC in the n/w.
Static NAT
200.1.1.5 = 192.168.10.6
Live 200.1.1.5
10.0.0.7200.100.100.12
1024
10.0.0.8200.100.100.12
1024
Router
Internet
Local 192.168.10.6
Dynamic NAT using Pool
Dynamic NAT is used for clients, which want to access Internet. The request from
multiple client IPs are translated with the Live IP obtained from the Pool. It is also called
Pool Based Dynamic NAT.
Pool => 200.1.1.8 – 200.1.1.12/28
Local address => 172.16.X.X
Except => 172.16.0.5
172.16.0.6
172.16.0.7
Web Server DNS Full access 172.16.X.X
172.16.0.5 172.16.0.6 172.16.0.7
Router
Internet
Pool allotted => 200.1.1.0 – 15/28
Server
Static => 200.1.1.3 = 172.16.0.7
Port Based Static NAT
200.1.1.4:53 = 172.16.0.6
200.1.1.4:80 = 172.16.0.5
Client
Dynamic NAT
Pool => 200.1.1.8 – 200.1.1.12/28
Local address => 172.16.0.X
Except
172.16.0.5
172.16.0.6
172.16.0.7
Configuring NAT
Router#conf ter
Router(config)#int serial 0
Router(config-if)#ip nat outside
Router(config-if)#int eth 0
Router(config-if)#ip nat inside
Router(config-if)#exit
Router(config)#ip nat inside source static 172.16.0.7 200.1.1.3
Router(config)#ip nat inside source static tcp 172.16.0.5 80 200.1.1.4 80
Router(config)#ip nat inside source static udp 172.16.0.6 53 200.1.1.4 53
Router(config)#access-list 30 deny 172.16.0.5
Router(config)#access-list 30 deny 172.16.0.6
Router(config)#access-list 30 deny 172.16.0.7
Router(config)#access-list 30 permit any
Router(config)#ip nat pool abc 200.1.1.8 200.1.1.12 netmask 255.255.255.240
Router(config)#ip nat inside source list 30 pool abc overload
NAT + PAt
To display NAT translation
Router#sh ip nat translations
(after ping any address, it shows ping details)
To clear IP NAT Translation
Router#clear ip nat Translation *
Configuring DHCPRouter(config)#int eth0
Router(config-if)#ip address 192.168.100.1 255.255.255.0
Router(config-if)#no sh
Router(config-if)#exit
Router(config)#ip dhcp pool abc
Router(dhcp-config)#network 192.168.100.0 255.255.255.0
Router(dhcp-config)#default-router 192.168.100.1
Router(dhcp-config)#dns-server 202.164.32.82 202.164.32.82
Router(dhcp-config)#domain-name ZCC.com
Router(dhcp-config)#lease 3
Router(dhcp-config)#exit
Router(config)#ip dhcp excluded-address 192.168.100.1 192.168.100.50
Router(config)#exit
About ZCC
SCO. 94-95, 4th FloorSec. 34 A Chandigarh,
Phone: 0172-2646400, 5087637Website. Zccindia.com, Email: info@zccindia.com
ZCC (Zealous Computer Centre) was established on 1st July 2001. It offers higher education in computer Hardware and Networking and also provides coaching in International certifications like A+, MCSE, CCNA, Linux Operating System.
ZCC also provides training of international standards. ZCC institute's own placement cell assures quality placement on local, national, and international level to good performer. ZCC Institute has 100% placement record in different companies like HCL, Targus, Wipro, Allegers and Tulip IT etc. Our primary focus is on providing quality education to our Students and provide better placement.
The vision of the ZCC Program is to provide students with knowledge and experience that adds value to computer education and Information Technologies through research, product development, and applicationof current tools to solving educational problems
Our philosophy is different from our competitors We don't believe in “watch me do this “training. - We believe in active learning. We make every minute of training relevent to the student. Classes are small, hence effective. Training is interactive. Instructors bring real-world experience to the classroom, using easy methods. Sometimes even humour is used to help students cut through foreign terms and get a full hands-on experience.
As a result, -- our classes simplify technical education; students learn faster and retain more.
Recommended