Cisco Tips & Tricks

October 18, 2009

System MTU / ip ospf mtu-igonore

Filed under: ccie, IP Routing, ospf, Switching — ciscotips @ 6:54 pm

I was working on OSPF lab and suddenly on my 3560’s I saw a OSPF adjacency errors.

%OSPF-5-ADJCHG: Process 1, Nbr on
FastEthernet0/0 from EXSTART to DOWN, Neighbor Down: Too many

%OSPF-5-ADJCHG: Process 1, Nbr on
FastEthernet0/0 from DOWN to DOWN, Neighbor Down: Ignore timer expired

Suddenly I realized that may be I have MTU issues as I just completed a Q-in Q lab and changed my switch MTU ,  but to double check

I thought of checking a “debug ip ospf events” … and here it was.

OSPF: Rcv DBD from on
FastEthernet0/0 seq 0x12A6 opt 0x52 flag 0x7 len 32  mtu 1504 state

OSPF: Nbr has larger interface MTU

There are multiple ways to fix this, you can either issue “system mtu 1500” on switches or use an interface level command on Routers “Ip ospf mtu-ignore” . or the third one will be to change MTU on router interfaces ( Least preferred).

when value is changed, it will not be stored in neither running-config
nor startup-config. On Catalyst 3550, this information is stored in a
separate file on the flash. On Catalyst 3560, you can’t see it, unless
you do “show system mtu”.

“system mtu 1500” on switches is the default command. Even when value is changed, it will not be stored in  running-config  or startup-config. On Catalyst 3550, this information is stored in a separate file on the flash. On Catalyst 3560, you can’t see it, unless you do “show system mtu”.

This is one of the well-know gotchas on the actual lab exam.You have to know how to solve this. Hence, when configuring routing protocols on switches, make sure you know what the MTU is.

One important thing to note is that you might break stuff in the lab if you were suppose to configure MTU for q-in q lab and later you changed “System MTU” in your switch to fix OSPF issue.

You can also use system mtu routing 1500 in your switch to fix OSPF issue as this will be only used for routing but for Q-in-Q lab switch MTU will be still used as 1504.

IMHO,Best way to fix this in the lab would be “ip ospf mtu-ignore” under the interface on your router.

MTU  has to be the same on both ends of the link before the neighbor can form adjacency.

July 16, 2009

Cisco Learning Network for your CCIE

Filed under: bgp, ccie, cisco, IP Routing, ospf — ciscotips @ 3:20 pm

Excellent resource to master IP routing ( IGP’s and BGP) with following free Lab resources from Cisco Learning Network. These labs are used for training Cisco TAC .

You will need a CCO username/password to access these free labs.


October 24, 2007

E1/E2 routes in OSPF

Filed under: IP Routing, ospf, Router — ciscotips @ 7:41 am

In OSPF we have 2 types of external routes. E1 and E2

For example 

R1#show ip route
Codes: C – connected, S – static, I – IGRP, R – RIP, M – mobile, B – BGP
D – EIGRP, EX – EIGRP external, O – OSPF, IA – OSPF inter area
N1 – OSPF NSSA external type 1, N2 – OSPF NSSA external type 2
E1 – OSPF external type 1, E2 – OSPF external type 2, E – EGP

Route redistribution is the process of taking routes learned via one routing protocol and injecting those routes into another routing domain. (Static and connected routes can also be redistributed.) When a router running OSPF takes routes learned by another routing protocol and makes them available to the other OSPF-enabled routers it’s communicating with, that router becomes an Autonomous System Border Router (ASBR). Let’s say R1 is running both OSPF and RIP. R4 is in the same OSPF domain as R1, and we want R4 to learn the routes that R1 is learning via RIP. This means we have to perform route redistribution on the ASBR. The routes that are being redistributed from RIP into OSPF will appear as E2 routes on R4:R4#show ip route ospfO E2 [110/20] via, 00:33:21, Ethernet06.0.0.0/32 is subnetted, 1 subnets

E2 is the default route type for routes learned via redistribution. The key with E2 routes is that the cost of these routes reflects only the cost of the path from the ASBR to the final destination.  It will not reflect the correct “Cost” or path. 

Now if  we want the cost of the routes to reflect the entire path, not just the path between the ASBR and the destination network. The routes must be redistributed into OSPF as E1 routes on the ASBR, as shown here.

R1(config)#router ospf 1
R1(config-router)#redistribute rip subnets metric-type 1
Now on R4, the routes appear as E1 routes and have a larger metric, since the entire path cost is now reflected in the routing table.O E1 [110/94] via, 00:33:21, Ethernet06.0.0.0/32 is subnetted, 1 subnets

July 15, 2007

Redistributing Default Route in OSPF

Filed under: IP Routing, ospf — ciscotips @ 3:15 pm

redistribute static subnets command is used to redistribute static routes in OSPF, However static default route (ip route…) is not injected in to OSPF topology database. IF you want to redistribute static route in OSPF, following command should be used with in the router ospf configuration.

default-information originate always

