interface (Protocols OSPF)
Syntax
interface interface-name { disable; authentication key <key-id identifier>; bfd-liveness-detection { authentication { algorithm algorithm-name; key-chain key-chain-name; loose-check; } detection-time { threshold milliseconds; } minimum-interval milliseconds; minimum-receive-interval milliseconds; transmit-interval { threshold milliseconds; minimum-interval milliseconds; } multiplier number; } dead-interval seconds; demand-circuit; hello-interval seconds; flood-reduction; ipsec-sa name; interface-type type; ldp-synchronization { disable; hold-time seconds; } metric metric; neighbor address <eligible>; no-eligible-backup; no-interface-state-traps; node-link-protection; passive; poll-interval seconds; priority number; retransmit-interval seconds; te-metric metric; secondary; topology (ipv4-multicast | name) { metric metric; } transit-delay seconds; }
Hierarchy Level
[edit logical-systems logical-system-name protocols (ospf | ospf3) area area-id], [edit logical-systems logical-system-name protocols ospf3 realm (ipv4-unicast | ipv4-multicast | ipv6-multicast) area area-id], [edit logical-systems logical-system-name routing-instances routing-instance-name protocols (ospf | ospf3) area area-id], [edit logical-systems logical-system-name routing-instances routing-instance-name protocols ospf3 realm (ipv4-unicast | ipv4-multicast | ipv6-multicast) area area-id], [edit protocols (ospf | ospf3) area area-id], [edit protocols ospf3 realm (ipv4-unicast | ipv4-multicast | ipv6-multicast) area area-id], [edit routing-instances routing-instance-name protocols (ospf | ospf3) area area-id], [edit routing-instances routing-instance-name protocols ospf3 realm (ipv4-unicast | ipv4-multicast | ipv6-multicast) area area-id]
Description
Enable OSPF routing on a routing device interface.
You must include at least one interface
statement
in the configuration to enable OSPF on the routing device.
Options
interface-name | Specify the interface by IP address or interface name
for OSPFv2, or only the interface name for OSPFv3. Using both the
interface name and IP address of the same interface produces an invalid
configuration. To configure all interfaces, you can specify Note:
For nonbroadcast interfaces, specify the IP address of the nonbroadcast interface as interface-name. |
||||
disable | Disable OSPF,
an OSPF interface, or an OSPF virtual link. By default, control packets
sent to the remote end of a virtual link must be forwarded using the
default topology. In addition, the transit area path consists only
of links that are in the default topology. You can disable a virtual
link for a configured topology, but not for a default topology. Include
the Note:
If you disable the virtual link by including the |
||||
dead-interval seconds | Specify how long OSPF waits before declaring that a neighboring routing device is unavailable. This is an interval during which the routing device receives no hello packets from the neighbor. The interval to wait is in seconds, and can range from 1 through 65,535 seconds. The default is four times the hello interval—40 seconds (broadcast and point-to-point networks); 120 seconds (nonbroadcast multiple access (NBMA) networks). |
||||
demand-circuit | Configure an interface as a demand circuit. |
||||
flood-reduction | Specify to send self-generated link-state advertisements (LSAs) with the DoNotAge bit set. As a result, self-originated LSAs are not reflooded every 30 minutes, as required by OSPF by default. An LSA is refreshed only when the content of the LSA changes, which reduces OSPF traffic overhead in stable topologies. |
||||
hello-interval seconds |
Specify how often, in seconds, the routing device sends hello packets out the interface. The hello interval must be the same for all routing devices on a shared logical IP network. The valid range is 1 through 255 seconds. The default is 10 seconds (broadcast and point-to-point networks); 30 seconds (non-broadcast multiple access [NBMA] networks) Note:
For EX Series and QFX Series switches, the hello interval is 10 seconds or longer. |
||||
ipsec-sa name | Apply the named IPsec authentication to the OSPF interface or virtual link or to an OSPFv2 remote sham link. |
||||
ldp-synchronization | Enable synchronization by advertising the maximum cost metric until LDP is operational on the link. LDP distributes labels in non-traffic-engineered applications. Labels are distributed along the best path determined by OSPF. If the synchronization between LDP and OSPF is lost, the label-switched path (LSP) goes down. Therefore, OSPF and LDP synchronization is beneficial. When LDP synchronization is configured and when LDP is not fully operational on a given link (a session is not established and labels are not exchanged), OSPF advertises the link with the maximum cost metric. The link is not preferred but remains in the network topology. LDP synchronization is supported only on point-to-point interfaces
and LAN interfaces configured as point-to-point interfaces under OSPF.
LDP synchronization is not supported during graceful restart. To advertise
the maximum cost metric until LDP is operational for LDP synchronization,
include the
|
||||
metric metric | Specify the cost of an OSPF interface. The cost is a routing metric that is used in the link-state calculation. To set the cost of routes exported into OSPF, configure the appropriate routing policy. Range is 1 through 65,535. By default, the cost of an OSPF route is calculated by dividing the reference-bandwidth value by the bandwidth of the physical interface. Any specific value you configure for the metric overrides the default behavior of using the reference-bandwidth value to calculate the cost of the route for that interface. |
||||
neighbor address <eligible> | For non-broadcast interfaces only, specify neighboring
routers. On a non-broadcast interface, you must specify neighbors
explicitly because OSPF does not send broadcast packets to dynamically
discover their neighbors. To specify multiple neighbors, include multiple
|
||||
no-eligible-backup | Exclude the specified interface as a backup interface for OSPF interfaces on which link protection or node-link protection is enabled. |
||||
no-interface-state-traps | Disable the OSPF traps for interface state changes. This statement is particularly useful for OSPF interfaces in passive mode. Note:
The |
||||
node-link-protection | Enable node-link protection on the specified OSPF interface. Junos OS creates an alternate loop-free path to the primary next hop for all destination routes that traverse a protected interface. This alternate path avoids the primary next-hop router altogether and establishes a path through a different router. Note:
This feature is not supported for the OSPF IPv4 multicast topology or for the OSPFv3 IPv4 multicast or IPv6 multicast topologies because node-link protection creates alternate next-hop paths only for unicast routes. |
||||
poll-interval seconds |
For non-broadcast interfaces only, specify how often, in seconds, the router sends hello packets out of the interface before it establishes adjacency with a neighbor. The valid range is from 1 to 65,535 seconds, and the default is 90 seconds. |
||||
priority number | Specify the routing device’s priority for becoming the designated routing device. The routing device that has the highest priority value on the logical IP network or subnet becomes the network’s designated router. You must configure at least one routing device on each logical IP network or subnet to be the designated router. You also should specify a routing device’s priority for becoming the designated router on point-to-point interfaces. The value number is the device’s priority for becoming the designated router. A priority value of 0 means that the routing device never becomes the designated router. A value of 1 means that the routing device has the least chance of becoming a designated router. The range is 0 through 255, and the default is 128. |
||||
retransmit-interval seconds | Specify how long the routing device waits to receive a link-state acknowledgment packet before retransmitting link-state advertisements (LSAs) to an interface’s neighbors. The range is from 1 through 65,535 seconds, and the default is 5 seconds. Note:
You must configure LSA retransmit intervals to be equal to or greater than 3 seconds to avoid triggering a retransmit trap, because Junos OS delays LSA acknowledgments by up to 2 seconds. |
||||
secondary | Configure an interface to belong to another OSPF area. A logical interface can be configured as primary interface only for one area. For any other area for which you configure the interface, you must configure it as a secondary interface. |
||||
strict-bfd | Enable strict bidirectional forwarding detection over an interface for OSPF. |
||||
te-metric metric | Metric value used by traffic engineering for information injected into the traffic engineering database. The value of the traffic engineering metric does not affect normal OSPF forwarding. Valid metric values can range from 1 through 65,535. The default is the IGP metric value. |
||||
transit-delay seconds | Set the estimated time required to transmit a link-state update on the interface. When calculating this time, make sure to account for transmission and propagation delays. The valid range is 1 through 65,535 seconds, with a default of 1 second. Note:
You should never have to modify the transit delay time. |
The remaining statements are explained separately. See CLI Explorer.
You cannot run both OSPF and ethernet-tcc encapsulation between two Juniper Networks routing devices.
Required Privilege Level
routing—To view this statement in the configuration.
routing-control—To add this statement to the configuration.
Release Information
Statement introduced before Junos OS Release 7.4.
Support for the topology
statement introduced in
Junos OS Release 9.0.
Support for the topology
statement introduced in
Junos OS Release 9.0 for EX Series switches.
Support for the realm
statement introduced in Junos
OS Release 9.2.
Support for the realm
statement introduced in Junos
OS Release 9.2 for EX Series switches.
Support for the no-interface-state-traps
statement
introduced in Junos OS Release 10.3. This statement is supported only
for OSPFv2.