You are on page 1of 13

DCE and DTE on Cisco Routers

When we connect two routers through serial port, then the port on one router needs to be
DCE and the other port on the other router needs to be DTE.

DCE stands for Data Communications Equipment or Data Carrier Equipment


DTE stands for Data Terminal Equipment

DCE decides the data transfer speed of the router to another router.

DTE receives the data transfer speed.

We need to set Clock Rate and Bandwidth on DCE port.

To check if a port is a DCE port or a DTE port on a router we need to use command:

#Show controllers serial 0/0(Port Number)

Check the port that connects directly to another router. It will tell you whether it is a DCE or
DTE port.

To set the clock speed of DCE port go to Global Configuration mode and enter

(Config)#Interface serial 0/0

(Config) if# Ip address 10.0.01 255.0.0.0


(Config) if# Clock Rate 64000

(Config) if# Bandwidth 64

(Config) if# No shutdown

*Press Ctrl + Z to escape to Privileged mode directly from Interface mode.


Working Modes of a Router
There are four working modes of a Router

1. User Mode
2. Privileged Mode
3. Global Configuration Mode
4. ROMMAN Mode (ROM Monitor)

User Mode: User mode is the first mode a user has access to after logging into the router.
This mode allows the user to execute only basic commands, such as those that show the
system status. The router cannot be configured or restarted from this mode.

The User Mode can be identified by the > sign


Router>

To find out the list of commands that can be used in User mode use the command:

Router>?

Privileged Mode: It allows the user to view the system configuration, save system
configuration, restart the system and enter global configuration mode. It also allows all the
commands that are available in user mode.
The Privileged Mode can be identified by the # sign

Router#

We can enter the privileged mode by entering the “enable” command in the user mode.

Global Configuration Mode: It allows the user to modify the running system configuration
like changing hostname, setting up IP address to ports, etc.
It can be identified by the symbol

Router (Config) #

We can enter the GC mode from PM by entering the command

“Configure Terminal”

ROMMAN Mode (ROM Monitor): If the router does not find a valid system image to load or
the image is corrupted, it will enter Read Only Memory (ROM) monitor mode. We can also
use this mode for password recovery.
It can also be accessed by interrupting the boot sequence during startup.

This mode can be identified by the symbol


ROMMAN1>

Press Ctrl + c or Ctrl + Pause break key during router boot process to enter this mode.

So ROMMAN mode is basically used for recovery purposes.

We can reboot the router by entering the “reload” command in Privileged mode then press
Enter to confirm the load the ROMMAN mode.

Router Configuration Files:


The router configuration files stores all the settings and information of a router like
configured ports, ip addresses, which port is up or down, What are the security features
implemented, passwords configured.

There are two types of configuration files in a router.

1. Running configuration file – Stored in RAM which is temporary and the current
configuration when the router is running. It is erased when the router is rebooted.
To check the running configuration in privileged mode: Show running-config

2. Startup configuration files – Stored in NVRAM which is permanent and loads every
time the router boots up.
To check the startup configuration in privileged mode: Show startup-config

Note: There is no startup configuration file on a fresh router. Only default


configuration files exists. So we need to make a startup configuration file or the
default file will load every time.

To save the running config file to startup config we can use the following commands
in privileged mode:

#Write
Or
#Write Memory
Or
#Copy running-config startup-config

Routing
A Router is a process of selecting path along which the data can be transferred from source
to the destination from one router to another.

There are three types of Routing


 Static Routing
 Dynamic Routing
 Default Routing

Static Routing: In static routing we can configure the route or path manually into the
routing table. Static routing is used in small networks and not proper for large networks as it
becomes complicated. The routing table needs to be changed and updated manually by the
network administrator.

Dynamic Routing: A dynamic routing table is created, maintained, and updated by


a routing protocol running on the router. It can be used in larger networks.
RIP, IGRP, EIGRP, OSPF, BGP and IS-IS are dynamic routing protocols.

