Router Ospf
Router Ospf
Router>enable
Router#erase startup-config
Router(config)#reload
r1(config)#router ospf 1
B1(config)#router ospf 1
B1(config-router)#network 192.168.0.0 0.0.0.255 area 0
B1(config-router)#network 192.168.15.0 0.0.0.3 area 0
B1(config-router)#end
Are there any router interfaces that do not need to have OSPF updates sent out?
bandwidth bandwidth-kbps
R3(config)#interface serial0/0/0
R3(config-if)#ip ospf cost 1562
R3(config-if)#interface serial0/0/1
R3(config-if)#ip ospf cost 1562
R1(config)#ip route 0.0.0.0 0.0.0.0 serial 0/0/0 (loopback or serial exit interface)
R1(config)#router ospf 1
R1(config-router)#default-information originate
R1(config-router)#
R2(config)#interface serial0/0/0
R2(config-if)#ip ospf hello-interval 5
R2(config-if)#ip ospf dead-interval 20
Use the auto-cost reference-bandwidth command to adjust the reference bandwidth value. Increase the reference bandwidth to 10000
to simulate 10GigE speed.
Make sure reference bandwidth is the same on all routers.
Show ip protocols Displays process ID, router ID, networks router is Advertising (receiving updates from) &
administrative distance (110 for ospf)
Show ip ospf Displays process ID, router ID, area info. & the last time SPF algorithm calculated
show interface display bandwidth, most serial link default to 1.544 Mbps
To turn off OSPF, use the following command. Router(config)#no router ospf process-id
R1(config)#interface fastEthernet0/0
R1(config-if)#ip ospf priority 255
R1(config-if)#end
Use the ip ospf priority interface command to change the OSPF priority of R3 to 100.
R3(config)#interface fastEthernet0/0
R3(config-if)#ip ospf priority 100
R3(config-if)#end
Use the ip ospf priority interface command to change the priority of R2 router to 0 A priority of 0
the router to be ineligible to participate and become a DR or BDR.
R2(config)#interface fastEthernet0/0
R2(config-if)#ip ospf priority 0
R2(config-if)#end
Shut down and re-enable the FastEthernet0/0 interfaces to force an OSPF election.
The FastEthernet0/0 interfaces of each of the routers can be shut down and re-enabled to force an OSPF election.
own the FastEthernet0/0 interface on each of the three routers. Notice that as the interfaces are shut down the OSPF
ncies are lost.
You are not required to alter any of these parameters, but some interface parameters must be consistent across all
routers in an attached network.
In interface configuration mode, specify any of Purpose
the following: Command
ip ospf cost cost Explicitly specify the cost of sending a packet on an OSPF
interface.
ip ospf retransmit-interval seconds Specify the number of seconds between link state advertisement
retransmissions for adjacencies belonging to an OSPF interface.
ip ospf transmit-delay seconds Set the estimated number of seconds it takes to transmit a link
state update packet on an OSPF interface.
ip ospf priority number Set router priority to help determine the OSPF designated router
for a network.
ip ospf hello-interval seconds Specify the length of time, in seconds, between the hello packets
that a router sends on an OSPF interface.
ip ospf dead-interval seconds Set the number of seconds that a router’s hello packets must not
have been seen before its neighbors declare the OSPF router
down.
ip ospf authentication-key password Assign a specific password to be used by neighboring OSPF
routers on a network segment that is using OSPF’s simple
password authentication.