interface Serial0/1
ip address 172.16.1.2 255.255.255.252
clock rate 64000
!
interface Serial0/2
ip address 172.16.2.2 255.255.255.252
clock rate 64000
!
interface Serial0/3
ip address 172.16.3.2 255.255.255.252
clock rate 64000
!
router ospf 1
log-adjacency-changes
network 172.16.1.0 0.0.0.3 area 0
network 172.16.2.0 0.0.0.3 area 0
network 172.16.3.0 0.0.0.3 area 0
R1-------------------------------------------------------------------------------------------------
interface FastEthernet0/0
ip address 192.168.1.1 255.255.255.0
duplex auto
speed auto
interface Serial0/0
ip address 172.16.1.1 255.255.255.252
!
router ospf 1
log-adjacency-changes
redistribute rip subnets
network 172.16.1.0 0.0.0.3 area 0
!
router rip
version 2
redistribute ospf 1 metric 1
network 192.168.1.0
no auto-summary
R2-------------------------------------------------------------------------------------------------
interface FastEthernet0/0
ip address 10.10.20.1 255.255.255.0
duplex auto
speed auto
!
interface Serial0/0
ip address 172.16.2.1 255.255.255.252
!
router ospf 1
log-adjacency-changes
area 20 virtual-link 10.10.20.6
network 10.10.20.0 0.0.0.255 area 20
network 172.16.2.0 0.0.0.3 area 0
R3-------------------------------------------------------------------------------------------------
interface FastEthernet0/0
ip address 10.40.1.1 255.255.255.0
duplex auto
speed auto
!
interface Serial0/0
ip address 172.16.3.1 255.255.255.252
!
router ospf 1
log-adjacency-changes
area 40 stub
network 10.40.1.0 0.0.0.255 area 40
network 172.16.3.0 0.0.0.3 area 0
R4-------------------------------------------------------------------------------------------------
interface Loopback21
ip address 21.21.21.1 255.255.255.0
!
interface Loopback22
ip address 22.22.22.1 255.255.255.0
!
interface FastEthernet0/0
ip address 192.168.1.2 255.255.255.0
duplex auto
speed auto
router rip
version 2
network 21.0.0.0
network 22.0.0.0
network 192.168.1.0
no auto-summary
R5-------------------------------------------------------------------------------------------------
interface Loopback11
ip address 11.11.11.1 255.255.255.0
!
interface Loopback12
ip address 12.12.12.1 255.255.255.0
!
interface FastEthernet0/0
ip address 10.40.1.2 255.255.255.0
duplex auto
speed auto
!
router ospf 1
log-adjacency-changes
area 40 stub
network 10.40.1.0 0.0.0.255 area 40
network 11.11.11.0 0.0.0.255 area 40
network 12.12.12.0 0.0.0.255 area 40
R6-------------------------------------------------------------------------------------------------
interface Loopback50
ip address 50.50.50.1 255.255.255.0
!
interface Loopback200
ip address 200.200.20.1 255.255.255.0
!
interface FastEthernet0/0
ip address 10.10.20.6 255.255.255.0
duplex auto
speed auto
!
router ospf 1
log-adjacency-changes
area 20 virtual-link 172.16.2.1
network 10.10.20.0 0.0.0.255 area 20
network 50.50.50.0 0.0.0.255 area 50
network 200.200.20.0 0.0.0.255 area 20
----------------------------------------------------------------------------------------------------
This lab is focus on Stub and Totally Stubby configuration, you can check the detail on Virtual-Link and Redistribution on previous lab
as you can see, we configure area 40 to be the stub area, ok now let's remove those two line first to see the different
on R3 and R5
R3(config)#router os 1
R3(config-router)#no area 40 stub
R5(config)#router ospf 1
R5(config-router)#no area 40 stub
after you remove the Stub area on one of this site, the neighbor will down because one site is configured as Stub and the other is normal area
*Mar 1 08:13:41.341: %OSPF-5-ADJCHG: Process 1, Nbr 10.40.1.2 on FastEthernet0/0 from FULL to DOWN, Neighbor Down: Adjacency forced to reset
after you remove it on both, then both neighbor are form again
*Mar 1 08:15:17.629: %OSPF-5-ADJCHG: Process 1, Nbr 172.16.3.1 on FastEthernet0/0 from LOADING to FULL, Loading Done
now check the routing table on R5
R5#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
200.200.20.0/32 is subnetted, 1 subnets
O IA 200.200.20.1 [110/131] via 10.40.1.1, 00:07:26, FastEthernet0/0
50.0.0.0/32 is subnetted, 1 subnets
O IA 50.50.50.1 [110/131] via 10.40.1.1, 00:07:26, FastEthernet0/0
21.0.0.0/24 is subnetted, 1 subnets
O E2 21.21.21.0 [110/20] via 10.40.1.1, 00:07:26, FastEthernet0/0
172.16.0.0/30 is subnetted, 3 subnets
O IA 172.16.1.0 [110/129] via 10.40.1.1, 00:07:26, FastEthernet0/0
O IA 172.16.2.0 [110/129] via 10.40.1.1, 00:07:26, FastEthernet0/0
O IA 172.16.3.0 [110/65] via 10.40.1.1, 00:07:26, FastEthernet0/0
22.0.0.0/24 is subnetted, 1 subnets
O E2 22.22.22.0 [110/20] via 10.40.1.1, 00:07:26, FastEthernet0/0
10.0.0.0/24 is subnetted, 2 subnets
O IA 10.10.20.0 [110/130] via 10.40.1.1, 00:07:28, FastEthernet0/0
C 10.40.1.0 is directly connected, FastEthernet0/0
11.0.0.0/24 is subnetted, 1 subnets
C 11.11.11.0 is directly connected, Loopback11
12.0.0.0/24 is subnetted, 1 subnets
C 12.12.12.0 is directly connected, Loopback12
O E2 192.168.1.0/24 [110/20] via 10.40.1.1, 00:07:28, FastEthernet0/0
as you can see, there are many type of route inside ( E2, IA.. etc) which mean all the route are being send to this area, but there are no more network beyond this router and do you think it is necessary for this router to have a full routing table and process everything ? after all they only have one gateway to outside.
so this is the situation where Stub configuration become useful, we not just reduce the routing table size, also we can reduce the using of Router resources
just apply back everything that you remove a while ago.. then check the routing table again
200.200.20.0/32 is subnetted, 1 subnets
O IA 200.200.20.1 [110/131] via 10.40.1.1, 00:01:41, FastEthernet0/0
50.0.0.0/32 is subnetted, 1 subnets
O IA 50.50.50.1 [110/131] via 10.40.1.1, 00:01:41, FastEthernet0/0
172.16.0.0/30 is subnetted, 3 subnets
O IA 172.16.1.0 [110/129] via 10.40.1.1, 00:01:41, FastEthernet0/0
O IA 172.16.2.0 [110/129] via 10.40.1.1, 00:01:41, FastEthernet0/0
O IA 172.16.3.0 [110/65] via 10.40.1.1, 00:01:41, FastEthernet0/0
10.0.0.0/24 is subnetted, 2 subnets
O IA 10.10.20.0 [110/130] via 10.40.1.1, 00:01:41, FastEthernet0/0
C 10.40.1.0 is directly connected, FastEthernet0/0
11.0.0.0/24 is subnetted, 1 subnets
C 11.11.11.0 is directly connected, Loopback11
12.0.0.0/24 is subnetted, 1 subnets
C 12.12.12.0 is directly connected, Loopback12
O*IA 0.0.0.0/0 [110/2] via 10.40.1.1, 00:01:42, FastEthernet0/0
notice that route type E2 no more in the routing table (in this case the route distribute from RIP), instead the route is replaced by default route (in yellow)
to know the theory and detail on type of route that not advertised into Stub and Totally Stub you can google for "OSPF LSA type"
now let's configure this area to be a Totally Stubby area, just replace the previous line with this new line on R3 and R5
R3(config)#router os 1
R3(config-router)#area 40 stub no-summary
R5(config)#router os 1
R5(config-router)#area 40 stub no-summary
check the routing table on R5
10.0.0.0/24 is subnetted, 1 subnets
C 10.40.1.0 is directly connected, FastEthernet0/0
11.0.0.0/24 is subnetted, 1 subnets
C 11.11.11.0 is directly connected, Loopback11
12.0.0.0/24 is subnetted, 1 subnets
C 12.12.12.0 is directly connected, Loopback12
O*IA 0.0.0.0/0 [110/2] via 10.40.1.1, 00:00:40, FastEthernet0/0
in Totally Stub area, all type of route are not advertised to him and it's only have one gateway to outside world,
so it depend on your network topology when you want to use Stub or Totally Stubby configuration
I'll try to go more detail on LSA type on next lab.. Happy routing ;)
there'll be a big game later, the race for fourth place! Manchester City face Tottenham in a must-win clash for both clubs' Champions League hopes
I'll try to go more detail on LSA type on next lab.. Happy routing ;)
there'll be a big game later, the race for fourth place! Manchester City face Tottenham in a must-win clash for both clubs' Champions League hopes
nice and simple post
ReplyDelete