Default Routing : This is the method where all routers are configured to send all packets
towards a single router. This is a very useful method for small networks or for networks
with a single entry and exit point. It is usually used in addition to Static and/or Dynamic
routing.

The default route is a route that a router uses to forward an incoming packet when no other
route is available for that packet in the routing table.

Not used in todays’ networks.

Routing Table
A routing table is a database that keeps track of paths, like a map, and uses these to
determine which way to forward traffic. A routing table is a data file in RAM that is used to
store route information about directly connected and remote networks.

Command to view routing table


#show ip route

Split Horizon
Split horizon is a method of preventing a routing loop in a network. The basic principle is
simple: Information about the routing for a particular packet is never sent back in the
direction from which it was received.

Distance vector protocols are susceptible to routing loops. Routing loops occur when a
packet is continually routed through the same routers over and over, in an endless circle.
Because they can render a network unusable, distance vector routing protocols (such
as RIP and EIGRP) employ several different mechanisms to prevent routing loops.
Split horizon is one of the methods used by distance vector routing protocols to avoid
routing loops. The principle is simple – a router will not advertise a route back onto the
interface from which it was learned. Split horizon is enabled on interfaces by default.
Routing Loops
A routing loop is a serious network problem which happens when a data packet is
continually routed through the same routers over and over. The data packets continue to be
routed within the network in an endless circle. Normally Routing Loop is a problem
associated with Distance Vector Protocols.

Dynamic Routing Protocols Types


 Routing Protocols: These protocols define the best path or route for data transmission
and helps to build and update the routing table.
Examples: RIP, IGRP, EIGRP, OSPF, IS-IS
 Routed Protocols: These protocols define routing and addressing which is used to
send the user data from one network to another. Based on the addressing scheme,
you will be able to identify the network to which a host belongs, in addition to
identifying that host on that network. All hosts on an internetwork (routers, servers,
and workstations) can utilize the services of a routed protocol.
Examples: IP, IPX and AppleTalk

Types of Routing Protocol


 Interior Routing Protocol: These are those protocols which are used designed for
use inside a single AS.
An Autonomous System (AS) is a group of networks under a single administrative
control which could be an Internet Service Provider (ISP) or a large Enterprise
Organization. An Interior Gateway Protocol (IGP) refers to a routing protocol that
handles routing within a single autonomous system. IGPs include RIP, IGRP, EIGRP,
and OSPF.
 Exterior Routing Protocol: These are those protocols which are used designed for
use for different AS.
Exterior Gateway Protocol (EGP) is a Routing Protocol which is used to find network
path information between different Autonomous Systems. Exterior Gateway
Protocol (EGP) is commonly used in the Internet to exchange routing table
information. There is only one Exterior Gateway Protocol (EGP) exists now and it is
Border Gateway Protocol (BGP).

Types of Interior Routing Protocol


 Distance Vector Protocol
 Link State Protocol
 Hybrid Protocol
How to configure static routing
The command to implement static routing go to GC mode

IP Route Destination-Network-ID Subnet-Mask Next-Hop-Address

We need to configure routes on each router and make entries of all the networks that are
not directly connected to it in order to establish communication.

Default Routing
A default route is the route that takes effect when no other route is available for an IP
destination address. When the router has only one exit path, then default routing is applied.
Command to implement default routing is.

Ip route 0.0.0.0 0.0.0.0 Next-Hop-Address

Needs to be configured on all the routers present.

Routing Information Protocol (RIP)


RIP is a routing protocol for exchanging routing table information between routers.

Routing updates must be passed between routers so that they can make the proper choice
on how to route a packet and decide the best route for data transfer.
RIP Characteristics:

 Distance Vector Routing Protocol


 Uses hop count as a path selection metric. The number of hops that are between
source and destination.
 Hop count 15 maximum. Can transfer data up to 15 routers.
 Operates at port number 520 (UDP)
 Supports Classful IP and CIDR
 Broadcasts address for routing updates 255.255.255.0

