hello welcome to lesson three of the practical ospf series
today's lesson is all about hello packets i'm going to show you all the pieces of information
inside of hello packet and we'll talk through each of their purposes and how they are used
as we mentioned in a previous lesson hello packets are sent by every ospf router
for the purpose of discovering other ospf neighbors these hello packets
are sent periodically to the multicast address 224.0.0.5 this address will reach any ospf router
by default for the most common network types these hello packets are sent out every 10
seconds but there are other network types that are going to talk about with different defaults
and you can of course configure any hello interval that you like now some network types do not
support multicast addresses meaning you can't send something to a multicast address these are known
as non-broadcast networks we're going to talk about them in more detail later on in this series
but for those types of networks since you can't send something to a multicast address to discover
other neighbors an administrator needs to manually configure the neighbor's ip address in those cases
the hello packets are then sent unicast directly to the ip address that was configured manually
this is how hello packets are still used to reach other neighbors and build a neighbor adjacency
even on networks that don't support multicast but the most common networks
do support multicast and you'll see these hello packets sent to the multicast address
inside these hello packets is a bunch of information and that information is what's
going to be used by the routers to determine if a full neighbor adjacency is going to form
so with that said let's start talking about some of the pieces of information inside a hello packet
first piece of information inside a hello packet that we're going to discuss is the router id
the router id is the identity of each router and in this case router 2's router id is 2.2.2.2
now that may look like an ip address but it's not actually an ip address
it's simply a 32 bit value that we represent using dotted decimal because it's familiar to us
now you might be asking yourself if we have an ip address on this link
why do we need a router id well the idea there is router 2 might end up with a bunch
of different interfaces which means a bunch of different ip addresses and it's nice to have
a single value that can be used to refer to router 2 and all of its connected interfaces
that's why ospf uses a router id to identify a router instead of simply an interface ip address
and each router will identify its own router id inside these hello packets the next piece
of information we're going to discuss inside a hello packet is the hello interval this is the
duration in between these periodic hellos in this case router 2 is using the default of 10 seconds
meaning router 2 is planning to send a hello packet every 10 seconds on this link now closely
related to the hello interval is the dead interval timer the dead interval is a duration that a
router is going to remember information about a neighbor if it no longer hears from that neighbor
the idea there is after router 1 and router 2 become full neighbors with one another
router 1 is going to be expecting to see a hello packet from router 2 every 10 seconds if
40 seconds passes without hearing a hello packet from router 2 router 1 will forget everything
that router 2 ever told them and will assume that router 2 is no longer available in the topology
these periodic hellos end up serving as a health check for the router typically the dead timer is
going to be four times the hello interval and you see that here but of course you can configure that
to whatever you want the next piece of information inside a hello packet is the neighbors field
the neighbors field is going to include any other neighbor router ids seen on the link at the moment
router 2's neighbor field in its hello packet is empty the reason for that is at this point
router 2 has simply sent hello packets it hasn't received anything from router 1. so router 2
doesn't know that anyone else actually exists on this link hence it has an empty neighbors
field at some point router 1 is also going to start sending hello packets and after that point
router 2's neighbors field is going to include router 1's router id in that field right there
the purpose that this serves is to verify 2-way reachability on the link winrouter1 is going to
receive this hello packet the hello packets from router 1 are going to include router 2's router id
in the neighbors field if router 2 receives that hello packet this proves to router 2 that router
1 received the initial hello packet and router 1 was able to send a hello packet back to router 2
which proves to router 2 that there is two-way reachability on this link this concept is going
to be very important later on when we discuss the neighbor adjacency process so keep in mind that
the neighbors field is going to include all the router ids seen on this particular link
next we come to the area id this is also a value that is included in hello packets
and you can see here that router 2 thinks this interface is in area 0.
from that we can determine that router 2 must be a backbone router next we have authentication data
often in production networks you only want to do ospf peering with other routers that you designate
well the way you do that is by setting a password within ospf and mandating that
you will only form a neighbor relationship with other routers that include that same password
well that password information is included in the authentication data section of the hello packet
and is included in every single hello packet that is sent by each router in this case router 2 is
not currently doing password restricted peering hence there's nothing in the contents of this
field and finally this brings us to the network mask this is also a value that is included in all
the hello packets in this case router 2 believes this ip address to be a part of a slash 24 network
so those are the first seven items that we've discussed inside a hello packet
we have a few more items to discuss but for each of the items that follow we're going
to go into more detail about them later on in the series for now i just want to
give you their definition give an idea of their purpose inside the ospf hello packet
the first of the additional items inside a hello packet that we're going to discuss
is the area type and there are three options for area type normal stub and nssa to talk
about them we're going to use the same topology we used when we discussed areas back in lesson 2.
the first type of area is a normal area this is actually the default area type meaning if you
don't explicitly tell an area that it is a stub or nssa area it'll assume to be a normal area
in a normal area every type of route is allowed so let me explain that let's say our area 0 has 10
routes and our area 99 also has 10 routes and our area 88 also has 10 routes and the eigrp topology
happens to have 100 routes these 100 routes are going to be redistributed by router 7 into our
ospf domain now if we left area 88 as the default area type meaning a normal area the routers inside
area 88 are going to have the 30 routes from ospf plus the 100 routes that are externally
redistributed into ospf which means if area 88 is a normal area area 88 is going to have 130
routes and with that in mind we can now introduce a stub area a stub area is an optimization of a
normal area it allows you to reduce the amount of routes that exist in a particular area
for example if we made area 88 a stub area what that would do is it would prevent any
redistributed route from appearing in area 88 instead to reach the redistributed networks
area 88 would include a default route pointing the routers inside the stub area to the apr so
if area 88 was a stub area it would only have the 30 routes from ospf plus the one default route
which is going to replace any redistributed route which then brings us to the last area type nssa
and to talk about it we're going to have to change our topology just slightly we're going to have
router 5 redistribute some rip routes now the specific protocol that's in use is arbitrary i'm
simply picking rip and eigrp understand these concepts apply to any form of redistribution
in any case let's just say that there are 50 routes in this rip domain and router 5 is going to
be redistributing all 50 of these routes into area 88 or at least it's going to try to remember where
we left off was that area 88 was a stub area and in a stub area no redistributed routes can exist
which means the routers in area 88 will not accept a redistributed route from this external domain
plus the default route is pointing to the abr away from the asbr so in this design if
area 88 was left as a stub area there would be no connectivity to the 50 networks in this rip domain
now of course we could make area 88 a normal area once again if we did area 88 routers would have
the 30 routes from ospf the 100 from this external domain redistributed by router 7 and the 50 from
this external domain redistributed by router 5 which means if this were the topology and area
88 was a normal area the routers in area 88 would have 180 routes total this is what then brings us
to the third type of area which is sort of like a blend of these two an nssa area is a not so
stubby area it's sort of stubby but not entirely so let me explain an nssa area still doesn't allow
redistributed routes like a stub area but it does allow redistribution from the local area
meaning if area 88 were an nssa route it wouldn't allow the redistributed routes from router 7
but it would allow the redistributed routes from router 5. if we made area 88 an nssa
area the routers in that area would have 80 routes so you can see how it's an optimization that sits
somewhere in between these two area types now the one additional thing i'll mention is that in not
so stubby routes this default route is optional the idea there is we want the administrator
to make that decision because it's possible we may want the default route pointing to the asbr
instead of the default right pointing to the abr that's up to the administrator
either way that's a rundown on the three types of areas that exist in ospf now we're going to go
into more detail about each of these later on in this course for now i simply want to give
you a definition now it's possible i went into more detail than you actually need at this point
but i would rather that than the alternative for now understand that there are three types
of areas and the type of area is advertised by each router inside a hello packet
which brings us to the last item or set of items that we're going to discuss inside a hello packet
and those items are the designated router or the dr the backup designated router or the bdr and the
priority number to talk about these three concepts we're going to extend the topology from router 2.
we're going to add a switch and connect three more routers and we're going to have router 2
router 3 router 4 and router 5 all be neighbors with each other now in normal ospf processing
what happens is as soon as a router learns something new it's instantly going to try
and update all of its neighbors so if rider1 learns a new lsa it's instantly going to say
oh i just learned something new i have to tell my friends and it's going to send an update to
router 2 with the new information router 2 is then going to do the same thing it's going to say oh
i just learned something new i have to tell all of my friends and it's going to send an update
to router 3 router 4 and router 5. then router 3 having just learned something new is now going to
update all of its friends letting its friends know that it learned something new in the same
way router 4 is going to do the same thing and router 5 also will end up doing the same thing
now of course you and i can see that all of this flooding is redundant they're all updating each
other with the same information the way ospf avoids that is by using these three items the
way it works is on a multi-axis segment like this one right here which includes these four routers
a single designated router is elected that designated router is responsible for all the
updates on that link so for example let's say router 3 becomes our designated router
and if the same situation plays itself out and router 2 learns something from router 1
it's only going to send the update to the designated router in this case router 3
and then router 3 is responsible for passing that on to the other routers on this link
this is how ospf avoids the redundant updates when multiple routers exist on the same link
now in addition to a designated router being elected on every link a backup designated router
is also elected the job of the bdr is to take over as the dr if something were to happen to
router 3. and finally the priority number is actually how the selection takes place
the way it works is by default every router interface has a priority number of one
and if i wanted to influence who becomes the dr and the bdr i can set a higher priority number
for instance i can set router 3 as 50 and router 4 as 25 and they would become the dr and the bdr
respectively that's the purpose of these three items and all three of them exist in the hello
packet every router in the hello packet is going to include the ip address of who they think is the
dr the ip address of who they think is the bdr and finally their own interface priority number
the last idea i want to leave you with insofar as this concept is that when i say multi-access
what i mean is any link with the potential for multiple access so here's what i mean by that
look at router 1 and router 2. you and i can see that they are directly connected to each other
but if router 1 and router 2 are connected with an ethernet cable they have no way of knowing
that there's not a hub or a switch on this link as well you and i of course can see this because
we can see the topology but they have no way of knowing that which means at some point in
the future a new router might be added to this link and therefore they would consider this a
multi-access link simply because the technology that they're using supports multiple access
and despite there being only two routers on this link they would still do a dr and bdr election
one of these routers would become the dr and the other one would become the bdr
and so that wraps up our discussion of these three items and we're going to have a dedicated
lesson where you unpack this a bit further for now just know a high level definition of what
each of these three are and understand that each of them are included inside low packets
and with that said we actually wrap up everything we meant to communicate to you
in this lesson to include the first seven items we discussed inside a hello packet
and the four additional items we discussed inside a hello packet
the last idea i want to leave you with is understanding which of these pieces of information
must match for a neighbor adjacency to form i told you earlier that the content of a hello packet is
going to decide whether router 1 and router 2 are going to become neighbors with another
they're going to do that based upon these six pieces of information first the hello interval and
the dead interval those have to match for router 1 and router 2 to become neighbors with another
consider if router 2 is using the default of 10 second hello intervals and 40 second dead
intervals but router 1 is using more aggressive values for instance 2 second hello intervals and
8 second dead intervals what's going to happen is between every one of these periodic hellos
router 1 is going to forget that router 2 exists that's going to cause a lot of topology flapping
therefore these two items must match for router 2 and router 1 to become neighbors with each other
then we have the area id if router 2 thinks this interface is an area 0 and router 1
thinks this interface is in area 25 then they clearly aren't going to understand
how they should share routes with another so they both have to agree what area that they are in
which then brings us to the authentication data and again the whole purpose of authentication data
is to do password restricted peering so if the authentication data that r1 sends doesn't match
the authentication data that r2 sends then clearly they will not become neighbors with another
which then brings us to the network mask and remember if these routers are doing
ospf with each other the purpose is to share routes about the networks that they know about
but if router 2 thinks this network is a slash 24 and router 1 thinks this network is a slash
23 if they can't even come to an agreement on the network that is directly connected between
the two of them then they definitely won't have agreement on the networks that exist on either
side of the routers so while it seems trivial network mask is also a value that must match for
these two routers to become neighbors and finally the area type if router 2 thinks this is a normal
area and router 1 thinks this is a stub area they will not form as a neighbor adjacency they must
agree upon what type of area they are connected to in addition to the actual area number as well
so that wraps up everything we wanted to communicate to you in this lesson
the main takeaway is understanding everything inside a hello packet how it's used and which
pieces must match for two routers to form a neighbor adjacency in the next lesson we're
going to take a look at the actual adjacency process we're going to show you all the packets
and all the neighbor states that two routers will go through in order to become fully adjacent
as always if you enjoyed this content and think it should be shown to a wider audience
you can help me out by liking leaving a comment and subscribing those three things tell youtube
to show this video to more people and they go a long way in encouraging me to continue producing
high quality free training content for you either way that's it for this video
i hope you enjoyed this lesson i want to thank you for watching and we'll see you in the next one