Search This Blog

Thursday, October 28, 2010

OSPF Filtering - Part 1

OSPF use IP protocol 89 to flood LSA's, these LSA's are used to form adjacencies (neighbors relationship), request update and advertise route prefixes and acknowledge these updates and synchronize databases. So we could say that the LSA's are one of the core intergradient when running OSPF.

There are 3 methods of filtering LSA's:

1. Distribute-list

filter routes from the routing table of the specific router, where we configure the list, but not from the LSDB, hence route will continue advertised LSA's to other routers.

Config example:

Router(config)#access-list 1 deny 10.1.0.0 0.0.0.255

Router(config)#access-list 1 permit any

Router(config)#ip ospf 1

Router(config-router)#distribute-list 1 in

In the following example we filter route 10.1.0.0/24 from the routing table, but the route will still exist in the LSDB and will be advertised to adjacent routers.

Distribute-list can affect the LSDB only when filtering from area 0 to other areas, Whereas if we filter from other area to area 0 it will effect only the configured router. Also configuring Distribute-list on an ASBR can filter LSA type 5 and 7 (External and NSSA).

2. Prefix-List

Filters LSA type 3, Inter-area LSA's, hence must be configured on an ABR in order to work.

Config example:

Router(config)#ip prefix-list seq 5 Test deny 11.1.1.0/24

Router(config)#ip prefix-list seq 10 Test permit 0.0.0.0/0 le 32

Router(config)#ip ospf 1

Router(config-router)#
area x filter-list prefix Test out

Area x is the area which the routes we want to filter found in.

The following example is configured on an ABR and will prevent from LSA type 3, from area x with route prefix 11.1.1.0/24, to flood into another area.

3. Summarization

We can summarize and prevent advertisement using ABR/ASBR summarization, it's very similar to the summarization process but with the addition of not-advertise and by that preventing advertisement of the summary route prefix.

For ABR:

Router(config)#ip ospf 1

Router(config-router)#
area x range 11.1.1.0 255.255.255.0 not-advertise

For ASBR:

Router(config)#ip ospf 1

Router(config-router)#
summary-address 50.5.5.0 255.255.255.0 not-advertise

4. Database-Filter

Allows one-way filter of All OSPF LSA but still keeps the adjacency and receiving LSA's from the filtered interface/neighbor.

Interface mode:

Router(config)#ip ospf 1

Router(config-router)#
ip ospf database-filter all out

Neighbor mode:

Router(config)#ip ospf 1

Router(config-router)# neighbor 10.1.34.4 database-filter all out

Can be only configured where two routers are adjacent through Point-to-Multipoint network type.


 

Wednesday, October 27, 2010

OSPF Area Type

There are four area types for OSPF:

Stub

An area which allow only LSA type 1,2 and 3, this area usually have one "way" out, which is through the ABR, but this is not must.

A Stub area can't be a transit for virtual-link but we can use a GRE tunnel instead.

A Stub area cannot have an ASBR

Area 0 (backbone) cannot be a Stub

LSA type 5 describe external routes, but are not allowed in a stub area, so the routers in the stub area can connect external routes via default route which will be injected by the ABR.

Every Router and the ABR should be configured with area x stub

Totally Stub

Even more strict then stub area, totally stub area accepts only LSA type 1 and 2 all other LSA's, including LSA type 3, are prohibited.

Config on every router in the area and on every ABR using the command Router(config)#area x stub no-summary

NSSA (Not So Stubby Area)

Very similar to a stub area but allows an LSA type 7, which describe external routes, hence an ASBR can reside in this area and inject external routes.

Using the command Router(config)#area x nssa

Totally NSSA (Not So Stubby Area)

Similar to NSSA beside that it is not accept LSA type 3

Using the command Router(config)#area x nssa no-summary


To summarize:

The target of the area types is to limit and reduce LSA flooding and by that optimize the routing table for routers in the specific areas.

All areas filter type 5 LSA's!

The totally one's (Stub and NSSA) also stops LSA type 3!

The different between Stub and NSSA is that NSSA allows ASBR to inject external routes using LSA type 7 (unlike the normal LSA type which is type 5).


OSPF LSA Types

Up to 11 LSA types are present but these are the 6 most common:

LSA Type 1 - Router (or Router Link state)

Each router create and flood LSA type 1 for himself. In these LSA's the router describe his directly connected interfaces,

the neighbor routers on each link, in each area. The LSA itself identified by a Link Stated ID (LSID) which is the Router ID (RID).

LSA Type 2 - Network (or Net Link state)

One per network, Advertised by the DR and represent his interfaces in this subnet.

LSA Type 3 - Summary (or Summary Net state)

Created by an ABR to represent LSA's type 1 and 2 when being advertised from one area into another. Define the links and the cost but no topology data.

Take note that ABR's never pass LSA type 1 and 2 from one area to another.

LSA Type 4 - ASBR Summary

Like type 3 LSA except it advertise a host route used to reach an ASBR

LSA Type 5 - AS External

Created by an ASBR for external routes injected into OSPF

LSA Type 7 - NSSA External

Created by an ASBR inside an NSSA area, instead of type 5 LSAs.


 

So in order to summarize this:

Type 1 and 2 are intra-area LSA's, type 3 is Inter-area and cross different areas, Type 4 pointing a route to an ASBR, type 5 describe external routes were type 7 do the same but in special area called NSSA.

Tuesday, October 26, 2010

Jazz music - Scott Hamilton

This post I would like to recommend you about great Jazz CD from Scott Hamilton, a jazz tenor saxophonist, born in 1954 and associated with swing (music) and mainstream jazz.

This CD called Ballad Essentials and it holds great, smooth, classic jazz with Scott's blows on his saxophone...

Enjoy!

Link:

Download (Hotfile/320Kbps/135MB)

OSPF LSA Update

Again working on the following OSPF lab and trying to figure out how does a router update and "erase" routes for neighbor routers?!
While summarize the networks from R4 (10.4.x.x) on the ABR (R3) i have done some packet capture in order to see the process of LSA update. I have run wireshark on the f0/0 interface, on R3, which connected to area 0 (SW1) and here are the results:

Before i have configured summarization on R3, he advertised 4 networks (10.4.0.0, 10.4.1.0, 10.4.2.0, 10.4.3.0) after configuring area 2 range 10.4.0.0 255.255.252.0, R3 which is the DR of area 0 has send two LSA updates to 224.0.0.5 (AllSPFRouters), the first an LSA update with 10.4.0.0/22, take note for the LA age which is 1 and the metric which is 65

The second LSA update packet was with 4 LSA's, 1 identical to the update on the summary address and 3 more, one for each subnet. But this time pay attention to the LS age and metric...

Each subnet was advertised with LS age of 3600 seconds and a metric of 1677215, by that the ABR keeps that the no new request (LSR) regards these subnets will be sent and the metric, which is in it's maximum value, is 16777215 so no SPF calculation will choose this path.

Following these packet capture findings i assume that subnets 10.4.x.x should be placed on the OSPF database for at least 1 hour more (LS age 3600) but i can't find the show command to see them...

Monday, October 25, 2010

OSPF Point-to-Multipoint config

While playing a little bit with an OSPF lab i had to configure Point-to-Multipoint network type,
Using the following Scenario:
(the post is related to R2, R5 and R6 only)

R2, R5 and R6 are all connected using frame-relay, dlci 205-502 connect R2 to R5 and dlci 206-602 connect R2 to R6.

R2 config:
interface Serial0/0
ip address 10.1.56.2 255.255.255.0
encapsulation frame-relay
ip ospf network point-to-multipoint non-broadcast
clock rate 2000000
frame-relay map ip 10.1.56.5 205 broadcast
frame-relay map ip 10.1.56.6 206 broadcast
frame-relay interface-dlci 205
frame-relay interface-dlci 206
no frame-relay inverse-arp
router ospf 1
router-id 2.2.2.2
log-adjacency-changes
network 10.1.56.2 0.0.0.0 area 1
network 10.1.123.2 0.0.0.0 area 0
neighbor 10.1.56.6
neighbor 10.1.56.5

R5 config:
interface Serial0/0
ip address 10.1.56.5 255.255.255.0
encapsulation frame-relay
clock rate 2000000
frame-relay map ip 10.1.56.2 502 broadcast
frame-relay interface-dlci 502
no frame-relay inverse-arp
router ospf 1
router-id 5.5.5.5
log-adjacency-changes
network 5.5.5.5 0.0.0.0 area 1
network 10.1.56.5 0.0.0.0 area 1
neighbor 10.1.56.2