Incase you issue above command without static route being configured, router will inject type 5 LSA for the default route in OSPF topology database.

October 10, 2006

Cisco Simulator for CCIE’s

Filed under: bgp, cisco, IP Routing, ospf, QOS — ciscotips @ 8:17 pm

what cisco simulator !!! Are you crazy… No I am not!

My frenz never believed me that I am using a cisco simulator for my CCIE lab practice. My simulator can support direct images of 7200 and now 3600 series. Hard to believe!

check this out

May 18, 2006

OSPF shortcut

Filed under: IP Routing, ospf — ciscotips @ 5:58 pm

Many of the newbies get confused while configuring OSPF network statements. Wild card masks are sometimes a pain. Although I have already covered wild card masks usage in my earlier post. Here is an example in lieu to OSPF.

OSPF usage

router ospf process id
network x.x.x.x wildcardmask area area-id

interface serial0
ip address

To add serial0 in OSPF, command will be

router ospf 100 —-> 100 is a process id
network area 0

Here we have used wild card mask. but you know we can accomplish the same task with following:-

router ospf 100
network area 0

Here we are directly advertising interface address rather then network. This is a convenient method as you don't have to always worry abt wild card masks.

May 15, 2006

Preferring OSPF over EIGRP routes

Filed under: IP Routing, ospf — ciscotips @ 8:15 pm

When we have two different routing protocols running, there is always a confusion in route preference. Lets say if we have both EIGRP and OSPF running in our backbone, routes learned from EIGRP will be preferred because OSPF has a default administrative distance of 110 and EIGRP has a default administrative distance of 90 for internal routes.

If the same route prefixes are learned under both routing protocols, EIGRP-learned routes will be installed into the IP routing table because of the lower administrative distance (90 is less than 110). The key to having OSPF routes installed in the Routing Information Base (RIB), instead of EIGRP routes, is to make the administrative distance of OSPF less than that of EIGRP using the distance command.

Usage as per Cisco command refference:-

distance ospf

To define OSPF route administrative distances based on route type, use the distance ospf command in router configuration mode. To restore the default value, use the no form of this command.

distance ospf {[intra-area dist1] [inter-area dist2] [external dist3]}

no distance ospf

Syntax Description
intra-area dist1
(Optional) Sets the distance for all routes within an area. The default value is 110.

inter-area dist2
(Optional) Sets the distance for all routes from one area to another area. The default value is 110.

external dist3
(Optional) Sets the distance for routes from other routing domains, learned by redistribution. The default value is 110.

dist1: 110

dist2: 110

dist3: 110

Command Modes
Router configuration

Usage Guidelines
You must specify at least one of the keyword-argument pairs.

This command performs the same function as the distance command used with an access list. However, the distance ospf command allows you to set a distance for an entire group of routes, rather than a specific route that passes an access list.

A common reason to use the distance ospf command is when you have multiple OSPF processes with mutual redistribution, and you want to prefer internal routes from one over external routes from the other.

The following example changes the external distance to 200, making the route less reliable:

Router A Configuration

router ospf 1

redistribute ospf 2 subnet

distance ospf external 200


router ospf 2

redistribute ospf 1 subnet

distance ospf external 200

Router B Configuration

router ospf 1
redistribute ospf 2 subnet

distance ospf external 200
router ospf 2

redistribute ospf 1 subnet

distance ospf external 200

May 9, 2006


Filed under: IP Routing, ospf — ciscotips @ 9:38 pm

CISCO uses the formula 108/Bandwidth (of an interface) to calculate the interface cost. This produces the following costs for the interfaces :

Interface Type Bandwidth Cost


45,045,00 2
Ethernet 10,000,000 10
Fast Ethernet 100,000,000 1

This formula is usable for interface speeds up to 100Mb, but with the introduction of high speed SONET and ATM interfaces in the network, this approach is not adequate. The following example will illustrate the problem.

Using a OC-3 interface, the bandwidth for this interface is 155,000,000. Using the formula 108/155,000,000 = 0.645. OSPF will round all decimals to 1, making it equal to the cost of a fast Ethernet interface. The same would hold true for OC-12, OC-48, and Gigabit Ethernet interfaces. Obviously, this would cause routing problems within the network. having interfaces with different bandwidths having the same cost.

CISCO provides a solution within certain router IOS software to be able to control how OSPF calculates the default metrics for an interface. This feature is enabled under the router ospf process using the ospf auto-cost reference-bandwidth ref-bw. Where ref-bw is the rate in megabits per second (bandwidth). The range is 1 to 4294967; the default is 100. The formula is now changed to be Reference-bandwidth/interface bandwidth. This feature allows us to globally change how the costs are determined by interface speed. This command was introduced in CISCO IOS release 11.2.

Conclusion:- If you are using OC-3 and higher links, you should enable ospf auto-cost reference-bandwidth under your router ospf process. Depending on your organizations routing policies you can implement different methods. The best practice here is specifying ip ospf cost manually for every interface. This is a best method to avoid confusion in route selection.