How to configure RIP


Enter GC Mode

Router rip

Then it will enter router configuration mode, after that provide the network IDs of directly
connected networks to the router.
#network 20.0.0.0

#network 10.0.0.0

Escape the configuration mode. Do those steps on all routers.


RIP versions
 RIP v1
 RIP v2

Differences between RIP v1 and RIP v2

RIP V1 RIP V2
It is a Distance Vector Routing Protocol Also a Distance Vector Routing Protocol
Supports Classful Network only Supports both Classful and Classless
Networks
It does not support Authentications It supports Authentications
Hop Count Limit is 15 Hop Count Limit is 15
It does not support for VLSM and It supports for VLSM and discontinuous
discontinuous networks. networks.
It is less secure. It is more secure.
RIPv1 use Broadcast traffic for updates. RIPv2 use Multicast traffic for updates.
255.255.255.255 244.0.0.9
RIPV1 does not provide trigger updates. RIPv2 provides trigger updates.
RIPV1 not send subnet mask to routing RIPv2 send subnet mask to routing table.
table.
RIPv1 don’t support manual route RIPv2 support manual route summarization.
summarization.

How to configure RIP v2


#router RIP

#version 2

#network Network-ID of directly connected networks.

Note: Use “show IP protocols” to check the routing protocol


configured in router.
RIP timers on Cisco Router
RIP uses a couple of timers to do its work.
There are four types of RIP timers

 Route Update Timer


 Route Hold Down Timer
 Route Invalid Timer
 Route Flush Timer

1. Update timer: The default timing for routing information being exchanged by the
routers operating RIP is 30 seconds. Using Update timer, the routers exchange their
routing table periodically.
2. Hold down timer: This is the time for which the router waits for neighbour router to
respond. If the router isn’t able to respond within a given time then it is declared
dead. It is 180 seconds by default. The router sends 6 updates every 30 secs. It will
still hold the routes as valid in the Hold Down timer.
3. Invalid timer: If no update comes until 180 seconds, then the destination router
consider it as invalid. In this scenario, the destination router mark hop count as 16
for that router.

4. Flush time: It is the time after which the entry of the route will be flushed if it
doesn’t respond within the flush time. It is 60 seconds by default. This timer starts
after the route has been declared invalid and after 60 seconds i.e. time will be 180 +
60 = 240 seconds. (It sends two more updates before flushing which takes 60 secs)

Note: Use “show IP protocols” to check the RIP timers configured in


router.
How to change default values of RIP timers
Go to Global configuration mode and type
#router rip

#timer basic update-timer(secs) invalid-timer(seconds) holddown-timer(secs) flush-


timer(secs)
You can press ? after every entry to check the range and type of timer.

Ex- #timer basic ? #timer basic 100 ?


Interior Gateway Routing Protocol (IGRP)
 It was developed by Cisco
 It is a Distance Vector routing protocol for exchanging routing table information
between routers.
 It exchanges routing information with an Autonomous System (AS) number.
 Routing table update timer 90 seconds
 Uses Delay and Bandwidth as a path selection metric.
 Hop count 255 maximum , default is 100
 Operates at port number 520 (UDP)
 Supports only Classful IP
 Does not support CIDR and VLSM
 It performs broadcast to exchange information with routers.

Many latest Cisco routers does not support IGRP.

Note: An autonomous system (AS) is a very large network or group of networks with a
single routing policy. Each AS is assigned a unique ASN, which is a number that identifies
the AS.
An Autonomous System (AS) is a set of Internet routable IP prefixes belonging to
a network or a collection of networks that are all managed, controlled and supervised by a
single entity or organization. An AS utilizes a common routing policy controlled by the entity.
An autonomous system number (ASN) is a unique number assigned to an autonomous
system (AS) by the Internet Assigned Numbers Authority (IANA).

Enhanced Interior Gateway Routing Protocol (EIGRP)


 It was developed by Cisco
 It is a Hybrid Routing Protocol for exchanging routing table information between
