Starts OSPF process 100. The process ID is any positive integer value between 1 and 65,535. The process ID is not related to the OSPF area. The process ID merely distinguishes one process from another within the device:
Router(config)# router ospf 100
OSPF advertises interfaces, not networks. Uses the wildcard mask to determine which interfaces to advertise. Read this line to say “Any interface with an address of 172.16.10.x is to be put into area 0.” Router(config-router)# network 172.16.10.0 0.0.0.255 area 0
NOTE: The process ID number of one router does not have to match the process ID of any other router. Unlike Enhanced Interior Gateway Routing Protocol (EIGRP), matching this number across all routers does not ensure that network adjacencies will form.
Configures the router to send a syslog message when thereis a change of state between OSPF neighbors.
Router(config-router)# log-adjacency-changes detail
TIP: Although the log-adjacency-changes command is on by default, only up/down events are reported unless you use the detail keyword.
TIP: An octet of all 0s means that the octet has to match exactly to the address. An octet of all 1s means that the octet can be ignored.
Read this line to say “Any interface with an exact address of 172.16.10.1 is to be put into area 0.”
Router(config-router)# network 172.16.10.1 0.0.0.0 area 0
Read this line to say “Any interface with an address of 172.16.x.x is to be put into area 0.”
Router(config-router)# network 172.16.10.0 0.0.255.255 area 0
Creates a virtual interface named loopback 0, and then moves the router to interface configuration mode.
Router(config)# interface loopback 0
Assigns the IP address to the interface.
Router(config-if)# ip address 192.168.100.1 255.255.255.255
NOTE: Loopback interfaces are always “up and up” and do not go down unless manually shut down. This makes loopback interfaces great for use as OSPF router IDs.
Starts OSPF process 1.
Router(config)# router ospf 1
Sets the router ID to 10.1.1.1. If this command is used on an OSPF router process that is already active (has neighbors), the new router ID is used at the next reload or at a manual OSPF process restart.
Router(config-router)# router-id 10.1.1.1
Removes the static router ID from the configuration. If this command is used on an OSPF router process that is already active (has neighbors), the old router ID behavior is used at the next reload or at a manual OSPF process restart.
Router(config-router)# no router-id 10.1.1.1
Changes the router to interface configuration mode.
Router(config)# interface serial 0/0
Changes the OSPF interface priority to 50.
Router(config-if)# ip ospf priority 50
NOTE: The assigned priority can be between 0 and 255. A priority of 0 makes the router ineligible to become a designated router (DR) or backup designated router BDR). The highest priority wins the election. A priority of 255 guarantees a tie in the election. If all routers have the same priority, regardless of the priority number, they tie. Ties are broken by the highest router ID.
Changes the router to interface configuration mode.
Router(config)# interface serial 0/0
If you change the bandwidth, OSPF recalculates the cost of the link.
Router(config-if)# bandwidth 128
Starts OSPF process 10.
Router(config)# router ospf 10
Enables simple authentication; password will be sent in clear text.
Router(config-router)# area 0 authentication
Moves to interface configuration mode.
Router(config)# interface fastethernet 0/0
Sets key (password) to zelda.
Router(config-if)# ip ospf authentication-key zelda
NOTE: The password can be any continuous string of characters that can be entered from the keyboard, up to 8 bytes in length. To be able to exchange OSPF information, all neighboring routers on the same network must have the same password.
Starts OSPF process 1.
Router(config)# router ospf 1
Enables authentication with MD5 password encryption.
Router(config-router)# area 0 authentication message-digest
Moves to interface configuration mode.
Router(config)# interface fastethernet 0/0
1 is the key-id. This value must be the same as that of your neighboring router. md5 indicates that the MD5 hash algorithm will be used. zelda is the key (password) and must be the same as that of your neighboring router.
Router(config-if)# ip ospf message-digest-key 1 md5 zelda
NOTE: If the service password-encryption command is not used when implementing OSPF MD5 authentication, the MD5 secret is stored as plain text in NVRAM.
Changes the Hello Interval timer to 20 seconds.
Router(config-if)# ip ospf hello-interval timer 20
Changes the Dead Interval timer to 80 seconds.
Router(config-if)# ip ospf dead-interval 80
NOTE: Hello and Dead Interval timers must match for routers to become neighbors.
Creates a default route.
Router(config)# ip route 0.0.0.0 0.0.0.0 s0/0
Starts OSPF process 10.
Router(config)# router ospf 10
Sets the default route to be propagated to all OSPF routers.
Router(config-router)# default-information originate
Displays parameters for all protocols running on the router.
Router# show ip protocol
Displays a complete IP routing table.
Router# show ip route
Displays basic information about OSPF routing processes
Router# show ip ospf
Displays OSPF info as it relates to all interfaces
Router# show ip ospf interface
Displays border and boundary router information.
Router# show ip ospf border-routers
Lists all OSPF neighbors and their states
Router# show ip ospf neighbor
Displays a detailed list of neighbors
Router# show ip ospf neighbor detail
Displays contents of the OSPF database
Router# show ip ospf database
Clears entire routing table, forcing it to rebuild
Router# clear ip route *
Clears specific route to network a.b.c.d
Router# clear ip route a.b.c.d
Resets OSPF counters
Router# clear ip opsf counters
Resets entire OSPF process, forcing OSPF to re-create neighbors, database, and routing table
Router# clear ip ospf process
Displays all OSPF events
Router# debug ip ospf events
Displays various OSPF states and DR/BDR election between adjacent routers:
Router# debug ip ospf adjacency
Dsplays OSPF packets
Router# debug ip ospf packets
biOos
No comments:
Post a Comment