Example: Configuring Nonstop Active Routing for PIM
Understanding Nonstop Active Routing for PIM
Nonstop active routing configurations include two Routing Engines that share information so that routing is not interrupted during Routing Engine failover. When nonstop active routing is configured on a dual Routing Engine platform, the PIM control state is replicated on both Routing Engines.
This PIM state information includes:
Neighbor relationships
Join and prune information
RP-set information
Synchronization between routes and next hops and the forwarding state between the two Routing Engines
The PIM control state is maintained on the backup Routing Engine by the replication of state information from the primary to the backup Routing Engine and having the backup Routing Engine react to route installation and modification in the [instance].inet.1 routing table on the primary Routing Engine. The backup Routing Engine does not send or receive PIM protocol packets directly. In addition, the backup Routing Engine uses the dynamic interfaces created by the primary Routing Engine. These dynamic interfaces include PIM encapsulation, de-encapsulation, and multicast tunnel interfaces.
The clear pim join, clear pim register, and clear pim statistics operational mode commands are not supported on the backup Routing Engine when nonstop active routing is enabled.
To enable nonstop active routing for PIM (in addition to the PIM configuration on the primary Routing Engine), you must include the following statements at the [edit] hierarchy level:
chassis redundancy graceful-switchover
routing-options nonstop-routing
system commit synchronize
Example: Configuring Nonstop Active Routing with PIM
This example shows how to configure nonstop active routing for PIM-based multicast IPv4 and IPv6 traffic.
Requirements
For nonstop active routing for PIM-based multicast traffic to work with IPv6, the routing device must be running Junos OS Release 10.4 or above.
Before you begin:
Configure the router interfaces. See the Network Interfaces Configuration Guide.
Configure an interior gateway protocol or static routing. See the Routing Protocols Configuration Guide.
Configure a multicast group membership protocol (IGMP or MLD). See Understanding IGMP and Understanding MLD.
Overview
Junos OS supports nonstop active routing in the following PIM scenarios:
Dense mode
Sparse mode
SSM
Static RP
Auto-RP (for IPv4 only)
Bootstrap router
Embedded RP on the non-RP router (for IPv6 only)
BFD support
Draft Rosen Multicast VPNs and BGP Multicast VPNs (use the
advertise-from-main-vpn-tables
option at the[edit protocols bgp]
hierarchy level, to synchronize MVPN routes, cmcast, provider-tunnel and forwarding information between the primary and the backup Routing Engines).Policy features such as neighbor policy, bootstrap router export and import policies, scope policy, flow maps, and reverse path forwarding (RPF) check policies
In Junos OS release 13.3, multicast VPNs are not supported with nonstop active routing. Policy-based features (such as neighbor policy, join policy, BSR policy, scope policy, flow maps, and RPF check policy) are not supported with nonstop active routing.
This example uses static RP. The interfaces are configured to receive both IPv4 and IPv6 traffic. R2 provides RP services as the local RP. Note that nonstop active routing is not supported on the RP router. The configuration shown in this example is on R1.
Topology
Figure 1 shows the topology used in this example.
Configuration
CLI Quick Configuration
To quickly configure this example, copy the following commands, paste
them into a text file, remove any line breaks, change any details necessary to match your
network configuration, copy and paste the commands into the CLI at the [edit]
hierarchy
level, and then enter commit
from configuration mode.
R1
set system syslog archive size 10m set system syslog file messages any info set system commit synchronize set chassis redundancy graceful-switchover set interfaces traceoptions file dcd-trace set interfaces traceoptions file size 10m set interfaces traceoptions file files 10 set interfaces traceoptions flag all set interfaces so-0/0/1 unit 0 description "to R0 so-0/0/1.0" set interfaces so-0/0/1 unit 0 family inet address 10.210.1.2/30 set interfaces so-0/0/1 unit 0 family inet6 address FDCA:9E34:50CE:0001::2/126 set interfaces fe-0/1/3 unit 0 description "to R2 fe-0/1/3.0" set interfaces fe-0/1/3 unit 0 family inet address 10.210.12.1/30 set interfaces fe-0/1/3 unit 0 family inet6 address FDCA:9E34:50CE:0012::1/126 set interfaces fe-1/1/0 unit 0 description "to H1" set interfaces fe-1/1/0 unit 0 family inet address 10.240.0.250/30 set interfaces fe-1/1/0 unit 0 family inet6 address ::10.240.0.250/126 set interfaces lo0 unit 0 description "R1 Loopback" set interfaces lo0 unit 0 family inet address 10.210.255.201/32 primary set interfaces lo0 unit 0 family iso address 47.0005.80ff.f800.0000.0108.0001.0102.1025.5201.00 set interfaces lo0 unit 0 family inet6 address abcd::10:210:255:201/128 set protocols ospf traceoptions file r1-nsr-ospf2 set protocols ospf traceoptions file size 10m set protocols ospf traceoptions file files 10 set protocols ospf traceoptions file world-readable set protocols ospf traceoptions flag error set protocols ospf traceoptions flag lsa-update detail set protocols ospf traceoptions flag flooding detail set protocols ospf traceoptions flag lsa-request detail set protocols ospf traceoptions flag state detail set protocols ospf traceoptions flag event detail set protocols ospf traceoptions flag hello detail set protocols ospf traceoptions flag nsr-synchronization detail set protocols ospf traffic-engineering set protocols ospf area 0.0.0.0 interface so-0/0/1.0 metric 100 set protocols ospf area 0.0.0.0 interface fe-0/1/3.0 metric 100 set protocols ospf area 0.0.0.0 interface lo0.0 passive set protocols ospf area 0.0.0.0 interface fxp0.0 disable set protocols ospf area 0.0.0.0 interface fe-1/1/0.0 passive set protocols ospf3 traceoptions file r1-nsr-ospf3 set protocols ospf3 traceoptions file size 10m set protocols ospf3 traceoptions file world-readable set protocols ospf3 traceoptions flag lsa-update detail set protocols ospf3 traceoptions flag flooding detail set protocols ospf3 traceoptions flag lsa-request detail set protocols ospf3 traceoptions flag state detail set protocols ospf3 traceoptions flag event detail set protocols ospf3 traceoptions flag hello detail set protocols ospf3 traceoptions flag nsr-synchronization detail set protocols ospf3 area 0.0.0.0 interface fe-1/1/0.0 passive set protocols ospf3 area 0.0.0.0 interface fe-1/1/0.0 metric 1 set protocols ospf3 area 0.0.0.0 interface lo0.0 passive set protocols ospf3 area 0.0.0.0 interface so-0/0/1.0 metric 1 set protocols ospf3 area 0.0.0.0 interface fe-0/1/3.0 metric 1 set protocols pim traceoptions file r1-nsr-pim set protocols pim traceoptions file size 10m set protocols pim traceoptions file files 10 set protocols pim traceoptions file world-readable set protocols pim traceoptions flag mdt detail set protocols pim traceoptions flag rp detail set protocols pim traceoptions flag register detail set protocols pim traceoptions flag packets detail set protocols pim traceoptions flag autorp detail set protocols pim traceoptions flag join detail set protocols pim traceoptions flag hello detail set protocols pim traceoptions flag assert detail set protocols pim traceoptions flag normal detail set protocols pim traceoptions flag state detail set protocols pim traceoptions flag nsr-synchronization set protocols pim rp static address 10.210.255.202 set protocols pim rp static address abcd::10:210:255:202 set protocols pim interface lo0.0 set protocols pim interface fe-0/1/3.0 mode sparse set protocols pim interface fe-0/1/3.0 version 2 set protocols pim interface so-0/0/1.0 mode sparse set protocols pim interface so-0/0/1.0 version 2 set protocols pim interface fe-1/1/0.0 mode sparse set protocols pim interface fe-1/1/0.0 version 2 set policy-options policy-statement load-balance then load-balance per-packet set routing-options nonstop-routing set routing-options router-id 10.210.255.201 set routing-options forwarding-table export load-balance set routing-options forwarding-table traceoptions file r1-nsr-krt set routing-options forwarding-table traceoptions file size 10m set routing-options forwarding-table traceoptions file world-readable set routing-options forwarding-table traceoptions flag queue set routing-options forwarding-table traceoptions flag route set routing-options forwarding-table traceoptions flag routes set routing-options forwarding-table traceoptions flag synchronous set routing-options forwarding-table traceoptions flag state set routing-options forwarding-table traceoptions flag asynchronous set routing-options forwarding-table traceoptions flag consistency-checking set routing-options traceoptions file r1-nsr-sync set routing-options traceoptions file size 10m set routing-options traceoptions flag nsr-synchronization set routing-options traceoptions flag commit-synchronize
Procedure
Step-by-Step Procedure
The following example requires you to navigate various levels in the configuration hierarchy. For information about navigating the CLI, see Using the CLI Editor in Configuration Mode in the Junos OS CLI User Guide.
To configure nonstop active routing on R1:
Synchronize the Routing Engines.
[edit] user@host# edit system [edit system] user@host# set commit synchronize user@host# exit
Enable graceful Routing Engine switchover.
[edit] user@host# set chassis redundancy graceful-switchover
Configure R1’s interfaces.
[edit] user@host# edit interfaces [edit interfaces] user@host# set so-0/0/1 unit 0 description "to R0 so-0/0/1.0" user@host# set so-0/0/1 unit 0 family inet address 10.210.1.2/30 user@host# set so-0/0/1 unit 0 family inet6 address FDCA:9E34:50CE:0001::2/126 user@host# set fe-0/1/3 unit 0 description "to R2 fe-0/1/3.0" user@host# set fe-0/1/3 unit 0 family inet address 10.210.12.1/30 user@host# set fe-0/1/3 unit 0 family inet6 address FDCA:9E34:50CE:0012::1/126 user@host# set fe-1/1/0 unit 0 description "to H1" user@host# set fe-1/1/0 unit 0 family inet address 10.240.0.250/30 user@host# set fe-1/1/0 unit 0 family inet6 address ::10.240.0.250/126 user@host# set lo0 unit 0 description "R1 Loopback" user@host# set lo0 unit 0 family inet address 10.210.255.201/32 primary user@host# set lo0 unit 0 family iso address 47.0005.80ff.f800.0000.0108.0001.0102.1025.5201.00 user@host# set lo0 unit 0 family inet6 address abcd::10:210:255:201/128 user@host# exit
Configure OSPF for IPv4 on R1.
[edit] user@host# edit protocols ospf [edit protocols ospf] user@host# set traffic-engineering user@host# set area 0.0.0.0 interface so-0/0/1.0 metric 100 user@host# set area 0.0.0.0 interface fe-0/1/3.0 metric 100 user@host# set area 0.0.0.0 interface lo0.0 passive user@host# set area 0.0.0.0 interface fxp0.0 disable user@host# set area 0.0.0.0 interface fe-1/1/0.0 passive
Configure OSPF for IPv6 on R1.
[edit] user@host# edit protocols ospf3 [edit protocols ospf3] user@host# set area 0.0.0.0 interface fe-1/1/0.0 passive user@host# set area 0.0.0.0 interface fe-1/1/0.0 metric 1 user@host# set area 0.0.0.0 interface lo0.0 passive user@host# set area 0.0.0.0 interface so-0/0/1.0 metric 1 user@host# set area 0.0.0.0 interface fe-0/1/3.0 metric 1
Configure PIM on R1. The PIM static address points to the RP router (R2).
[edit] user@host# edit [edit protocols pim] user@host# set protocols pim rpstatic address 10.210.255.202 user@host# set protocols pim rp static address abcd::10:210:255:202 user@host# set protocols pim interface (Protocols PIM) lo0.0 user@host# set protocols pim interface fe-0/1/3.0 mode sparse user@host# set protocols pim interface fe-0/1/3.0 version 2 user@host# set protocols pim interface so-0/0/1.0 mode sparse user@host# set protocols pim interface so-0/0/1.0 version 2 user@host# set protocols pim interface fe-1/1/0.0 mode sparse user@host# set protocols pim interface fe-1/1/0.0 version 2
Configure per-packet load balancing on R1.
[edit] user@host# edit policy-options policy-statement load-balance [edit policy-options policy-statement load-balance] user@host# set then load-balance per-packet
Apply the load-balance policy on R1.
[edit] user@host# set routing-options forwarding-table export load-balance
Configure nonstop routing on R1.
[edit] user@host# set routing-options nonstop-routing user@host# set routing-options router-id 10.210.255.201
Step-by-Step Procedure
For troubleshooting, configure system log and tracing operations.
Enable system log messages.
[edit] user@host# set system syslog archive size 10m user@host# set system syslog file messages any info
Trace interface operations.
[edit] user@host# set interfaces traceoptions file dcd-trace user@host# set interfaces traceoptions file size 10m user@host# set interfaces traceoptions file files 10 user@host# set interfaces traceoptions flag all
Trace IGP operations for IPv4.
[edit] user@host# set protocols ospf traceoptions file r1-nsr-ospf2 user@host# set protocols ospf traceoptions file size 10m user@host# set protocols ospf traceoptions file files 10 user@host# set protocols ospf traceoptions file world-readable user@host# set protocols ospf traceoptions flag error user@host# set protocols ospf traceoptions flag lsa-update detail user@host# set protocols ospf traceoptions flag flooding detail user@host# set protocols ospf traceoptions flag lsa-request detail user@host# set protocols ospf traceoptions flag state detail user@host# set protocols ospf traceoptions flag event detail user@host# set protocols ospf traceoptions flag hello detail user@host# set protocols ospf traceoptions flag nsr-synchronization detail
Trace IGP operations for IPv6.
[edit] user@host# set protocols ospf3 traceoptions file r1-nsr-ospf3 user@host# set protocols ospf3 traceoptions file size 10m user@host# set protocols ospf3 traceoptions file world-readable user@host# set protocols ospf3 traceoptions flag lsa-update detail user@host# set protocols ospf3 traceoptions flag flooding detail user@host# set protocols ospf3 traceoptions flag lsa-request detail user@host# set protocols ospf3 traceoptions flag state detail user@host# set protocols ospf3 traceoptions flag event detail user@host# set protocols ospf3 traceoptions flag hello detail user@host# set protocols ospf3 traceoptions flag nsr-synchronization detail
Trace PIM operations.
[edit] user@host# set protocols pim traceoptions file r1-nsr-pim user@host# set protocols pim traceoptions file size 10m user@host# set protocols pim traceoptions file files 10 user@host# set protocols pim traceoptions file world-readable user@host# set protocols pim traceoptions flag mdt detail user@host# set protocols pim traceoptions flag rp detail user@host# set protocols pim traceoptions flag register detail user@host# set protocols pim traceoptions flag packets detail user@host# set protocols pim traceoptions flag autorp detail user@host# set protocols pim traceoptions flag join detail user@host# set protocols pim traceoptions flag hello detail user@host# set protocols pim traceoptions flag assert detail user@host# set protocols pim traceoptions flag normal detail user@host# set protocols pim traceoptions flag state detail user@host# set protocols pim traceoptions flag nsr-synchronization
Trace all routing protocol functionality.
[edit] user@host# set routing-options traceoptions file r1-nsr-sync user@host# set routing-options traceoptions file size 10m user@host# set routing-options traceoptions flag nsr-synchronization user@host# set routing-options traceoptions flag commit-synchronize
Trace forwarding table operations.
[edit] user@host# set routing-options forwarding-table traceoptions file r1-nsr-krt user@host# set routing-options forwarding-table traceoptions file size 10m user@host# set routing-options forwarding-table traceoptions file world-readable user@host# set routing-options forwarding-table traceoptions flag queue user@host# set routing-options forwarding-table traceoptions flag route user@host# set routing-options forwarding-table traceoptions flag routes user@host# set routing-options forwarding-table traceoptions flag synchronous user@host# set routing-options forwarding-table traceoptions flag state user@host# set routing-options forwarding-table traceoptions flag asynchronous user@host# set routing-options forwarding-table traceoptions flag consistency-checking
If you are done configuring the device, commit the configuration.
[edit] user@host# commit
Results
From configuration mode, confirm your configuration by entering the show chassis, show interfaces, show policy-options, show protocols, show routing-options, and show system commands. If the output does not display the intended configuration, repeat the configuration instructions in this example to correct it.
user@host# show chassis redundancy { graceful-switchover; }
user@host# show interfaces traceoptions { file dcd-trace size 10m files 10; flag all; } so-0/0/1 { unit 0 { description "to R0 so-0/0/1.0"; family inet { address 10.210.1.2/30; } family inet6 { address FDCA:9E34:50CE:0001::2/126; } } } fe-0/1/3 { unit 0 { description "to R2 fe-0/1/3.0"; family inet { address 10.210.12.1/30; } family inet6 { address FDCA:9E34:50CE:0012::1/126; } } } fe-1/1/0 { unit 0 { description "to H1"; family inet { address 10.240.0.250/30; } family inet6 { address ::10.240.0.250/126; } } } lo0 { unit 0 { description "R1 Loopback"; family inet { address 10.210.255.201/32 { primary; } } family iso { address 47.0005.80ff.f800.0000.0108.0001.0102.1025.5201.00; } family inet6 { address abcd::10:210:255:201/128; } } }
user@host# show policy-options policy-statement load-balance { then { load-balance per-packet; } }
user@host# show protocols ospf { traceoptions { file r1-nsr-ospf2 size 10m files 10 world-readable; flag error; flag lsa-update detail; flag flooding detail; flag lsa-request detail; flag state detail; flag event detail; flag hello detail; flag nsr-synchronization detail; } traffic-engineering; area 0.0.0.0 { interface so-0/0/1.0 { metric 100; } interface fe-0/1/3.0 { metric 100; } interface lo0.0 { passive; } interface fxp0.0 { disable; } interface fe-1/1/0.0 { passive; } } } ospf3 { traceoptions { file r1-nsr-ospf3 size 10m world-readable; flag lsa-update detail; flag flooding detail; flag lsa-request detail; flag state detail; flag event detail; flag hello detail; flag nsr-synchronization detail; } area 0.0.0.0 { interface fe-1/1/0.0 { passive; metric 1; } interface lo0.0 { passive; } interface so-0/0/1.0 { metric 1; } interface fe-0/1/3.0 { metric 1; } } } pim { traceoptions { file r1-nsr-pim size 10m files 10 world-readable; flag mdt detail; flag rp detail; flag register detail; flag packets detail; flag autorp detail; flag join detail; flag hello detail; flag assert detail; flag normal detail; flag state detail; flag nsr-synchronization; } rp { static { address 10.210.255.202; address abcd::10:210:255:202; } } interface lo0.0; interface fe-0/1/3.0 { mode sparse; version 2; } interface so-0/0/1.0 { mode sparse; version 2; } interface fe-1/1/0.0 { mode sparse; version 2; } }
user@host# show routing-options traceoptions { file r1-nsr-sync size 10m; flag nsr-synchronization; flag commit-synchronize; } nonstop-routing; router-id 10.210.255.201; forwarding-table { traceoptions { file r1-nsr-krt size 10m world-readable; flag queue; flag route; flag routes; flag synchronous; flag state; flag asynchronous; flag consistency-checking; } export load-balance; }
user@host# show system syslog { archive size 10m; file messages { any info; } } commit synchronize;
Verification
To verify the configuration, run the following commands:
show pim join extensive
show pim neighbors inet detail
show pim neighbors inet6 detail
show pim rps inet detail
show pim rps inet6 detail
show multicast route inet extensive
show multicast route inet6 extensive
show route table inet.1 detail
show route table inet6.1 detail
Configuring PIM Sparse Mode Graceful Restart
You can configure PIM sparse mode to continue to forward existing multicast packet streams during a routing process failure and restart. Only PIM sparse mode can be configured this way. The routing platform does not forward multicast packets for protocols other than PIM during graceful restart, because all other multicast protocols must restart after a routing process failure. If you configure PIM sparse-dense mode, only sparse multicast groups benefit from a graceful restart.
The routing platform does not forward new streams until after the restart is complete. After restart, the routing platform refreshes the forwarding state with any updates that were received from neighbors during the restart period. For example, the routing platform relearns the join and prune states of neighbors during the restart, but it does not apply the changes to the forwarding table until after the restart.
When PIM sparse mode is enabled, the routing platform generates a unique 32-bit random number called a generation identifier. Generation identifiers are included by default in PIM hello messages, as specified in the Internet draft draft-ietf-pim-sm-v2-new-10.txt. When a routing platform receives PIM hello messages containing generation identifiers on a point-to-point interface, the Junos OS activates an algorithm that optimizes graceful restart.
Before PIM sparse mode graceful restart occurs, each routing platform creates a generation identifier and sends it to its multicast neighbors. If a routing platform with PIM sparse mode restarts, it creates a new generation identifier and sends it to neighbors. When a neighbor receives the new identifier, it resends multicast updates to the restarting router to allow it to exit graceful restart efficiently. The restart phase is complete when the restart duration timer expires.
Multicast forwarding can be interrupted in two ways. First, if the underlying routing protocol is unstable, multicast RPF checks can fail and cause an interruption. Second, because the forwarding table is not updated during the graceful restart period, new multicast streams are not forwarded until graceful restart is complete.
You can configure graceful restart globally or for a routing instance. This example shows how to configure graceful restart globally.
To configure graceful restart for PIM sparse mode:
See Also
Change History Table
Feature support is determined by the platform and release you are using. Use Feature Explorer to determine if a feature is supported on your platform.