routers.
 It exchanges information within an autonomous system.
 Upgraded version of IGRP
 It is the only protocol that has a backup of every route. Which means if one route is
down it has an alternate route to transfer data.
 Uses delay, bandwidth, load and reliability as a path selection metric.
 Hop count is 224 maximum, default is 100. Means it can provide routes up to 224
routers.
 It operates at port number 88
 Supports Classful IP
 Supports CIDR and VLSM
 Uses multicast to exchange routing information between routers using 224.0.0.10
How to Configure EIGRP
EIGRP uses Autonomous System Number. All routers must be under the same ASN.

Select an ASN below


#router eigrp ?

#router eigrp 100 (ASN)

#network 10.0.0.0 (Directly Connected)


#network 20.0.0.0 (Directly Connected)

Exit

Open Shortest Path First (OSPF)


 It was developed by Cisco
 OSPF is a link state routing protocol for exchanging routing table information
between routers but only when there is a change in network or its topology. This
prevents unnecessary traffic in the network.
 It uses Process ID to exchange routing information.
 It uses the shortest path for data transmission.
 It uses Area No. to update the routing table.
 Uses Bandwidth as a path selection metric
 Hop count is unlimited
 Operates at IP port number 89
 Supports Classful IPv4 and Ipv6
 Supports CIDR and VLSM
 Uses multicast to exchange routing information between routers using the addresses
224.0.0.5 and 224.0.0.6

There are three update states in OSPF

 LSA (Link State Advertisement)


 LSU (Link State Update)
 LSDB (Link State Database)

OSPF takes help of the above three update states to update its neighbor router’s routing
table and the changes that occurred in the network.

Whenever we provide route to multiple routers using OSPF, the first router generates and
advertisement which is called LSA and sends this to the neighbor router to check the
connectivity between them. It is used to check the link.

When the second router receives the LSA, it also sends back an LSA to confirm the
connectivity. When both the routers have received the LSA packets then the first router
sends an LSU packet in order to share its routing table information. So the LSU is used to
share the routing table.
When the second router receives the LSU packet, it stores the routing table information
inside the LSDB.

In the same way, router 2 sends its routing table using the LSU packet and router 1 after
receiving the packet stores it in LSDB.

This is how routing table is shared by OSPF or is updated on the neighbor router.

Area in OSPF
Every router has routing information stored in the LSDB of all the other routers in the
network.

For example, if a network has 50 routers then every router has the routing information
stored in LSDB of all other 49 routers.

Due to this the size of the LSDB increases, so in order to decrease this size we use Area.

Area converts a large network into small logical networks so that the LSDB size can be
decreased. For example we divide 100 routers into a group of 25 routers and 4 small areas
instead of one large area.

The routers will only share the LSDB information with its own area and not with other areas.

This will reduce the LSDB size.

There are two types of Area:

1. Backbone Area (0)


2. Off-backbone Area (1-65535)
The multiple small areas created are the Off-backbone area. The routers in the off-backbone
area will only share its LSDB database within its area and cannot directly communicate
directly with another off-backbone are.

In order to make off-backbone areas communicate with each other we need a backbone
area. It helps to link off-backbone areas and will help to share and update LSDB of routers in
multiple off-backbone areas.

Wildcard Mask and Process ID


Wildcard Mask

1. It is the inverse of Subnet Mask, it has 32-bit and is represented in decimal number.
It is used in OSPF and ACL.
2. Wildcard Mask of different classes

Class Subnet Mask Wildcard Mask


A 255.0.0.0 0.255.255.255
B 255.255.0.0 0.0.255.255
C 255.255.255.0 0.0.0.255

The On-bit in Subnet Mask is Off-bit in Wildcard Mask and vice-versa.


Process ID

Every process has a unique ID on a router. You can use the same or different process IDs on
routers.

Process ID range is 1-65535

OSPF Configuration on Cisco Router

You might also like