Redistribute static into OSPF with single area …

Posted: November 4, 2009 in Cisco, Networking

Alhamdulillah ternyata, bisa juga coba2 redistribute static into OSPF . Untuk simulasi kali ini belum dibedain path costnya,,prioritas link masih by default. Berikut network diagramnya…

Screenshot-GNS3 - -home-widodo-Learning By Doing-Cisco-OSPF_working-Network OSPF.net-1

Created By Wiwid

Disini ada 2 routing yg dipakai yaitu OSPF dan static, dimana :
1. R7 – R9 – R8 menggunakan Routing OSPF
2. R7 – R2 – R8 menggunakan Routing Static

Lanjut ya ..

Ada 2 command yang cukup penting,, karena 2 command ini OSPF baru bisa jalan, he.h.e.he.thanks mbah google..2 command ini antara lain :

1. default-information originate, yang fungsinya kurang lebih untuk redistribute default route ke dalam routing protocol dynamic.
2. redistribute connected subnets, kl ga salah sich untuk redistribute interface yang direct connected..moga2 ga salah ..he.he.

Ok berikut hasil show run dari masing2 router…

Router-2

interface Loopback0
ip address 1.1.1.1 255.255.255.255
!
interface FastEthernet0/0
ip address 10.8.8.197 255.255.255.0
ip nat outside
duplex auto
speed auto
!
interface FastEthernet1/0
description B2B To R7 (F1/0)
ip address 172.10.2.1 255.255.255.0
duplex auto
speed auto
!
interface FastEthernet2/0
description B2B To R8 (F2/0)
ip address 172.10.1.1 255.255.255.0
ip nat inside
duplex auto
speed auto
!
ip nat inside source list 1 interface FastEthernet0/0 overload
ip http server
ip classless
ip route 0.0.0.0 0.0.0.0 10.8.8.1
ip route 172.20.1.0 255.255.255.0 172.10.1.2
!

access-list 1 permit 172.10.1.0
access-list 1 permit 172.10.0.0 0.0.255.255

Lah ko ada ip nat bos..ya biar dari router2 dibelakang R2 bisa test koneksi ke internet.. Cuma R9 doank yang belum bisa test koneksi internet,, kl R7 & R8 sdh bisa ke internet..Gpp,, tar lagi cari kenapa NAT nya ga sampe ke R9. lanjut …

Router-8

interface Loopback0
ip address 2.2.2.2 255.255.255.255
!
interface FastEthernet0/0
no ip address
shutdown
duplex auto
speed auto
!
interface FastEthernet0/1
ip address 172.20.1.1 255.255.255.0
ip nat inside
duplex auto
speed auto
!
interface FastEthernet1/0
no ip address
shutdown
duplex auto
speed auto
!
interface FastEthernet2/0
ip address 172.10.1.2 255.255.255.0
ip nat outside
duplex auto
speed auto
!
router ospf 20
router-id 2.2.2.2
log-adjacency-changes
redistribute connected subnets
redistribute static
network 172.20.1.0 0.0.0.255 area 0
neighbor 3.3.3.3
default-information originate
!
ip forward-protocol nd
ip route 0.0.0.0 0.0.0.0 172.10.1.1
ip route 0.0.0.0 0.0.0.0 172.20.1.2 200 name Alternate-Route-R9

Kl itu knp ada route static ke R9, ya sbg backup aja jaga2 kl OSPF nya lepas/down..
Catatan : R7 & R8 merupakan router redistribute, karena di kedua router ini merupakan pertemuan routing OSPF dan routing Static

Router-9

interface Loopback0
ip address 3.3.3.3 255.255.255.0
!
interface FastEthernet0/0
ip address 172.20.2.2 255.255.255.0
duplex auto
speed auto
!
interface FastEthernet0/1
ip address 172.20.1.2 255.255.255.0
duplex auto
speed auto
!
interface FastEthernet1/0
no ip address
shutdown
duplex auto
speed auto
!
interface FastEthernet2/0
no ip address
shutdown
duplex auto
speed auto
!
router ospf 20
router-id 3.3.3.3
log-adjacency-changes
redistribute connected subnets
redistribute static
network 172.20.1.0 0.0.0.255 area 0
network 172.20.2.0 0.0.0.255 area 0
neighbor 4.4.4.4
neighbor 2.2.2.2
default-information originate

ip route 0.0.0.0 0.0.0.0 172.20.1.1 name alternate-to-R8

Disini ada perbedaan sedikit config OSPF nya, dimana list neighbor R9 ada 2 yaitu 4.4.4.4 dan 2.2.2.2.
Ko bisa,, karena R9 terhubung oleh 2 router OSPF. Sedangkan R7 & R8, cukup satu neighbornya yaitu ip loopback R9 : 3.3.3.3

Coba kita lihat show ip ospf neighbor R9 :
Neighbor ID Pri State Dead Time Address Interface
4.4.4.4 1 FULL/BDR 00:00:36 172.20.2.1 FastEthernet0/0
2.2.2.2 1 FULL/BDR 00:00:39 172.20.1.1 FastEthernet0/1

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s