R6 config:
interface Serial0/0
ip address 10.1.56.6 255.255.255.0
encapsulation frame-relay
clock rate 2000000
frame-relay map ip 10.1.56.2 602 broadcast
frame-relay interface-dlci 602
no frame-relay inverse-arp
router ospf 1
router-id 6.6.6.6
log-adjacency-changes
network 6.6.6.6 0.0.0.0 area 1
network 10.1.56.6 0.0.0.0 area 1
network 10.6.0.0 0.0.3.255 area 1
neighbor 10.1.56.2

As you may recall OSPF network type point-to-multipoint doesn't use DR/BDR election and due to the use of the neighbor statement, hello and updates, are exchange via unicast.
But still, although i have configured ospf network type point-to-multipoint on R2 s0/0 interface something is missing and because of that i do see adjacency's but no routing exchange has occur?!

R2#sh ip ospf neighbor

Neighbor ID Pri State Dead Time Address Interface
R1 1 FULL/DROTHER 00:00:39 10.1.123.1 FastEthernet0/0
R3 1 FULL/BDR 00:00:36 10.1.123.3 FastEthernet0/0
6.6.6.6 0 FULL/ - 00:01:46 10.1.56.6 Serial0/0
5.5.5.5 0 FULL/ - 00:01:33 10.1.56.5 Serial0/0

R2# sh ip route
Codes: C - connected, S - static, 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
i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
ia - IS-IS inter area, * - candidate default, U - per-user static route
o - ODR, P - periodic downloaded static route

Gateway of last resort is not set

2.0.0.0/24 is subnetted, 1 subnets
C 2.2.2.0 is directly connected, Loopback0
10.0.0.0/24 is subnetted, 6 subnets
O 10.1.3.0 [110/11] via 10.1.123.1, 00:44:09, FastEthernet0/0
O 10.1.2.0 [110/11] via 10.1.123.1, 00:44:09, FastEthernet0/0
O 10.1.1.0 [110/11] via 10.1.123.1, 00:44:09, FastEthernet0/0
O 10.1.0.0 [110/11] via 10.1.123.1, 00:44:09, FastEthernet0/0
C 10.1.56.0 is directly connected, Serial0/0
C 10.1.123.0 is directly connected, FastEthernet0/0

The reason for this behavior is because i didn't configure the network type on R5 and R6.

R5# sh ip ospf interface s0/0
Serial0/0 is up, line protocol is up
Internet Address 10.1.56.5/24, Area 1
Process ID 1, Router ID 5.5.5.5, Network Type NON_BROADCAST, Cost: 64
Transmit Delay is 1 sec, State DR, Priority 1
Designated Router (ID) 5.5.5.5, Interface address 10.1.56.5
Backup Designated router (ID) 2.2.2.2, Interface address 10.1.56.2
Timer intervals configured, Hello 30, Dead 120, Wait 120, Retransmit 5
oob-resync timeout 120
Hello due in 00:00:16
Supports Link-local Signaling (LLS)
Index 1/1, flood queue length 0
Next 0x0(0)/0x0(0)
Last flood scan length is 1, maximum is 6
Last flood scan time is 0 msec, maximum is 0 msec
Neighbor Count is 1, Adjacent neighbor count is 1
Adjacent with neighbor 2.2.2.2 (Backup Designated Router)
Suppress hello for 0 neighbor(s)

R5 believe that the network is NON_BROADCAST which act differently (DR/BDR election) form PtMP network type.

Configuring the network type on interface s0/0 on R5 and R6 will fix the problem.

R2#sh ip route
Codes: C - connected, S - static, 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
i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
ia - IS-IS inter area, * - candidate default, U - per-user static route
o - ODR, P - periodic downloaded static route

Gateway of last resort is not set