May 4, 2006

Load Balancing

Filed under: IP Routing, ospf — ciscotips @ 9:13 pm

Load balancing has always been a trivial issuse for many Cisco engineers.There has never been a shortcut for a load balancing.

If you are running OSPF, don’t try any method of load balancing. A simple tip out here is that OSPF will do equal cost lad balancing by default so if you want to load balance between two links, simply make there cost equal. use ip ospf cost command in interface mode.

The IGRP and EIGRP routing processes also support unequal cost load-balancing. You can use the variance command with IGRP and EIGRP to accomplish unequal cost load-balancing.

You can usually use the show ip route command to find equal cost routes. For example, below is the show ip route command output to a particular subnet that has multiple routes. Notice there are two routing descriptor blocks. Each block is one route. There is also an asterisk (*) next to one of the block entries. This corresponds to the active route that is used for new traffic. The term ‘new traffic’ corresponds to a single packet or an entire flow to a destination, depending on the type of switching configured.

For process-switching—load balancing is on a per-packet basis and the asterisk (*) points to the interface over which the next packet is sent.

For fast-switching—load balancing is on a per-destination basis and the asterisk (*) points to the interface over which the next destination-based flow is sent.

The position of the asterisk (*) keeps rotating among the equal cost paths each time a packet/flow is served.

M2515-B# show ip route
Routing entry for
Known via “rip”, distance 120, metric 1
Redistributing via rip
Advertised by rip (self originated)
Last update from on Serial1, 00:00:00 ago
Routing Descriptor Blocks:
*, from, 00:00:18 ago, via Serial0
Route metric is 1, traffic share count is 1, from, 00:00:00 ago, via Serial1
Route metric is 1, traffic share count is 1

Per-Destination and Per-Packet Load Balancing
You can set load-balancing to work per-destination or per-packet. Per-destination load balancing means the router distributes the packets based on the destination address. Given two paths to the same network, all packets for destination1 on that network go over the first path, all packets for destination2 on that network go over the second path, and so on. This preserves packet order, with potential unequal usage of the links. If one host receives the majority of the traffic all packets use one link, which leaves bandwidth on other links unused. A larger number of destination addresses leads to more equally used links. To achieve more equally used links use IOS software to build a route-cache entry for every destination address, instead of every destination network, as is the case when only a single path exists. Therefore traffic for different hosts on the same destination network can use different paths. The downside of this approach is that for core backbone routers carrying traffic for thousands of destination hosts, memory and processing requirements for maintaining the cache become very demanding.

Per-packet load-balancing means that the router sends one packet for destination1 over the first path, the second packet for (the same) destination1 over the second path, and so on. Per-packet load balancing guarantees equal load across all links. However, there is potential that the packets may arrive out of order at the destination because differential delay may exist within the network. In Cisco IOS software, except the release 11.1CC, per packet load balancing does disable the forwarding acceleration by a route cache, because the route cache information includes the outgoing interface. For per-packet load balancing, the forwarding process determines the outgoing interface for each packet by looking up the route table and picking the least used interface. This ensures equal utilization of the links, but is a processor intensive task and impacts the overall forwarding performance. This form of per-packet load balancing is not well suited for higher speed interfaces.

Per-destination or per-packet load-balancing depends on the type of switching scheme used for IP packets. By default, on most Cisco routers, fast switching is enabled under interfaces. This is a demand caching scheme that does per-destination load-balancing. To set per-packet load-balancing, enable process switching (or disable fast switching), use these commands:

Router# config t
Router(config)# interface Ethernet 0
Router(config-if)# no ip route-cache
Router(config-if)# ^Z
Now the router CPU looks at every single packet and load balances on the number of routes in the routing table for the destination. This can crash a low-end router because the CPU must do all the processing. To re-enable fast switching, use these commands:

Router# config t
Router(config)# interface Ethernet 0
Router(config-if)# ip route-cache
Router(config-if)# ^Z
Newer switching schemes such as Cisco Express Forwarding (CEF) allow you to do per-packet and per-destination load-balancing more quickly. However, it does imply that you have the extra resources to deal with maintaining CEF entries and adjacencies.

When you work with CEF, you could ask: Who does the load balancing, CEF or the routing protocol used? The way in which CEF works is that CEF does the switching of the packet based on the routing table which is being populated by the routing protocols such as EIGRP. In short, CEF performs the load-balancing once the routing protocol table is calculated.

May 3, 2006


Filed under: IP Routing, ospf — ciscotips @ 4:55 pm

If you are running Open Shortest Path First (OSPF) with static routes and you use the distribute-list command to control the advertisement of these routes, alwaysuse the clear ip ospf redist command if you make a change to the distribute list.If you do not, the routing tables will not reflect the change.W e run Cisco IOS Software Release 12.2(12f) on our Cisco 2600 routers and the IP OSPF priority does not appear to have any effect when the DR fails or recovers.So if this situation occurs, I use the clear ip ospf proc command on the current DR rather than reloading it.

Create a free website or blog at