OSPF area types
By stretch | Tuesday, June 24, 2008 at 12:31 a.m. UTC
Advancing from last week's discussion on OSPF network types, today's topic is a source of considerable confusion for many people new to OSPF: area types. Recall that a large OSPF domain is typically broken into separate areas to restrict the propagation of routes and reduce the amount of resources required by each router to maintain its link state database. Each area is connected to a central backbone, area zero.
OSPF relies on several types of Link State Advertisements (LSAs) to communicate link state information between neighbors. A brief review of the most applicable LSA types:
- Type 1 - Represents a router
- Type 2 - Represents the pseudonode (designated router) for a multiaccess link
- Type 3 - A network link summary (internal route)
- Type 4 - Represents an ASBR
- Type 5 - A route external to the OSPF domain
- Type 7 - Used in stub areas in place of a type 5 LSA
LSA types 1 and 2 are found in all areas, and are never flooded outside of an area. Whether the other types of LSAs are advertised within an area depends on the area type, and there are many:
- Backbone area (area 0)
- Standard area
- Stub area
- Totally stubby area
- Not-so-stubby area (NSSA)
Let's begin by examining a standard area. Note that the backbone area is essentially a standard area which has been designated as the central point to which all other areas connect, so a discussion of standard area behavior largely applies to the backbone area as well.
In the example above, router 2 acts as the area border router (ABR) between a standard area and the backbone. R3 is redistributing routes from an external domain, and is therefore designated as an autonomous system boundary router (ASBR).
As mentioned, type 1 and 2 LSAs are being flooded between routers sharing a common area. This applies to all area types, as these LSAs are used to build an area's shortest-path tree, and consequently only relevant to a single area. Type 3 and 5 LSAs, which describe internal and external IP routes, respectively, are flooded throughout the backbone and all standard areas. External routes are generated by an ASBR, while internal routes can be generated by any OSPF router.
Note the peculiar case of type 4 LSAs. These LSAs are injected into the backbone by the ABR of an area which contains an ASBR. This is to ensure all other routers in the OSPF domain can reach the ASBR.
Standard areas work fine and ensure optimal routing since all routers know about all routes. However, there are often situations when an area has limited access to the rest of the network, and maintaining a full link state database is unnecessary. Additionally, an area may contain low-end routers incapable of maintaining a full database for a large OSPF network. Such areas can be configured to block certain LSA types and become lightweight stub areas.
In this next example, R2 and R3 share a common stub area. Instead of propagating external routes (type 5 LSAs) into the area, the ABR injects a type 3 LSA containing a default route into the stub area. This ensures that routers in the stub area will be able to route traffic to external destinations without having to maintain all of the individual external routes. Because external routes are not received by the stub area, ABRs also do not forward type 4 LSAs from other areas into the stub.
For an area to become a stub, all routers belonging to it must be configured to operate as such. Stub routers and non-stub routers will not form adjacencies.
Router(config-router)# area 10 stub
This idea of substituting a single default route for many specific routes can be applied to internal routes as well, which is the case of totally stubby areas.
Totally Stubby Areas
Like stub areas, totally stubby areas do not receive type 4 or 5 LSAs from their ABRs. However, they also do not receive type 3 LSAs; all routing out of the area relies on the single default route injected by the ABR.
A stub area is extended to a totally stubby area by configuring all of its ABRs with the
Router(config-router)# area 10 stub no-summary
Stub and totally stubby areas can certainly be convenient to reduce the resource utilization of routers in portions of the network not requiring full routing knowledge. However, neither type can contain an ASBR, as type 4 and 5 LSAs are not permitted inside the area. To solve this problem, and in what is arguably the worst naming decision ever made, Cisco introduced the concept of a not-so-stubby area (NSSA).
An NSSA makes use of type 7 LSAs, which are essentially type 5 LSAs in disguise. This allows an ASBR to advertise external links to an ABR, which converts the type 7 LSAs into type 5 before flooding them to the rest of the OSPF domain.
An NSSA can function as either a stub or totally stubby area. To designate a normal (stub) NSSA, all routers in the area must be so configured:
Router(config-router)# area 10 nssa
Type 3 LSAs will pass into and out of the area. Unlike a normal stub area, the ABR will not inject a default route into an NSSA unless explicitly configured to do so. As traffic cannot be routed to external destinations without a default route, you'll probably want to include one by appending
default-information-originate (thanks to Adam for pointing this out).
Router(config-router)# area 10 nssa default-information-originate
To expand an NSSA to function as a totally stubby area, eliminating type 3 LSAs, all of its ABRs must be configured with the
Router(config-router)# area 10 nssa no-summary
The ABR of a totally stubby NSSA (or not-so-totally-stubby area, if you prefer) injects a default route without any further configuration.
- Standard areas can contain LSAs of type 1, 2, 3, 4, and 5, and may contain an ASBR. The backbone is considered a standard area.
- Stub areas can contain type 1, 2, and 3 LSAs. A default route is substituted for external routes.
- Totally stubby areas can only contain type 1 and 2 LSAs, and a single type 3 LSA. The type 3 LSA describes a default route, substituted for all external and inter-area routes.
- Not-so-stubby areas implement stub or totally stubby functionality yet contain an ASBR. Type 7 LSAs generated by the ASBR are converted to type 5 by ABRs to be flooded to the rest of the OSPF domain.
Posted in Routing
June 24, 2008 at 12:35 p.m. UTC
Very good job on this documentation!
June 24, 2008 at 3:17 p.m. UTC
Best description I've seen.
June 25, 2008 at 1:27 a.m. UTC
That was really really good...
June 25, 2008 at 2:52 p.m. UTC
Just for clarification in the last diagram.....the NSSA area, (R2) will only inject a default route automatically if the "no-summary" keyword is added. It will not inject a default route otherwise. Try saying Not-So-Totally-Stubby-Area 3 times fast
June 25, 2008 at 4:31 p.m. UTC
Thanks for pointing this out, Adam. While you can have a default route injected into an NSSA without configuring it as totally stubby, the 'default-information-originate' parameter needs to be explicitly included, and this was overlooked in my review. I've updated the post to reflect the change. Thanks again!
July 7, 2008 at 7:44 a.m. UTC
Well done :)
November 14, 2008 at 11:11 a.m. UTC
Thank you very much, that was very helpful. But I am confused, what is the benefit of Standard Areas (apart from the logical partitioning of the topology)? Standard Area internal routers still have a complete link state database, right?
December 11, 2008 at 3:40 a.m. UTC
i Am studing for CCNP, this explicattion is the best yhat i have read. thank a lot
January 5, 2009 at 7:22 a.m. UTC
This is the best article i have seen regarding OSPF Area & LSA types
January 8, 2009 at 4:09 a.m. UTC
So lucid and descriptive..
January 13, 2009 at 3:56 p.m. UTC
i just wanted to ask about one thing, which i think is a little bit confusing. i am going through all your articles and i believe this is either unclear or wrong. your sentence in this article "ospf area types" >> quote: Note the peculiar case of type 4 LSAs. These LSAs are injected into the backbone by the ABR of an area which contains an ASBR. This is to ensure all other routers in the OSPF domain can reach the ASBR. << end of quote. if you compare this with your previous article about ospf LSA type 4, it is there where you write, that the LSA type 4 is being advertised by other ABRs, not the one which contains the ASBR. can you tell me whether i did not understand it correctly or maybe you did not write it the same way? anyway, thanks very much for your work. me and my colleagues who read your articles wonder, whether you have any free time at all...sports, girlfriend, etc. have a good day
April 20, 2009 at 8:29 a.m. UTC
Very simple, very clear!
Really best document I've seen.
June 26, 2009 at 12:41 a.m. UTC
Is type#4 LSA allowed in Stub areas?
In the Summary only types#1, 2 and 3 are mentioned under 'Stub Area'.
July 3, 2009 at 6:44 p.m. UTC
Very simple and clear description.
Thanks a lot.
July 21, 2009 at 9:17 a.m. UTC
what if we an ASBR in area O, in that case what LSAs will be propogated inside Area 0.
August 28, 2009 at 5:54 p.m. UTC
PERFECT!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! GOOD EFFORT.... can any one tell me what is the similarity between area 0 and non area 0.. ? in just one line.
August 30, 2009 at 10:24 a.m. UTC
Hi, Good article, but I've found a mistake. R2 on the last diagram is not sending LSA type 4, because NSSA ABR never sends LSA type 4. As per RFC 3101, page 5: "Also an NSSA's border routers never originate Type-4 summary-LSAs for the NSSA's AS boundary routers, since Type-7 AS-external-LSAs are never flooded beyond the NSSA's border." As Type-4 describes how to reach the sender of Type-5, the ABRs towards other areas will flood Type-4 LSAs
Good luck !
September 11, 2009 at 5:40 a.m. UTC
Really helpful article.....
October 3, 2009 at 8:31 p.m. UTC
As CCIE running for my Recertification I can honestly say: This is clearly the best explanation of this stuff I've ever read. Thanks and congrats
November 24, 2009 at 4:18 a.m. UTC
I have one basic question about type3 and type4 lsa. Why do we need type4 when type3 can do the same to reach external routes?. Anyways type3/4 are generated by ABR, then y need type4 ??
can any1 help me understand this ?
November 25, 2009 at 7:33 a.m. UTC
In continuation to my earlier post, Take for eg: stub area, where there is a type 3 lsa (Default route) to reach any inter area or external routes.
January 4, 2010 at 3:38 a.m. UTC
thank full it is very good to understand . it is like spoon feeding
February 2, 2010 at 4:31 a.m. UTC
good work ...amazing
March 31, 2010 at 9:56 a.m. UTC
Fantastic job buddy, Thank you so much
October 13, 2010 at 10:45 a.m. UTC
HI I think this is one among the best document regarding the ospf and the LSA types
October 22, 2010 at 9:19 a.m. UTC
Thank you for the post Jeremy.
December 6, 2010 at 12:21 p.m. UTC
Great work thanks!!
December 30, 2010 at 5:11 p.m. UTC
To solve this problem, and in what is arguably the worst naming decision ever made, Cisco introduced the concept of a not-so-stubby area (NSSA). Love that !! They made it even worse with their 'totally NSSA' area!!!
January 9, 2011 at 9:42 a.m. UTC
Good diagram illustrating area types: https://learningnetwork.cisco.com/docs/DOC-7995
January 11, 2011 at 5:51 a.m. UTC
Thanks a Lot
Your article help me a lot.
February 8, 2011 at 5:01 a.m. UTC
I appreciate your effort on this one. However this is good for a entry level person. Please include bit level information so that it looks more interesting.
February 8, 2011 at 2:55 p.m. UTC
@Sandesh: Try doing some research yourself: http://tools.ietf.org/html/rfc2328
February 26, 2011 at 5:03 p.m. UTC
Real good article!!! A short clear summary of LSAs and OSPF areas
September 17, 2011 at 6:34 p.m. UTC
Good explanation, easy to understand .
September 23, 2011 at 12:46 p.m. UTC
October 4, 2011 at 1:51 a.m. UTC
Great write up! Thanks for sharing, the role of the NSSA regarding an ASBR has escaped me until now.
October 24, 2011 at 5:05 p.m. UTC
YOU ARE A LIFE SAVER.....NEVER THOUGHT THAT THIS COULD BE EXPLAINED IN SO EASY TERMS.............KUDOS...
October 25, 2011 at 7:49 a.m. UTC
Very good page!
Easy to learn, ease to teach.
October 25, 2011 at 11:49 a.m. UTC
Best description I have seen on the subject so far. Kudos
January 6, 2012 at 6:05 p.m. UTC
January 16, 2012 at 4:05 p.m. UTC
Great Job.Thanks for sharing!!!!
January 17, 2012 at 9:51 p.m. UTC
Not-so-stubby areas implement stub or totally stubby functionality yet contain an ASBR. Type 7 LSAs generated by the ASBR are converted to type 5 by ABRs to be flooded to the rest of the OSPF domain.
This article is very well done, but this two rows are genial. this is the first time i can summarize the NSSA confusion cisco implemented!!!
February 3, 2012 at 1:04 a.m. UTC
Thanks for a wonderful post. As Andy mentioned, in that last diagram, NSSA ABR wouldn't send Type 4 into the backbone.
February 29, 2012 at 4:28 a.m. UTC
March 1, 2012 at 5:47 p.m. UTC
Best description of OSPF area/LSA types I'v ever seen! Thanks.
March 9, 2012 at 3:33 p.m. UTC
Anybody can shed some light on why in NSSA area, when we redistribute static routes pointing to the client's PI address space are not being redistributed into OSPF backone 0 area ?
March 28, 2012 at 10:46 p.m. UTC
Thank this clear explaination is just what i needed
March 29, 2012 at 6:51 a.m. UTC
Very good article!!! This article helped me get a much better handle on OSPF. Thank you Jeremy!
May 29, 2012 at 4:41 p.m. UTC
One just can't leave without thanking you for this explanation :)
June 2, 2012 at 4:34 p.m. UTC
Wow......finally could decipher the LSA's and area types.....one stop repository....thanks!
June 5, 2012 at 1:13 p.m. UTC
Isn't the NSSA picture (the 3rd picture) actually depicting a Totally NSSA area as the type 3 messages are missing?
June 11, 2012 at 2:02 a.m. UTC
June 24, 2012 at 2:35 a.m. UTC
i appreciate your efforts
it was wonderful, and it was my only way to understand this subject
thx a lot
July 28, 2012 at 7:40 a.m. UTC
Really good explanation, one of the best I've seen.
August 12, 2012 at 5:08 p.m. UTC
thanks a lot
October 30, 2012 at 7:35 p.m. UTC
Very good & easy discription...but i have a question....
How many stub areas can connected to Backbone area through ABR? means what is the amount of stub arae 1,2,3,4,5.....
November 16, 2012 at 1:26 p.m. UTC
Thanks for that. A great article on area types and also helped clarify LSA types into the bargain, definitely one of the best documents i have read on the subject. This entire is awesome, although it can get a little detailed at times, i often wind up here as a point of reference for my CCNP studies.
November 24, 2012 at 9:41 a.m. UTC
thank you very much Mr. Jeremy .Itwas really useful for me.
December 31, 2012 at 7:56 a.m. UTC
Very well explain. Good job man !
January 28, 2013 at 7:21 p.m. UTC
very nice work done man
February 22, 2013 at 9:31 a.m. UTC
dont ask me why but i was getting confused before..
this has cleared it for me...
March 21, 2013 at 7:27 p.m. UTC
April 14, 2013 at 11:15 a.m. UTC
Great explanation, Cisco can't even top this. Good work!
April 24, 2013 at 9:23 a.m. UTC
Very simple and clear explanation.
June 12, 2013 at 6:54 a.m. UTC
Good blog , understood how ospf area and types are propagated.
July 19, 2013 at 8:05 a.m. UTC
September 9, 2013 at 11:00 a.m. UTC
As always Jeremy great job. This is probably one of the best summarization of OSPF areas and their roles/purpose on the net.
October 17, 2013 at 1:24 a.m. UTC
November 21, 2013 at 2:29 a.m. UTC
Still up-to-date and one of the best resources, congrats.
December 6, 2013 at 2:41 a.m. UTC
I have a doubt. I think NSSA does not generate a default route (by default) untill
Area nssa default-information-originate.
Am i wrong in thinking that?
I Must say. Your articles are so helpful.
Thank you for sharing all of your beautiful stuffs with us.
May 17, 2014 at 5:19 p.m. UTC
Thanks, best explanation on the net!
May 20, 2014 at 7:08 a.m. UTC
I was always confused on OSPF Area types since i have known them, but thanks to this article i am no more confused. Also the ambiguities about LSA-types are also cleared. The best Explanation ever. keep it up
May 20, 2014 at 9:15 p.m. UTC
Good information, thanks from Spain
June 9, 2014 at 6:54 a.m. UTC
Great job. Thanks a lot mate!
June 12, 2014 at 2:12 a.m. UTC
This is just what I needed. Thank you.
June 23, 2014 at 6:01 a.m. UTC
Great explanation, Thank you for this post.
June 30, 2014 at 7:45 p.m. UTC
Wow, this is still the best explanation of area types in the web. Thanks for the great job, this made understanding way easier for me.
July 1, 2014 at 9:23 a.m. UTC
August 10, 2014 at 10:32 p.m. UTC
Very good presentation! Thanks! :)
August 20, 2014 at 6:59 a.m. UTC
Super stuff :)
August 22, 2014 at 7:43 p.m. UTC
nice and easy
September 28, 2014 at 10:00 a.m. UTC
Very simple and clear explanation,Thanks for sharing.
October 1, 2014 at 8:09 p.m. UTC
Thanks for this!
October 3, 2014 at 8:13 p.m. UTC
I read about this on the certification guide book from Cisco but it was very confusing. I was pulling my hair until I found your post. Thank you so much! Now I have a better understanding of ospf area types. Although I still think nssa defeats the purpose of using stub in the first place :/
October 22, 2014 at 10:10 a.m. UTC
Thanks Jeremy, That was a next good piece of information which I found here. Anyway as all posted here already.
I wish you all the best buddy!
November 3, 2014 at 7:12 a.m. UTC
November 7, 2014 at 11:54 a.m. UTC
Hi Thanks for the great explanation jeremy.. I have a samll doubt... What is requirement of NSSA area... Let us assume that we have Area0 & Area1 and a RIP/EIGRP External network is directly connected to Area 1.. So what happens.. Does the LSA type 5 flow to Area 0 ?
November 10, 2014 at 6:26 a.m. UTC
For the statement
The illustration for NSSA shows a default route towards the NSSA Area, that is actually optional if you explicitly declare default-information originate, isn't it?
January 7, 2015 at 9:21 p.m. UTC
January 15, 2015 at 6:59 a.m. UTC
Well explained. Precise and to the point.
January 16, 2015 at 6:16 a.m. UTC
Great article: visually and logically clear and concise. I did notice however, that in the NSSA diagram you did not show the type 3 LSA/s which would be propagated into the NSSA. It may also assist understanding, if the 'default' arrows additionally stated: Single Type 3 LSA.
January 28, 2015 at 2:05 p.m. UTC
February 8, 2015 at 5:38 p.m. UTC
Have not touched OSPF in 3y 11m and 29d and have to recert. Thank goodness for good notes and your diagrams to keep it simple and knock the cob webs out!
March 10, 2015 at 10:49 a.m. UTC
Great article man! The NSSA illustration should reflect LSA Type 3 allowed into the NSSA area and the default should reflect being optional. Thanks, Chris
April 20, 2015 at 5:50 a.m. UTC
Thanks. Well explained and easy to digest.
May 18, 2015 at 6:06 p.m. UTC
Bravo ! superb article which is really well explained Well done
June 12, 2015 at 2:41 a.m. UTC
Jeremy you did an excellent and lucid presentation of the most important element of OSPF. Thank You!!!
June 21, 2015 at 6:04 p.m. UTC
July 19, 2015 at 6:05 a.m. UTC
You have best notes on the NET, to make it more perfect, for “Totally Stubby Areas” as you said that ABR advertises summary routes into the “Totally Stubby Area” but other areas connected to the ABR receive all route updates of routes that exist in “Totally Stubby Areas”.
I just tested this in the lab. Probably if you put a note that would be BEST.
July 21, 2015 at 3:33 a.m. UTC
You explain the topic on stub areas very clear, for us newbies like me. Thank you very much. Btw, hope you can include a diagram on Totally Stubby NSSA. :)
November 4, 2015 at 8:43 p.m. UTC
Described in a way that I can finally put this to rest
November 11, 2015 at 5:56 p.m. UTC
thank you for your effort
January 12, 2016 at 12:44 p.m. UTC
Very nice article, kudos for the good work. I find little difficult to understand NSSA. I think the diagram must is using area 0 to show as NSSA because the arrows are showing converting the type 7 to type 5 LSA from right to left. But NSSA area is shown in the Right.Seems little confusing to me.
January 21, 2016 at 9:34 a.m. UTC
Great article with clear explanation!
January 22, 2016 at 3:07 a.m. UTC
Thank you very much for the nice explanation man!
February 3, 2016 at 3:32 p.m. UTC
I can only attest that to this day, this system is probably one of the most confusing naming conventions that has ever been made up by a technology vendor.
It's not that difficult, but the naming just doesn't help to make it clear.
June 16, 2016 at 1:59 a.m. UTC
Nice explaination, very straightforward.
June 23, 2016 at 2:12 p.m. UTC
Great, I didn't understand the nssa, now it's ok!
July 25, 2016 at 2:41 a.m. UTC
That is the most accurate interpretation of OSPF any one ever did
July 28, 2016 at 1:05 p.m. UTC
Very good writing-up, as always. I learned a lot form your articles. Thanks a lot for your hard work.
August 15, 2016 at 7:15 p.m. UTC
Great explanation Jeremy,i would add explanation for one more area: The Totally NSSA blocks external routes (LSA Type 5) + inter-area routes (LSA Type 3) but allows an ASBR within the area
September 20, 2016 at 7:45 p.m. UTC
Clear description but if you need more details please visit my blog :) Cheers!
October 8, 2016 at 3:09 a.m. UTC
Thanks a lot, guy