2.0.0.0/24 is subnetted, 1 subnets
C 2.2.2.0 is directly connected, Loopback0
5.0.0.0/24 is subnetted, 1 subnets
O 5.5.5.0 [110/65] via 10.1.56.5, 00:00:01, Serial0/0
6.0.0.0/24 is subnetted, 1 subnets
O 6.6.6.0 [110/65] via 10.1.56.6, 00:00:01, Serial0/0
10.0.0.0/8 is variably subnetted, 12 subnets, 2 masks
O 10.1.3.0/24 [110/11] via 10.1.123.1, 00:51:08, FastEthernet0/0
O 10.1.2.0/24 [110/11] via 10.1.123.1, 00:51:08, FastEthernet0/0
O 10.1.1.0/24 [110/11] via 10.1.123.1, 00:51:08, FastEthernet0/0
O 10.1.0.0/24 [110/11] via 10.1.123.1, 00:51:08, FastEthernet0/0
O 10.6.0.0/24 [110/65] via 10.1.56.6, 00:00:01, Serial0/0
O 10.6.1.0/24 [110/65] via 10.1.56.6, 00:00:01, Serial0/0
O 10.6.2.0/24 [110/65] via 10.1.56.6, 00:00:01, Serial0/0
O 10.6.3.0/24 [110/65] via 10.1.56.6, 00:00:01, Serial0/0
C 10.1.56.0/24 is directly connected, Serial0/0
O 10.1.56.6/32 [110/64] via 10.1.56.6, 00:00:01, Serial0/0
O 10.1.56.5/32 [110/64] via 10.1.56.5, 00:00:01, Serial0/0
C 10.1.123.0/24 is directly connected, FastEthernet0/0

So do pay attention to the network type while configuring OSPF.

Monday, October 18, 2010

OSPF GRE instead of Virtual-link

As you all know each area in an OSPF AS should be connected to the backbone area - area 0.
Basically in order to do that we are using virtual-link to interconnect between areas but there is another way to do that using GRE.

Following Narbik Advanced CCIE R&S Workbook 2.0 here is OSPF LAB 6:

In order to connect area 3 (loopback interface on R1) to area 0, we need to create a link between R2 and R1.
We can use virtual link and configure the following on the routers:
R1:
R1(config-router)#area 1 virtual-link 2.2.2.2
R2:
R2(config-router)#area 1 virtual-link 1.1.1.1
Where 1.1.1.1 and 2.2.2.2 represent Router-ID for each router.

or we can configure GRE tunnel between both routers, take note that GRE does pass broadcast and multicast and often use with IPsec in order to provide this abilities which IPsec doesn't support.

So configuration goes as follows:
R1:
R1(config-router)#network 200.1.12.1 0.0.0.0 area 0
R1(config)#interface tunnel 1
R1(config-if)#ip address 200.1.12.1 255.255.255.0
R1(config-if)#tunnel source 1.1.1.1
R1(config-if)#tunnel destination 2.2.2.2
R2:
R1:
R2(config-router)#network 200.1.12.2 0.0.0.0 area 0
R2(config)#interface tunnel 1
R2(config-if)#ip address 200.1.12.2 255.255.255.0
R2(config-if)#tunnel source 2.2.2.2
R2(config-if)#tunnel destination 1.1.1.1

pay attention that we should advertise the tunnel ip in area 0 else OSPF won't advertise this link and wouldn't be able to exchange routing information.

Friday, October 15, 2010

Cisco IOS Security - Image Resilience

Cisco IOS Image Resilience is part of hardening and securing your Cisco IOS router.

The IOS image or/and the startup configuration can be tampered or corrupted and during downtime failure, the recovery procedure, to bring up the router, can take sometime. You have to load a new IOS image and then a find and load new config file.

In order to save all that and to ensure that during a downtime failure, your router, will be able to recover at a minimum time an IOS Resilience feature has introduced since IOS 12.3(8)T.
The feature maintains a secure working copy of the router image and the startup configuration at all times.

The configuration is made in the global configuration mode:
Router(config)# secure boot-image
to maintain and secure IOS image

Router(config)# secure boot-config
to maintain and secure startup config

to view the configured setting type: Router# show secure bootset

That's All!

Windows Adapter Information

Sometimes we are trying to find out the registry key that represent a network adapter,
For example. in my computer i have two identical network adapters from Realtek model RTL8168C/8111C, I have connected both of them to the same switch and configured one for network access and the other as a SPAN port for packet capturing.
When i starts WireShark i can't tell which one is the LAN and which one is the SPAN?!
Of course i can access the registry and start looking for the regkey settings but a simple and much more convenient way will be to use AdapterWatch utility from NirSoft site.

