Example: Configuring Active Monitoring on an M, MX or T Series Router’s Logical System
This example shows a sample configuration that allows you to configure active monitoring on a logical M-series, MX-series, T-series, or PTX Series system.
The following section shows the configuration on the primary router:
[edit forwarding-options] sampling { instance inst1 { input { rate 1; } family inet; output { flow-server 198.51.100.2 { port 2055; version9 { template { ipv4; } } } } interface sp-0/1/0 { source-address 10.11.12.13; } } } family mpls; output { flow-server 198.51.100.2 { port 2055; version9 { template { mpls; } } } } interface sp-0/1/0 { source-address 10.11.12.13; } } } services { flow-monitoring { version9 { template ipv4 { flow-active-timeout 60; flow-inactive-timeout 60; ipv4-template; template-refresh-rate { packets 1000; seconds 10; } option-refresh-rate { packets 1000; seconds 10; } } template mpls { mpls-template; } } } }
The configuration for the logical router uses the input parameters and the output interface for sampling from the primary router. Each logical router should have separate template definitions for the flow-server configuration. The following section shows the configuration on the logical router:
logical-systems { ls-1 { firewall { family inet { filter test-sample { term term-1 { then { sample; accept; } } } } } interfaces { ge-0/0/1 { unit 0 { family inet { filter { input test-sample; output test-sample; } } } } } forwarding-options { sampling { instance sample-inst1 { family inet; output { flow-server 198.51.100.2 { port 2055; version9 { template { ipv4-ls1; } } } } } } family mpls; output { flow-server 198.51.100.2 { port 2055; version9 { template { mpls-ls1; } } } } } } } services { flow-monitoring { version9 { template ipv4-ls1 { flow-active-timeout 60; flow-inactive-timeout 60; ipv4-template; template-refresh-rate { packets 1000; seconds 10; } option-refresh-rate { packets 1000; seconds 10; } } template mpls-ls1 { mpls-template; } } } } } }