|
|
This chapter explains the function and syntax of the Open Shortest Path First (OSPF) routing commands. For more information about defaults and usage guidelines, see the corresponding chapter of the Cisco IOS IP and IP Routing Command Reference, Release 12.1.
To enable authentication for an OSPF area, use the area authentication router configuration command. To remove an area's authentication specification or a specified area from the configuration, use the no form of this command.
area area-id authentication [message-digest]
Syntax Description
area-id Identifier of the area for which authentication is to be enabled. The identifier can be specified as either a decimal value or an IP address. message-digest (Optional) Enables MD5 authentication on the area specified by area-id.
To specify a cost for the default summary route sent into a stub or NSSA area, use the area default-cost router configuration command. To remove the assigned default route cost, use the no form of this command.
area area-id default-cost cost
Syntax Description
area-id Identifier for the stub or NSSA area. The identifier can be specified as either a decimal value or as an IP address. cost Cost for the default summary route used for a stub or NSSA area. The acceptable value is a 24-bit number.
To configure an area as a not so stubby area (NSSA), use the area nssa router configuration command. To remove the NSSA distinction from the area, use the no form of this command.
area area-id nssa [no-redistribution] [default-information-originate]
Syntax Description
area-id Identifier of the area for which authentication is to be enabled. The identifier can be specified as either a decimal value or an IP address. no-redistribution (Optional) Used when the router is a NSSA ABR and you want the redistribute command to import routes only into the normal areas, but not into the NSSA area. default-information- (Optional) Used to generate a Type 7 default into the NSSA area. This argument only takes effect on NSSA ABR or NSSA ASBR.
originate
To consolidate and summarize routes at an area boundary, use the area range router configuration command. To disable this function, use the no form of this command.
area area-id range address mask [advertise | not-advertise]
Syntax Description
area-id Identifier of the area about which routes are to be summarized. It can be specified as either a decimal value or as an IP address. address IP address. mask IP mask. advertise (Default) Sets the address range status to advertise and generates a Type 3 summary LSA. not-advertise Sets the address range status to DoNotAdvertise. The Type 3 summary LSA is suppressed and the component networks remain hidden from other networks.
To define an area as a stub area, use the area stub router configuration command. To disable this function, use the no form of this command.
area area-id stub [no-summary]
Syntax Description
area-id Identifier for the stub area; either a decimal value or an IP address. no-summary (Optional) Prevents an ABR from sending summary link advertisements into the stub area.
Syntax Description
area-id Area ID assigned to the transit area for the virtual link. This can be either a decimal value or a valid IP address. There is no default. router-id Router ID associated with the virtual link neighbor. The router ID appears in the show ip ospf display. It is internally derived by each router from the router's interface IP addresses. This value must be entered in the format of an IP address. There is no default. authentication (Optional) Specifies authentication type. message-digest (Optional) Specifies that message-digest authentication is used. null (Optional) No authentication is used. Overrides password or message-digest authentication if configured for the area. hello-interval seconds (Optional) Time in seconds between the hello packets that the Cisco IOS software sends on an interface. Unsigned integer value to be advertised in the software's hello packets. The value must be the same for all routers and access servers attached to a common network. The default is 10 seconds. retransmit-interval seconds (Optional) Time in seconds between link state advertisement retransmissions for adjacencies belonging to the interface. Expected round-trip delay between any two routers on the attached network. The value must be greater than the expected round-trip delay. The default is 5 seconds. transmit-delay seconds (Optional) Estimated time in seconds it takes to transmit a link state update packet on the interface. Integer value that must be greater than zero. Link state advertisements in the update packet have their age incremented by this amount before transmission. The default value is 1 second. dead-interval seconds (Optional) Time in seconds that a software's hello packets are not seen before its neighbors declare the router down. Unsigned integer value. The default is four times the hello interval, or 40 seconds. As with the hello interval, this value must be the same for all routers and access servers attached to a common network. authentication-key key (Optional) Password to be used by neighboring routers. Any continuous string of characters that you can enter from the keyboard up to 8 bytes long. This string acts as a key that will allow the authentication procedure to generate or verify the authentication field in the OSPF header. This key is inserted directly into the OSPF header when originating routing protocol packets. A separate password can be assigned to each network on a per-interface basis. All neighboring routers on the same network must have the same password to be able to route OSPF traffic. The password is encrypted in the configuration file if the service password-encryption command is enabled. There is no default value. message-digest-key keyid md5 key (Optional) Key identifier and password to be used by neighboring routers and this router for MD5 authentication. The keyid argument is a number in the range 1 to 255. The key is an alphanumeric string of up to 16 characters. All neighboring routers on the same network must have the same key identifier and key to be able to route OSPF traffic. There is no default value.
To control how OSPF calculates default metrics for the interface, use the auto-cost router configuration command. To assign cost based only on the interface type, use the no form of this command.
auto-cost reference-bandwidth ref-bw
Syntax Description
reference-bandwidth ref-bw Rate in megabits per second (bandwidth). The range is 1 to 4294967; the default is 100.
To generate a default external route into an OSPF routing domain, use the default-information originate router configuration command. To disable this feature, use the no form of this command.
default-information originate [always] [metric metric-value] [metric-type type-value] [route-map map-name]
Syntax Description
always (Optional) Always advertises the default route regardless of whether the software has a default route. metric metric-value (Optional) Metric used for generating the default route. If you omit a value and do not specify a value using the default-metric router configuration command, the default metric value is 10. The value used is specific to the protocol. metric-type type-value (Optional) External link type associated with the default route advertised into the OSPF routing domain. It can be one of the following values: 1---Type 1 external route 2---Type 2 external route The default is Type 2 external route. route-map map-name (Optional) Routing process will generate the default route if the route map is satisfied.
To set default metric values for the OSPF routing protocol, use this form of the default-metric router configuration command. To return to the default state, use the no form of this command.
default-metric number
Syntax Description
number Default metric value appropriate for the specified routing protocol.
To define OSPF route administrative distances based on route type, use the distance ospf router configuration command. To restore the default value, use the no form of this command.
distance ospf {[intra-area dist1] [inter-area dist2] [external dist3]}
Syntax Description
intra-area dist1 (Optional) Sets the distance for all routes within an area. The default value is 110. inter-area dist2 (Optional) Sets the distance for all routes from one area to another area. The default value is 110. external dist3 (Optional) Sets the distance for routes from other routing domains, learned by redistribution. The default value is 110.
To suppress the sending of syslog messages when the router receives LSA Type 6 (MOSPF) packets, which are unsupported, use the ignore lsa mospf router configuration command. To restore the sending of syslog messages, use the no form of this command.
ignore lsa mospfSyntax Description
This command has no arguments or keywords.
To specify the authentication type for an interface, use the ip ospf authentication interface configuration command. To remove the authentication type for an interface, use the no form of this command.
ip ospf authentication [message-digest | null]
Syntax Description
message-digest (Optional) Specifies that message-digest authentication will be used. null (Optional) No authentication is used. Useful for overriding password or message-digest authentication if configured for an interface.
To assign a password to be used by neighboring routers that are using the OSPF simple password authentication, use the ip ospf authentication-key interface configuration command. To remove a previously assigned OSPF password, use the no form of this command.
ip ospf authentication-key password
Syntax Description
password Any continuous string of characters that can be entered from the keyboard up to 8 bytes in length.
To explicitly specify the cost of sending a packet on an interface, use the ip ospf cost interface configuration command. To reset the path cost to the default value, use the no form of this command.
ip ospf cost cost
Syntax Description
cost Unsigned integer value expressed as the link state metric. It can be a value in the range 1 to 65535.
To filter outgoing LSAs to an OSPF interface, use the ip ospf database-filter interface configuration command. To restore the forwarding of LSAs to the interface, use the no form of this command.
ip ospf database-filter all outSyntax Description
This command has no arguments or keywords.
To set the interval at which hello packets must not be seen before neighbors declare the router down, use the ip ospf dead-interval interface configuration command. To return to the default time, use the no form of this command.
ip ospf dead-interval seconds
Syntax Description
seconds Unsigned integer that specifies the interval in seconds; the value must be the same for all nodes on the network.
To configure OSPF to treat the interface as an OSPF demand circuit, use the ip ospf demand-circuit interface configuration command. To remove the demand circuit designation from the interface, use the no form of this command.
ip ospf demand-circuitSyntax Description
This command has no arguments or keywords.
To specify the interval between hello packets that the Cisco IOS software sends on the interface, use the ip ospf hello-interval interface configuration command. To return to the default time, use the no form of this command.
ip ospf hello-interval seconds
Syntax Description
seconds Unsigned integer that specifies the interval in seconds. The value must be the same for all nodes on a specific network.
Syntax Description
keyid An identifier in the range 1 to 255. key Alphanumeric password of up to 16 bytes.
Syntax Description
This command has no arguments or keywords.
Syntax Description
broadcast Sets the network type to broadcast. non-broadcast Sets the network type to NBMA. point-to-multipoint [non-broadcast] Sets the network type to point-to-multipoint. point-to-point Sets the network type to point-to-point.
The optional non-broadcast keyword sets the point-to-multipoint network to be nonbroadcast. If you use the non-broadcast keyword, the neighbor command is required.
Syntax Description
number 8-bit unsigned integer that specifies the priority. The range is from 0 to 255.
To specify the time between link-state advertisement (LSA) retransmissions for adjacencies belonging to the interface, use the ip ospf retransmit-interval interface configuration command. To return to the default value, use the no form of this command.
ip ospf retransmit-interval seconds
Syntax Description
seconds Time in seconds between retransmissions. It must be greater than the expected round-trip delay between any two routers on the attached network. The range is 1 to 65535 seconds. The default is 5 seconds.
To set the estimated time it takes to transmit a link state update packet on the interface, use the ip ospf transmit-delay interface configuration command. To return to the default value, use the no form of this command.
ip ospf transmit-delay seconds
Syntax Description
seconds Time in seconds that it takes to transmit a link state update. The range is 1 to 65535 seconds. The default is 1 second.
To configure the router to send a syslog message when the state of an OSPF neighbor changes, use the log-adj-changes router configuration command. To turn off this function, use the no form of this command.
log-adj-changesSyntax Description
This command has no arguments or keywords.
Syntax Description
ip-address Interface IP address of the neighbor. priority number (Optional) 8-bit number indicating the router priority value of the nonbroadcast neighbor associated with the IP address specified. The default is 0. This keyword does not apply to point-to-multipoint interfaces. poll-interval seconds (Optional) Unsigned integer value reflecting the poll interval. RFC 1247 recommends that this value be much larger than the hello interval. The default is 120 seconds (2 minutes). This keyword does not apply to point-to-multipoint interfaces. cost number (Optional) Assigns a cost to the neighbor, in the form of an integer from 1 to 65535. Neighbors with no specific cost configured will assume the cost of the interface, based on the ip ospf cost command. On point-to-multipoint interfaces, this is the only keyword and argument that make sense. This keyword does not apply to NBMA networks. database-filter (Optional) Filters outgoing LSAs to an OSPF neighbor.
To filter outgoing LSAs to an OSPF neighbor, use the neighbor database-filter router configuration command. To restore the forwarding of LSAs to the neighbor, use the no form of this command.
neighbor ip-address database-filter all out
Syntax Description
ip-address all out IP address of the neighbor to which outgoing LSAs are blocked.
To define the interfaces on which OSPF runs and to define the area ID for those interfaces, use the network area router configuration command. To disable OSPF routing for interfaces defined with the address wildcard-mask pair, use the no form of this command.
network address wildcard-mask area area-id
Syntax Description
address IP address. wildcard-mask IP-address-type mask that includes "don't care" bits. area-id Area that is to be associated with the OSPF address range. It can be specified as either a decimal value or as an IP address. If you intend to associate areas with IP subnets, you can specify a subnet address as the area-id.
To configure an OSPF routing process, use the router ospf global configuration command. To terminate an OSPF routing process, use the no form of this command.
router ospf process-id
Syntax Description
process-id Internally used identification parameter for an OSPF routing process. It is locally assigned and can be any positive integer. A unique value is assigned for each OSPF routing process.
To display general information about OSPF routing processes, use the show ip ospf EXEC command.
show ip ospf [process-id]
Syntax Description
process-id (Optional) Process ID. If this argument is included, only information for the specified routing process is included.
Syntax Description
This command has no arguments or keywords.
To display lists of information related to the OSPF database for a specific router, use the show ip ospf database EXEC command . The various forms of this command deliver information about different OSPF link state advertisements.
show ip ospf [process-id [area-id]] database
Syntax Description
process-id (Optional) Internal identification. It is locally assigned and can be any positive integer. The number used here is the number assigned administratively when enabling the OSPF routing process. area-id (Optional) Area number associated with the OSPF address range defined in the network router configuration command used to define the particular area. link-state-id (Optional) Portion of the Internet environment that is being described by the advertisement. The value entered depends on the advertisement's LS type. It must be entered in the form of an IP address. When the link state advertisement is describing a network, the link-state-id can take one of two forms: When the link state advertisement is describing a router, the link state ID is always the described router's OSPF router ID. When an autonomous system external advertisement (LS Type = 5) is describing a default route, its link state ID is set to Default Destination (0.0.0.0). adv-router [ip-address] (Optional) Displays all the LSAs of the specified router. If no IP address is included, the information is about the local router itself (in this case, the same as self-originate). asbr-summary (Optional) Displays information only about the autonomous system boundary router summary LSAs. database-summary (Optional) Displays how many of each type of LSA for each area there are in the database, and the total. external (Optional) Displays information only about the external LSAs. network (Optional) Displays information only about the network LSAs. nssa-external (Optional) Displays information only about the NSSA external LSAs. opaque-area (Optional) Displays information about the opaque Type 10 LSAs. Type 10 denotes an area-local scope. Refer to RFC 2370 for more information on the opaque LSA options. opaque-as (Optional) Displays information about the opaque Type 11 LSAs. Type 11 denotes that the LSA is flooded throughout the autonomous system (AS). opaque-link (Optional) Displays information about the opaque Type 9 LSAs. Type 9 denotes a link-local scope. router (Optional) Displays information only about the router LSAs. self-originate (Optional) Displays only self-originated LSAs (from the local router). summary (Optional) Displays information only about the summary LSAs.
To display a list of OSPF link state advertisements (LSAs) waiting to be flooded over an interface, use the show ip ospf flood-list EXEC command.
show ip ospf flood-list interface type number
Syntax Description
interface type number Interface type and number over which the LSAs will be flooded.
To display OSPF-related interface information, use the show ip ospf interface EXEC command.
show ip ospf interface [type number]
Syntax Description
type (Optional) Interface type. number (Optional) Interface number.
To display OSPF-neighbor information on a per-interface basis, use the show ip ospf neighbor EXEC command.
show ip ospf neighbor [type number] [neighbor-id] [detail]
Syntax Description
type (Optional) Interface type. number (Optional) Interface number. neighbor-id (Optional) Neighbor ID. detail (Optional) Displays all neighbors given in detail (list all neighbors).
To display a list of all link state advertisements (LSAs) requested by a router, use the show ip ospf request-list EXEC command.
show ip ospf request-list [nbr] [intf] [intf-nbr]
Syntax Description
nbr (Optional) Neighbor. Displays the list of all LSAs requested by the router from this neighbor. intf (Optional) Interface. Displays the list of all LSAs requested by the router from this interface. intf-nbr (Optional) Displays the list of all LSAs requested by the router on this interface from this neighbor.
To display a list of all link state advertisements (LSAs) waiting to be retransmitted, use the show ip ospf retransmission-list EXEC command.
show ip ospf retransmission-list [nbr] [intf] [intf-nbr]
Syntax Description
nbr (Optional) Neighbor. Displays the list of all LSAs waiting to be retransmitted for this neighbor. intf (Optional) Interface. Displays the list of all LSAs waiting to be retransmitted on this interface. intf-nbr (Optional) Displays the list of all LSAs waiting to be retransmitted on this interface from this neighbor.
To display parameters and the current state of OSPF virtual links, use the show ip ospf virtual-links EXEC command.
show ip ospf virtual-linksSyntax Description
This command has no arguments or keywords.
To create aggregate addresses for OSPF, use the summary-address router configuration command. The no summary-address command restores the default.
summary-address address mask prefix mask [not-advertise] [tag tag]
Syntax Description
address Summary address designated for a range of addresses. mask IP subnet mask used for the summary route. prefix IP route prefix for the destination. mask IP subnet mask used for the summary route. not-advertise (Optional) Used to suppress routes that match the prefix/mask pair. This keyword applies to OSPF only. tag tag (Optional) Tag value that can be used as a "match" value for controlling redistribution via route maps. This keyword applies to OSPF only.
To change the interval at which OSPF LSAs are collected into a group and refreshed, checksummed, or aged, use the timers lsa-group-pacing router configuration command. To restore the default value, use the no form of this command.
timers lsa-group-pacing seconds
Syntax Description
seconds Number of seconds in the interval at which LSAs are grouped and refreshed, checksummed, or aged. The range is 10 seconds to 1800 seconds. The default value is 240 seconds.
To configure the delay time between when OSPF receives a topology change and when it starts a shortest path first (SPF) calculation, and the hold time between two consecutive SPF calculations, use the timers spf router configuration command. To return to the default timer values, use the no form of this command.
timers spf spf-delay spf-holdtime
Syntax Description
spf-delay Delay time, in seconds, between when OSPF receives a topology change and when it starts a SPF. calculation. It can be an integer from 0 to 65535. The default time is 5 seconds. A value of 0 means that there is no delay; that is, the SPF calculation is started immediately. spf-holdtime Minimum time, in seconds, between two consecutive SPF calculations. It can be an integer from 0 to 65535. The default time is 10 seconds. A value of 0 means that there is no delay; that is, two consecutive SPF calculations can be done one immediately after the other.
![]()
![]()
![]()
![]()
![]()
![]()
![]()
Posted: Wed Jul 26 14:07:22 PDT 2000
Copyright 1989-2000©Cisco Systems Inc.