So here is the link: http://www.nirsoft.net/utils/awatch.zip

Tuesday, October 12, 2010

OSPF Route summarization

In OSPF summarization can occur on 2 types of routers: ABR and/or ASBR.
The internal routes of OSPF can be summarized on an ABR whereas the external (redistributed) routes can be summarized on an ASBR.When a summary on an ABR use the command: area xx range, whereas on an ASBR we will use the command: summary-address.
For example:In OSPF summarization can occur on 2 types of routers: ABR and/or ASBR.
The internal routes of OSPF can be summarized on an ABR whereas the external (redistributed) routes can be summarized on an ASBR.When a summary on an ABR use the command: area xx range, whereas on an ASBR we will use the command: summary-address.
For example:R2 is the ABR and we want to summarize R1 networks into area 1, so we will configure at R2, under router ospf:
area 1 range 1.1.0.0 255.255.252.0

By doing that we will advertise to area 1 (in this case R3) a route summary of 1.1.x.x networks from area 0.

Show ip route, at R3, will show:
R3#sh ip route ospf
1.0.0.0/22 is subnetted, 1 subnets
O IA 1.1.0.0 [110/75] via 10.1.23.2, 04:08:43, FastEthernet0/0
[output omitted]
R2 is the ABR and we want to summarize R1 networks into area 1, so we will configure at R2, under router ospf:
area 1 range 1.1.0.0 255.255.252.0

By doing that we will advertise to area 1 (in this case R3) a route summary of 1.1.x.x networks from area 0.

Show ip route, at R3, will show:
R3#sh ip route ospf
1.0.0.0/22 is subnetted, 1 subnets
O IA 1.1.0.0 [110/75] via 10.1.23.2, 04:08:43, FastEthernet0/0
[output omitted]

While show ip route, at R2, will show:
R2#sh ip route
Codes: C - connected, S - static, 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
i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
ia - IS-IS inter area, * - candidate default, U - per-user static route
o - ODR, P - periodic downloaded static route

Gateway of last resort is not set

1.0.0.0/8 is variably subnetted, 5 subnets, 2 masks
O 1.1.1.1/32 [110/65] via 10.1.12.1, 05:38:56, Serial0/0.21
O 1.1.0.0/22 is a summary, 05:38:56, Null0
O 1.1.0.1/32 [110/65] via 10.1.12.1, 05:38:56, Serial0/0.21
O 1.1.3.1/32 [110/65] via 10.1.12.1, 05:38:56, Serial0/0.21
O 1.1.2.1/32 [110/65] via 10.1.12.1, 05:38:56, Serial0/0.21
C 2.0.0.0/8 is directly connected, Loopback0
[output omitted]

Take note for route to null 0 - In OSPF a discard route is installed automatically when summarization is configured, the discard route prevents routing loops.

In order to remove the discard route use the command: no discard-route internal
under OSPF router config.

Like wise the same concept works for summarization of external routes, routes that are redistributed into OSPF from different source (Static, RIPv2, EIGRP etc.).

For example:
Here i have distributed 5 networks from RIPv2 through R3, which in this case an ASBR.
The summarization should occur on R3 using the following config:
router ospf 1
log-adjacency-changes
summary-address 4.4.0.0 255.255.252.0
network 3.3.3.3 0.0.0.0 area 2
[output omitted]

Show ip route on R2 will shows:
R2#sh ip route
Codes: C - connected, S - static, 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
i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
ia - IS-IS inter area, * - candidate default, U - per-user static route
o - ODR, P - periodic downloaded static route

Gateway of last resort is not set

C 2.0.0.0/8 is directly connected, Loopback0
O E2 4.4.0.0/22 [110/20] via 10.1.23.3, 06:07:50, FastEthernet0/0
[output omitted]

Again, as in the case of the ABR, the OSPF protocol injects discard route automatically, which can be ignored using the command: no discard-route external, under OSPF router config.Take note for route to null 0 - In OSPF a discard route is installed automatically when summarization is configured, the discard route prevents routing loops.

In order to remove the discard route use the command: no discard-route internal
under OSPF router config.

Like wise the same concept works for summarization of external routes, routes that are redistributed into OSPF from different source (Static, RIPv2, EIGRP etc.).

For example:
Here i have distributed 5 networks from RIPv2 through R3, which in this case an ASBR.
The summarization should occur on R3 using the following config:
router ospf 1
log-adjacency-changes
summary-address 4.4.0.0 255.255.252.0
network 3.3.3.3 0.0.0.0 area 2
[output omitted]

Show ip route on R2 will shows:
R2#sh ip route
Codes: C - connected, S - static, 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
i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
ia - IS-IS inter area, * - candidate default, U - per-user static route
o - ODR, P - periodic downloaded static route

Gateway of last resort is not set

C 2.0.0.0/8 is directly connected, Loopback0
O E2 4.4.0.0/22 [110/20] via 10.1.23.3, 06:07:50, FastEthernet0/0
[output omitted]

Again, as in the case of the ABR, the OSPF protocol injects discard route automatically, which can be ignored using the command: no discard-route external, under OSPF router config.

Monday, October 11, 2010

Backup your Life! NOW!

A quite excite headline for this kind of post, but it has to be, due to my last encounter with a laptop of a friend of mine...

We are using a lot of digital information more and more each day, every typical average computer user has files he should keep from harm, starts from documents and excel sheets, which he waste a lot of time to create, through pictures and videos from the latest super mega pixel HD camera up to music collections, pdf books and much more.

Last week one of my friend's has brought me her laptop after he starts to show her "no bootable device found" messages. The laptop, Dell Inspirion 1525, holds 160GB of HDD which can contain quite some of files and digital information. At first she didn't realize the true meaning of losing the disk, she thought that few courses and summaries, from her studies, has gone and that's all! as time pass by she realize that all her photos, music collections, e-mails and much more has lost and she wouldn't have them anymore!!!

Me for example has got more then 2TB of digital information which i care about, so for my opinion, every one should have a backup plan which he accomplish in order to keep his digital "life" safe.

In order to form a home backup plan you first have to answer some crucial questions:
1. Which data should i backup? Which files i can't stand the loss?
2. What is the importance of each one of them? (and I'm not talking about each file rather grouping files into groups)
3. What type of backup should i implement? easy to use, online, one-to-one backup (which can be expansive!) or responsible monthly copy of files?

Later on i will explain my way to home backup plan.

OSPF Designated router (DR) and Backup DR (BDR)

In an OSPF environment all routers floods hellos and LSA's in order to adjacent neighborhood and exchanging routing information.

This kind of behavior is a little problematic , on a multiaccess link, due to the fact that OSPF will form full mesh connectivity between every and each router and will cause waste of bandwidth (with LSA floods).

In order to solve this issue a Designated Router (DR) concept has been made, were an election is preformed, a DR and BDR (Backup DR) are elected, and every router (AllSPFRouter) will adjacent one instance with the DR instead of one instance with every router on a multiaccess link(which can be great sum of instances in a large scale network).

The DR and the BDR election occurs through the use of hello messages, were the router with the highest priority wins. The RID (Router ID) is used as a tie breaker. take note that no preemption can occur, once DR and BDR are elected, no election process is done until both DR and BDR are fails.

After selecting DR and BDR for the multiaccess link, All routers keeps sending hellos to ALLSPFRouters at 224.0.0.5 in order to inform all neighbors about their existence and updates messages to ALLDRouters at 224.0.0.6, which only the DR and BDR are listen to, and update the rest of the routers (DR Others) through ALLSPFRouters (224.0.0.5).

the DR/BDR concept doesn't work for every type of topology, for example LAN interfaces default to use an OSPF network type of broadcast. OSPF broadcast networks elect a DR, use Hellos to dynamically find neighbors, and allow more than two routers to be in the same subnet on that LAN.

For HDLC and PPP links, OSPF uses a network type of point-to-point, meaning that no DR is elected, only two IP addresses are in the subnet, and neighbors can be found through Hellos.


Thursday, October 7, 2010

Playing with OSPF - Part I

First post on this blog i will write on my GNS3 Lab while playing a little bit with OSPF and trying to examine his behavior in different situations.
So here is the setup of the LAB:

i have tried to combine different scenarios to see how it works.